An XML sitemap is a machine-readable file that lists the canonical URLs a site wants Google, Bing, and other search engines to discover. The file also carries optional metadata about meaningful page updates, alternate-language versions, images, video, and news content. Within technical SEO, the sitemap is the clearest declaration of a site’s preferred search inventory.

The sitemap’s most useful role goes beyond discovery. A clean sitemap declares the site’s intended indexable inventory. Compare that declaration with a Screaming Frog crawl and the Google Search Console Page indexing report, and the gaps reveal orphan pages, stale URLs, accidental exclusions, and page groups Google has yet to process.

A sitemap is your declared search inventory. Its diagnostic value comes from every URL you include, every URL you exclude, and the patterns in between.

XML sitemap requirementRecommended treatment
Included URLsCanonical, indexable URLs returning 200
Excluded URLsRedirects, errors, duplicates, noindex pages, and blocked URLs
Maximum file size50 MB uncompressed
Maximum URLs per file50,000
Required URL tag<loc> with a full absolute URL
Useful optional tagAccurate <lastmod> after a significant update
Ignored by Google<priority> and <changefreq>
SubmissionSearch Console Sitemaps report, Search Console API, or a Sitemap: line in robots.txt
Retired by GoogleThe sitemap ping endpoint (deprecated June 2023)
Best generatorThe CMS or application that publishes the URLs

Google’s sitemap documentation treats the file as a discovery aid: a sitemap “doesn’t guarantee that all the items in your sitemap will be crawled and indexed.” That distinction matters. A valid sitemap can still list weak, duplicated, blocked, redirected, or poorly linked pages. This relationship between discovery and eligibility is one of the core SEO fundamentals.

XML sitemap design is one part of the system I review in technical SEO consulting. The work starts with the intended inventory, then aligns generation, canonicals, directives, internal links, and monitoring around it.

What is an XML sitemap?

An XML sitemap is a structured file that gives search engines a list of URLs and optional metadata about those URLs. XML stands for Extensible Markup Language, a format designed for machines to read consistently, and the file follows the Sitemaps.org protocol, the shared standard that names Google, Yahoo, and Microsoft as supporters.

What does an XML sitemap example look like?

An XML sitemap example needs only three elements: a <urlset> wrapper that declares the Sitemaps.org namespace, one <url> entry per page, and a <loc> holding each page’s absolute URL. A basic file can be very short:

sitemap.xml
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
  <loc>https://www.example.com/platform</loc>
  <lastmod>2026-09-28</lastmod>
</url>
<url>
  <loc>https://www.example.com/pricing</loc>
  <lastmod>2026-09-14</lastmod>
</url>
</urlset>

The file above contains two page entries. Each <loc> value is a complete URL. Each <lastmod> value records the date of the last significant update to that page.

Google also discovers pages through crawlable links, redirects, feeds, and previously known URLs. A sitemap adds a direct, structured source. Google’s own sitemap overview names the clearest cases: large sites, new sites with few external links, and sites with substantial video, image, or Google News content. Sites where important pages sit deep in the architecture belong on that list too.

What is the purpose of an XML sitemap?

The purpose of an XML sitemap is to help search engines discover preferred URLs and to give site owners a measurable view of the submitted inventory. Those two jobs support different parts of technical SEO. For sitemap SEO, consistency between the file and every page-level signal carries more value than extra optional tags.

XML sitemaps support URL discovery

A sitemap gives Googlebot and Bingbot a direct list of pages the site considers important. This helps when internal discovery is slow, the site is new, an inventory is large, or new URLs launch frequently.

Discovery is the first step of Google’s crawl, index, and serve pipeline. Googlebot still decides whether to request the URL, render it, index it, and show it for a query. Strong internal linking remains essential because links communicate context, relationships, and relative importance in ways a flat list cannot.

XML sitemaps create a diagnostic cohort

The Search Console Sitemaps report shows each submitted file’s type, last read date, status (Success, Has errors, or Couldn’t fetch), and discovered pages. Google’s Sitemaps report help adds the feature that makes sitemaps a diagnostic tool: “You can filter the Page indexing report by sitemap to see how many page URLs in this sitemap have been indexed.” Child sitemaps therefore create cohorts. If product pages and blog posts live in separate files, a coverage problem affecting one template shows up in one filtered view.

The diagnostic value improves as the grouping becomes more deliberate. A 40,000-URL file satisfies the protocol. Four files grouped by commercial pages, integrations, documentation, and editorial content make the same inventory easier to operate.

