3

The Yoast SEO plugin for wordpress creates an XML sitemap with the file name sitemap_index.xml. There is another sitemap plugin (Google XML Sitemaps) in the Wordpress site I'm working on that creates a sitemap named sitemap.xml.

Unfortunately I don't know too much about SEO stuff. The top result in Google when searching for the answer to my question is this StackOverflow post that seems to say that it DOES matter for search engines other than Google: https://stackoverflow.com/questions/23041115/what-should-be-the-name-of-sitemap-file-while-submitting-to-google-webmasters. It says to use sitemap.xml. But I'm doubtful of the accuracy of this claim. Also, the sitemap that YoastSEO generates is preferable for my client but it doesn't look like there is a way to configure the name of the sitemap file.

So I thought I would ask the experts here to get a definitive answer. Does it matter that the YoastSEO plugin generates a sitemap with a seemingly non-standard filename?

3

No, the name does not matter. In the Google Search Console (and the Bing version of that, FWIW), you tell it which sitemaps to look at. Other search engines might look for sitemap.xml by default but this is not guaranteed nor standard behavior and doesn't really need to be worried about.

  • 1
    Thanks. After doing a little bit more research on the matter, it looks like there is a "Sitemap" directive you can add to robots.txt to tell the search engines the path to your sitemap file. What is our opinion about this? If you agree, can you add it to your answer? See here and here – Kodos Johnson Jan 11 '17 at 21:33
  • My opinion is largely unchanged in that if you use Google Search Console to make the sitemap available, nothing else needs to be done. If you have the kind of site that attracts people who won't use Google for whatever reason, then using robots.txt makes more sense so as to be accessible to DuckDuckGo or other boutique engines. – JCL1178 Jan 12 '17 at 17:38
  • But since Google suggests adding that line to robots.txt as an alternative, wouldn't it be best to do that instead to handle all search engines? – Kodos Johnson Jan 13 '17 at 21:44
  • Kind of getting off-topic from the original question here, but anything you try to do with other search engines and robots.txt is wholly dependent on the spider requesting robots.txt and honoring the directives found there. So the assumption that robots.txt will inform all spiders is probably specious. tl;dr it can't hurt, so do it anyway but use GSC to register sitemaps because that ALWAYS works. – JCL1178 Jan 15 '17 at 0:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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