3

I'm working on the sitemaps of a multilingual website and I have a doubt regarding the best practice for referencing each language version of a page.

For a bit of background, the website references around 20 000 places with comments from the community and descriptions. The website is available in 5 languages (website.com/fr; website.com/it...)

For the moment, my sitemap only references english pages and in the sitemap for each page I specify <xhtml:link rel="alternate" hreflang="en" href="URL"/> for each language (as well as English) as Google recommends.

In the Google Search Console, I see that about 75% of the pages with valid coverage are described as "indexed, not submitted in Sitemap" which makes me think that the alternate link with hreflang attribute is not enough to "submit" the page for google to index it.

Do I need to list the pages in all 5 languages in my sitemap and use as well <xhtml:link rel="alternate" hreflang="en"... on each link?

1 Answer 1

2

Just to begin a question: do you have certain Search Console properties for each language? If not - consider to establish.

According to my experience it should be enough to have such setup as you have it - one sitemap with all hreflangs. But such setups are pretty error-prone. There are many factors influencing 100% retrieving of sitemap urls - it is not possible to make a remote diagnose for this issue. Maybe you attach your sitemap to make it easier.

But i'll do the first try. According to your question, "Do I need to list the pages in all 5 languages in my sitemap", it seems, that you list in your sitemap only your english urls with corresponding hreflang urls. Like this:

  <url>
    <loc>http://www.example.com/english/page1.html</loc>
    <xhtml:link 
               rel="alternate"
               hreflang="de"
               href="http://www.example.com/deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="de-ch"
               href="http://www.example.com/schweiz-deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="en"
               href="http://www.example.com/english/page1.html"/>
  </url>
  <url>

    <url>
    <loc>http://www.example.com/english/page2.html</loc>
    <xhtml:link 
               rel="alternate"
               hreflang="de"
               href="http://www.example.com/deutsch/page2.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="de-ch"
               href="http://www.example.com/schweiz-deutsch/page2.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="en"
               href="http://www.example.com/english/page2.html"/>
  </url>
  <url>

But, according to Google, one should list ALL urls in this sitemap - means, if you list an english page as <loc></loc> with corresponding german hreflang url, so you should list the german url as <loc></loc> too, with corresponding english hreflang url. So, if you have three different language urls, you should have in the sitemap three <url></url> blocks, like this:

  <url>
    <loc>http://www.example.com/english/page1.html</loc>
    <xhtml:link 
               rel="alternate"
               hreflang="de"
               href="http://www.example.com/deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="de-ch"
               href="http://www.example.com/schweiz-deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="en"
               href="http://www.example.com/english/page1.html"/>
  </url>

    <url>
    <loc>http://www.example.com/deutsch/page1.html</loc>
    <xhtml:link 
               rel="alternate"
               hreflang="de"
               href="http://www.example.com/deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="de-ch"
               href="http://www.example.com/schweiz-deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="en"
               href="http://www.example.com/english/page1.html"/>
  </url>

    <url>
    <loc>http://www.example.com/schweiz-deutsch/page1.html</loc>
    <xhtml:link 
               rel="alternate"
               hreflang="de"
               href="http://www.example.com/deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="de-ch"
               href="http://www.example.com/schweiz-deutsch/page1.html"/>
    <xhtml:link 
               rel="alternate"
               hreflang="en"
               href="http://www.example.com/english/page1.html"/>
  </url>
5
  • Thanks! That's what I ended up doing. It makes a lot of files (130 sitemaps including 90 with 1000 URLs each) but it seems like it's the best way indeed.
    – EdouardF
    Commented Sep 20, 2019 at 12:50
  • Newb mistake I guess, but I just realized (based on what you said at the beginning of your comment), that i'm adding all the sitemaps on my website.com property whereas I think you're recommending adding website.com/fr as a property and putting the french sitemaps there. Am I correct ?
    – EdouardF
    Commented Sep 20, 2019 at 13:02
  • exact: each language folder into own property. and corresponding sitemap into it.
    – Evgeniy
    Commented Sep 20, 2019 at 13:15
  • "But, according to Google, one should list ALL urls in this sitemap" - Do you have a reference URL for this (I mean, for what Google say)? BTW, I found the same 'error' reported by Merkle hreflang Tags Testing Tool which allows testing a sitemap, so I don't doubt that you are correct.
    – Jake
    Commented Jul 11, 2020 at 1:22
  • PS. This also solves the problem: how to provide localized titles and captions for images in a sitemap (in image:title and image:caption where xmlns:image="http://www.google.com/schemas/sitemap-image/1.1").
    – Jake
    Commented Jul 11, 2020 at 3:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.