XML Sitemap Validator (Paste)

Paste an XML sitemap to check its syntax, URLs and dates — before Google finds the errors.

Processed locally — files never leave your device
Works offline once loaded Uploaded: 0 bytes

A broken sitemap is worse than no sitemap at all. One bad tag can make Google ignore the whole file, and a sitemap full of dead or redirected URLs teaches crawlers that your site is unreliable. Checking the file before you submit it takes a minute and saves weeks of silent crawl problems.

Paste your sitemap XML below and this validator parses it in your browser, counts the URLs, and flags syntax errors, bad addresses and invalid dates. It pairs well with the Robots.txt Generator that points crawlers at the file, and the Robots.txt Tester (Paste) that checks the file is reachable.

How to use

  1. Paste your full sitemap XML into the box, from the opening urlset tag to the closing one.
  2. Click Validate sitemap and wait a moment while the XML is parsed in your browser.
  3. Read the summary: URL count, valid entries, and a list of every problem found.
  4. Fix the flagged lines in your sitemap file, then paste it again to confirm a clean pass.

Why use Toolsvine

Online validators usually ask you to enter your sitemap URL and wait for their server to fetch it, which fails on staging sites and private servers. This validator parses the text you paste, so it works on draft files, staging copies and local files that no outside service can reach. The XML never leaves your browser, and the checks are the same ones Google applies.

What makes a sitemap valid?

A valid sitemap is an XML document that follows the sitemap protocol: a urlset root element in the sitemaps.org namespace, one url entry per page, and a loc element in every entry with a complete URL. Optional lastmod, changefreq and priority elements are allowed, but one misspelled tag, an unescaped ampersand or a stray character breaks the whole file.

The protocol also has hard limits: no more than 50,000 URLs or 50 MB uncompressed per file. Larger sites split their sitemaps and list the parts in a sitemap index file. Every URL must belong to the same host as the sitemap itself, use the same protocol, and return a 200 status — a sitemap full of redirects and 404s is treated as low quality.

Which errors matter most?

Syntax errors matter most, because Google stops reading at the first one and may ignore the file. Next come bad URLs: relative addresses, missing protocols, spaces, and unescaped ampersands, all of which make an entry unusable. Invalid lastmod dates are the third common fault, because a date uses the wrong format or a future date that cannot be real.

Duplicates and non-canonical URLs matter too. A sitemap should list each page once, using its canonical address, and should never include URLs blocked by robots.txt or tagged noindex. This validator checks the format and the contents; only a live server check can prove each URL returns 200, so spot-check the flagged ones before submitting.

Worked example: a 5-page sitemap for a Denver bakery

Flour & Stone Bakery in Denver, Colorado, has five pages in its sitemap: the homepage, a menu page, a catering page, an about page and a contact page. The test file below contains one deliberate error — the catering entry is missing its closing loc tag — and the validator reports exactly one error and four valid URLs.

<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url><loc>https://flourstone.example.com/</loc><lastmod>2026-11-10</lastmod></url>
  <url><loc>https://flourstone.example.com/menu</loc></url>
  <url><loc>https://flourstone.example.com/catering</url>
  <url><loc>https://flourstone.example.com/about</loc></url>
  <url><loc>https://flourstone.example.com/contact</loc></url>
</urlset>

The validator reports the XML parse error with its line and column, plus a summary showing four parseable entries and one broken one. Fixing the missing closing tag and re-pasting gives a clean pass: five URLs, zero errors, and one lastmod date accepted.

CheckResult for the example
URLs found5
Valid entries4
XML errors1 — unclosed loc tag
Bad URLs0
Invalid dates0
XML sitemap validator worked example for a Denver bakery with four valid URLs and one error
Worked example: one broken loc tag, four valid URLs — the validator names the line and the fault.

What mistakes should I avoid with sitemaps?

The most common mistake is listing every URL the site has ever had, including redirects, 404s, blocked pages and noindex pages. A sitemap should list only live, canonical, indexable pages. The second is forgetting to update it: a sitemap that still lists last year's pages while new pages are missing does more harm than good.

Watch out for special characters too. An ampersand in a URL must be written as &amp; in XML, and a space or a curly quote will break parsing. Generate the file from your real page list, validate it here, and resubmit it in Search Console after every fix.

Frequently asked questions

Does a sitemap help a page rank higher?

No, a sitemap does not boost rankings directly. It helps Google discover and crawl your pages, especially new or deeply buried ones, but ranking still depends on content quality and links. Think of it as a map that makes sure the crawler finds every room, not as a vote for any particular page.

How many URLs can one sitemap hold?

One sitemap file can hold up to 50,000 URLs and must stay under 50 MB uncompressed. Larger sites split their pages across several sitemaps and list them all in a sitemap index file, which itself can point to up to 50,000 sitemaps. Staying well under the limit also keeps the file fast to fetch.

Should my sitemap include images or PDFs?

Only if you want them found through search. Image and video sitemaps are separate extensions, and ordinary PDFs can be listed in a normal sitemap, but most sites list HTML pages only. Never list a file that is blocked by robots.txt or tagged noindex, because the contradiction tells Google the sitemap cannot be trusted.

Why does Google say my sitemap has errors I cannot see?

Google reads the live file at your sitemap URL, so check that it is the same file you validated here. A common cause is a cached or compressed version served by a plugin, a redirect to a different host, or a file that changes between your check and Google's fetch. Re-download the live file and paste that exact text here.

How often should I update my sitemap?

Update it whenever you publish, move or delete a page, and set honest lastmod dates so Google knows what changed. A site that publishes weekly should regenerate its sitemap at least weekly. A stale sitemap wastes crawl budget on dead pages and leaves new pages undiscovered, so automate the regeneration if you can.