XML sitemaps reinforce canonical preferences

Google recommends listing canonical URLs. Google’s canonicalization documentation calls sitemap inclusion “a weak signal,” ranked below redirects and rel="canonical". A sitemap therefore becomes one signal in a larger canonical system. The page’s canonical tag, redirect behavior, internal links, hreflang annotations, and sitemap entry should identify the same preferred URL.

Conflicts weaken the declaration. A sitemap that lists an HTTP URL while the page canonicals to HTTPS asks Google to reconcile two choices. The fix is to make the site’s outputs agree.

Which URLs belong in an XML sitemap?

An XML sitemap should include every canonical page that returns 200, permits indexing, and deserves a place in search. Apply that rule by template and page role, then test representative URLs from each group.

URL stateSitemap treatmentReason
Canonical, indexable 200 pageIncludeThis is the preferred search URL
301 or 302 redirectExcludeList the final canonical destination
404, 410, or 5xx responseExcludeThe URL has no stable indexable resource
noindex pageExcludeThe directives disagree about search eligibility
Duplicate or parameter variantExcludeList the preferred canonical version
URL blocked in robots.txtExcludeGoogle cannot reliably fetch and evaluate it
Paginated URLDecide from its search roleInclude when it is a canonical, indexable discovery page
Localized canonical URLInclude with valid hreflang annotationsEach approved language or region page can be listed

For B2B SaaS, the included inventory often covers the homepage, pricing, platform, feature, use-case, industry, integration, public documentation, and intentional editorial pages. It commonly excludes account screens, internal search results, preview environments, tracking variants, filtered combinations with no distinct demand, and expired campaign pages.

The phrase “all pages” causes trouble here. A SaaS site with tag archives, filters, and tracking parameters easily exposes thousands of reachable URLs that have no search role. The sitemap belongs to the preferred search inventory, which is a deliberate subset of everything the application can serve.

The four-inventory XML sitemap audit

The four-inventory audit compares intended URLs, crawl-discovered URLs, sitemap-listed URLs, and Google-known URLs. Each source answers a different question, and the differences point to specific technical problems.

Inventory 1: URLs the business intends to index

The intended inventory is the source of truth for the whole XML sitemap audit. Build it from approved page types, the CMS or database, product requirements, keyword mapping, and the site’s architecture. Assign every group an expected response code, index directive, canonical behavior, sitemap status, and internal-link route.

Screaming Frog cannot define this list for you. A crawler reports what the site exposes. Strategy determines which pages deserve exposure.

Inventory 2: URLs a crawler can discover

Run Screaming Frog SEO Spider or another capable crawler from the homepage and approved entry points. This inventory shows which URLs are reachable through links and how they respond.

Compare the crawl with the intended list. An intended URL missing from the crawl may be orphaned, hidden behind JavaScript interaction, linked from an excluded page, or absent from the architecture. An extra crawled group may expose duplicate parameters, old URLs, or unintended templates.

That extra group is where the biggest surprises sit. On a healthcare SaaS account I run, the first technical review found the blog platform generating a duplicate URL for every topic tag, which exposed 292 articles at 620 URLs. The fix was a single platform setting. A Screaming Frog crawl found it, by comparing what the site exposed against a list of what should exist.

Inventory 3: URLs listed in the sitemap

Extract every <loc> value from the sitemap index and its child files. Screaming Frog crawls XML sitemaps directly in List mode, and a sitemap URL extractor gives a quick flat list for a smaller site.

Compare the sitemap list with the intended inventory and the Screaming Frog crawl. Intended URLs missing from the sitemap point to a generator rule or publishing gap. Sitemap URLs missing from the crawl may be orphaned. Crawled redirects, errors, and noindex pages found in the sitemap are stale declarations.

Inventory 4: URLs Google knows

Use the Search Console Page indexing report (filtered by sitemap), the Sitemaps report, and representative URL Inspection checks to see which URLs Google has discovered, crawled, indexed, or excluded. Export by reason and page group where possible.

The Google-known inventory introduces the search engine’s state. A page can appear in all three site-controlled inventories while Google still shows it as discovered, crawled, duplicate, or excluded. At that point, inspect page quality, uniqueness, canonical selection, internal-link support, rendering, and demand.

