Instantly validate your XML sitemap for errors, broken structure, and Google compliance — free, no login required.
/sitemap.xml or
/sitemap_index.xml
An invalid XML sitemap can silently block Google from indexing your pages — and you'll never know until you check. This free XML sitemap validator scans your sitemap for syntax errors, missing required tags, malformed URLs, incorrect date formats, and compliance issues with the official sitemaps.org protocol. Paste your XML or enter your sitemap URL and get instant results.
An XML sitemap is a file that lists every important URL on your website and tells search engines like Google, Bing, and Yandex where to find them. Think of it as a roadmap — without it, crawlers must discover pages through internal links alone, which can miss newly published or deeply nested content.
A valid XML sitemap follows the sitemaps.org protocol — the universal standard supported by Google, Bing, Yahoo, and other major search engines. Even small formatting errors can cause the entire file to be rejected by Google Search Console.
Here is a valid, minimal XML sitemap that passes all validation checks:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://example.com/</loc>
<lastmod>2025-01-15</lastmod>
<changefreq>weekly</changefreq>
<priority>1.0</priority>
</url>
<url>
<loc>https://example.com/about</loc>
<lastmod>2024-11-20</lastmod>
<changefreq>monthly</changefreq>
<priority>0.8</priority>
</url>
</urlset>
Every valid XML sitemap must include:
<?xml version="1.0" encoding="UTF-8"?>
<urlset> tag:
xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
<loc> tag inside every
<url> — this is the only required child element
https://example.com/page, never just /page
If your site has more than 50,000 URLs or your sitemap exceeds 50MB, split it into multiple files and reference them in a sitemap index:
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>https://example.com/sitemap-pages.xml</loc>
<lastmod>2025-01-15</lastmod>
</sitemap>
<sitemap>
<loc>https://example.com/sitemap-posts.xml</loc>
<lastmod>2025-01-14</lastmod>
</sitemap>
</sitemapindex>
yourdomain.com/sitemap.xml or check your
robots.txt file for a Sitemap: directive.
| Error | What Causes It | How to Fix It |
|---|---|---|
| Wrong or missing namespace | The xmlns attribute is absent or incorrect |
Add xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" to your <urlset> tag |
| Missing XML declaration | File doesn't start with <?xml ...?> |
Add <?xml version="1.0" encoding="UTF-8"?> as the very first line |
| Relative URLs in <loc> | Using /page instead of full URL |
Always use absolute URLs: https://example.com/page |
| Wrong date format in lastmod | Using 01/15/2024 or January 15 2024 |
Use ISO 8601 format: 2024-01-15 |
| Unclosed XML tags | Missing </url> or </urlset> |
Ensure every opening tag has a matching closing tag |
| Unescaped special characters | Raw &, <, or > in URLs |
Replace with &, <, > |
| File too large | Sitemap exceeds 50MB or 50,000 URLs | Split into multiple sitemaps and use a sitemap index file |
| 404 or blocked URLs included | Deleted pages or noindex pages in sitemap | Remove non-200 URLs and pages blocked by robots.txt or noindex tags |
| HTTP URLs on HTTPS site | Using http:// when site has SSL |
Update all <loc> values to use https:// |
| Duplicate URLs | Same URL listed multiple times | Remove duplicates — each URL should appear once only |
The full URL of the page. This is the only required tag inside
<url>. Must be an absolute URL using the correct
protocol (https:// if your site uses SSL). Special
characters like & must be escaped as &.
The date the page was last significantly modified, in YYYY-MM-DD format (ISO 8601). Google uses this to prioritize recrawling updated content. Only set this if the page was genuinely updated — fake or inflated lastmod dates cause Google to distrust the entire sitemap.
A hint about how often the page changes. Valid values:
always, hourly, daily,
weekly, monthly, yearly,
never. Note: Google has confirmed it largely ignores
this tag and relies on its own crawl data instead.
A relative priority from 0.0 to 1.0.
Default is 0.5. This is relative to other pages on
your site — it does not affect how Google ranks you versus
competitors. Google also largely ignores this tag. Setting every
page to 1.0 has no benefit.
noindex tags, pages blocked by robots.txt,
404 error pages, or redirect URLs to your sitemap.
Sitemap: https://example.com/sitemap.xml on its
own line — this helps all crawlers find it automatically.
<lastmod> when content genuinely changes —
not on every deploy.
Not sure where your sitemap is? Try these locations in order:
https://yourdomain.com/sitemap.xmlhttps://yourdomain.com/sitemap_index.xmlrobots.txt at https://yourdomain.com/robots.txt — look for a line starting with Sitemap:https://yourstore.myshopify.com/sitemap.xmlNot strictly — Google can discover pages through internal links. However, a sitemap significantly helps for new sites, large sites (1,000+ pages), sites with weak internal linking, and pages that are not linked from other pages. Google officially recommends submitting a sitemap via Search Console.
Each sitemap file can contain a maximum of 50,000 URLs and must not exceed 50MB uncompressed. For larger sites, create a sitemap index file that references multiple individual sitemaps. A sitemap index itself can reference up to 50,000 sitemaps.
The most common reasons are: including URLs that return 404 errors, using HTTP URLs on an HTTPS site, including pages blocked by robots.txt or noindex tags, incorrect XML formatting, or the sitemap file itself returning an error when fetched. Validate your sitemap here first, then resubmit in Search Console.
Only if the page content actually changed. Updating lastmod on every deploy — even when page content is unchanged — causes Google to distrust your lastmod values and may reduce crawl efficiency. Set it only when content is genuinely modified.
A sitemap doesn't directly boost rankings, but it ensures your pages get discovered and indexed — a prerequisite for ranking at all. Without proper indexing, even excellent content will receive zero organic traffic. For new sites especially, a sitemap dramatically speeds up initial indexing.
A validator checks the XML structure — syntax, tags, namespaces, and format compliance. A checker tests whether the sitemap is accessible and that the listed URLs return valid HTTP responses. Ideally, use both: validate the format first, then check that all URLs are live and returning 200 status codes.
Yes, and for large sites it's recommended. You can separate sitemaps
by content type — e.g. sitemap-pages.xml,
sitemap-posts.xml, sitemap-products.xml —
and reference all of them in a sitemap index file. This makes it
easier to diagnose which section has crawl issues.