A sitemap is one of those things most website owners never think about — until their pages aren't showing up in Google. Here's what it is, why it matters, and the exact steps to create and submit one.

What a sitemap actually is

A sitemap is a file — almost always an XML file named sitemap.xml — that lists the URLs on your website. Think of it as a table of contents you give directly to search engines. Instead of making Google find your pages by following links, you hand it a complete list of everything that exists and where to find it.

A basic sitemap entry looks like this:

<url>
  <loc>https://yoursite.com/about/</loc>
  <lastmod>2026-07-15</lastmod>
  <changefreq>monthly</changefreq>
  <priority>0.8</priority>
</url>

The <loc> tag is required — it's the URL. The others are optional metadata: when the page was last changed, how often you update it, and how important it is relative to other pages on the site.

Google and Bing support the standard XML sitemap format. It's defined by the sitemaps.org protocol, which all major search engines agreed to follow.

Types of sitemaps

There are a few different sitemap types, and large sites often use several at once:

  • XML sitemap — the standard type. Lists page URLs with optional metadata. This is what almost every site needs.
  • Image sitemap — lists images on your site so Google can index them separately for image search. You can either create a separate image sitemap or add image tags inside your standard XML sitemap.
  • Video sitemap — similar to image sitemaps, but for videos. Useful if video content is a significant part of your site.
  • News sitemap — required to be eligible for Google News. Only relevant if you're a news publisher.
  • Sitemap index — a sitemap of sitemaps. When your site has more than 50,000 URLs or the sitemap file exceeds 50MB, you split it into multiple files and reference them from a sitemap index file.
  • HTML sitemap — a regular webpage listing links to your content, aimed at human visitors rather than search engines. Helpful for navigation on large sites, but separate from the XML sitemap Google reads.

For most small to medium business sites, a single XML sitemap is all you need.

Do you need a sitemap?

Google says a sitemap is most helpful for:

  • Large sites (many pages that might not all be discovered via crawling)
  • New sites with few external links pointing to them
  • Sites with pages that are poorly linked internally
  • Sites that add new content regularly and want it indexed quickly
  • Sites with rich media (video, images) that want that content indexed in media search

Small, well-linked sites can technically be crawled without one — but there's no downside to having a sitemap. It's free to create, takes minutes to set up, and makes crawling more efficient. The only reason not to have one is forgetting about it.

If your site has more than 10 pages, add a sitemap. Full stop.

What to include (and what to exclude)

Include:

  • Every page you want indexed: homepage, service pages, blog posts, product pages, location pages
  • Your canonical URLs (the "official" version — no duplicates)
  • Pages with substantial content that you want to rank

Exclude:

  • Pages blocked by robots.txt — don't include a URL in your sitemap if you're also blocking crawlers from accessing it. Google will either ignore it or flag it as an error.
  • Pages with noindex tags — same logic. If you don't want it indexed, don't list it.
  • Duplicate URLs (e.g. both /page and /page/ — pick one canonical version)
  • Paginated pages (unless you specifically want them indexed)
  • Admin, login, and account pages
  • Thank-you and confirmation pages
  • Staging or test pages (they shouldn't be publicly accessible anyway)

The sitemap should be a clean list of exactly the pages you want in the index — nothing more.

How to create a sitemap

WordPress

Yoast SEO and Rank Math both generate sitemaps automatically and update them when you publish new content. Once a plugin is installed and the sitemap is enabled, it's usually at yoursite.com/sitemap.xml or yoursite.com/sitemap_index.xml. Yoast also handles video and image sitemaps.

Squarespace

Squarespace generates a sitemap automatically at yoursite.com/sitemap.xml. No setup required — just submit it to Google Search Console.

Shopify

Shopify auto-generates a sitemap at yoursite.com/sitemap.xml covering products, collections, blog posts, and pages. It updates automatically as you add content.

Webflow

Webflow generates sitemaps automatically for published sites. You can also control which pages appear in the sitemap via the CMS settings for each collection.

Static or custom sites

For hand-coded or static sites with no CMS, you create the sitemap manually and update it when pages change. Use the free XML sitemap generator to enter your URLs, set priorities, and download a ready-to-upload sitemap.xml file. Place it at the root of your domain: yoursite.com/sitemap.xml.

How to submit to Google

Creating the file is half the job. The other half is telling Google it exists.

  1. Go to Google Search Console and select your property.
  2. In the left sidebar, under Indexing, click Sitemaps.
  3. In the "Add a new sitemap" field, enter the path to your sitemap — usually just sitemap.xml.
  4. Click Submit.

Google will crawl the sitemap and show you how many URLs it found, how many are indexed, and any errors. Check back after a few days. If you see "Couldn't fetch" errors, make sure the file is accessible at the URL you specified. If pages show as submitted but not indexed, check for noindex tags or crawl blocks on those pages.

See the full Google Search Console setup guide for step-by-step verification and the other reports worth checking.

Add it to robots.txt

Beyond submitting in Search Console, you should also reference your sitemap in your robots.txt file. Add this line at the bottom:

Sitemap: https://yoursite.com/sitemap.xml

This tells crawlers — not just Google, but Bing, DuckDuckGo, and others — where to find your sitemap without you having to submit it to every search engine separately. It also means any crawler that finds your robots.txt will automatically discover the sitemap.

Common sitemap mistakes

Including noindex pages

If a page has a noindex tag, don't list it in the sitemap. Including it creates a conflict signal — you're telling Google "here's a page I want you to know about" and also "don't index this page". Google will generally follow the noindex, but it still wastes crawl budget and creates errors in Search Console.

Including blocked pages

Same issue in reverse. If your robots.txt blocks a URL pattern, don't include those URLs in the sitemap. Google can't crawl them, so listing them achieves nothing except flagging errors.

Using non-canonical URLs

If your site has both http:// and https:// versions, or both www and non-www, only list the canonical version in the sitemap. Same for trailing slash consistency: pick either /page/ or /page and stick to it throughout.

Forgetting to update it

A sitemap that's months out of date doesn't help anyone. Every time you publish a new page or delete an old one, update the sitemap. For static sites, build this into your publishing workflow so it doesn't get forgotten.

Exceeding the limits

A single sitemap file can have a maximum of 50,000 URLs and must be under 50MB (uncompressed). Exceed either limit and the file becomes invalid. For larger sites, split into multiple sitemaps and reference them from a sitemap index file.

Create your sitemap in 60 seconds

Use the free XML sitemap generator — enter your URLs, set change frequencies and priorities, then download a valid sitemap.xml file ready to upload to your server. No sign-up required.

The short version

A sitemap is a file that lists your URLs for search engines. If your site has more than 10 pages, you need one. Create it (or generate it automatically with your CMS), upload it to yoursite.com/sitemap.xml, add a Sitemap: directive to your robots.txt, and submit it in Google Search Console. Then keep it updated as your content changes.