What goes in (and stays out of) your sitemap
Include only canonical, indexable URLs that return 200 status codes. Exclude noindex pages, redirected URLs (301/302), 404s, and pages blocked by robots.txt.
Include accurate <lastmod> dates — Google uses these as a signal of freshness. Lying about lastmod dates eventually causes Google to ignore them entirely.
Splitting sitemaps for large sites
Each sitemap can hold up to 50,000 URLs and 50MB uncompressed. Beyond that, split into multiple sitemaps and reference them in a sitemap index file.
Logical splits help debugging: separate sitemaps for blog posts, services, locations, and products make it easy to see which section is having indexing issues in Search Console.