DifferenceLikely interpretationFirst investigation
Intended, absent from crawlWeak or missing discovery routeInternal links and rendered navigation
Intended, absent from sitemapGenerator or publishing-rule gapCMS eligibility logic
In sitemap, absent from crawlPossible orphan URLInbound internal links
In crawl, absent from intended listUncontrolled URL generationTemplate, parameter, or archive rules
In sitemap, redirecting or noindexStale or conflicting entrySitemap filters and canonical destination
Intended and submitted, unknown to GoogleDiscovery or processing lagSitemap fetch date, links, logs, and URL Inspection
Crawled by Google, excluded from indexQuality or consolidation decisionContent value, duplication, canonical, and rendering

The audit becomes more useful when repeated after a release. Save each inventory with a timestamp, compare additions and removals, and ask whether every change was expected.

XML sitemap audit example: 212 URLs, zero errors, 117 indexed

This site is my worked example. On 2026-11-29, I ran every URL in the live sitemap through the Search Console URL Inspection API, all 212 of them. When I checked on 2026-11-16, Search Console had last read the sitemap on 2026-11-09 with zero errors, and I resubmitted it the next day. The file was clean. Google’s state was not.

URL Inspection status, 2026-11-29Sitemap URLs
Submitted and indexed117 (55.2%)
URL is unknown to Google50
Discovered, currently not indexed36
Crawled, currently not indexed9
Total212

Fifty URLs listed in a sitemap Google had read without an error had no record in Google at all. That includes this guide, which was two days old. The counts come from per-URL inspections, so they cover sitemap URLs only and are not the totals of the Page indexing report. I tracked how long each of those URLs took to reach Google’s results, by page type and age, in how long Google indexing takes.

The split by folder is where the diagnosis starts. Every one of the 17 top-level pages was indexed. The blog had 89 of 176 indexed, and service pages 11 of 19. Within the blog, 74 of the 87 unindexed URLs were posts published in November. The newest pages were the ones Google had not processed, which points at discovery and crawl priority (internal links from pages Google already visits, and time) before it points at page quality. The 9 crawled-not-indexed URLs are the opposite case: Google fetched them and passed, so those are content-quality verdicts.

Repeating the check is what makes it an audit. I had recorded a status for 33 zero-impression URLs on 2026-11-16, and re-inspected all 33 on 2026-11-29:

Change, 2026-11-16 to 2026-11-29URLs
Newly indexed10
Moved from unknown to discovered10
Unchanged, still not indexed7
Moved backward4
Indexed both times2

Seven of the ten newly indexed URLs were service pages. The four that moved backward are as URL Inspection reported them: three went from “discovered, currently not indexed” to “URL is unknown to Google,” and the seo-strategy hub went from indexed to “discovered, currently not indexed.” Three of the seven unchanged pages were crawled-not-indexed posts refreshed on 2026-11-11 whose last crawl was still in August or September, so Google had not yet seen the new versions. A sitemap entry got every one of these URLs onto Google’s list. It decided nothing after that.

How should a B2B SaaS site structure its XML sitemap?

A B2B SaaS site should group child sitemaps by stable page type or business role when those groups have different publishing patterns, owners, or indexation risks. A sitemap index points to each file while Search Console reports on the child inventories.

Consider a software company with this intended inventory:

Child sitemapExample inventoryOperational reason
sitemap-core.xmlHomepage, platform, pricing, company pagesSmall, high-value set with strict QA
sitemap-features.xmlFeature and solution pagesProduct-marketing templates and release cadence
sitemap-integrations.xmlIntegration detail pagesProgrammatic inventory with duplication risk
sitemap-docs.xmlPublic product documentationHigh change frequency and separate owner
sitemap-blog.xmlApproved articles and hubsEditorial workflow and pruning cycle

The cohort view is what isolates a failing template. When one child sitemap’s indexed count trails the others, the problem belongs to one page family, and the investigation starts there. On a SaaS site, that is often an integration sitemap: check whether the thin integration pages share large blocks of copy, whether canonicals collapse variations, whether internal links reach the inventory, and whether the application creates empty states.

A single mixed sitemap would still report a valid file. It would make the affected group slower to isolate.

Segmentation should remain stable enough for trend analysis. Daily files, alphabetical shards, and arbitrary batches satisfy file limits and produce weak diagnostic cohorts. Page type, locale, product family, or publishing system usually yields a more useful operating view.

What is a sitemap index?

A sitemap index is an XML file that lists multiple sitemap files. A sitemap index lets a site submit one parent file to Search Console while preserving separate child inventories for reporting.

