OneWebDesk

Sitemap Validator

Fetch sitemap.xml and validate format, URL count and index files.

Sitemap Validator fetches your site's sitemap.xml directly and shows whether the format is valid, what kind it is (a regular sitemap vs a sitemap index), and how many URLs or child sitemaps it contains. Enter just a domain and it automatically looks up /sitemap.xml for you.

Search engines use sitemaps to discover and index pages efficiently. A malformed file, an empty sitemap, a non-200 response, or non-XML content can lead to missing pages in the index. Use this tool to confirm your sitemap is healthy before submitting it.

The two sitemap formats

  • urlset: a regular sitemap listing actual page URLs. Each entry is a loc element.
  • sitemapindex: an index that groups multiple sitemap files. Used by large sites to split sitemaps.

This tool automatically detects whether the response is a sitemapindex or a urlset, and for an index it also lists the child sitemaps.

Limits: 50,000 URLs / 50MB

A single sitemap file can hold up to 50,000 URLs and up to 50MB uncompressed. Beyond that you must split the sitemap into several files and group them with a sitemap index. For large sites, an index structure is the safe choice.

Submitting and verifying

Declare the sitemap location in robots.txt and submit it to tools like Google Search Console. After submission, compare the reported URL count with the indexed count to spot gaps. Even a well-formed sitemap can be skipped if it returns a non-200 status or a content-type that is not XML. To add a sitemap line to robots.txt, use the robots.txt generator, and verify the live robots.txt advertises it with the robots.txt checker.

Sitemap tag reference

Each <url> entry in a urlset sitemap may carry the child tags below. In practice the only one search engines truly rely on is <loc>; the rest are weak hints or largely ignored.

TagRequiredExample valueHow Google treats it
<loc>Requiredhttps://example.com/pageUsed. Must be an absolute URL; & and similar must be entity-encoded
<lastmod>Optional2026-06-27 or 2026-06-27T09:00:00+09:00Used if accurate. Ignored if you falsely bump it to today on every fetch
<changefreq>Optionaldaily, weekly, etc.Effectively ignored by Google
<priority>Optional0.01.0Ignored by Google; has no effect on crawl priority

Each <sitemap> entry in a sitemapindex carries only a <loc> (the child sitemap URL) and an optional <lastmod>. Nesting an index inside another index is invalid; only one level of indexing is allowed.

Worked example: detecting an index

Suppose the fetch returns the following.

FieldValue
Status code200 OK
content-typeapplication/xml
Root tag<sitemapindex>
Child tags<sitemap> × 3

Because the root is <sitemapindex>, the tool reports Format: sitemap index and lists the <loc> of the three child <sitemap> entries (e.g. /sitemap-posts.xml, /sitemap-pages.xml, /sitemap-images.xml). To learn the total URL count, re-run the check against each child sitemap URL.

Common pitfall

  • BOM or leading whitespace: an invisible byte-order mark or a blank line before the <?xml ...?> declaration prevents the parser from finding <urlset>, yielding "unknown format". The file must be XML from byte one.
  • Unescaped &: writing a URL like ?a=1&b=2 raw inside <loc> is an XML error; it must be encoded as &amp;.
  • HTTP 200 but HTML: a missing path that returns a friendly landing page with a 200 (a soft 404) fails the format check. Do not trust the 200 alone — verify the root tag.

Frequently asked questions

Can I enter just a domain?
Yes. If you enter a domain like example.com, the tool automatically fetches https://example.com/sitemap.xml. For a sitemap at a different path, enter the full URL.
Does it check sitemap index files?
Yes. If the response is in sitemapindex format it is recognized as an index, and the tool lists the child sitemaps it contains along with the count. You can re-check each child sitemap by its URL.
What if there are more than 50,000 URLs?
A single sitemap file is limited to 50,000 URLs and 50MB. If you exceed that, split the sitemap into multiple files and group them with a sitemap index so search engines process them all.
Is my input stored anywhere?
No. The URL you enter is only used to fetch the sitemap, and the server requests it safely through SSRF protection. Results are cached briefly (about 2 minutes) and not otherwise stored.
Why does it say 'unknown format'?
If the response has no urlset or sitemapindex tag, it is not recognized as a sitemap. It may be an HTML error page, an empty response, or a wrong path — check the status code and content-type.

Related guides

Related tools

SEO / Indexing