Skip to content

Magento2.4.3: How to stop adding non-canonical url from in sitemap.xml?

I have 400k products in my store and when I generate a sitemap it contains non-canonical URL, is there any way I can stop adding non-canonical URLs in sitemap.xml,
and still be able to generate sitemap.
any idea?
Thanks