Technical rules
- At most 50,000 URLs and 50 MB (uncompressed) per file; larger sites use a sitemap index.
- Only canonical URLs returning 200 — no redirects, noindex pages or duplicates.
- lastmod should reflect a real content change; Google ignores priority and changefreq.
- The sitemap location is declared in robots.txt and in Google Search Console.
Special sitemaps
Beyond the standard page sitemap there are extensions for images, video and news, as well as sitemaps with hreflang annotations for language versions. In practice, sitemap generation should be automated and tied to the content publishing cycle.
Example
A minimal sitemap with two URLs — only canonical addresses returning 200, with a real lastmod date.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://example.com/</loc>
<lastmod>2026-07-01</lastmod>
</url>
<url>
<loc>https://example.com/pricing</loc>
<lastmod>2026-06-15</lastmod>
</url>
</urlset>Sitemap: https://example.com/sitemap.xml