sitemap-index.xml
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
  <loc>https://www.example.com/sitemap-core.xml</loc>
  <lastmod>2026-10-03</lastmod>
</sitemap>
<sitemap>
  <loc>https://www.example.com/sitemap-integrations.xml</loc>
  <lastmod>2026-10-05</lastmod>
</sitemap>
</sitemapindex>

Google limits an individual sitemap to 50,000 URLs or 50 MB uncompressed. Split the inventory when either threshold is reached. Operational segmentation can justify smaller child files long before the protocol requires it.

Google’s large-sitemap rules set three more boundaries for a sitemap index:

  • A sitemap index file can hold up to 50,000 <loc> tags, and Search Console accepts up to 500 sitemap index files per site.
  • Child sitemaps must live on the same site as the index, in the same directory or lower, unless cross-site submission is set up.
  • Nested sitemap index files are not supported. An index lists URL sitemaps only, never another index.

The <lastmod> value on a sitemap-index entry refers to the child sitemap’s modification date. Inside a URL sitemap, it refers to a significant change to the page itself.

How do you create an XML sitemap?

Create an XML sitemap from the publishing system’s canonical, indexable URL inventory, validate the output, place it on the site, and submit it to search engines. The generation method should match the size and change rate of the site: WordPress core for a small blog, application code for a 50,000-URL integration directory.

1. Define sitemap eligibility rules

Write the inclusion rule before choosing a sitemap generator. A URL qualifies when it is a preferred canonical page, returns 200, permits indexing, and belongs in search. Translate that rule into fields and states your CMS or application understands.

For example, a blog entry might qualify when its status is published, its canonical domain matches production, its draft flag is false, and its route responds successfully. A product page may also need an active-product state and substantive content.

2. Which XML sitemap generator should you use?

Use the XML sitemap generator closest to the system that publishes and retires the site’s canonical pages. That source updates the file as each URL changes state.

MethodBest fitMain risk
CMS-native sitemapStandard sites where the CMS owns every indexable URLDefault rules may include unwanted archives or omit custom content types
Application or database generationLarge, dynamic, or programmatic inventoriesEligibility logic needs engineering ownership and automated tests
Crawler-generated sitemapSmall static sites, migrations, and temporary recovery workThe file ages quickly and can reproduce crawl-discovery gaps
Manual XML fileA few stable URLsHuman maintenance fails as the site changes
Online sitemap generatorA quick snapshot of a small public siteLimited control, upload steps, and stale output

WordPress core has generated a sitemap index at /wp-sitemap.xml since WordPress 5.5, with a default of 2,000 URLs per child sitemap, and it switches the sitemap off when the site asks search engines not to index it. Yoast SEO and Rank Math replace it with their own sitemaps and add controls for content types and taxonomies. The free version of Screaming Frog crawls up to 500 URLs, which makes it a usable free sitemap generator for a small site; the paid license removes that cap for larger crawls.

The durable choice is the system closest to the source of truth. When a page publishes, changes canonical URL, gains a noindex directive, or retires, the sitemap should update through the same workflow.

3. Generate full absolute URLs

Every <loc> value needs the complete preferred URL, including the protocol and hostname. Choose the final HTTPS URL and the canonical hostname. Keep casing, trailing-slash behavior, and encoded characters consistent with the live canonical.

The file must use UTF-8 encoding, and XML-reserved characters require entity escaping. Follow the Sitemaps.org protocol for syntax and escaping rules.

4. Add accurate modification dates

Use <lastmod> when the publishing system can provide a trustworthy date for a significant page update. Google’s build guide says it uses the value “if it’s consistently and verifiably (for example by comparing to the last modification of the page) accurate,” and it lists changes to main content, structured data, and page links as significant. A copyright-year change does not qualify.

Accuracy compounds. Google announced in June 2023 that it uses <lastmod> “as a signal for scheduling crawls to URLs that we previously discovered,” so a trustworthy date helps Google prioritize recrawls of the pages that actually changed. A deployment timestamp applied to every URL on every release does the opposite. In lintlab’s October 2026 sitemap study of popular sites, 22.0% of the sites with a sitemap used one lastmod value on every URL in a file, which tells Google nothing about which pages changed.

Google ignores <priority> and <changefreq>; its June 2023 announcement repeated that Google “still doesn’t use the changefreq or priority elements at all.” Removing them makes the file simpler and prevents teams from spending time tuning values that Google does not use.

