Sitemap validatorDoes your sitemap follow Google's rules?
Enter your site or sitemap URL. We find the sitemap via your robots.txt file, follow an index down to its child sitemaps, and check each file for XML format, URL count, dates and domain. We also test the status codes, redirects and noindex tags of randomly selected URLs.
We find the sitemap for you
If you enter a domain name, we look at the Sitemap: lines in the robots.txt file or, failing that, at /sitemap.xml, /sitemap_index.xml and /wp-sitemap.xml. Compressed (.xml.gz), RSS and text sitemaps are read too.
Google's limits
A file can have at most 50,000 URLs and 50 MB (uncompressed); URLs must be on the same host as the sitemap and fully qualified. lastmod must be in W3C format and accurate; Google ignores the changefreq and priority fields.
Sampled URL check
We open 20 randomly selected URLs from the sitemap and show pages that return errors, redirect, are noindex or have a different canonical URL. These URLs shouldn't be in a sitemap.
How to read the results
The first line tells you where the sitemap was found: from the URL you entered, from the Sitemap line in robots.txt, or by trying one of the default addresses. If it was found at a default address, it isn't declared in robots.txt, and the findings say so separately. Then come four summary boxes: the number of sitemaps and indexes read, the total and unique number of URLs, the critical and warning-level issues, and the URLs that passed the sample check. If the total exceeds the unique count, some URLs are listed more than once or written incorrectly.
The sitemap tree
The tree shows indexes and the sitemaps under them, nested. The badge at the start of each row is the file type: Index, URL list, RSS, Atom or Text. Rows that read “Unreadable”, “HTML” or “Unrecognized” are files that search engines won't be able to process either. The tags next to them summarize the file's problem: “XML error” with the line number, “no namespace”, “nested index”, “redirects” and so on. One check reads at most 25 sitemaps; for larger indexes, the number of sitemaps not read appears below the tree, and you can check them one by one using their URLs.
Sampled URL check
Each check picks 20 URLs from the sitemap at random and requests them without following redirects, so you'll see different URLs on every run. “Indexable” means the URL returns 200, carries no noindex and is its own canonical. “redirects” means an old URL is still in the sitemap, “Different canonical” that the sitemap lists a copy instead of the main version, and “noindex” that a page you don't want indexed has ended up in the sitemap. If a few of the 20 URLs have problems, the rest of the sitemap very likely has similar ones. In addition, the first 10,000 URLs in the sitemap are checked against the Googlebot rules in robots.txt; if any are blocked, a warning appears in the findings.
Common problems and how to fix them
XML error: an unescaped & character
One common XML error is the & sign in URLs with parameters. In XML this character must be written as &; if it isn't, the tool shows the line with the error and Google can read the file only partly or not at all. The same rule applies to <, > and quotation marks. If you generate the sitemap with your own code, escape URLs before writing them into the XML; in PHP, htmlspecialchars($url, ENT_XML1) does this conversion:
<loc>https://magaza-ornek.com/urun?id=5&renk=siyah</loc>
The same lastmod on every entry
If the sitemap is regenerated on every request and the current time is written as the date, every URL carries the same lastmod; Google ignores these values and the tool flags them with a warning. Take the date from when the page's content last changed: from the update column in your database (updated_at, or post_modified in WordPress) or, on static sites, from the file's last commit date. Google wants lastmod to reflect significant content changes; don't update the date when only the copyright year or a counter changes.
URLs in the sitemap that aren't the main version
If the sample check turns up pages that redirect, are noindex or have a different canonical, the sitemap isn't generated from the same source as the URLs the site actually shows. Typical causes: http:// or non-www URLs left in the sitemap, the trailing slash written differently, deleted and redirected pages not removed from the list, and noindex pages such as tags or search results being added to the sitemap. In WordPress, check that the site address under Settings › General uses https and the right host; in your SEO plugin's settings, remove the content types you don't index from the sitemap too. If you generate it with your own code, write only URLs that return 200, aren't noindex and declare themselves as canonical.
The sitemap URL returns 404 or HTML
When you switch SEO plugins, the sitemap URL may change too (for example /wp-sitemap.xml instead of /sitemap_index.xml), but robots.txt and Search Console keep pointing to the old one. The tool reads the URL in robots.txt and reports that the sitemap can't be opened or returns an HTML page. Write the new URL on the Sitemap: line in robots.txt and submit it in Search Console as well. If you see “Unrecognized sitemap format”, open the file in your browser and look at the first line: a PHP warning or error text printed before the XML causes this result.
Example: a store's product sitemaps
The robots.txt file of magaza-ornek.com declares the https://magaza-ornek.com/sitemap.xml index, which contains urunler-1.xml, urunler-2.xml and kategoriler.xml. The check's summary boxes look like this:
- Sitemap: 4 files, one of them an index.
- URL: 12,480, all unique.
- Issues: 3, one of them critical.
- Sample check: 16 of 20 URLs without issues.
The main findings:
- 1 of the sampled URLs returns an error (critical):
/urun/kis-botu-2024returns 404; the product was deleted but not removed from the sitemap. - 3 of the sampled URLs redirect (warning): sold-out models are sent to the category page with a 301.
- Same lastmod on all entries (warning): the sitemap is regenerated on every request with that day's date.
- Sitemap declared in robots.txt (passed).
- Fix the query that builds the sitemap. Include only products that return 200 at their own URL; leave out deleted and redirected products.
- Take lastmod from the product's update date. Let the date change when the price, stock or description changes, not on every request.
- Look beyond the sample. 20 URLs are only a sample. Use “Download CSV” in the URL list to download the first 5,000 URLs, and paste them in batches of 100 into the bulk status code checker; the 3xx and 4xx tabs give you every URL that needs to come out of the sitemap.
- Run the check again. The goal is the results “All 20 sampled URLs return 200 and are indexable” and “Sitemap is valid”. Then check in the Sitemaps report in Search Console that the sitemap has been read again.
Frequently asked questions
Does a sitemap affect rankings?
Not directly; it makes it easier for search engines to find your pages and notice changes. It's especially important for new or large sites and sites with weak internal linking. A sitemap should contain only canonical URLs that return 200 and that you want indexed.
How should lastmod be used?
lastmod should be updated only when a page's content actually changes, and written in W3C format (2026-10-25 or 2026-10-25T14:30:00+03:00). Google uses lastmod on sites where it sees that it's kept accurate; if every URL shows the same date every day, it's ignored.
I have more than 50,000 URLs; what should I do?
Split the URLs into several sitemaps and list them all in a sitemap index (<sitemapindex>). An index can contain at most 50,000 sitemaps and must not list another index. It's enough to add only the index to your robots.txt file and Search Console.
How do I submit my sitemap to Google?
Add the line Sitemap: https://your-domain.com/sitemap.xml to your robots.txt file and submit the sitemap in the Sitemaps report in Search Console. For Bing, you can use Bing Webmaster Tools or IndexNow; Google's old ping endpoint was shut down in 2023.
Learn more about this topic: XML sitemap guide · Technical SEO checklist