XML SITEMAP VALIDATOR / A PRACTICAL GUIDE
Prepare a clean XML sitemap
Check the document and its entries before submitting it to a search engine.
Start with a sitemap file
Fetch a public sitemap URL or paste XML from your generator. This tool checks URL sitemaps and sitemap indexes, rather than arbitrary XML schemas. Paste the uncompressed XML if a compressed file cannot be fetched.
Review URLs and dates
Fix malformed XML and missing locations first. Review duplicates, URL fragments, host differences and optional date fields. Use the real modification date when you provide lastmod, rather than changing every date on every build.
Check the site as well
The validator checks the submitted file, not the HTTP status or canonical URL of every listed page. For an index, it does not fetch child sitemaps. Review those separately before submission.
An example to work from
<?xml version="1.0" encoding="UTF-8"?> <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> <url><loc>https://example.com/about</loc></url> </urlset>
Before you finish
Confirm the URLs are the pages you intend to publish. Valid XML does not guarantee crawling or indexing.