5. Publish and validate the file

Place the sitemap at a stable HTTPS URL. The root is the conventional location and gives a file the broadest default scope: unless you submit it through Search Console, Google says a sitemap “affects only descendants of the parent directory.” Confirm that it returns 200, uses the correct content, opens to search-engine crawlers, and stays available during normal deployments.

Validation has two layers. XML validation proves the file can be parsed. URL validation proves the entries describe the intended inventory. You need both.

How do you submit sitemap to Google?

To submit sitemap to Google, add the file in the Search Console Sitemaps report and declare its absolute URL in robots.txt. Search Console records processing status, last read time, discovered URLs, and errors. This Google sitemap submission gives you a persistent processing record for the file. Submitting through the report requires owner permissions on the property; teams without owner access can rely on the robots.txt line, and engineering teams can submit programmatically through the Search Console API.

The old sitemap ping URL no longer works. Google announced its deprecation on June 26, 2023 and gave it six months to stop functioning, so any deployment script still pinging Google is doing nothing.

The robots.txt declaration is one line:

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

Follow this sequence:

  1. Open the correct Search Console property.
  2. Choose Sitemaps under Indexing.
  3. Enter the sitemap or sitemap-index path.
  4. Submit the file.
  5. Confirm a successful fetch and review the discovered URL count.
  6. Return after Google processes the file and inspect errors by child sitemap.

Submission is a hint. Repeatedly submitting an unchanged file does not create a ranking advantage; Google’s guidance is to resubmit after big changes to a sitemap and otherwise let its regular crawl schedule pick up updates. A meaningful post-launch check confirms that Google fetched the current file and that the discovered count matches the expected inventory.

Bing Webmaster Tools also accepts sitemap submissions. A standards-compliant file serves Google, Bing, and every other engine that reads the Sitemaps.org protocol.

How do you use a sitemap checker?

Use a sitemap checker to verify XML syntax, fetch every listed URL, and compare each response with the intended canonical and indexing state. Search Console is the definitive view of Google’s sitemap processing, while a crawler provides row-level technical QA.

A complete check covers these questions:

  1. Does the sitemap URL return 200 and valid XML?
  2. Can crawlers access the file?
  3. Does every <loc> use the production canonical hostname and protocol?
  4. Does every listed URL return 200?
  5. Is every listed page indexable?
  6. Does each page self-canonicalize to the listed URL?
  7. Are duplicate entries absent across child sitemaps?
  8. Are <lastmod> values valid and tied to meaningful updates?
  9. Do Search Console’s discovered counts match the generated counts?
  10. Do the four inventories reconcile by page type?

In Screaming Frog, crawl the sitemap or upload its URL list, then review status codes, indexability, canonicals, directives, and duplicates. Export the rows and join them with the intended inventory. That turns a generic XML sitemap checker into a release test for the site’s actual rules.

For dynamic sites, automate the same checks in deployment or scheduled monitoring. Alert on sudden count changes, file-fetch failures, non-200 entries, noindex entries, and canonical mismatches. A sitemap count falling from 12,000 to 1,200 deserves attention before the next monthly report.

Which XML sitemap errors matter most?

The most important XML sitemap errors are entries that conflict with the site’s preferred search inventory. A syntactically valid file can still communicate the wrong set of URLs, and the pattern is common even on well-resourced sites. In an October 2026 lintlab study of the 1,000 most popular origins in Chrome UX Report data, 400 exposed a sitemap, and “248 (62.0%) had at least one measured issue.” The most frequent issues were a sampled URL answering with a redirect (23.0%), one lastmod value on every URL in a file (22.0%), and the same URL listed more than once (17.3%).

Lintlab sells a sitemap checker, so treat the figures as a vendor crawl that sampled up to 20 URLs per site. The direction still holds: popularity does not keep a sitemap clean, and a generator rule usually explains every bad entry.

Redirects and error URLs in the sitemap

Redirecting and broken URLs make the submitted inventory stale. The first technical audit on a cybersecurity SaaS account I run found exactly this: redirecting URLs listed in the sitemap, alongside H1s duplicating the title tag on 174 pages. Replace a redirect with its final canonical destination. Remove 404, 410, and persistent 5xx URLs, then fix the generator rule that allowed them in.

