A sitemap index is an XML file that lists other sitemap files instead of page addresses. It lets you split a large site into several sitemaps, each within the 50,000 URL and 50 MB limits, and submit a single address to search engines. Its root element is sitemapindex, and each child file sits in a sitemap element with a loc address.
Why it matters
Big sites and sites with distinct sections outgrow one file quickly. An index keeps everything under one address, and splitting by section makes the Search Console report far easier to read. You can see at a glance which group of pages has a problem.
How to do it
- Decide how to group your pages. Common choices are by content type (pages, posts, products) or by number, such as 40,000 addresses per file.
- Build a normal sitemap for each group, following the usual format with a
urlsetelement. - Create the index file with a
sitemapindexelement:
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>https://www.example.com/sitemap-pages.xml</loc>
<lastmod>2026-11-01</lastmod>
</sitemap>
<sitemap>
<loc>https://www.example.com/sitemap-products.xml</loc>
<lastmod>2026-10-28</lastmod>
</sitemap>
</sitemapindex>
- Save the index in a stable location such as
/sitemap_index.xmlor/sitemap.xml, and publish the child files at the addresses you listed. - Submit the index address in the Sitemaps report in Google Search Console. The child sitemaps appear under it. You can also point to the index from robots.txt with a
Sitemap:line. - Open each child file once to confirm that it loads and contains the pages you expect.
An index may list up to 50,000 sitemaps. For a lastmod value on a child entry, use the date the most recent change inside that child file happened.
Common mistakes
- Putting page addresses directly in the index rather than in child sitemaps.
- Listing another index inside the index. The format expects sitemap files, not further indexes.
- Using the wrong root element or leaving out the namespace, which makes the file unreadable.
- Listing child files that return errors or redirect elsewhere.
- Submitting every child file and the index, which is unnecessary clutter.
Frequently asked questions
Do I have to submit the child sitemaps too?
No. Submitting the index is enough, and Search Console shows the children beneath it. Submitting the children separately only adds duplicates to the report.
When do I need an index?
When you pass 50,000 URLs or 50 MB in one file, or when you want separate files for separate sections of the site. A small site with one short sitemap does not need one.
Does an index help rankings?
No. It is only a way to organize and deliver your sitemaps. It helps discovery and reporting, nothing more.
Related guides
- Sitemap index files for large websites
- What is the sitemap size limit?
- How to submit a sitemap to Google
- How to create a valid XML sitemap
For a quick look at how your site reads to a crawler, Try the free website sample.