XML Sitemap Best Practices for SEO in 2026

An XML sitemap is one of the most straightforward technical SEO tools available, and one of the most consistently misconfigured. Following xml sitemap best practices seo requires more than generating a file and submitting it. It requires keeping it accurate, keeping it clean, and ensuring it works in alignment with your indexation strategy rather than contradicting it.

A sitemap is not a guarantee of indexation. It is a roadmap that tells Google which pages exist and which ones you consider worth indexing. When that roadmap is cluttered with low-value pages, includes URLs that are blocked by robots.txt, or reflects content that is outdated or thin, it gives Google a confusing signal that can actually slow down the discovery and indexation of the pages that matter.

This guide covers what a properly structured XML sitemap looks like, what common configurations undermine its value, and what ongoing maintenance keeps it working as an asset rather than a liability.

Is your website invisible on Google?

Get a free, no-obligation SEO audit from a real expert 100% free, actionable insights, and built to boost your rankings.

Get a Free Audit

What an XML Sitemap Actually Does

Google does not need a sitemap to crawl your site. With a well-structured internal linking architecture, Googlebot can discover most pages through link traversal alone. The sitemap accelerates that discovery, signals priority, and ensures newly published pages get found faster than they would through organic crawl alone.

XML Sitemap Best Practices

For new sites with limited external links, the sitemap is often the primary mechanism through which Google discovers content. For large sites with thousands of pages, the sitemap helps Google understand the scope of the content it should be prioritizing with its crawl budget.

What a sitemap does not do is guarantee rankings, override no index tags, or force Google to index pages it determines are low quality. Google uses sitemaps as a hint, not a directive. It will use the information in the sitemap to inform its crawl behavior, but it will ultimately index or exclude pages based on its own quality evaluation.

The practical implication is that what you include in the sitemap matters as much as what you exclude. A sitemap that contains every URL on a site, including thin category filter pages, duplicate content, and outdated posts, is telling Google that you consider all of those pages equally worth indexing. Google will draw its own conclusions, but a cleaner signal is always better.

XML Sitemap Best Practices: The Core Rules

These are the specific practices that separate a sitemap working for your SEO from one working against it.

XML Sitemap Best Practices

Include only indexable URLs

Every URL in your sitemap should be returning a 200 OK status code and should not have a no index directive. Including redirected URLs, 404 pages, or nonindexed pages in the sitemap is one of the most common sitemap errors we find in audits. It creates a contradiction: the sitemap tells Google to index the URL while the page itself tells Google not to. Google will generally respect the no index directive, but the conflicting signal is noise that slows down the process.

Exclude low-value and thin pages

Not every indexable URL deserves to be in the sitemap. Faceted navigation filter pages, empty category pages, paginated archive pages beyond the first, and session parameter URLs should generally be excluded. The sitemap should reflect the curated set of pages you are confident Google will find worth indexing. Including everything signals that you have not made that editorial judgment, which is not the impression you want to give.

Keep the sitemap current

A sitemap that reflects the site structure from six months ago is not serving its purpose. Every time a page is added, removed, or significantly updated, the sitemap should reflect that change. Most CMS platforms and SEO plugins generate sitemaps dynamically, meaning they update automatically as content changes. If your sitemap is manually maintained or generated by a tool that requires manual regeneration, build a process for keeping it current.

Use sitemap index files for large sites

Google allows up to 50,000 URLs per sitemap file and a maximum file size of 50MB. For large sites, use a sitemap index file that references multiple individual sitemaps: one for blog posts, one for product pages, one for service pages, one for images. This structure makes the sitemap easier to manage and makes it easier to diagnose indexation issues by page type.

Submit the sitemap in Google Search Console

Submitting the sitemap through Search Console does more than tell Google it exists. It gives you access to reporting on how many submitted URLs have been indexed versus how many Google has excluded and why. This data is essential for diagnosing indexation problems and monitoring the health of your crawl coverage over time.

Align the sitemap with robots.txt

Any URL blocked in robots.txt should not appear in the sitemap. If a URL is in the sitemap but blocked by robots.txt, Google cannot crawl it to evaluate it for indexation. The fix-crawl-errors-google-search-console guide covers how to identify and resolve these conflicts when they appear in Search Console reporting.

The sitemap and robots.txt work as a pair. The sitemap says which pages exist and are worth indexing. robots.txt says which pages Google is allowed to crawl. They need to be consistent with each other. Any contradiction between them creates confusion that takes Google time and crawl budget to resolve. The robots-txt-guide covers the configuration of that file in detail and how to audit it for conflicts with your sitemap.

Is your website invisible on Google?

Get a free, no-obligation SEO audit from a real expert 100% free, actionable insights, and built to boost your rankings.

Get a Free Audit

Sitemap Structure: What a Well-Built Sitemap Looks Like

A properly structured XML sitemap includes the following elements for each URL:

