← All articles
AFTERWORKS ARTICLES

What Is an XML Sitemap and Does My Website Need One?

An XML sitemap lists the canonical URLs a website wants search engines to discover. It supports crawling but does not guarantee indexing or rankings.

By afterworks.space9 min read
A paper librarian checks a collection map against tagged website-page shelves to guide discovery.

Part of our guide: Website SEO: A Beginner’s Guide for Small Businesses

An XML sitemap is a machine-readable file listing the canonical pages and other files you want search engines to know about. It helps discovery and can provide modification, image, video, news or language information, but it does not guarantee that a URL will be crawled, indexed or ranked.

Most business websites should have a correctly generated sitemap because it is inexpensive to maintain and useful during launches and migrations. A small, comprehensively linked site may be discoverable without one, but still benefits from a clean inventory and Search Console reporting.

What does an XML sitemap look like?

The file contains full URLs inside a defined XML structure. It is intended primarily for machines rather than normal website navigation. A sitemap index can point to several separate sitemap files when a site has many URLs or content types.

Google supports multiple sitemap formats, but XML is the most versatile. Its sitemap-building documentation sets a limit of 50 MB uncompressed or 50,000 URLs per sitemap file; larger sets need to be split.

Thinking about your own rebuild?

Tell us about your business, your current website and what you would like to improve. We will help you work out the next step.

A sitemap helps discovery, not ranking

Search engines commonly discover pages by following links. A sitemap offers another route and communicates which URLs the site owner considers important. It is especially helpful for a new domain with few external links, a large site, rich media or a recent migration.

Google’s sitemap overview explicitly says a sitemap does not guarantee that every item will be crawled and indexed. Adding a page to the file does not make weak, duplicate or blocked content rank.

Keep investing in useful content, clear internal links and reliable technical delivery. The sitemap supports that system rather than replacing it.

Does a small business website need one?

Google says a site with roughly 500 or fewer pages may not need a sitemap when all important pages are well linked. “Not required” is different from “harmful”. Modern platforms usually generate one automatically, making it a sensible standard feature.

A sitemap is particularly useful when:

  • the website is new;
  • pages are published frequently;
  • the structure is large or deep;
  • a redesign changes URLs;
  • important images or videos need additional discovery information;
  • multiple languages or regions are supported;
  • Search Console monitoring is part of the maintenance process.

Do not use it to compensate for pages that visitors cannot reach through the website itself.

Which URLs should be included?

Include the preferred, canonical URLs you want eligible for search. They should normally return a successful response, allow indexing and contain substantive public content.

Typical inclusions are the homepage, service and product pages, genuine location pages, useful articles, case studies and contact or about pages where appropriate.

Use fully qualified addresses such as https://example.com/services/, not relative paths. Keep the protocol, hostname and trailing-slash convention consistent with canonical tags and internal links.

Which URLs should be excluded?

Do not list:

  • redirects or broken pages;
  • duplicate parameters and filter combinations;
  • staging and preview URLs;
  • account, basket or internal-search pages;
  • content marked noindex;
  • alternate URLs canonicalised elsewhere;
  • pages removed without a replacement;
  • low-value automatically generated archives.

A sitemap that contradicts other signals is confusing. If a URL is deliberately excluded from search, it does not belong in the search sitemap.

What does lastmod mean?

The optional lastmod value states when the page’s significant content was last changed. Update it when the main text, structured data or important links change, not every time a footer timestamp or deployment changes.

Search engines may ignore values that are consistently inaccurate. Do not rewrite every date daily to simulate freshness. A trustworthy modification date helps crawlers decide what may need revisiting.

The sitemap protocol also permits other fields, but follow the current search-engine documentation rather than assuming every historic attribute influences crawling.

How do I find my sitemap?

Common locations include /sitemap.xml and /sitemap-index.xml, but there is no universal filename. Check your content management system, website documentation or ask the developer.

Open the address directly. Confirm it loads on the public HTTPS domain and contains the pages you expect. A browser may show formatted XML, plain text or a styled index; the underlying response matters more than presentation.

This Astro website produces a sitemap during its build. WordPress core and SEO plugins may generate sitemaps, while hosted builders commonly manage them automatically. Avoid enabling several generators that publish conflicting versions.

How do I submit it to Google?

Verify the correct property in Google Search Console, open the Sitemaps report and submit the sitemap URL. The report can show whether Google fetched it and encountered processing errors.

You can also declare its full URL in robots.txt. Submission is a hint, not a command. Google’s documentation recommends Search Console because it provides access and error information.

After submission, review whether the file was read successfully. Do not resubmit it after every ordinary page edit; a dynamically generated sitemap can be revisited at the same stable address.

Sitemaps and Search Console indexing reports

Filtering the Page indexing report by a submitted sitemap can narrow an audit to URLs you intentionally supplied. That is more useful than comparing Google’s total known URLs with a rough page estimate.

