Sitemap XML Generator
Make a valid sitemap.xml from a URL list or CSV with lastmod, split lists over 50,000 URLs into a sitemap index, or validate a sitemap with line and column errors.
How to use Sitemap XML Generator
- 1Paste one URL per line, or a CSV with a url column and optional lastmod, changefreq, priority and hreflang columns.
- 2Set default values if you want them, check the warnings, then copy or download sitemap.xml. Over 50,000 URLs, switch to Split.
- 3Upload the file to your site root, reference it from robots.txt and submit it in Google Search Console. Use Validate to check any sitemap you already have.
What makes it better
- URLs are checked for an absolute http or https address, escaped for XML, de-duplicated and warned about when the host differs
- lastmod accepts W3C dates (YYYY-MM-DD or a full date-time with zone); invalid dates and out-of-range priorities are dropped with a warning
- Split makes sitemap-1.xml and so on plus a sitemap-index.xml, with each file downloadable or all of them as one ZIP
- Validate refuses DOCTYPE declarations and reports XML errors with line and column, plus duplicates and non-absolute URLs
- An optional hreflang column writes xhtml:link alternates for multilingual sites
About Sitemap XML Generator
Sitemap XML Generator turns a list of URLs, or a CSV with url, lastmod, changefreq and priority columns, into a sitemap.xml with every ampersand and quote escaped. Lists beyond the 50,000 URL or 50 MB limit can be split into a sitemap index plus several files, downloaded one by one or as a ZIP. The Validate mode reads an existing sitemap and reports malformed XML, relative URLs, duplicates and bad dates with their line numbers.
Common uses
- Build a sitemap for a static site or a small CMS that does not generate one automatically.
- Turn a crawl export or spreadsheet of URLs and modified dates into a sitemap for Search Console.
- Split a product catalogue of 120,000 URLs into three files and an index that stays under the protocol limits.
- Find out why Search Console says a sitemap could not be read by validating it here first.
Example
Input
url,lastmod,changefreq,priority https://example.com/,2025-03-01,weekly,1.0 https://example.com/pricing,2025-02-14,monthly,0.8 https://example.com/blog/seo-basics?ref=nav&page=2,2025-01-20,,
Result
<?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-03-01</lastmod>
<changefreq>weekly</changefreq>
<priority>1.0</priority>
</url>
<url>
<loc>https://example.com/pricing</loc>
<lastmod>2025-02-14</lastmod>
<changefreq>monthly</changefreq>
<priority>0.8</priority>
</url>
<url>
<loc>https://example.com/blog/seo-basics?ref=nav&page=2</loc>
<lastmod>2025-01-20</lastmod>
</url>
</urlset>
Good to know
- Google ignores changefreq and priority and only uses lastmod when it is consistently accurate, so leave lastmod out rather than filling every URL with today's date. Other search engines may still read all three fields.
- A sitemap may only list URLs on the host, scheme and port it is served from, and each file is limited to 50,000 URLs and 50 MB uncompressed. The generator warns about both but still writes the file.
- Image, video and news sitemap extensions are not generated or checked here. Only xhtml:link alternates are supported as an optional column, and URLs are written in canonical form, so https://example.com becomes https://example.com/.
Sitemap XML Generator FAQ
How many URLs can one sitemap contain?
At most 50,000 URLs and 50 MB uncompressed per file. Bigger sites use a sitemap index that lists several sitemap files; the Split mode writes that index and the files, and each file also passes through the validator.
Does Google use changefreq and priority?
No. Google has said it ignores both and reads lastmod only when it proves reliable, meaning it changes when the page content changes. They are harmless to include, and some other engines may read them, but they will not speed up crawling.
Why do I need & in a sitemap URL?
A sitemap is XML, where a bare ampersand starts an entity and makes the whole file invalid. A URL like /shop?a=1&b=2 must be written /shop?a=1&b=2. The generator does this for you and the validator flags it.
Where should I upload sitemap.xml and how do I tell Google?
Put it at the site root, for example https://example.com/sitemap.xml, add a Sitemap: line to robots.txt, and submit the address under Sitemaps in Google Search Console. A sitemap in a folder can only list URLs inside that folder.
Can a sitemap list URLs from another domain?
Not usefully. Search engines ignore URLs whose host, scheme or port differs from where the sitemap lives, unless ownership of both is verified for cross-submission. The tool warns when the first URL's origin and a later URL's origin differ.