Skip to content

Sitemap SEO: When You Need an XML Sitemap, What to Include and How to Read Search Console

For SEO, an XML sitemap is a file that lists the canonical URLs you want search engines to crawl, each with an accurate lastmod date. It won't lift rankings by itself. It speeds up discovery and recrawling and gives you indexing diagnostics, which matters most on large, new or media-heavy sites. Small, well-linked sites can often skip it.

By , founder of Slibur

15 min read

Sitemap SEO: When You Need an XML Sitemap, What to Include and How to Read Search Console
In this article

The rules below come from Google's and Bing's documentation and the sitemaps.org protocol. For a whole-site review, the technical SEO audit checklist puts sitemaps next to canonicals, status codes and rendering. Here the sitemap is the whole subject, including what is (and isn't) documented about sitemaps in AI search. Getting your brand named inside ChatGPT's answers is a separate job, and the guide to ChatGPT SEO tools explains the two kinds of tools built for it.

What an XML sitemap does, and what it doesn't

Google describes a sitemap as a file with information about the pages, videos and other files on a site, which search engines read "to crawl your site more efficiently." In practice it does three jobs:

  • Discovery. It lists URLs a crawler might never reach through links, such as new pages or pages buried deep in the site.
  • Recrawl scheduling. An accurate lastmod tells Google and Bing which known URLs changed since their last visit.
  • Diagnosis. Once you submit it, Search Console tells you how many URLs it parsed and lets you filter its indexing report by that sitemap.

What it doesn't do matters just as much. Google's guide to building and submitting a sitemap (opens in a new tab) calls submitting one "merely a hint" and says it doesn't guarantee that the URLs in it will be crawled or indexed. It won't make a thin page rank. It is also a weak canonical signal: Google's canonicalization guide ranks redirects and rel="canonical" annotations as strong signals, and sitemap inclusion as a weak one. When the sitemap and the canonical tag disagree, a weak signal is up against a strong one.

Google accepts XML, RSS, mRSS or Atom 1.0 feeds, and plain text files with one URL per line, with no preference among them. XML is the usual choice because it can also carry image, video, news and alternate-language data. An HTML sitemap, a page of links written for visitors, isn't one of the formats Google lists for submission.

When you need a sitemap, and when you can skip it

There are three situations where Google's guide says a sitemap helps:

  1. The site is large. The more pages you have, the harder it is to make sure each one is linked from at least one other page.
  2. The site is new and has few external links. Crawlers find pages by following links, so a young site gives them few ways in.
  3. The site has a lot of video or images, or appears in Google News. Sitemaps can carry extra data about those files.

It also lists when you might not need one: a "small" site of about 500 pages or fewer (counting only pages you want in search results), with every important page reachable through links from the homepage, and few media files or news articles you care about in search.

Even below that size, if your CMS already publishes a sitemap (Google names WordPress, Wix and Blogger as platforms that usually do), keep it and submit it: it costs nothing, and the indexing diagnostics alone are worth it. What a sitemap can't replace is link structure. A URL that only appears in the sitemap gets found, but no links pass context or authority to it, so fix internal linking first.

Which URLs belong in your sitemap, and which don't

Google's rule is short: include the URLs you want to see in search results. Those are your canonical URLs. Everything else is noise that makes the indexing report harder to read.

URL typeIn the sitemap?Why
Canonical, indexable pages that return 200YesThese are the pages you want in search results
Redirected URLs (301, 302)NoList the final URL instead; Search Console flags redirect chains as "URLs not followed"
Deleted pages (404)NoRemove them from the file as soon as they go
Pages with a noindex tagNoThe sitemap asks for indexing and the tag forbids it
URLs blocked by robots.txtNoSearch Console reports "Sitemap contains urls which are blocked by robots.txt"
Duplicates, tracking parameters, sort ordersNoList only the version your canonical tag points to
Internal search results, cart, account and login pagesNoNo searcher needs to land there
Separate mobile and desktop URLsOne of themGoogle recommends listing only one version, or annotating both
Paginated pages (page 2 onward)Only if they are indexable and canonical to themselvesFollow your own canonical setup

Write every URL in full (https://www.example.com/mypage.html, not /mypage.html) and on the same protocol and host as the sitemap file; a www sitemap listing non-www URLs triggers a path mismatch error. Order doesn't matter to Google.

Pagination is where guides disagree, and the consistent answer is to follow your own setup. If page 2 of a category is indexable and canonical to itself, list it. If you canonicalize it to page 1 or mark it noindex, leave it out. The sitemap, the canonical tag, robots.txt and the robots meta tag should all say the same thing about each URL; Google's canonicalization guide warns specifically against naming one URL in the sitemap and another in rel="canonical".

On bigger sites, split the sitemap by page type (products, categories, articles). Google notes that several sitemaps can be tracked separately in Search Console, so an indexing problem in one section stands out instead of hiding in a site-wide total.

lastmod: the one optional tag still worth keeping

The protocol defines three optional tags per URL: lastmod, changefreq and priority. Google ignores priority and changefreq, and Bing's July 2025 post says Bing does too. Delete both and spend the effort on lastmod.

Google uses lastmod "if it's consistently and verifiably" accurate. It should record the last significant change, meaning the main content, the structured data or the links, and not a new copyright year. In its June 26, 2023 post, Google said it uses lastmod to schedule recrawls of known URLs, with a blunt warning: a page that changed seven years ago but claims it changed yesterday will eventually stop being believed. Leaving lastmod out is fine for pages your software can't date, such as a category page that aggregates others.

Bing has measured how often this goes wrong. In a February 1, 2023 study (opens in a new tab) of sites with at least one URL in its index, 58% of hosts had at least one XML sitemap Bing knew about, and 42% had none. Among those sitemaps, 84% set lastmod, and 18% had lastmod values that were not set correctly. The most common mistake was the same date on every URL, which is what you get when the value is the sitemap's build time instead of each page's change date.

Dates follow the W3C Datetime format. Search Console accepts a date alone (2005-02-21) or a date with time (2005-02-21T18:00:15+00:00); a time without a time zone triggers an "Invalid date" error. Bing asks for ISO 8601 with both date and time.

Put together, an entry is small. This is what Google's basic example holds (in the file, each element name sits between angle brackets, with a closing tag after its value):

ElementRequiredWhat it holds
urlsetYesThe root of the file, declaring the namespace http://www.sitemaps.org/schemas/sitemap/0.9
urlYesOne block per page
locYesThe page's absolute URL, such as https://www.example.com/foo.html
lastmodNoThe date of the last significant change, such as 2022-06-04
changefreq, priorityNoIgnored by Google and Bing, so leave them out

To keep lastmod honest:

  • Take the value from the content's real modified date, never from the time the sitemap was generated.
  • Leave it unchanged for footer, sidebar and copyright edits.
  • When your system can't tell the real date for a URL, omit lastmod there.

Size limits and sitemap index files

The protocol caps every sitemap at 50,000 URLs and 50MB (52,428,800 bytes) uncompressed. You can gzip the file, but the limit applies to the uncompressed size. The file must be UTF-8, and characters such as the ampersand have to be entity-escaped (& becomes &), or Search Console reports a parsing error.

Past the limit, you split the list into several sitemaps and point to them from a sitemap index. It has the same shape with different names: a sitemapindex root, one sitemap block per child file, and inside each block a loc with the child file's full URL (for example https://www.example.com/sitemap1.xml.gz) plus an optional lastmod.

Index files have their own rules:

  • One level only. An index lists sitemap files, never other indexes; Google reports nesting as an error.
  • Up to 50,000 sitemaps per index. Bing's July 2025 post works out that one index can therefore reference up to 2.5 billion URLs.
  • Same site, same folder or deeper. Google requires the child sitemaps to sit on the same site as the index, in its directory or below, unless you set up cross-site submission.
  • Up to 500 index files per site can be submitted in Search Console.
  • lastmod in an index describes when the child sitemap file changed, not the pages inside it.

Location matters too. Google recommends the site root, because a sitemap in a subfolder only covers URLs in that folder and below, unless you submit it in Search Console.

Images and video can go into the same files through Google's sitemap extensions. Whether you need them depends on how your pages load media, and the section on image sitemaps covers when a separate image sitemap earns its place.

On WordPress, core publishes its own sitemap index and most SEO plugins replace it with theirs, so check which one is live before you submit; step 3 of the WordPress SEO setup walks through it.

How to submit a sitemap to Google and Bing

There are two ways to tell search engines where your sitemap is: submit it in their webmaster tools, or name it in robots.txt. Do both.

Google Search Console

The Search Console Help page lays out the steps:

  1. Publish the sitemap on your site, ideally at the root.
  2. Confirm Googlebot can fetch it. Run a live test in the URL Inspection tool and check that Page fetch says "Successful". The file can't sit behind a login or a robots.txt rule.
  3. Open the Sitemaps report under Indexing, paste the URL into "Add a new sitemap" and click Submit.
  4. Come back later to confirm the status is Success.

Submitting needs owner permissions on the property; without them, use robots.txt. Google fetches a sitemap as soon as you submit it, then recrawls it "at a pace independent of the site crawl schedule", so resubmit only after big changes.

The Sitemap line in robots.txt

Add one line anywhere in robots.txt:

Sitemap: https://www.example.com/sitemap.xml

Google sets no limit on how many Sitemap lines you add, and Bing reads the same line. It is also how you point to a sitemap hosted on another domain.

Bing Webmaster Tools and IndexNow

Bing fetches a sitemap as soon as you submit it in Bing Webmaster Tools or reference it in robots.txt, then revisits it "typically at least once per day." For individual changes, Bing pairs sitemaps with IndexNow, a protocol that notifies participating engines when a URL is added, updated or removed. The full setup, including how Bing reads RSS and text sitemaps, is in our Bing SEO guide.

Sitemap pings no longer do anything

Some older plugins still "ping" search engines with a sitemap URL. Google deprecated its sitemaps ping endpoint (opens in a new tab) on June 26, 2023, saying its own studies and other search engines such as Bing found those unauthenticated submissions not very useful. Pings to Google now return a 404. They do no harm, but they do nothing either.

How to read the Sitemaps report in Search Console

The Sitemaps report (opens in a new tab) shows one row per submitted sitemap, with its type (sitemap, sitemap index, RSS or Atom), the date you submitted it, the last time Google read it, a status and the number of discovered pages and videos. The status describes the latest fetch:

  • Success: fetched and processed with no errors, and every URL queued for crawling.
  • Has errors: fetched, but with one or more errors. URLs that parsed correctly are still queued.
  • Couldn't fetch: Google couldn't retrieve the file at all.

Most misreadings come from four details:

  • Discovered pages is not indexed pages. It counts URLs parsed from the file. "See index coverage" opens the Page indexing report filtered to that sitemap, with the reason each missing URL isn't indexed.
  • Only submitted sitemaps appear. One found through robots.txt won't show until you submit it, and an http, https, www or non-www property mismatch can hide it.
  • The report lists at most 1,000 submissions. Google says there is no way to see more in Search Console.
  • Removing a sitemap doesn't make Google forget its URLs. To stop crawling, use robots.txt, delete the file or add noindex (as a response header for the sitemap itself).

When a fetch fails, Google retries for a few days and then stops, so fix the cause and resubmit.

Common sitemap errors and how to fix them

Error in the reportUsual causeFix
Couldn't fetchWrong URL (404), a robots.txt block, a server error, an unresolved manual action or low crawl demandRun a live URL Inspection test and look for Crawl allowed "Yes" and Page fetch "Successful"
Parsing errorAn unescaped character, usually & in a URLEntity-escape every value
Invalid dateWrong format, or a time without a time zoneUse 2005-02-21 or 2005-02-21T18:00:15+00:00
URL not allowed, Path mismatchURLs on another host, protocol or www variant, or above the sitemap's folderMatch the sitemap's host and keep URLs in its folder or below
URLs not followedToo many redirectsReplace each redirect with its final URL
Nested sitemap indexesAn index that lists another indexList only sitemap files
Too many URLsMore than 50,000 URLs in one fileSplit it and use a sitemap index
Sitemap contains urls which are blocked by robots.txtA Disallow rule covers listed URLsRemove the URLs or change the rule

Sitemaps and AI search: what is documented and what isn't

AI answers add a reason to keep a sitemap clean, but the documentation is uneven.

What Bing has said

On July 31, 2025, Bing product managers Fabrice Canel and Krishna Madhavan published Keeping Content Discoverable with Sitemaps in AI Powered Search (opens in a new tab). Their core claim: sitemaps "remain a foundational signal for ensuring comprehensive URL coverage." Freshness signals, they wrote, affect how quickly updates show up in search results and AI generated answers, and lastmod tells Bing which URLs to recrawl and which to skip.

Their recipe is a complete XML sitemap with accurate lastmod, the Sitemap line in robots.txt and IndexNow for individual changes, with a caveat: no tool can guarantee when or how content appears in AI-generated results.

A Bing post from May 6, 2026 explains why freshness weighs more when an index grounds AI answers: "In grounding, a stale fact produces a misleading response."

What Google has said

Google's guide to its generative AI features (last updated July 10, 2026) says a page must be indexed and eligible to show with a snippet to appear in those features. It also says you don't need new machine-readable files or AI text files to appear in Google Search, including its AI features. For AI Overviews and AI Mode, then, the sitemap does the same job it does for regular Search: it helps the URL get found and indexed. There is no separate AI sitemap.

What OpenAI, Anthropic and Perplexity document

OpenAI's crawler overview, Anthropic's help article on its crawlers and Perplexity's guide to its bots, all read on November 17, 2026, describe their user agents (GPTBot, OAI-SearchBot and ChatGPT-User; ClaudeBot and Claude-SearchBot; PerplexityBot and Perplexity-User), how they follow robots.txt and, for OpenAI and Perplexity, where to find their IP ranges. None of the three mentions XML sitemaps.

So there is no public documentation that GPTBot, ClaudeBot or PerplexityBot read sitemaps. They might; none of these companies has said so. What they do document is robots.txt, which is where AI crawlers get blocked by accident, and our free AI crawler checker reads it bot by bot. For hard evidence on sitemaps, check your server logs for requests to the sitemap file from those user agents.

Slibur dataChatGPT, United States, 4 answers, November 17, 2026

What ChatGPT says about sitemaps

We asked ChatGPT four questions on November 17, 2026, from the United States:

  • Do I need an XML sitemap for SEO, and does it actually help rankings?
  • Which pages should I include or exclude from my XML sitemap?
  • How do I submit a sitemap to Google Search Console, and what do the statuses in the Sitemaps report mean?
  • Do AI crawlers like GPTBot, ClaudeBot and PerplexityBot use XML sitemaps?

The answers were accurate and leaned on primary sources. Three of the four cited Google's own documentation, on developers.google.com or the Search Console Help Center. The answer about which pages to include cited nothing, and the one about AI crawlers also cited OpenAI's and Anthropic's crawler pages and a post on Perplexity's developer forum.

Websites ChatGPT cited most in its answers about sitemap SEO (November 17, 2026)

Websites ChatGPT cited as sources

  1. developers.google.com2 of 4 answers
  2. community.perplexity.ai1 of 4 answers
  3. developers.openai.com1 of 4 answers
  4. support.claude.com1 of 4 answers
  5. support.google.com1 of 4 answers
Source: Slibur, ChatGPT answers from the United States, November 17, 2026.

A few patterns stood out:

  • No rankings promise. Two of the four answers said a sitemap doesn't guarantee crawling or indexing, and the first called it "not a ranking factor."
  • Bing was missing. None of the four mentioned Bing, Bing Webmaster Tools or IndexNow, although Bing is the one search engine with sitemap guidance written for AI answers.
  • An honest hedge on AI crawlers. ChatGPT's verdict was "sometimes, but don't assume they do", noting that none of the three companies publicly commits to sitemap support, which matches the documentation above.
  • Pagination by the same rule. ChatGPT would list paginated pages when each one is independently valuable and indexable, which matches the follow-your-own-canonical rule above.
  • No tools named. Apart from a passing mention of WordPress plugins, no answer recommended a sitemap generator or SEO product.

The lesson is about where AI answers get their facts. On a technical question, ChatGPT went straight to the companies that set the rules. If your business owns the definitive page on its own subject (your specs, your pricing, your process), that page is the one an AI answer has a reason to cite.

A sitemap SEO checklist

Run through it whenever you launch a site, migrate one or change your CMS:

  • Only canonical, indexable URLs that return 200: no redirects, 404s, noindex pages or parameter duplicates.
  • Absolute URLs on the same protocol and host as the sitemap.
  • lastmod from the real content date, or left out; no priority or changefreq.
  • Under 50,000 URLs and 50MB uncompressed per file, UTF-8, entity-escaped, no nested indexes.
  • Submitted in Search Console and Bing Webmaster Tools, and named on a Sitemap line in robots.txt.
  • Sitemaps report on Success, with every non-indexed URL explained in the Page indexing report.
  • No robots.txt rule blocking the AI crawlers you want on your site.

Slibur's free 18-point GEO audit checks your homepage, robots.txt, sitemap and llms.txt in one pass. Once the technical side is in order, the open question is whether AI answers mention you at all. Slibur asks ChatGPT, Google AI Overviews, Claude, Perplexity and Grok your buyers' questions and shows whether they name your brand, who shows up instead and which sources they cite. You can try it for 7 days free, no card required.

Frequently asked questions

Does a sitemap improve SEO rankings?

Not directly. Google calls a sitemap a hint that helps it discover and schedule URLs, with no guarantee that listed URLs get crawled or indexed. The value is indirect: important pages are found and recrawled sooner, and Search Console shows which listed URLs are indexed and why the others aren't.

How many URLs can one XML sitemap hold?

Up to 50,000 URLs and 50MB uncompressed per file, under the sitemaps.org protocol that Google and Bing follow. Past that, split the list into several sitemaps and list them in a sitemap index, which can reference up to 50,000 sitemaps. An index can't list other index files.

Should noindex or redirected pages be in my sitemap?

No. A sitemap should list only canonical URLs that return 200 and allow indexing. A noindex page sends a contradictory signal, a redirect should be replaced by its final URL, and URLs blocked by robots.txt trigger a warning in Search Console.

Does Google use priority and changefreq in sitemaps?

No. Google's documentation says it ignores both values, and Bing said the same in its July 31, 2025 post. The only optional tag worth keeping is lastmod, and only when it reflects the date of the last significant change to the page.

How often do Google and Bing read a sitemap?

Both fetch a sitemap as soon as you submit it. Google then recrawls it at a pace independent of the rest of the site, and Bing says it revisits sitemaps typically at least once per day. If a fetch keeps failing, Google stops trying after a few days, so fix the error and resubmit.

Do GPTBot, ClaudeBot and PerplexityBot read XML sitemaps?

Nobody has documented it. The crawler pages of OpenAI, Anthropic and Perplexity, read on November 17, 2026, cover user agents and robots.txt but don't mention sitemaps. Bing is the one search engine that has tied sitemaps and lastmod to AI-generated answers. Your server logs show whether those bots request your sitemap file.

What is the difference between an XML sitemap and an HTML sitemap?

An XML sitemap is a file for search engines that lists URLs and, optionally, their last change date. An HTML sitemap is an ordinary page of links for visitors. Only the XML version, along with RSS, Atom and text files, is a format Google accepts for sitemap submission.

About the author

Founder of Slibur

Raúl Díaz is the founder of Slibur, the tool that asks ChatGPT, Google AI Overviews, Claude, Perplexity and Grok the questions your customers ask and shows which brands they recommend. He writes about answer engine optimization from the data Slibur collects.

  • Technical seo

    Microsite SEO: Separate Site or Folder, and What to Do When the Campaign Ends

    For SEO, a microsite on its own domain starts from zero. Its links, Search Console property and analytics sit apart from your main site, while a folder such as example.com/launch shares all three and a subdomain sits in between. Build one only for a separate brand or audience, and plan its 301 redirects before launch.

    12 min read

  • Technical seo

    Subdomain SEO: Subdomain or Subfolder for Your Blog, Store, Help Center and App

    Subdomain SEO comes down to one fact. Google has no ranking preference between blog.example.com and example.com/blog, but it treats every hostname as its own site for crawling, crawl budget and robots.txt. Keep content that should rank together in subfolders, and use a subdomain only when the platform, team or risk behind a section is separate.

    11 min read

  • AI crawlers

    Python for SEO: 6 Short Scripts for Sitemaps, Canonicals, Search Console and AI Crawlers

    Python for SEO is a set of scripts that take over the checks you repeat every week: listing the URLs in a sitemap, testing status codes and canonical tags, joining that crawl with Search Console data, grouping queries, and reading robots.txt the way GPTBot or ClaudeBot does. The six scripts below need only the Python standard library.

    12 min read