What Is a Sitemap? XML and HTML Sitemaps Explained
A sitemap is a file that lists the important pages, images, videos and other files on a website so that search engines such as Google and Bing can find and crawl them more efficiently. Most sitemaps are written in XML for search engines to read, though the same word describes an HTML page that lists a website’s content for visitors and the planning diagram a designer draws before a website is built. Sitemaps are one of the first technical foundations we check when delivering SEO services for UK businesses and they are quick to get right compared with most technical SEO work.
The three meanings are related, but they serve different readers and solve different problems. In short, the word sitemap usually refers to one of the following.
- An XML sitemap, a machine-readable file that lists URLs for search engines, usually found at /sitemap.xml or /sitemap_index.xml.
- An HTML sitemap, an ordinary web page that links to the main sections and pages of a website so visitors can find them.
- A web design sitemap, a diagram of a planned website’s pages and how they connect, drawn before design or build work starts.
A sitemap helps search engines discover pages, but it does not guarantee they will be crawled, indexed or ranked. It works alongside clear navigation and sensible internal linking, which remain the main ways crawlers find pages and judge how they relate to each other.
How an XML Sitemap Works
An XML sitemap works as a list of URLs that a search engine downloads and adds to the pages it plans to crawl, next to the links it finds by following one page to another. Crawlers discover most content by moving from link to link, so a page buried deep in a website or linked from nowhere can go unnoticed for a long time. The sitemap gives the crawler a direct route to those pages and tells it when each one last changed.
Google is clear that a sitemap is a hint rather than an instruction. Its documentation says a sitemap helps search engines discover URLs but does not guarantee that every item listed will be crawled and indexed. In practice the sitemap is as useful for diagnosis as for discovery, as comparing the URLs it lists with the pages Google has indexed quickly shows where a website has crawling or quality problems.
Sitemaps sit within the crawling and indexing side of technical SEO services, next to robots.txt rules, canonical tags and internal linking. Each of those signals should agree with the others and a sitemap listing URLs the rest of the website contradicts sends search engines mixed messages.
What Goes in an XML Sitemap
An XML sitemap needs only one piece of information per page, which is its full address inside a loc tag, plus an optional last modified date inside a lastmod tag. The format is defined by the sitemaps protocol, which Google, Bing and other search engines support. A minimal example for a website with two pages looks like this.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://www.example.co.uk/services/</loc>
<lastmod>2026-09-14</lastmod>
</url>
<url>
<loc>https://www.example.co.uk/insights/what-is-a-sitemap/</loc>
<lastmod>2026-10-01T09:30:00+01:00</lastmod>
</url>
</urlset>
Every URL must be written in full, including the protocol and domain and the file must be UTF-8 encoded. The lastmod value can be a plain date or a date with a time and the protocol states that it should record when the linked page was last modified rather than when the sitemap file was generated.
Google’s guide to building and submitting a sitemap says it ignores the priority and changefreq values that many older sitemaps still carry. It uses lastmod only when the dates are consistently and verifiably accurate and it counts changes to the main content, structured data or links as significant, where a new copyright year in the footer is not. Bing takes the same view of priority and changefreq, so there is little point maintaining either by hand.
Yoast explains in its help documentation on XML sitemaps that it removed priority values from its sitemaps after Google said publicly that it does not use them on most websites. Setting every page to maximum priority in the hope of faster crawling achieves nothing.
Types of Sitemap Compared
Most websites need one XML sitemap, or a sitemap index pointing to several and an HTML sitemap is optional. Google supports extensions to the XML format for image sitemaps, video sitemaps and news sitemaps, which can be separate files or extra tags added to an existing sitemap. The table below sets out who reads each type and when it earns a place.
| Sitemap type | Read by | What it lists | When to use it |
|---|---|---|---|
| XML sitemap | Search engines | Canonical page URLs with optional lastmod dates | Almost every website, usually generated by the CMS |
| HTML sitemap | Visitors and crawlers | Links to the main sections and pages | Large websites with deep content or complex navigation |
| Image sitemap | Images on each page, including those loaded with JavaScript | Websites where image search visibility matters | |
| Video sitemap | Video details such as running time and rating | Websites hosting video they want found in search | |
| News sitemap | Google News | Articles published in the last two days | News publishers |
| Sitemap index | Search engines | Other sitemap files | Any website with more than one sitemap, including most WordPress websites |
An HTML sitemap is worth considering on websites with hundreds of service, product or location pages, where visitors who cannot find something through the menu or search need another route in. It is a normal page linked from the footer, so it should meet the same WCAG accessibility standards as the rest of the website. On smaller websites with clear navigation it rarely adds much for visitors or search engines.
Size Limits and Sitemap Index Files
A single sitemap can list up to 50,000 URLs and must be no larger than 50MB once uncompressed, according to the sitemaps.org FAQ. The same page states that a sitemap index can list up to 50,000 sitemaps. Gzip compression reduces the transfer size, but the limit applies to the file after it has been decompressed.
A sitemap index looks much like an ordinary sitemap, with sitemap entries in place of URL entries and it lets you submit one address that points to many files. Google’s guidance on managing sitemaps with an index file says the referenced sitemaps must sit on the same website as the index, in the same directory or deeper. It allows up to 500 sitemap index files per website in a Search Console account.
Few business websites come close to these limits, yet most still use an index as their CMS splits content by type. Separate sitemaps for pages, posts, categories and authors keep each file small and make it easier to see which section of a website has indexing problems.
Does Your Website Need a Sitemap
Most websites benefit from an XML sitemap, though a small website with thorough internal linking will usually be crawled properly without one. Google’s introduction to sitemaps says you might need one if your website is large, if it is new and has few external links pointing to it, or if it has a lot of video and image content or appears in Google News. It defines a small website as about 500 pages or fewer that you want in search results and says a website of that size with strong internal linking and few media files might not need a sitemap at all.
For the B2B and public sector websites we work on, the question is rarely whether to have a sitemap, since WordPress produces one automatically. The more useful question is whether the sitemap lists the right URLs. A new website with no backlinks gains the most, as the sitemap may be the only route Google has to its deeper pages until other websites start linking to it.
How WordPress Creates a Sitemap
WordPress has generated an XML sitemap automatically since version 5.5, so every current installation has one switched on by default. The WordPress core announcement explains that the sitemap index sits at /wp-sitemap.xml, that a single sitemap holds a maximum of 2,000 entries by default and that the robots.txt file WordPress produces references the index so search engines can find it.
The core sitemap covers public post types, taxonomies, author archives and the homepage. That is a sensible starting point, but it can include pages many organisations would rather leave out, such as author archives on a website with one editor or tag archives holding a single post each.
SEO plugins generate their own sitemaps with more control over what is included. Yoast SEO serves its sitemap index at /sitemap_index.xml and, according to its XML sitemaps feature page, splits sitemaps into files of up to 1,000 URLs each. Its help documentation advises disabling other sitemap plugins and removing any physical sitemap file before switching its sitemaps on, which avoids two competing sitemaps on the same website.
Checking those settings is part of launching any WordPress website properly. Our guide to the web design process from brief to launch covers the launch checks we run, which include submitting the new XML sitemap in Google Search Console.
Finding Your Sitemap and Adding It to robots.txt
The quickest way to find a sitemap is to add /sitemap.xml or /sitemap_index.xml to the end of the domain, or to open the website’s robots.txt file and look for a line starting with Sitemap. On a WordPress website without an SEO plugin, /wp-sitemap.xml is the place to look. If none of those return a file, the Sitemaps report in Search Console will show any sitemap that has already been submitted.
Referencing the sitemap in robots.txt lets any search engine find it without a manual submission. Google’s robots.txt specification confirms that Google, Bing and other major search engines support the sitemap field, which takes the full absolute URL of the file. A typical entry is a single line such as Sitemap: https://www.example.co.uk/sitemap_index.xml and a website with several sitemaps can list each one on its own line.
Submitting a Sitemap to Google and Bing
Submitting a sitemap directly through each search engine’s webmaster tools is the most reliable way to confirm it has been read. In Google Search Console, open the Sitemaps report, enter the sitemap address and submit it and the report then shows when Googlebot last fetched the file and any processing errors it found. Bing Webmaster Tools works the same way in principle, with sitemaps added from a verified account.
Bing’s guidance on sitemaps in AI powered search recommends a robots.txt reference or direct submission in Bing Webmaster Tools and asks for lastmod values in ISO 8601 format with the time included. It describes sitemaps as a foundation for keeping content discoverable in AI powered search such as Copilot, which makes an accurate sitemap relevant to AI search visibility and not only to traditional results.
Google deprecated its sitemaps ping endpoint in 2023, so plugins or scripts that still ping Google after each update do nothing useful. Submit through Search Console or a robots.txt reference instead.
Submission is not a one-off task. Revisit the Sitemaps report after a redesign, a migration or a large content change, when errors tend to appear. If the report shows that Google could not read the file, our guide to fixing a sitemap Google could not fetch works through the causes one at a time.
Common Sitemap Mistakes
Most sitemap problems come from listing URLs that contradict other signals on the website. Google’s guidance is to include the URLs you want to appear in search results, which in practice means canonical, indexable pages that load without a redirect. Its documentation on consolidating duplicate URLs treats sitemap inclusion as a weak canonical signal and warns against naming one URL in a sitemap and a different one in a canonical tag for the same page.
The same handful of faults turns up in most technical audits. Our guide to common technical SEO issues covers how to find them across a whole website and the checklist below covers the sitemap itself.
- Every listed URL loads directly, with no redirects or 404 errors.
- No listed URL carries a noindex tag or is blocked in robots.txt.
- Every listed URL is the canonical version, with consistent https and www.
- The lastmod date changes only when the page content changes.
- Staging, test, thank you and internal search results pages are left out.
- Each file stays within the protocol’s size limits.
- The sitemap is referenced in robots.txt and submitted in Search Console and Bing Webmaster Tools.
A sitemap that passes these checks gives search engines a clean, consistent list of the pages that matter. A sitemap full of redirects and noindexed URLs has the opposite effect and it makes Search Console reports harder to read as real indexing problems get lost among URLs that were never meant to be indexed.
What a Sitemap Means in Web Design
In web design, a sitemap is a planning diagram that maps every page of a proposed website and shows how those pages relate to each other, usually as a tree that branches out from the homepage. It is drawn before wireframes or visual designs and it settles the navigation, the URL structure and the content each page will carry.
A well planned sitemap does a lot of SEO work early. Grouping services, sectors and supporting content into clear sections gives each page a logical place in the hierarchy, keeps important pages within a few clicks of the homepage and shapes the internal links the finished website will carry. Our article on how internal linking strengthens site architecture covers how that structure affects search performance once the website is live.
The planning diagram and the XML file end up describing the same structure from two directions. When the website launches, the XML sitemap generated by the CMS should mirror the hierarchy agreed at the planning stage and any page that appears in one but not the other is worth questioning before search engines find it.
FAQs
What is a sitemap?
A sitemap is a file that lists the pages, images, videos and other files on a website so search engines can find and crawl them more efficiently. The term also covers HTML sitemap pages written for visitors and the planning diagrams designers use to map out a website’s structure.
What is the difference between an XML sitemap and an HTML sitemap?
An XML sitemap is a machine-readable file written for search engines, listing URLs with optional last modified dates. An HTML sitemap is an ordinary web page that links to a website’s main sections so visitors can find content the menu does not surface.
Where do I find my website's sitemap?
Try adding /sitemap.xml or /sitemap_index.xml to the end of your domain, or look for a Sitemap line in your robots.txt file. WordPress websites without an SEO plugin use /wp-sitemap.xml by default.
Does a sitemap improve SEO rankings?
A sitemap helps search engines discover and recrawl pages, but Google is clear that it does not guarantee those pages will be crawled or indexed. Rankings still depend on the quality and relevance of each page, so the value of a sitemap lies in making sure the right pages are found quickly.