Consolidation projects create these entries in bulk. A content audit I ran on 929 programmatic pages for a creator-tools SaaS site produced 393 redirect recommendations, 42% of the inventory. Each of those URLs has to leave the sitemap when its redirect ships, and its destination has to stay in, or the sitemap starts listing hundreds of redirects the day the consolidation launches.

Noindex or blocked sitemap URLs

A noindex entry asks Google to discover a URL that the page excludes from search. A robots-blocked entry can prevent Google from reading the page’s content and directives. Align the sitemap with the final indexing decision.

Canonical conflicts

A listed URL that canonicals elsewhere sends competing preferences. Inspect the reason for consolidation, choose the intended winner, and update the sitemap, internal links, redirects, and page canonical together.

This site had the quiet version of the conflict. Its sitemap listed clean URLs while every page declared a canonical ending in .html, which 308-redirects to the clean URL. The fix shipped on 2026-08-07. On 2026-11-29, URL Inspection still showed the .html version as the declared canonical on three indexed pages whose last crawl came before the fix, though Google had already chosen the clean URL listed in the sitemap. A canonical fix lands page by page, on each page’s next crawl.

Missing canonical pages

Important pages can disappear from a sitemap because a content type, locale, publication state, or custom route falls outside the generator rules. Compare the sitemap with the intended inventory after every template launch and platform migration.

False modification dates

Sitewide deployment timestamps make every URL appear freshly changed. Connect <lastmod> to meaningful page data such as a publication date, editorial update, product revision, or approved content change.

This site’s Astro build reads each post’s <lastmod> from its frontmatter: the newest of its publish date, updated date, and changelog dates. It never uses the file’s modification time, because a fresh checkout on the build server stamps every file with the build time, which would tell Google every page changed on every deploy. An earlier version of the sitemap carried no lastmod at all, and three dead sitemaps from the previous WordPress platform were still registered in Search Console, all returning 404.

One undifferentiated sitemap

A large mixed file passes every protocol test and still produces weak diagnostics. Split inventories that have different templates, owners, publishing systems, or indexation behavior. Keep the groupings stable enough to compare over time.

XML sitemaps work with the rest of technical SEO

XML sitemaps work best when every URL-control mechanism supports the same intended inventory. Robots rules, redirects, canonicals, index directives, internal links, and the sitemap each answer a different part of the problem.

I saw that interaction during a large cybersecurity SaaS migration. While Google processed roughly 900 redirects into the site’s security resources hub, I blocked parameter URLs, staging pages, feeds, and other crawl waste in robots.txt, and roughly 280 URLs cleared from the crawled-not-indexed backlog. On the same site, 27 of the new hub URLs sat in “crawled, currently not indexed” until an internal-link audit fixed them. Two rules follow from cases like that one: after a migration, internal links point straight at the final URLs, never through redirects, and a hub with indexing trouble goes in the site footer.

The sitemap’s role in a migration is to list the canonical destinations. The robots.txt rules control repeatable crawl waste while leaving redirect sources available for processing. Redirects communicate the move. Internal links point directly to the destinations. Canonicals confirm the preferred versions.

That is the standard for an operational sitemap: every listed URL agrees with the rest of the system, and every surrounding control has one clear job. The larger program and its attribution boundaries are documented in the cybersecurity SaaS case study.

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

An XML sitemap is a machine-readable URL feed for search engines, while an HTML sitemap is a navigable web page built for people and crawlable through ordinary links.

XML sitemapHTML sitemap
Structured XML fileStandard web page
Built primarily for search-engine processingBuilt for visitors and crawlers
Can carry lastmod, hreflang, image, video, and news metadataCarries visible anchor text and link context
Submitted through Search Console and robots.txtLinked through the site’s navigation or footer
Supports large inventories through sitemap indexesBest when curated into useful sections

An HTML sitemap can help visitors navigate a complex site and can strengthen discovery through real links. It should be curated enough to remain useful. A page containing thousands of ungrouped links creates a poor visitor experience and a weak architectural substitute.

Most B2B SaaS sites need only the XML file because their navigation and hubs already provide strong human discovery. Sites with complex catalogs, deep documentation, or many user paths may find value in both formats.

When do image, video, news, and hreflang sitemaps help?

Specialized sitemap extensions help when a site needs to supply Google with structured information about media, news, or localized page relationships. Use them for content that genuinely qualifies for those search features.

  • Image extensions identify images and their locations on a page. Google’s image sitemap documentation allows up to 1,000 <image:image> entries per <url> and has dropped the old caption, title, geo_location, and license tags, so <image:loc> is the field that matters.
  • Video extensions can provide thumbnail, title, description, duration, and player or file information.
  • News extensions can describe qualifying recent news articles and publication details.
  • Hreflang annotations can connect approved language and regional alternates.

