Can I include canonical URLs in sitemap for SEO?

6.4k views Asked by At

Can I include canonical URLs in sitemaps for SEO?

For example www.example.com/url.html is a duplicate page of www.example2.com/url.html.

So I used following tag in www.example.com/url.html page for SEO not to be penalized by search engines:

<link rel="canonical" href="www.example2.com/url.html">

Now my question is can I display www.example.com/url.html URL inside of www.example.com/sitemap.xml?

I already display www.example2.com/url.html URL inside of www.example2.com/sitemap.xml.

Please suggest me what I have to do.

2

There are 2 answers

0
Zistoloen On BEST ANSWER

You can include these two pages into your sitemap.xml and there won't be a problem for SEO because you're using the rel="canonical" tag. Indeed, when web crawlers will try to index the duplicate page, they will see the rel="canonical" tag and they will index the second page (the good one).

1
praktik_man On

For better index you must leave one URL - canonical URL in XML site map