For the complete documentation index, see llms.txt. Every page on this site is also served as Markdown: append `.md` to any URL, or send `Accept: text/markdown`.
Skip to content
Attensira LogoAttensira

Glossary term

XML sitemaps

An XML sitemap is a file listing the URLs you want search engines to discover, each with an optional last-modified date. It is a hint: listing a URL does not make it crawled or indexed. One file holds at most 50,000 URLs or 50 MB, and Google uses lastmod only when it is consistently accurate.

7 days free · card required

Pull requestexample-co/website · #214

Drop two redirected URLs from the sitemap and stop re-stamping lastmod

Waits for your approval

public/sitemap.xml

  1. unchanged: <url><loc>https://example.com/pricing</loc><lastmod>2026-09-12</lastmod></url>
  2. removed: <url><loc>https://example.com/old-pricing</loc><lastmod>2026-10-04</lastmod></url>
  3. removed: <url><loc>https://example.com/blog?page=2</loc><lastmod>2026-10-04</lastmod></url>
  4. removed: <url><loc>https://example.com/blog</loc><lastmod>2026-10-04</lastmod></url>
  5. added: <url><loc>https://example.com/blog</loc><lastmod>2026-09-30</lastmod></url>
Example · example pull request on an example site
Karl-Gustav KallasmaaKarl-Gustav Kallasmaa, Founder & CEO

Last updated

Key facts

A sitemap is a list of the URLs a site wants crawlers to know about. Search engines find most pages by following links; a sitemap covers the ones links miss and tells crawlers when something changed. It is one of the few things in SEO that is fully specified, and also one of the most commonly faked.

How does an XML sitemap work?

The format comes from sitemaps.org. Each URL is a <url> with a <loc> and, optionally, a <lastmod>:

xml
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>https://attensira.com/glossary/robots-txt</loc>
    <lastmod>2026-10-04</lastmod>
  </url>
</urlset>

One file holds at most 50,000 URLs or 50 MB uncompressed. Larger sites split into several files and publish a sitemap index that lists them. Crawlers learn where the sitemap is from a Sitemap: line in robots.txt, or from a submission in Google Search Console or Bing Webmaster Tools.

What does Google actually use?

Google is explicit about it:

FieldWhat Google does with it
locDiscovers the URL
lastmodUses it if it is consistently and verifiably accurate
changefreqIgnores it
priorityIgnores it

And the whole file is "merely a hint". Google may not download it, and listing a URL does not get it crawled or indexed.

The lesson is about lastmod. A sitemap generator that stamps every URL with the time of the last build makes every page look changed every day. A crawler that learns the dates are noise stops using them, for the whole site.

What does a real sitemap look like?

Here is how attensira.com builds its own. The robots.txt ends with Sitemap: https://attensira.com/sitemap-index.xml, and that index lists twelve files, /sitemap/0.xml to /sitemap/11.xml, one or more per content family: static pages, compare, features, tools, glossary, blog, guides, bots and the rest.

The dates come from git, not from the build clock. A script finds the last commit that touched the files that actually produce each page and writes that date. A page whose files have no history gets no lastmod at all, rather than a made-up one. A change to a shared template dates the family's index page, not every page under it, so one template fix does not re-stamp hundreds of URLs on the same day. There is no changefreq and no priority, because nobody reads them.

Pages from the content tree, like this one, are dated by their own last-updated field. This page's lastmod changes when its content changes, and at no other time.

How does one site split its sitemap?

attensira.com's robots.txt points at one sitemap index, and the index lists twelve files, one per group of page families. Search Console then reports indexing per group, so a family Google is rejecting shows up on its own instead of inside one site-wide number.

attensira.com/sitemap-index.xml · twelve files
attensira.com/sitemap-index.xml · twelve files
FileHolds
/sitemap/0.xmlStatic and legal pages
/sitemap/1.xmlCompare and alternatives
/sitemap/2.xmlFeatures and industries
/sitemap/3.xmlPlatform visibility and tools
/sitemap/4.xmlGlossary, including this page
/sitemap/5.xmlBlog
/sitemap/6.xmlGuides and best-of lists
/sitemap/7.xmlBots
/sitemap/8.xml to 11.xmlData, MCP use cases, concepts, integrations
attensira.com sitemap index, as the site's code builds it ·