Investigate why important sitemap URLs are not indexed. They may be new, blocked, duplicate, canonicalised elsewhere or judged unsuitable for inclusion. Our guide to checking which pages Google has indexed explains the report and its limitations.

For one page, use URL Inspection rather than relying on the sitemap status alone.

Every important page should have a meaningful route from known content. Navigation, topic hubs, contextual links and breadcrumbs help people and crawlers understand relationships.

A URL listed only in a sitemap can be discovered, but its isolation may indicate that the website structure does not value or explain it. Link pages where they genuinely support the visitor’s next question.

The beginner’s website SEO guide covers internal structure alongside content and search foundations.

Sitemaps and canonical URLs

Google treats sitemap inclusion as one signal about the preferred canonical URL. Stronger signals include redirects and canonical annotations. Keep them aligned.

If the same content is accessible at HTTP and HTTPS, with and without www, or through multiple parameters, list only the chosen canonical version. Google’s canonical guidance explains how sitemap URLs contribute.

An incorrect sitemap cannot override a template that points every canonical somewhere else. Fix the source of the conflict.

Sitemaps during a redesign

Before launch, export the existing canonical URLs and identify what will be retained, redirected, consolidated or removed. After launch, generate a sitemap containing final new URLs and verify the redirect map separately.

Do not place old redirecting URLs in the new sitemap merely to remind Google about them. Keep the redirects live and list their final canonical destinations.

Submit the new sitemap and monitor Search Console while Google recrawls the change. Read does redesigning a website affect SEO? and the detailed redesign migration guide before changing established URLs.

Image, video and news sitemaps

XML extensions can supply additional information about images, video and news. They are useful when those media types are a material part of search discovery and not otherwise easy to find.

Do not add specialist markup without following the current eligibility rules. A normal business brochure site rarely needs a separate news sitemap. Image discovery also depends on accessible files, useful surrounding content and appropriate rights.

Common sitemap mistakes

  • Publishing staging or non-canonical hostnames.
  • Listing URLs that redirect, error or carry noindex.
  • Including every search, filter and parameter combination.
  • Using relative rather than absolute URLs.
  • Setting false modification dates on every build.
  • Generating several conflicting sitemap indexes.
  • Forgetting to update the sitemap after a migration.
  • Assuming submission guarantees indexing.
  • Using the sitemap instead of crawlable navigation.

Most problems are solved at the generator or content-model level. Manual edits will be overwritten if the platform rebuilds the file.

A sitemap audit checklist

  1. Find the actual public sitemap address.
  2. Confirm a successful response and valid format.
  3. Check that URLs use the canonical HTTPS host.
  4. Sample the homepage, services, articles and contact routes.
  5. Remove redirects, errors and excluded pages.
  6. Confirm important pages have internal links too.
  7. Submit the stable URL in Search Console.
  8. Review processing errors and indexing patterns.
  9. Test regeneration after publishing content.
  10. Repeat after migrations or platform changes.

Use how to get Google to index your website for the wider discovery process and what technical SEO means for the controls around it.

Frequently asked questions

Will a sitemap improve my rankings?

Not directly. It helps search engines discover preferred URLs. Content relevance, quality and many other signals affect ranking.

Should I list pages marked noindex?

No. That sends conflicting signals. Include public canonical pages you want considered for indexing.

How often should a sitemap update?

It should update when canonical URLs are added, removed or meaningfully changed. A generated sitemap can update automatically when content is published.

Can I have more than one sitemap?

Yes. Large sites commonly use a sitemap index linking to separate files. Smaller sites can also separate types for reporting, provided the setup remains accurate.

Keep the sitemap clean and uneventful

When Search Console cannot retrieve the file, use the sitemap fetch checklist to distinguish the address, access and format problems before submitting again.

Generate the sitemap from the canonical site, submit it, monitor errors and keep it consistent with navigation, canonicals and redirects.

Afterworks includes automated sitemaps and migration checks in appropriate website rebuilds. Explore our website rebuild service or contact us if your current platform produces confusing search signals.

  • XML sitemap
  • Google indexing
  • technical SEO
  • Google Search Console
  • website SEO
AFTERWORKS ARTICLES
All articles ↗
16 min read

Website SEO: A Beginner’s Guide for Small Businesses

A practical introduction to small business website SEO, with clear steps to improve content, check indexing, fix technical issues and plan a search-friendly redesign.

  • website SEO
  • small business SEO
  • technical SEO
  • website indexing
  • website speed
  • website redesign
9 min read

How Do I Get Google to Index My Website?

You cannot force Google to index a page, but you can make important pages easy to discover, crawl and understand, then monitor the result in Search Console.

  • Google indexing
  • Google Search Console
  • website SEO
  • XML sitemap
  • technical SEO

Thinking about your own website?

Explore our website rebuilds and pricing and ownership. If we have already contacted you, our preview guide explains why and what happens next.