The short version: most website builders and CMS platforms (WordPress, Wix, Shopify) generate an XML sitemap for you automatically, usually at yoursite.com/sitemap.xml, so your real job is checking it’s correct, submitting it to Google Search Console, and keeping it clean rather than building one from scratch by hand.
I want to get one thing out of the way before anything else. An XML sitemap does not get you ranked. It has never got anyone ranked. I have watched people spend an entire afternoon fiddling with sitemap settings expecting some sort of SEO miracle, and it just doesn’t work that way. What it does is tell search engines where your pages live and roughly how important you think each one is. That’s it. It’s a map, not a magic trick. Once you accept that, the whole topic gets a lot less stressful.
What an XML sitemap is, in plain terms
An XML sitemap is a file, usually called sitemap.xml, that lists every page (or the pages you want indexed) on your website in a format search engines can read quickly. Each entry typically includes the page URL, when it was last changed, and sometimes how often it changes. Google, Bing, and other search engines use this file as a shortcut instead of relying purely on following links from page to page, which is slower and less reliable, especially on a big site.
Think of it like handing someone a table of contents instead of making them read every page of a book to find out what’s in it. Google will still crawl your site whether or not you have one, but the sitemap makes the process faster and more complete, particularly for pages that are buried deep in your structure or have few internal links pointing at them.
Do you even need to build one manually? (Probably not)
Here’s the bit most sitemap guides gloss over: if you’re on WordPress with a decent SEO plugin, Wix, Squarespace, or Shopify, your sitemap already exists. You don’t need to create it from nothing. Yoast SEO and Rank Math both generate one automatically the moment you install them, and it updates itself every time you publish or delete a page. Wix does the same thing behind the scenes, no plugin needed. If you’re comparing platforms for a new build, I’ve written before about the real differences between Wix and WordPress for a small business website, and sitemap handling is one of the small but genuine points in Wix’s favour for anyone who doesn’t want to touch code.
So the honest first step isn’t “create an XML sitemap.” It’s “go and check whether one already exists.” Type your domain followed by /sitemap.xml into your browser. If you see a page full of URLs wrapped in XML tags, you have one. If you get a 404, then yes, you need to create it, and I’ll show you exactly how below.
Step-by-step: creating an XML sitemap depending on your platform
Here’s what I do for clients, broken down by platform, because the method changes depending on what you’re running.
WordPress
- Install Yoast SEO or Rank Math (both free versions do this fine).
- Activate the plugin. Yoast automatically creates sitemap_index.xml at yoursite.com/sitemap_index.xml. Rank Math uses /sitemap_index.xml too.
- Go into the plugin’s settings and confirm which post types and taxonomies are included. This matters more than people realise, because by default some plugins include tag archives and author pages, which you almost never want indexed.
- Check the sitemap loads by visiting the URL directly in a browser.
Shopify
- Shopify builds this automatically at yourstore.com/sitemap.xml. There is no setting to turn on or off. You cannot switch it off, which is fine, because Shopify manages it sensibly by default.
- Your only real job is submitting the URL to Google Search Console (covered below).
Wix
- Wix generates yoursite.com/sitemap.xml automatically once your site is live and connected to a domain.
- You cannot edit it manually, but Wix does exclude pages you’ve marked “noindex” in the SEO settings for that page, which is the correct behaviour.
A custom-built or static site with no CMS
- You’ll need to build the file yourself. Free tools like XML-Sitemaps.com will crawl your site and spit out a sitemap.xml file for sites under 500 pages at no cost.
- Upload the resulting file to the root directory of your site via FTP, so it sits at yoursite.com/sitemap.xml.
- Set a reminder to regenerate it every time you add a meaningful number of new pages, because a static sitemap doesn’t update itself the way a plugin-generated one does.
Submitting your sitemap to Google (the step people skip)
Having the file exist isn’t enough. Google can find it eventually through your robots.txt file if you’ve referenced it there, but the fastest way is to hand it over directly.
- Log into Google Search Console for your verified property.
- In the left menu, click Sitemaps.
- Type just the end part of the URL, so sitemap.xml or sitemap_index.xml, and click Submit.
- Come back in 24 to 48 hours and check the status says “Success” rather than “Couldn’t fetch.”
I’d also recommend doing this in Bing Webmaster Tools. It takes about three minutes and Bing still drives a small but real slice of search traffic, plus its data now feeds into some AI answer engines too.
The real story: what happens when your sitemap lies
I’ll tell you where this went wrong for me, because it’s a useful cautionary tale. A couple of years ago I was migrating an old section of my own site into a new structure, and the plugin kept the sitemap pointed at hundreds of URLs that no longer existed, old blog categories, tag pages, event listings from a conference I ran back in 2019. Google Search Console started flagging a rising number of “Submitted URL not found (404)” errors, week after week. It doesn’t tank your rankings overnight, but it does something quieter and more damaging: it tells Google your sitemap isn’t trustworthy, which means Google starts crawling it less diligently and takes longer to notice new pages I published afterward.
That mess is what pushed me into a proper spring clean, which I wrote about honestly in de-indexing 1,300 pages to save my website. The sitemap wasn’t the whole problem, but a dead, bloated sitemap was a symptom of a wider structural mess I’d let build up for years. If you’re planning any kind of migration or big restructure, read through my notes on protecting your rankings during a website migration before you touch anything, because sitemap errors are one of the most common and preventable things that go wrong.
What should and shouldn’t be in your sitemap
This is where most guides go quiet, and it’s where the real skill sits. A sitemap crammed with every URL on your site isn’t better. It’s worse.
- Include: your useful, indexable pages: blog posts, service pages, product pages, your key landing pages.
- Exclude: thank-you pages, internal search result pages, tag archives with thin content, duplicate content variants, admin pages, and anything marked noindex (a sitemap listing a noindex page sends Google a contradictory signal).
- Exclude: pages behind a login or paywall that Google can’t crawl anyway.
Most decent SEO plugins handle this exclusion logic reasonably well by default, but I always check manually once a year, because default settings drift as plugins update and new post types get added that nobody remembers configuring.
How this fits into your bigger site structure
A sitemap is a reflection of your structure, not a replacement for having a good one. If your site’s navigation is a mess, your sitemap will just be a very organised list of a mess. Before you even think about sitemap files, it’s worth stepping back and mapping out how your pages connect to each other. I go into this in my piece on how to map your website structure before you plan new content, and it’s a step people skip constantly because a sitemap tool feels more concrete and finished than a structural diagram does.
If you want to go further and use sitemap data diagnostically, not just as a submission checkbox, I’ve written a longer walkthrough on how to use a sitemap tool to improve your site structure, including spotting orphaned pages that exist on your site but link to nowhere.
How often should you update it?
If you’re on WordPress, Shopify, or Wix, your sitemap updates itself the instant you publish, edit, or delete a page. You don’t need to manually regenerate it. If you’re running a static, manually built sitemap, I’d regenerate it every time you add more than 5 to 10 pages, or at minimum once a month if you’re publishing regularly. Leaving a static sitemap untouched for six months while your site keeps growing is exactly how you end up with the 404 mess I described above.
A few small technical checks worth doing
- Make sure your sitemap URL is referenced in your robots.txt file, usually as a line reading “Sitemap: https://yoursite.com/sitemap.xml” near the bottom.
- Keep individual sitemap files under 50,000 URLs and 50MB uncompressed, which is Google’s stated limit. Most small business sites will never come close to this, but larger sites need a sitemap index file that splits URLs across several smaller files.
- Check the sitemap only lists canonical URLs, the version you want indexed, not both the www and non-www version, or both http and https.
If you’re curious about how sitemaps and site architecture connect to useful web tools generally, I’d also point you toward my roundup of 50 websites you didn’t know existed but really should, a few of which are handy for quick technical SEO checks like this.
When it’s worth getting help
For most small business owners, a plugin and a five-minute Search Console submission covers it. Where I’d bring in outside help is if you’re running a large ecommerce catalogue, a multi-language site, or you’re mid-migration and things are already going wrong. That’s a different, more technical job, and it’s the kind of work that falls under proper hands-on AI and SEO support rather than a weekend DIY fix. If that’s where you are, it’s worth looking at what an AI implementation coach can do for the technical side of your site, not just the content side.
Frequently asked questions
Do I need an XML sitemap if my site is small, say under 20 pages?
Yes, but it matters less. Google can crawl a 20-page site through normal links fairly easily. A sitemap still helps, costs you nothing since most platforms generate it automatically, and there’s no good reason to skip it.
Can having an XML sitemap hurt my SEO?
Only if it’s badly maintained. A sitemap full of dead URLs, noindexed pages, or duplicate content sends confusing signals to Google and can slow down how quickly new pages get crawled, but the file itself is never harmful when it’s accurate.
How is an XML sitemap different from an HTML sitemap?
An XML sitemap is built for search engines to read and isn’t meant for human visitors. An HTML sitemap is a visible page on your site, often linked in the footer, that helps actual visitors handle. Some sites benefit from having both.
How long does it take Google to crawl my new sitemap after submitting it?
Usually 24 to 48 hours for Google to fetch and process it, though full indexing of every URL inside it can take days or weeks depending on how much authority and crawl budget your site already has.
Useful references
Related reading: How to Improve SEO on a WordPress Website (Without Wasting Six Months on a Plugin) and How to Schedule an Entire Photo Album on Facebook in Advance.