What is an XML sitemap?
An XML sitemap is a file that lists the important pages on your website. It helps search engines discover pages quickly, especially new pages, pages with few internal links and large sites. Google, Bing and other search engines all support the standard sitemap format this generator creates.
How to create a sitemap
- Paste your page URLs, one per line. Use full addresses starting with
https://. - Choose a change frequency and priority, or omit them.
- Set the last modified date. Today’s date is filled in for you.
- Invalid and duplicate URLs are removed automatically.
- Download
sitemap.xml, upload it to your site’s root folder and submit it in Google Search Console under Sitemaps.
Sitemap best practices
- Only include pages you want in search results. Leave out redirects, error pages and pages marked noindex.
- Use the canonical version of each URL, with the same https and www format everywhere.
- Keep each file under 50,000 URLs and 50 MB. Larger sites should split into several sitemaps.
- Add the sitemap address to your robots.txt file so every crawler can find it.
Google mainly uses the lastmod date and largely ignores priority and changefreq, so an accurate last-modified date matters most.
Do WordPress sites need this?
WordPress creates a sitemap automatically at /wp-sitemap.xml, and SEO plugins like Rank Math and Yoast make their own. This tool is most useful for static HTML sites, custom-built sites and landing pages. After creating your sitemap, reference it in a robots.txt file made with our robots.txt generator.
What an XML sitemap looks like
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://example.com/</loc>
<lastmod>2026-09-28</lastmod>
</url>
</urlset>
Each <url> entry needs a <loc> with the full address. <lastmod> is optional but useful. Special characters such as & must be escaped, which the generator does automatically.
Features
- Removes invalid and duplicate URLs automatically and tells you which lines were skipped.
- Gives your homepage priority 1.0 automatically, if you want it to.
- Sets the last-modified date to today, or any date you choose.
- Downloads a ready-to-upload
sitemap.xmlfile.
Where to find your page URLs
- Copy them from your site’s navigation and footer.
- Export them from Google Search Console under Pages.
- Use a crawler such as Screaming Frog (free up to 500 URLs) and export the list.
After uploading your sitemap
- Open
yourdomain.com/sitemap.xmlto check it loads. - Add
Sitemap: https://yourdomain.com/sitemap.xmlto robots.txt. - Submit it in Google Search Console and Bing Webmaster Tools.
- Update the file whenever you add or remove pages, and change
lastmodwhen content changes meaningfully.
Sitemap index files
Large sites split URLs into several sitemaps (for example pages, posts and products) and list them in a sitemap index file. Search engines read the index and then each sitemap. For sites with more than 50,000 URLs, an index is required.
Frequently asked questions
How many URLs can a sitemap contain?
Up to 50,000 URLs, and the file must be no larger than 50 MB uncompressed. Use a sitemap index file for bigger sites.
How do I submit my sitemap to Google?
Upload sitemap.xml to your site root, open Google Search Console, go to Sitemaps, enter the sitemap URL and click Submit.
Does a sitemap improve rankings?
Not directly, but it helps search engines find and crawl your pages sooner, which is the first step to ranking.
Are priority and changefreq important?
Google says it ignores them. The lastmod date is useful as long as it is accurate.
