A sitemap tells search engines which URLs exist and when each one last changed, and for AI visibility its value is indirect: it feeds the search indexes that answer engines retrieve from. The bottom line: list every indexable page once, make lastmod an accurate date, skip the fields Google ignores, submit the file to both Google Search Console and Bing Webmaster Tools, and do not mistake a sitemap for an AI specific file, because Google says none is needed.

For a full definition, read our answer engine optimization guide.

What a sitemap does and why it matters for AI

The sitemaps protocol, published at sitemaps.org, lets a site list its URLs in an XML file. Each file may contain up to 50,000 URLs and be up to 50 MB uncompressed, and a sitemap index file can group several. It is a discovery hint, not a guarantee of indexing. The AI connection is through the indexes answer engines use. Seer Interactive checked more than 500 SearchGPT citations in early 2025 and found 87 percent matched Bing's top results, and Google's AI Overviews and AI Mode draw on Google's index. A page that is not in those indexes cannot be retrieved from them.

What to put in it

ElementUse it?Why
locYesThe full canonical URL of each page you want indexed
lastmodYes, only if accurateGoogle uses it when it is consistently and verifiably accurate, and ignores it otherwise
changefreqNoGoogle's documentation says it ignores this value
priorityNoGoogle's documentation says it ignores this value

The lastmod mistake, including on our own site

The most common error is stamping the build date or today's date on every URL, so the whole site appears to change daily. We found exactly this in our own sitemap generators: both write the current date as lastmod for every page. A search engine that learns your lastmod values are not reliable stops trusting them, which removes the one field that helps it prioritize recrawling. The fix is to take the date from the page itself, such as the dateModified in its Article markup, and to leave lastmod out when no true date exists.

Steps

  1. List only indexable, canonical URLs. Leave out redirects, noindex pages, duplicates, and URLs that return errors.
  2. Set lastmod from the real modification date. Use the date of the last meaningful content change.
  3. Split large sites. Stay under 50,000 URLs and 50 MB per file and use a sitemap index to group them.
  4. Reference it in robots.txt. Add a Sitemap line with the full URL.
  5. Submit it in Google Search Console. Use the Sitemaps report and check for errors.
  6. Submit it in Bing Webmaster Tools. If your site is verified in Search Console you can import it, and Bing validates ownership through that connection.
  7. Regenerate it when pages are added or changed. Automate it in your build so it never goes stale.
  8. Add IndexNow for Bing. A sitemap is the full inventory. IndexNow notifies Bing of individual changes as they happen.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>https://www.example.com/services/emergency-plumbing</loc>
    <lastmod>2026-09-12</lastmod>   <!-- the date the page's content last changed -->
  </url>
</urlset>

# robots.txt
Sitemap: https://www.example.com/sitemap.xml

What a sitemap is not

An llms.txt file is not a sitemap and does not replace one. Google states you do not need to create new machine readable files, AI text files, or markup to appear in AI Overviews or AI Mode, and BlueGrid Media notes llms.txt is not a confirmed ranking factor for any single engine. Build the sitemap for search engines, and treat llms.txt as optional housekeeping.

Questions people ask

Does a sitemap help AI visibility?

Indirectly. It helps search engines discover pages, and answer engines retrieve from those indexes. Google says no AI specific file is required to appear in AI Overviews.

What is the size limit for a sitemap?

Each sitemap file can hold up to 50,000 URLs and be up to 50 MB uncompressed. Use a sitemap index file to combine several.

Should I include priority and changefreq?

No. Google's documentation says it ignores both values.

Why should lastmod be accurate?

Google uses lastmod only when it is consistently and verifiably accurate. Stamping today's date on every URL teaches search engines to ignore it.

Sources