Sitemap Validator & Generator
Create clean XML sitemaps or validate existing ones.
What This Tool Does
The Sitemap Validator and Generator provides two functions: validating existing XML sitemaps for correct structure and protocol compliance, and generating new sitemaps from a list of URLs. It checks XML syntax, URL format, and optional elements like lastmod, changefreq, and priority.
Inputs
- Validator mode: Paste an XML sitemap or provide a URL to fetch and validate its structure.
- Generator mode: Enter a list of URLs, set optional metadata, and generate a valid XML sitemap.
How It Works
The validator parses your XML and checks it against the sitemaps.org protocol specification. It verifies that the root element is a valid urlset, each URL entry has a properly formatted loc element, and optional elements use correct values. The generator takes your URL list and wraps each entry in proper XML sitemap markup with the namespace declaration.
Understanding the Results
- Validation report: Lists any errors or warnings found in the sitemap structure.
- URL count: Total number of URLs found in the sitemap.
- Generated output: A complete XML sitemap ready to save and deploy.
1. Scan Website or Enter URLs
2. Configuration
Result
Step-by-Step Example
- To validate: paste your sitemap XML into the validator input or enter the sitemap URL.
- Click Validate. The tool checks XML structure and reports any issues.
- Fix reported errors such as missing loc elements or invalid date formats.
- To generate: switch to generator mode and enter your URLs one per line.
- Set optional lastmod dates, changefreq, and priority values.
- Click Generate to produce the XML sitemap, then copy and save it as sitemap.xml.
Use Cases
- Validating sitemaps before submitting to Google Search Console.
- Creating sitemaps for small to medium websites without a CMS plugin.
- Checking that CMS-generated sitemaps follow the correct XML format.
- Building section-specific sitemaps for large websites.
- Verifying lastmod dates are accurate after a content update.
Limitations and Notes
- The validator checks XML structure but does not verify that listed URLs return 200 status codes.
- Generated sitemaps are limited by the 50,000 URL and 50 MB protocol limits.
- The tool does not support sitemap index files or image/video sitemap extensions.
- Changefreq and priority are hints that search engines may ignore.
Frequently Asked Questions
What is an xml sitemap?
An XML sitemap is a structured file that lists the URLs you want search engines to crawl on your site, along with metadata like last-modified date and priority. It doesn't guarantee indexing, but it tells Google 'these are the pages I care about', which is especially useful for big sites or sites with weak internal linking. Most CMS platforms generate one automatically. Always include only canonical, indexable URLs — never noindexed, redirected, or duplicate pages, since that just wastes crawl budget.
How to validate xml sitemap?
Run the sitemap URL through our Sitemap Validator. It checks XML syntax, file size limits, URL count limits, and flags broken or non-200 URLs. Then submit it in Google Search Console → Sitemaps; that report shows what Google read versus what you submitted. Common issues to watch for: URLs that 404, URLs that 301 redirect, noindex pages still in the sitemap, or staging URLs leaking in. Fix those, regenerate, resubmit, and re-check after 48 hours to confirm.
How many urls can be in a sitemap?
A single sitemap can hold up to 50,000 URLs and must stay under 50 MB uncompressed. Hit either limit and you split into multiple sitemaps with a sitemap index file pointing to each one. Most sites never come close — a typical blog with 200 posts sits comfortably in one file. For e-commerce stores or news sites with millions of URLs, splitting is non-negotiable. Group splits by content type (products, categories, blog) so you can monitor each set separately in Search Console.
Where should sitemap be placed?
Standard placement is the root: example.com/sitemap.xml. It's not a strict rule — a sitemap can technically live anywhere on the same domain — but the root is what every crawler checks first. Add a Sitemap directive in robots.txt and submit the URL in Google Search Console for full coverage. To verify, open the URL in a browser; you should see the XML render or download. If you have a sitemap index, that file goes at the root with the individual sitemaps wherever convenient.
Does sitemap help Google index pages?
It helps with discovery, not with ranking. Google still decides what's worth indexing. For a small site with strong internal linking, the sitemap rarely makes a measurable difference. For a large e-commerce store with deep product pages, news sites with fast-publishing schedules, or sites with weak navigation, it's essential. Real example — a client's 8,000-product site went from 60% indexed to 92% within three months after fixing their sitemap. Worth doing right, but don't expect it to fix bad content.
What is sitemap index file?
A sitemap index is a master file that points to multiple individual sitemaps. You'd use it when you exceed the 50,000-URL or 50MB limit, or when you want to organize sitemaps by content type — products, blog, categories. The index uses the same XML format but with sitemap entries instead of url entries. Submit only the index file in Search Console; Google will follow the links and read each child sitemap. It's the cleanest way to manage scale.
How to submit sitemap to Google?
Open Google Search Console, pick your property, go to Sitemaps in the left menu, and paste the sitemap URL (just the path after your domain, like /sitemap.xml). Hit Submit. Within a few hours you'll see status, discovered URLs, and any errors. Resubmit whenever you make a structural change. For Bing, use Bing Webmaster Tools the same way. Don't bother pinging the old ping URLs — Google retired that endpoint in mid-2023.
Sources and References
- Sitemaps.org Protocol: sitemaps.org
- Google Search Central - Sitemaps: developers.google.com
- Bing Webmaster - Sitemaps: bing.com
- W3C - XML Specification: w3.org
- Google Search Console Help: support.google.com