What is an XML sitemap?

An XML sitemap is a file that lists your site’s important URLs to help search engines discover and prioritize them. It acts as a direct map to your canonical pages, which is useful when internal links alone do not surface everything.

A sitemap does not force indexing. It helps discovery, which is a key part of crawlability and technical SEO. Google’s guide to building and submitting a sitemap covers the details, and the format itself is defined by the sitemaps.org protocol.

Why XML sitemaps matter

On large sites, new sites, and sites with weak internal linking, a sitemap speeds up how quickly search engines find new and updated pages. After a migration, it helps engines pick up the new URLs faster.

A clean sitemap also sends a clarity signal. When it lists only your canonical, indexable pages, it tells search engines exactly which URLs you consider important.

What to include and exclude

Include:

  • Canonical URLs you want indexed.
  • Pages that return a 200 status and are not blocked.
  • An accurate last-modified date where possible.

Exclude:

  • URLs that redirect, since a sitemap should list final destinations only.
  • Noindexed pages, canonicalized duplicates, and blocked paths.
  • Parameter and filter URLs that are not meant to rank.

A sitemap that lists redirects or noindexed pages sends mixed signals and wastes crawl attention.

How to create and submit a sitemap

  1. Generate the sitemap. Most content platforms and SEO plugins produce one automatically, or you can maintain it by hand for a small static site.
  2. Confirm it lists only canonical, 200-status URLs.
  3. Reference it in your robots.txt file.
  4. Submit it in Google Search Console under Sitemaps.
  5. Check back for read errors and coverage, and update it whenever URLs change.

Common sitemap mistakes

  • Leaving old or redirected URLs in the sitemap after a migration.
  • Listing noindexed or canonicalized pages, which conflicts with your other signals.
  • Never updating the sitemap, so new pages are slow to be found.
  • Splitting a large site poorly, so index sitemaps do not point to the right child files.

Key takeaways

  • A sitemap helps search engines discover your important pages faster.
  • List only canonical, indexable, 200-status URLs.
  • Submit it in Search Console and keep it current as URLs change.

Frequently asked questions

Do I need a sitemap if my site is small?
It still helps, though a small, well-linked site may be crawled fully without one. There is little downside to having a clean sitemap.

Does submitting a sitemap guarantee indexing?
No. It aids discovery. Whether a page is indexed still depends on its quality and other signals.


Part of our Technical SEO guide. For help, see our Technical SEO service.