A sitemap validator checks two separate things that are easy to conflate: whether the file is a legal XML sitemap, and whether the URLs inside it are the ones you actually want crawled. The first is a parsing question with a definite answer. The second is a judgement about consistency — protocols, hostnames, parameters, duplicates — and it is where most real sitemaps fail, long after they have passed every syntax check. This page does both, entirely in your browser, with no request made to your site or to ours.
Arb Digital's SEO team runs this check whenever a sitemap has been generated by a plugin, a framework, or a build script rather than written by hand, because automated generators are excellent at producing well-formed XML and unreliable at producing canonical URLs. A file can be flawless against the schema and still list five thousand pages on the wrong protocol. Search engines will not tell you that. They will simply crawl a set of redirects and quietly discount the file.
What This Sitemap Validator Does
Paste the XML and the tool parses it with the browser's own XML parser, so a malformed document fails exactly where a crawler's parser would fail, with the position reported rather than guessed. If it parses, the structural checks run: the root element must be urlset or sitemapindex, the sitemaps namespace should be declared on it, every <url> entry must contain exactly one <loc>, and every <sitemap> entry in an index must do the same. Missing, empty or duplicated <loc> elements are errors, not warnings, because an entry without a location has no meaning at all.
Then the limits. The protocol caps a single sitemap file at 50,000 URLs and 50 MB uncompressed, and both counters above show your position against those ceilings rather than a bare pass or fail — a file at 47,000 URLs is technically valid and about to become a problem. Size is measured on the exact bytes you pasted.
Finally the URL quality pass, which is the part a schema check will never do. Each location is examined for an absolute form with a scheme and host, for protocol and host consistency against the rest of the file, for query strings and fragments, for duplicates, for excessive length, and for optional elements that are present but invalid — a priority outside 0.0 to 1.0, an unrecognised changefreq, or a lastmod that is not a valid W3C date. Every finding is listed with its entry number so you can go straight to it.
How to Use It
- Paste the raw XML. Open your sitemap in a browser, view source, and copy the whole document including the XML declaration.
- Optionally name your canonical host. Enter the hostname your site should be serving from. Leave it blank and the validator infers the reference host from whichever appears most often.
- Click Validate sitemap. The verdict is immediate: valid, valid with warnings, or the count of errors that must be fixed first.
- Work through errors before warnings. Errors are protocol violations that can invalidate the file. Warnings are URLs that are legal but probably not what you meant to submit.
- Re-validate after regenerating. Sitemap defects almost always come from the generator's configuration, so the fix belongs upstream rather than in the file.
What Is Checked, and Against What
The structural rules come from the sitemaps protocol itself, which is a small and unusually readable specification. It defines the namespace, the required <urlset> and <loc> elements, the optional <lastmod>, <changefreq> and <priority>, the character-escaping rules, and the two size limits. It is worth reading once in full — the whole thing is shorter than most blog posts about it, and it is published at sitemaps.org.
Escaping is the rule that catches hand-edited files most often. A raw ampersand in a URL is not valid XML, so ?a=1&b=2 must be written with the ampersand escaped. The browser's XML parser enforces that automatically, which is why an unescaped ampersand shows up here as a parse error rather than a warning: the document is not XML at all, and a crawler will reject the whole file rather than the one bad entry. The same applies to unescaped angle brackets and to a stray byte order mark or blank line before the XML declaration.
The URL rules are stricter than XML's. Every <loc> must be a fully qualified absolute URL beginning with a scheme — /pricing/ is not acceptable even though it is perfectly valid XML text, and neither is example.com/pricing/ without the protocol. The protocol also expects every URL in a single file to share the same host as the sitemap itself, which is the rule behind most of the cross-host warnings this tool produces.
The 50,000 URL and 50 MB Limits
A single sitemap file may contain at most 50,000 URLs and must not exceed 50 MB uncompressed. Both limits bind independently: 20,000 URLs with long paths and full lastmod timestamps can approach the size ceiling well before the count ceiling. Gzip compression is allowed and encouraged for transfer, but the 50 MB limit applies to the uncompressed document, so compressing an oversized file does not make it legal.
The remedy for either limit is a sitemap index: a file whose root is <sitemapindex> and whose entries point at other sitemap files rather than at pages. An index is itself subject to the same 50,000-entry limit, which in practice puts the ceiling for a single index at 2.5 billion URLs and means very few sites ever need nested indexes. Splitting also has a diagnostic benefit that has nothing to do with the limits: if you split by section — products, blog posts, category pages — then the coverage report in Search Console reports discovery and indexing per file, and a section-wide problem becomes visible immediately instead of being averaged away across the whole site.
Google's own guidance on building and submitting sitemaps, including the index format and the submission methods, is documented in Google Search Central. Once the file is in place, the reference to it belongs in your robots.txt as well as in Search Console, and our robots.txt generator writes that directive correctly.
Relative and Non-Canonical URLs
This is the class of defect that survives every other check. A relative <loc> such as /about/ is well-formed XML, reads fine to a human, and is invalid to a crawler, which will not resolve it against the sitemap's own location. It usually appears when a template that was written for internal links gets reused by the sitemap generator, and it can affect every entry in the file at once.
Non-canonical URLs are subtler and more common. Listing http:// URLs on a site that redirects everything to https:// means every entry in your sitemap is a redirect, which wastes crawl requests and sends a contradictory signal about which version is authoritative. The same applies to www and non-www mixed in one file, to URLs with tracking or session parameters, to URLs with fragments after a hash — which are never separate documents to a crawler — and to inconsistent trailing slashes where both forms resolve. None of these break the file. All of them make it less useful.
The rule that resolves nearly all of it: a sitemap should list the canonical, final, 200-status URL of every page you want indexed, and nothing else. Not redirects, not parameter variants, not pages carrying a noindex directive, and not pages canonicalised to a different URL. If you are unsure how a particular URL decomposes into scheme, host, path and query, our URL parser breaks it apart, and the HTTP status code lookup explains what a crawler does with each response it might get instead of a 200.
lastmod Is the Field Most Often Wrong
The lastmod element must be a W3C datetime value: either a complete date such as 2026-08-01, or a date and time with a timezone offset such as 2026-08-01T09:15:00+00:00. Values like 01/08/2026, August 1 2026, or a Unix timestamp are invalid and this validator flags them.
A correctly formatted lastmod can still be misleading, and that is the more expensive failure. Some content management systems update the value on every publish of any page, or on every build, so an entire sitemap reports today's date every morning. When that happens the field carries no information and crawlers learn to ignore it for that site. Google has been explicit that it uses the value only when it is consistently accurate. The discipline is simple: set lastmod only when the page's main content genuinely changed, and leave it alone for a comment count, a sidebar update, or a template change.
changefreq and priority deserve less attention than they get. Both are hints, both are widely ignored by major search engines, and a file where every page carries priority 1.0 conveys exactly the same information as a file with no priorities at all. Validating them is still worthwhile — an out-of-range value is a sign that the generator is misconfigured in other ways too.
What a Validator Cannot Tell You
A clean report here means the file is legal and internally consistent. It does not mean the URLs work. This tool makes no network requests by design, so it cannot know whether a listed page returns 200, 301, 404 or 500, whether it carries a noindex tag, whether robots.txt blocks it, or whether its canonical tag points somewhere else entirely. Those checks require fetching each URL, and any tool that claims to do them from a pasted file is inferring rather than verifying.
That gap matters because the most common real-world sitemap problem is a conflict rather than a syntax error: a URL is listed in the sitemap, which says "index this", and simultaneously carries a noindex meta tag or a canonical pointing at another page, which says the opposite. Search engines resolve the conflict in favour of the on-page directive and the sitemap entry is wasted. Validate the file here, then verify a sample of the URLs themselves in Search Console's inspection tool. If crawl efficiency is your concern rather than syntax, our crawl budget calculator models how far a crawler gets through a site of a given size at a given rate.
Generating a Sitemap Versus Validating One
These are two different jobs and we publish a separate tool for each. Our XML sitemap generator creates a sitemap from a list of URLs you supply, complete with the namespace declaration and optional metadata. This page takes a sitemap that already exists — typically produced by your CMS, your framework, or that generator — and audits it. Use the generator when you need a file; use this one before you submit whatever file you have.
The two work well in sequence. Generate, validate, fix whatever the report names, then submit. For an international site, the sitemap is also one of the three valid places to declare alternate language versions, and our hreflang tag generator covers the reciprocity rules that markup has to satisfy before search engines will act on it.
Reading the Report on a Large File
On a sitemap with thousands of entries, the useful signal is the pattern, not the individual line. Fifty warnings about mixed protocols spread randomly through the file suggests content that was migrated at different times. Fifty consecutive warnings suggests one section of the site is generated by different code. Every entry warning at once almost always means a single template or configuration value is wrong, which is a one-line fix rather than thousands.
Because the whole check runs locally, pasting a large file is safe — nothing about your site structure leaves the browser, which matters when the sitemap belongs to a staging environment or an unlaunched section. If the XML is minified onto one line and hard to read while you work through the findings, our XML formatter will indent it first.
Arb Digital audits crawlability, indexation, canonical signals and site architecture, then fixes what is actually holding rankings back — with the changes documented so your team can maintain them.
SEO Services Talk To Our TeamCommon Mistakes to Avoid
- Listing redirecting URLs — an
http://entry on an HTTPS-only site makes every crawl request a redirect and muddies the canonical signal. - Including noindexed or canonicalised pages — the sitemap asks for indexing while the page refuses it, and the on-page directive wins every time.
- Updating lastmod on every build — a file where every date is today teaches crawlers to ignore the field entirely.
- Compressing an oversized sitemap instead of splitting it — the 50 MB limit applies uncompressed, so gzip does not buy you headroom.
- Leaving relative paths in
<loc>— every location must be absolute with a scheme and host, no matter how the rest of your templates write links.
Related Free Tools From Arb Digital
Build the file itself with the XML sitemap generator, declare it correctly with the robots.txt generator, indent a minified document with the XML formatter, decompose a problem URL with the URL parser, interpret crawler responses with the HTTP status code lookup, or plan crawl capacity with the crawl budget calculator. Everything we publish is listed in the free online tools hub.
Frequently Asked Questions
Up to 50,000, and the file must not exceed 50 MB uncompressed. If you need more, split the URLs across several files and list those files in a sitemap index, which is subject to the same 50,000-entry limit.
No. The limit applies to the uncompressed document. Compression reduces transfer size and is encouraged, but an oversized sitemap has to be split rather than zipped.
No. Every loc element must be a fully qualified absolute URL including the scheme and host. A relative path is valid XML but invalid as a sitemap entry, and crawlers will not resolve it against the file's own location.
The generator creates a sitemap from a list of URLs you provide. This page validates a sitemap that already exists, checking well-formedness, required elements, the size limits and URL consistency before you submit it.
A W3C datetime value: either a complete date such as 2026-08-01, or a date and time with a timezone offset such as 2026-08-01T09:15:00+00:00. Slash-separated dates and written month names are invalid.
No. Both are hints and major search engines largely ignore them. They are validated here because an out-of-range value usually indicates a generator that is misconfigured in other ways too.
No, and deliberately so. It makes no network requests, so it cannot see status codes, noindex tags or canonical conflicts. Validate the file here, then inspect a sample of the URLs themselves in Search Console.
No. Parsing and validation both happen in your browser, which means pasting a staging or pre-launch sitemap does not expose your site structure to anyone.