The XML sitemap is the most underrated tool in your SEO toolkit. It's the official list of URLs you hand to Google and say "please index these." Done right, it speeds up indexing. Done wrong, it's noise Google ignores.
What goes in a sitemap
A standard XML sitemap is a list of <url> entries. Each has a <loc> (the URL) and ideally a <lastmod> (when it last changed). Skip priority and changefreq — Google ignores them.
What does NOT go in a sitemap
- URLs blocked by
robots.txt(contradictory) - URLs with
noindex - Non-canonical URLs (you'll confuse Google)
- Redirects (use the destination)
- 404s (drop them from the sitemap when you delete a page)
One sitemap or many?
A single sitemap can hold up to 50,000 URLs (or 50 MB uncompressed). Past that, split into multiple sitemaps (post-sitemap.xml, page-sitemap.xml, product-sitemap.xml) and reference them all from a parent sitemap_index.xml.
Splitting by content type also makes it easy to see, in Search Console, which type of page is having indexing trouble.
Submitting the sitemap
Two things:
- Add it to
robots.txtwith a line likeSitemap: https://yoursite.com/sitemap.xml. - Submit it in Google Search Console under Sitemaps → Add a new sitemap.
Keep it fresh
A stale sitemap with old URLs and missing new ones is worse than no sitemap. Most CMSs (WordPress, Webflow, Shopify, Ghost) regenerate the sitemap automatically when you publish. If yours doesn't, fix that first.
Sitemap + Indexing API = fastest path
The sitemap tells Google "here's everything I want indexed." The Indexing API tells Google "this specific URL just changed — come look now." Use both, and you've covered both the broad picture and the new-page rush.