These extensions can live inside the relevant URL sitemap. Separate media sitemaps can also make sense when a distinct team or publishing system owns the inventory. Follow Google’s current documentation for each extension because eligibility fields and search-feature behavior change over time. The full image workflow, including when an image sitemap earns its place, lives in the image SEO guide.

Who should own XML sitemap maintenance?

XML sitemap maintenance should have one accountable technical owner, clear SEO eligibility rules, and automated validation against Search Console and a scheduled crawl. Ownership often sits with engineering or the web platform team because the application generates the file, while SEO defines the intended inventory and validates the output.

Use a simple responsibility split:

  • SEO defines which page groups qualify, reviews exceptions, and monitors Search Console.
  • Engineering implements generation, availability, and automated tests.
  • Content or product owners maintain accurate publication and update states.
  • Analytics or SEO operations preserves snapshots and reports changes by cohort.

My role as a consultant is to define the rules, specifications, and acceptance tests, then validate the implemented result. The client’s development team owns the application change. That separation keeps the strategy tied to business intent and the implementation tied to the system that creates the URLs.

Review the sitemap after migrations, CMS changes, template launches, international expansion, programmatic page releases, and large pruning projects. A scheduled monthly check works for a stable site. High-change inventories benefit from daily automated monitoring.

Frequently asked questions

How important is sitemap for SEO?

A sitemap is important for discovery and diagnostics, especially on large, new, frequently updated, media-heavy, or weakly linked sites. Sitemap.xml is important for one more reason: it is the only place a site lists its intended indexable inventory in a form Search Console can report against. It creates no direct ranking boost and gives no guarantee of crawling or indexation. Smaller sites with comprehensive internal linking may see little discovery change, though a clean sitemap still provides a useful submitted inventory.

Are sitemaps still relevant?

Sitemaps remain relevant because Google and Bing still support them for URL discovery, metadata, and reporting, and both document the protocol in their current webmaster guidance. Their operational value rises with site size and complexity. Modern JavaScript frameworks, programmatic inventories, international sites, and frequent releases all benefit from an explicit machine-readable inventory.

Can an XML sitemap improve rankings?

An XML sitemap can help a search engine discover and process eligible pages, which is a prerequisite for ranking. The file itself does not make a page more relevant, authoritative, useful, or competitive. Ranking gains depend on the page and site signals that search systems evaluate after discovery.

Where should an XML sitemap be located?

An XML sitemap should usually live at a stable root-level URL such as https://example.com/sitemap.xml or https://example.com/sitemap-index.xml. A root location covers every URL on the host and is easy to declare in robots.txt. A sitemap placed in a subfolder affects only URLs below that folder unless you submit it through Search Console.

How often should an XML sitemap update?

An XML sitemap should update whenever an eligible URL publishes, moves, changes search status, or retires. Dynamic sites should generate it automatically. The <lastmod> date should change after a significant page update, while routine deployments and cosmetic changes should leave it unchanged.

Do small websites need an XML sitemap?

Small websites can operate successfully through strong internal linking alone. Google describes a small site as “about 500 pages or fewer” for this decision. A sitemap remains inexpensive when the CMS maintains it accurately, and it provides a clean inventory for submission and troubleshooting.

How do I find my XML sitemap?

You find an XML sitemap by checking the site’s robots.txt file for a Sitemap: line first, since that declaration names the exact URL. If robots.txt has none, try the common default paths:

  • /sitemap.xml or /sitemap_index.xml (Yoast SEO and many CMS platforms);
  • /wp-sitemap.xml (WordPress core since version 5.5);
  • /sitemap-index.xml (the Astro sitemap integration, which writes child files such as /sitemap-0.xml; drewgarrett.org uses this setup and declares it in robots.txt).

For a site you manage, the Search Console Sitemaps report lists every submitted file with its last read date and status. If none of these turns one up, the site may have no sitemap at all. Lintlab’s crawler found none at the declared or default locations on more than half of the popular origins it reached, though some of those blocked the crawler.

What changed

  • November 29, 2026: Added a full indexing check of this site's own sitemap (212 URLs, with a then-and-now comparison), this site's canonical and lastmod setup, and a consolidation case from a creator-tools content audit.