XML Sitemaps: What They Do and Do Not Do

An XML sitemap is a file that lists the URLs on your site you want search engines to know about. It is a hint, not a command. This guide explains what sitemaps actually do, when they matter, and how to use them without expecting miracles.

A real sitemap

Here is what a valid sitemap looks like in practice. It is a plain XML file, one <url> block per page, with a <loc> (the address) and optionally a <lastmod> (when the content really changed):

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>https://wizetool.com/</loc>
    <lastmod>2026-10-31</lastmod>
  </url>
  <url>
    <loc>https://wizetool.com/tools/geo-optimizer/</loc>
    <lastmod>2026-10-31</lastmod>
  </url>
  <url>
    <loc>https://wizetool.com/guides/what-is-geo/</loc>
    <lastmod>2026-10-31</lastmod>
  </url>
</urlset>

That is the whole format. Open yours in a browser at /sitemap.xml and you should see something very similar. For the full template, size limits and a sitemap index, see our XML Sitemap Example and Format guide.

Sitemap index and referring sitemaps

When one sitemap is not enough, you use a sitemap index. A sitemap index is itself an XML file that points to other sitemaps. It lists each child sitemap with a <loc> and its own <lastmod>, and nothing else. Search engines follow the links in the index to reach the individual sitemaps.

A referring sitemap is simply a sitemap that references another sitemap. In practice this means your sitemap index is the referring file, and each entry in it refers to a real sitemap hosted on the same site. The referred files are the ones that actually contain the <url> entries.

This structure exists for one reason: size. A single sitemap can hold up to 50,000 URLs and 50 MB. Once you cross that, split your URLs across multiple sitemaps and point a sitemap index at them. The index keeps crawlers in one place while the real sitemaps stay within the limits.

Rules for a sitemap index:

  • List only sitemaps you host yourself. Do not point at other people's sitemaps.
  • Each entry needs a <loc> with the full URL and a <lastmod> that reflects when that sitemap last changed.
  • Keep the index itself small. It holds one line per sitemap, not one line per page.
  • Submit the index URL in Search Console and robots.txt. Submitting the index is enough; the child sitemaps are discovered automatically.
  • Update the index's <lastmod> whenever any of the child sitemaps changes.

A common mistake is submitting every individual sitemap separately instead of just the index. Another is leaving old sitemap references in the index after you delete a file. Keep the index in sync with the sitemaps it points to.

Five rules

  1. List only canonical URLs. Every address in the file should be the one version you want indexed, with a trailing slash and HTTPS.
  2. Only include pages you want indexed. No login pages, no paywalled content, no pages marked noindex.
  3. Keep lastmod dates honest. Update them only when the content actually changed. A stale or invented date erodes trust.
  4. Respect the size limits. One file holds up to 50,000 URLs and 50 MB. If you go over, split into multiple sitemaps and point a sitemap index at them.
  5. Host it at a stable URL. Keep it at /sitemap.xml and reference it in robots.txt, so crawlers always know where to look.

Five mistakes

  1. Including non-canonical URLs. Parameter variants and duplicates in the sitemap keep the duplicates alive.
  2. Stale lastmod dates. A date that never moves makes the whole file look ignored.
  3. Huge sitemaps with junk. Quality over quantity. Ten good pages beat five thousand thin ones.
  4. Forgetting to update after a redesign. Old URLs in the sitemap confuse crawlers and waste their time.
  5. Expecting instant indexing. Submitting a sitemap is a request, not a command. A URL in it can still be ignored.

What a sitemap does

  • Tells search engines which URLs exist.
  • Provides last-modified dates to help prioritize crawling.
  • Helps new or large sites get discovered faster.
  • Surfaces pages that are hard to reach through normal links.

What a sitemap does not do

  • It does not force indexing. A URL in a sitemap can still be ignored.
  • It does not improve rankings directly.
  • It does not fix thin, duplicate or low-quality content.
  • It does not replace internal linking.

Think of a sitemap as a map you hand to a crawler. The crawler still decides where to go and what to index.

When you need one

  • New sites with few external links.
  • Large sites with thousands of pages.
  • Sites with deep or orphaned pages.
  • Sites that publish frequently and want faster discovery.

For a small site with good internal linking, a sitemap is still worth having but is not critical.

What to include

  • Only canonical, indexable URLs.
  • Pages you actually want indexed.
  • Last-modified dates that reflect real changes.

What to exclude

  • Non-canonical URLs (parameters, duplicates).
  • Pages behind login or paywalls.
  • Pages marked noindex.
  • 404 or redirected URLs.
  • Thin or low-value pages you do not want indexed.

How to create one

Most CMS platforms generate sitemaps automatically. If yours does not, you can generate one with a crawler or a small script. Keep it under 50,000 URLs and 50 MB per file; split into multiple sitemaps with a sitemap index if needed.

How to submit

  1. Host the sitemap at a stable URL (for example /sitemap.xml).
  2. Add it to robots.txt: Sitemap: https://example.com/sitemap.xml.
  3. Submit the URL in Google Search Console under Sitemaps.
  4. Check the status after a few days. Look for errors and the number of discovered URLs.

Common mistakes

  • Including non-canonical URLs. This keeps duplicates alive.
  • Stale lastmod dates. Update them only when content actually changes.
  • Huge sitemaps with junk. Quality over quantity.
  • Forgetting to update after a redesign. Old URLs in the sitemap confuse crawlers.
  • Expecting instant indexing. Submission is a request, not a guarantee.

Maintenance

  • Regenerate or update the sitemap when you add or remove pages.
  • Re-submit after major changes.
  • Monitor Search Console for sitemap errors.
  • Keep the sitemap in version control if you generate it manually.

Checklist

  • Sitemap contains only canonical, indexable URLs.
  • Submitted in Search Console and referenced in robots.txt.
  • No errors reported.
  • Updated when pages change.

Where to go next

Read How to Read the Search Console Pages Report to see what actually got indexed. For URL structure, see How to Fix Duplicate URLs and Canonical Issues and 301 vs 302 Redirects Explained. For the page-level side, use How to Check On-Page SEO Manually in 10 Minutes and the On-Page SEO Checklist. Google's sitemaps documentation covers the official guidance.

Last updated: November 2, 2026.

Try it on your own content

The SEO Optimizer checks content against these practices in seconds. Free and no sign-up; see the tool page for how analysis works.

Meet the SEO Optimizer