Indirectly. AI search engines find pages through their own crawlers and through search indexes such as Bing's and Google's, and those use sitemaps for discovery like any crawler. No AI operator documents a sitemap as a reason to cite a page. A sitemap gets a page found sooner; whether the answer uses it depends on what the page says.

Attensira reads sitemaps for a different reason. It keeps an inventory of every URL your site publishes, so the crew can reason about pages no engine has cited yet. A web reader maps the domain; when it is unavailable, the inventory falls back to /sitemap.xml or the sitemaps your robots.txt declares, and then a page missing from your sitemap is missing from the inventory too.

What do people get wrong about sitemaps?

  • Listing URLs that are not canonical. Redirects, parameters and noindex pages in a sitemap send mixed signals. List only the URL you want indexed.
  • Fake lastmod dates. Stamping the build time on everything teaches crawlers to ignore the field.
  • Forgetting the robots.txt line. A sitemap no crawler knows about does nothing.
  • Blocking the listed URLs in robots.txt. A URL can be in the sitemap and disallowed at the same time; the disallow wins.
  • Treating submission as indexing. It is a request to look, not a promise to keep.

How can you check yours?

The free XML sitemap validator fetches a sitemap or index and checks it against the protocol: the namespace, the URL and size limits, lastmod formats, duplicates, URLs on another host, and whether robots.txt declares it. In a workspace, sitemaps at the root are among the files the crew's web engineer may change, and a fix arrives as a pull request like the one at the top of this page, waiting for your approval. That is the service of an SEO agency at the price of a tool.

Questions about XML sitemaps

What is an XML sitemap?
A file, usually at /sitemap.xml, that lists the canonical URLs of a site in the format defined by sitemaps.org. Each entry has a loc and may carry a lastmod date. A sitemap index file lists other sitemap files, for sites too large for one.
How many URLs can one sitemap hold?
50,000 URLs or 50 MB uncompressed, whichever comes first, under the sitemaps.org protocol. The same limits apply to a sitemap index file. Larger sites split their URLs across several sitemaps and list them in an index.
Does a sitemap guarantee my pages get indexed?
No. Google calls submitting a sitemap merely a hint: it does not guarantee Google will download it or crawl the URLs in it. Pages still have to be reachable, allowed in robots.txt, and worth indexing.
Do priority and changefreq matter?
Not to Google, which says it ignores both. It uses lastmod if the value is consistently and verifiably accurate. A lastmod stamped with today's date on every build teaches Google to distrust it.
Do AI search engines use sitemaps?
Their crawlers are web crawlers, and Bing's index, which several AI products search, uses sitemaps like Google's does. None of the major AI operators documents sitemaps as a citation signal. A sitemap helps a page get found; it does nothing for whether an answer uses it.

Where do these facts come from?

5 sources: each statement with the page it came from and the day it was checked.

  1. The sitemaps.org protocol limits each sitemap file to no more than 50,000 URLs and no larger than 50MB (52,428,800 bytes), with the same limits applying to a sitemap index file.

    sitemaps.org · retrieved

  2. Google states that all sitemap formats limit a single sitemap to 50MB uncompressed or 50,000 URLs, that it ignores priority and changefreq, that it uses lastmod if it is consistently and verifiably accurate, and that submitting a sitemap is merely a hint.

    developers.google.com · retrieved

  3. Attensira keeps an inventory of every URL a workspace's site publishes, made by its web reader with the home page always included; when the web reader is unavailable it falls back to /sitemap.xml or the sitemaps robots.txt declares, and in that fallback a page missing from the sitemaps is not discovered. Discovery re-runs once a day.

    docs.attensira.com · retrieved

  4. Attensira's own sitemap index at attensira.com/sitemap-index.xml lists twelve sitemap files, one per group of page families, as built from the site's code on 4 October 2026.

    attensira.com · retrieved

  5. Attensira's default editable paths for the crew include sitemaps, robots.txt and llms.txt at the root of a connected repository.

    docs.attensira.com · retrieved

Want whatever it takes to win the answer?

7 days free · card required