Webmasters Stack Exchange is a question and answer site for pro webmasters. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have been arguing a point and would like a second opinion. The basic point of contention is as follows:

We have a site X with a sitemap index file located at:


This file lists a number of site maps and the structure for the location of the site maps is:

<?xml version="1.0" encoding="UTF-8"?>
  <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">

As far as i understand things search engines will except this just fine and it will not cause any issues.

However the problem being raise is this, because the actual site XML sits under a directory structure like /sitemap/date/ search engines will not include the URLS. My opinion is that this is incorrect. If anyone can clarify that would be great i have read the documentation on Sitemaps Protocol and would welcome any further articles that could be of use.

share|improve this question
FYI if it was the other way around (sitemap in a subfolder, pointing at URLs in the root), this could be an issue, but what you have is fine. This might be why there is some confusion. – Tim Fountain Apr 8 '11 at 8:20
Hi Tim thats what i thought and probably where the confusion stems from. it good to get an independent opinion though to clear things up. – Matthew Brookes Apr 10 '11 at 12:40
up vote 3 down vote accepted

Having just done the same thing (placing the referenced sitemap files in a different sub-folder) I can confirm this works fine with no issues.

  • The XML Sitemap index file doesn't have to be in the root of the site, but it is preferable (for convention)
  • The Sitemaps referenced by the index file don't have to be in the root of the site folder either
share|improve this answer

I assume you have a robots.txt file and have specified where the sitemaps are. Remember there are many smaller search engines out there. We don't want to make it hard for them. Someday they may be very important.

share|improve this answer
"We don't want to make it hard for them. Someday they may be very important." - The protocol is there to reduce the likelihood of error and if the bots are not doing their part, it's doubtful they'll ever become important enough to justify spending time accommodating them. – danlefree Apr 7 '11 at 23:38

I put mine in a directory structure as I please, but URL rewrite them to exist on the root. I don't think it matters much as long as robots.txt points to the correct absolute location.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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