Developer Tool

XML Sitemap Generator

Generate, validate, and format XML sitemaps instantly. Build clean sitemap.xml files for Astro, Next.js, WordPress, Shopify, blogs, docs sites, and modern websites without leaving the browser.

Build your sitemap.xml

Add rows for each page you want in your sitemap and preview the result live.

Live XML preview

Ready

Turn every app session into activation, retention, and revenue.

What is an XML Sitemap?

An XML sitemap is a structured list of canonical URLs that helps search engines discover and revisit important pages on your website. A standard sitemap usually contains a `loc` value and may also include `lastmod`, `changefreq`, and `priority` values for each URL entry.

How Astro Generates Sitemaps

Astro can generate sitemap output with the official `@astrojs/sitemap` integration during your build. On larger sites, you may also encounter `sitemap-index.xml` files that point to multiple sitemap files. Static routes are naturally included from your generated pages, while dynamic routes can be surfaced through `getStaticPaths()` so each pre-rendered path becomes part of the build output.

This page is useful when you want to inspect, handcraft, validate, or normalize sitemap XML alongside Astro’s automated approach, especially for custom SEO workflows or migration projects.

Where sitemap files help most

Astro sites

Create or inspect sitemap.xml output for static routes, content collections, and hand-built pages before deployment.

Blogs

List posts, categories, and evergreen landing pages with consistent lastmod values to help search engines revisit updated content.

SaaS products

Document marketing pages, docs hubs, templates, and public feature pages in one clean sitemap file.

eCommerce stores

Validate large product, category, and brand URLs to catch duplicate or malformed entries before submitting to search consoles.

Docs sites

Generate machine-readable URL lists for product documentation, changelogs, knowledge bases, and help centers.

XML sitemap best practices

Canonical URLs only

Only include URLs that you want indexed. Exclude redirects, duplicates, filtered parameters, and non-canonical alternates.

Keep `lastmod` accurate

Update modification dates when meaningful page content changes instead of leaving stale or automatic timestamps everywhere.

Submit to Google Search Console

Once published, submit your sitemap URL in Google Search Console to help monitor coverage, indexing issues, and crawl behavior.

Reference it in `robots.txt`

Add a `Sitemap:` line to your `robots.txt` file so crawlers can discover the sitemap location quickly.

How to use this tool

  1. 1. Add one or more canonical URLs in the generator tab and optionally set last modified date, change frequency, and priority for each row.
  2. 2. Generate the sitemap XML instantly, review the live preview, and copy or export the sitemap.xml output.
  3. 3. Paste any existing sitemap into the validator tab to check structure, duplicates, invalid URLs, invalid changefreq values, and malformed XML.

Frequently asked questions

What is an XML sitemap?

An XML sitemap is a machine-readable file that lists canonical URLs you want search engines to crawl and index. It commonly includes loc, lastmod, changefreq, and priority values.

Does every website need a sitemap.xml file?

Not every website strictly needs one, but most production sites benefit from it. Sitemaps are especially useful for blogs, SaaS apps, eCommerce stores, docs sites, and websites with many pages or changing content.

Can I use this sitemap generator for Astro websites?

Yes. This tool is useful for Astro sites when you want to manually build, inspect, or validate sitemap XML alongside or before using the official @astrojs/sitemap integration.

What should go inside the loc field?

The loc field should contain the full canonical URL for a page, including protocol and hostname. Avoid adding duplicate, redirected, parameter-heavy, or non-canonical URLs.

What values are valid for changefreq?

Valid sitemap changefreq values are always, hourly, daily, weekly, monthly, yearly, and never.

What values are valid for priority?

Priority values should be between 0.0 and 1.0. They help express relative importance inside your site, but they do not guarantee ranking outcomes in search engines.

Can this page validate an existing sitemap.xml file?

Yes. Paste your XML into the validator tab and the tool checks for malformed XML, missing core nodes, duplicate URLs, invalid URLs, invalid priority values, and unsupported changefreq values.

Should I include lastmod in my sitemap?

Yes, when you can keep it accurate. A trustworthy lastmod field helps communicate when a page changed, but outdated values are less useful than omitting the field entirely.

TL;DR

Generate XML sitemap files row by row, validate pasted sitemap XML, normalize the output, and copy a clean sitemap.xml file in seconds. This free SEO tool is useful for Astro builds, blogs, SaaS marketing sites, eCommerce stores, and documentation portals.

  • Free to use
  • No signup required
  • Live XML preview
  • Copy to clipboard
  • Validator included
  • Astro friendly
  • Static-first page
· · Last reviewed: April 2026