XML Sitemaps: What They Are and How to Get Them Right
The short answer
An XML sitemap is a file on your website that lists the pages you want search engines to find. Google says a site with about 500 pages or fewer, where every page is linked from another, may not need one. Large sites, new sites and sites with many videos or images benefit most.
Key takeaways
- A sitemap helps Google find pages. Google calls it a hint, and it does not guarantee that a page is crawled or indexed.
- List only the addresses you want to appear in search results.
- Google ignores the priority and change frequency fields, and uses the last modified date only when it is consistently accurate.
- One file holds up to 50,000 addresses or 50MB. Larger sites split the list and join the files with a sitemap index.
- Submit the sitemap once in Search Console, then check the Sitemaps report after any big change to the site.
In this guide
This guide is for owners who have seen the word sitemap in Google Search Console or in a developer's quote and want to know what it is for. It covers XML sitemap best practices in plain terms: who needs one, what belongs in the file, how to submit it and how to read the errors. Sitemap checks are part of our technical SEO service.
What is an XML sitemap?
It is a list of page addresses in a format search engines read. Google describes a sitemap as a file where you provide information about the pages, videos and other files on your site. XML is the usual format. Google also accepts a plain text list and the feed formats RSS and Atom, and has no preference among them.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://www.example.com/</loc>
<lastmod>2026-10-01</lastmod>
</url>
<url>
<loc>https://www.example.com/services/roof-repair</loc>
<lastmod>2026-09-12</lastmod>
</url>
</urlset>You rarely write this by hand. Google says that if you use a website platform such as WordPress, Wix or Blogger, it has likely already made a sitemap available. Your platform's help pages give its address.
Does your website need a sitemap?
Google's own answer depends on the size of the site, its age and how well its pages link to each other.
Google's test for whether a sitemap helps
- The site is largeYou might need one, so new and changed pages are not missed
- The site is new and few other sites link to itYou might need one, because Google finds pages by following links
- The site has a lot of video or imagesYou might need one, with the media details included
- About 500 pages or fewer, and every page is linked from anotherYou might not need one
Our view: a sitemap costs almost nothing when your platform produces it, so have one either way. Do not expect it to rescue a page. Google says a sitemap does not guarantee that the items in it will be crawled and indexed.
How would you know your sitemap has a problem?
Open the address of your sitemap in a browser and compare it with the pages you know you have. Then open the Sitemaps report in Search Console.
| What you notice | What it usually means | What to ask your developer |
|---|---|---|
| The Sitemaps report shows: Couldn't fetch | Google could not retrieve the file | Does the sitemap load in a browser, and is it behind a login or blocked by robots.txt? |
| The file lists far more addresses than you have pages | It includes filter, tag or duplicate addresses | Which rule decides what goes into the sitemap? |
| A page published last week is not in the file, or a deleted page still is | The file is built by hand, or on a schedule that has stopped | Is the sitemap rebuilt automatically when a page is published or removed? |
XML sitemap best practices: what belongs in the file?
Only the pages you want people to find in search, each at its preferred address. Everything else is noise that makes real problems harder to see.
What a good sitemap looks like
- Only pages you want in search resultsThis is Google's wording. Leave out addresses that redirect, show an error or carry a noindex tag. Where several addresses show the same page, list the one you prefer: Google treats a place in the sitemap as a weak signal of which version is the main one.
- Full addressesGoogle asks for complete addresses that start with https:// and include the domain, exactly as the page should be fetched.
- An honest last modified dateGoogle uses this date (the lastmod field) only if it is consistently and verifiably accurate. It should change when the main content, the structured data or the links on the page change. Google's example of a change that does not count is an updated copyright year.
- No priority or change frequencyGoogle ignores both fields. There is no reason to pay anyone to tune them.
- Built by the website, not by handGoogle says a sitemap with more than a few dozen addresses needs to be generated. A file your website builds itself stays in step with what is live.
- Kept at the top of the siteGoogle recommends the site root, such as yourdomain.com/sitemap.xml, so that the file can cover every page.
- Within the size limitsOne sitemap holds up to 50,000 addresses or 50MB uncompressed. A larger site splits its list into several files and joins them with a sitemap index, a file that lists the other sitemaps.
How do you submit a sitemap to Google?
Through the Sitemaps report in Google Search Console. It takes a few minutes, and you do it once.
Submitting a sitemap
- Find the sitemap's address and open it
Your platform's help pages or your developer can give you the address. Open it in a browser and check that it lists your real pages.
- Open the Sitemaps report in Search Console
You need owner permission on the property. Paste the address into the Add a new sitemap box and submit it.
- Name the sitemap in robots.txt as well
Robots.txt is a small text file that tells search engines which parts of a site they may fetch. A line in it that starts with Sitemap: and gives the address lets Google find the file without Search Console.
- Check the status
The report should show Success. Google says there is no need to resubmit a sitemap that has not changed. Resubmit after a big change, such as a redesign.
Submitting does not put pages into Google at once. Google says crawling can take anywhere from a few days to a few weeks. If pages are still missing after that, work through why a website is not showing up on Google.
Sitemap errors in Search Console: what do they mean?
The report gives each sitemap one of three statuses, and names the errors it finds. These are the ones owners meet most often.
| What the report says | What it means | What to do |
|---|---|---|
| Success | Google loaded and processed the file with no errors | Nothing. Check again after the next big change |
| Has errors | The file was fetched but some entries failed. The entries that were read are still used | Open the list of errors and fix the ones below |
| Couldn't fetch | Google could not retrieve the file | Check that the address loads and is not blocked or behind a login |
| URLs not accessible | Google hit an error when it fetched a listed address | Remove dead pages from the list or repair them |
| URLs not followed | Listed addresses were not crawled, often because of redirect chains or incomplete addresses | List the final, full address of each page |
| Sitemap contains urls which are blocked by robots.txt | The sitemap asks Google to fetch pages that robots.txt tells it not to | Decide which instruction is right and remove the other |
To see how many of the listed pages made it into Google, filter the Page indexing report by sitemap. On a larger site, split the sitemap by type of page: one file for products, one for categories, one for articles. A problem then shows up against one group, which tells your developer where to look.
Sitemaps are checked as part of Taskcover's Technical SEO Audit, which starts from $2,500 one-time. See the pricing page.
Related serviceTechnical SEO: make sure Google can reach every page
We compare what your sitemap lists with what Google has indexed, and write each fix as a clear task for your developers.
See the serviceQuestions people ask about XML sitemaps
What is the difference between an XML sitemap and an HTML sitemap?
An XML sitemap is a file written for search engines, which visitors never see. An HTML sitemap is an ordinary page on the site that lists links for people. The XML file is the one you submit in Search Console.
Do images and videos need their own sitemap?
Not a separate file. Google says video details can go in a sitemap of their own or be added to the one you already have, whichever is easier. See video SEO for videos and image SEO for images.
How do I remove a sitemap from Google?
Deleting it in the Sitemaps report only removes it from the report. Google says it won't forget the sitemap or the addresses listed in it. To stop Google using the file, delete it from your site. To keep a listed page out of search, use a noindex tag on that page.
Should a site with several languages list them in the sitemap?
It can. Google accepts the tags that connect language and country versions (hreflang) in three places: the page's code, the server's response headers, or the sitemap. Whichever you choose, every version has to list itself and all the others. What hreflang is explains the tags.
Not sure Google can find all your pages?
Send us your website and we will show you which pages Google has found and which it has missed, at no cost.
The authors
Who wrote and checked this guide

Written by
Jamiez Nguyen
Founder & CEO
Jamiez Nguyen founded Taskcover and leads strategy and client growth. He started it in 2017 as a team doing search work behind the scenes for other agencies, then opened it to businesses in the USA, Canada and Australia.

Reviewed by
John Edward
CTO
John Edward leads the technical side of Taskcover: how sites are built, how fast they load, and how search engines read them.
Updated Fact-checked About the people at Taskcover
Sources
Where the facts in this guide come from
Facts last checked on October 12, 2026.
- 1Learn about sitemapsGoogle Search CentralChecked on October 12, 2026
- 2Build and submit a sitemapGoogle Search CentralChecked on October 12, 2026
- 3How to specify a canonical URL with rel="canonical" and other methodsGoogle Search CentralChecked on October 12, 2026
- 4Manage your sitemaps with a sitemap index fileGoogle Search CentralChecked on October 12, 2026
- 5Sitemaps reportGoogle Search Console HelpChecked on October 12, 2026
- 6Video sitemaps and alternativesGoogle Search CentralChecked on October 12, 2026
- 7Tell Google about localized versions of your pageGoogle Search CentralChecked on October 12, 2026
- 8Ask Google to recrawl your URLsGoogle Search CentralChecked on October 12, 2026