ElementRequiredPurpose
locYesThe canonical URL of the page
lastmodRecommendedDate the page was last significantly updated
changefreqOptionalHow frequently the page changes (hint only)
priorityOptionalRelative priority within the site (hint only)

A few clarifications on the optional elements. Google has stated that it largely ignores changefreq and priority values because they are almost universally set inaccurately by site owners who assign high priority to every page. If you include these elements, set them accurately: reserve high priority for your most commercially important pages and set changefreq to a value that actually reflects how often the page changes.

XML Sitemap Best Practices

The lastmod element is more useful. When set accurately to the date of the last meaningful content update, it signals to Google that the page is fresh and may warrant a re-crawl. Setting lastmod to a future date or updating it without changing the content is something Google has learned to detect and discount.

For most business sites, the sitemap structure that works best is a sitemap index with separate child sitemaps for blog content, service pages, and any additional content types with significantly different update frequencies.

Common XML Sitemap Mistakes That Hurt SEO

Including no indexed pages in the sitemap

A no index directive on a page combined with a sitemap entry for that same URL is a direct contradiction. Google will generally honor the no index, but the conflicting signal is counterproductive. Audit your sitemap against your no index configuration regularly and remove any URL from the sitemap that has a no index tag.

Not updating the sitemap after a site migration or redesign

A site migration that changes URLs without updating the sitemap leaves Google with a map that points to old URLs, many of which now return 404 errors or redirects. After any migration, the sitemap should be regenerated from the new URL structure before the site goes live and resubmitted to Search Console immediately after launch.

XML Sitemap Best Practices

Submitting the sitemap once and never monitoring it

The sitemap submission is not a set-and-forget task. Search Console’s Sitemaps report shows how many URLs were submitted versus how many were indexed. A significant gap between submitted and indexed URLs is a signal worth investigating. Monitoring this data monthly identifies indexation problems before they become ranking losses.

Including every paginated URL

 For sites with blog archives, product catalogs, or other paginated content, including every page of pagination in the sitemap adds low-value duplicate content to the crawl queue. Include only the first page of a paginated series, or configure canonical tags on subsequent pages to point to the first page, depending on your pagination strategy.

Setting all priority values to 1.0

When every URL in the sitemap has a priority of 1.0, the signal is meaningless because no URL is prioritized over another. If you use the priority attribute, create a genuine hierarchy: 1.0 for the homepage and primary commercial pages, 0.8 for key service and category pages, 0.6 for blog content, and lower values for supporting pages. A meaningful hierarchy is better than a uniform one.

FAQ

Does Google require an XML sitemap?

No. Google can crawl and index a site without a sitemap if the internal linking structure is sufficient. The sitemap accelerates discovery and is especially valuable for large sites, new sites with limited external links, or sites with content that is not well-connected through internal links. It is a strong recommendation, not a technical requirement.

How often should I update and resubmit my XML sitemap?

For dynamically generated sitemaps, this happens automatically. For manually maintained sitemaps, update and resubmit any time you add or remove significant content, change your URL structure, or complete a site migration. At minimum, verify the sitemap accuracy quarterly in the Search Console.

Why are some of my sitemap URLs not being indexed?

Common reasons include: the pages are thin or low-quality and Google does not consider them worth indexing, there are canonicalization issues pointing Google to a different URL, the pages have no index tags, or the pages are blocked by robots.txt. Use the URL Inspection tool in Search Console to diagnose the specific reason for any URL that is submitted but not indexed.

How large can an XML sitemap be?

Google allows up to 50,000 URLs per sitemap file and a maximum uncompressed file size of 50MB. For sites that exceed these limits, use a sitemap index file that references multiple child sitemaps. Sitemap files can be compressed using gzip to reduce file size while remaining within Google’s limits.

Should I include image and video URLs in my XML sitemap?

Yes, if images and videos are important content for your business. Image sitemaps help Google discover images that might not be found through standard HTML crawling, which can improve visibility in Google Images. Video sitemaps help Google understand the content and metadata of embedded videos. These are separate sitemap files referenced through the sitemap index.

Is your website invisible on Google?

Get a free, no-obligation SEO audit from a real expert 100% free, actionable insights, and built to boost your rankings.

Get a Free Audit

The Bottom Line

XML sitemap best practices seo comes down to one principle: the sitemap should be a curated, accurate representation of the pages you are confident are worth indexing, kept current as the site evolves, and monitored for the gap between what was submitted and what Google actually indexed.

A clean, well-maintained sitemap is a small investment in technical hygiene that pays disproportionate returns in crawl efficiency, indexation speed, and the ability to diagnose problems before they affect rankings. The businesses that get these fundamentals right build a technical foundation that makes every other SEO investment work harder.

Want to know if your sitemap is working for your rankings or against them?

If you want a strategy that actually fits your business, book a free strategy call. We will walk you through your sitemap health and the technical issues holding your site back. Visit our Technical SEO Service Page to learn more about how we approach this work.