TECHNICAL SEO · 03
Make the list, then hand it over.

How to create an XML sitemap and submit it to Google

Find the sitemap your site already has, make one if it has none, check it for problems, and submit it to Google and Bing in a few minutes.

Most site owners never need to write a sitemap by hand. The site builder makes one, and the real work is finding it, checking it and telling search engines where it is. This lesson walks through all three, plus what to do if your site has no sitemap at all.

If you are not sure what a sitemap is for, read XML sitemaps: what to include and what to leave out first. The short version: an XML sitemap is a list of the pages you want search engines to find.

Step 1: find the sitemap you already have

Before making anything, check whether your site already has one. Type your domain followed by one of these into the browser:

  • /sitemap.xml, the most common address, used by Shopify, Wix, Squarespace and many others.
  • /sitemap_index.xml, used by WordPress plugins such as Yoast and Rank Math.
  • /wp-sitemap.xml, the sitemap WordPress has built in since version 5.5, when no plugin replaces it.

If none of those load, open your robots.txt file at your domain followed by /robots.txt and look for a line that starts with Sitemap:. It names the file directly.

Where each builder keeps the setting:

  • WordPress: the SEO plugin's settings, under Sitemaps.
  • Shopify, Wix and Squarespace: created automatically, with nothing to switch on.
  • Webflow: the SEO tab of the site settings, under "Auto-generate sitemap".

Step 2: make one if you have none

If your site really has no sitemap, for example a hand-coded site or a small static site, you can make one from a list of addresses.

  1. List every page you want in search, one full address per line, including https://.
  2. Leave out pages that redirect, pages that return errors, and pages marked noindex.
  3. Paste the list into the free XML sitemap generator. It writes a valid file you can copy or download.
  4. Upload the file to the root of your site, so it loads at your domain followed by /sitemap.xml.

A hand-made sitemap goes out of date as soon as you add a page, so set a reminder to regenerate it whenever your pages change.

BEFOREhttps://example.com/blog/my-post?utm_source=newsletter
AFTERhttps://example.com/blog/my-post

The first address carries a tracking tag, which makes it a duplicate of the real page. Sitemaps should list each page once, at its clean, final address.

Step 3: check it before you submit

A sitemap with problems in it sends mixed signals. Open the checker on the sitemap tool and paste your sitemap's address. It reads the file and flags:

  • addresses that redirect somewhere else,
  • addresses that return an error such as 404,
  • addresses marked noindex,
  • lastmod dates that are all the same, which usually means they are not real.

Fix the problems at the source: in your plugin settings, by removing old pages, or by updating your own links. Then check again.

KEY TAKEAWAYSubmit a sitemap only after it lists real pages you want in Google. A short, clean list beats a long one full of redirects and errors.
FREE GUIDEGet the free On-Page SEO Guide

The full on-page checklist we use on every page, free by email.

Step 4: submit it to Google and Bing

Search engines can find a sitemap on their own through robots.txt, but submitting it gives you a report on how it is used.

Google Search Console:

  1. Open your property in Search Console.
  2. In the menu, go to Indexing, then Sitemaps.
  3. Type the sitemap's address, for example sitemap.xml, and press Submit.

Bing Webmaster Tools: open Sitemaps, press Submit sitemap and paste the full address.

Also add one line to your robots.txt, so every search engine can find the file:

Sitemap: https://example.com/sitemap.xml

Google retired its old sitemap "ping" address in 2023, so there is no need to ping it after each change. Keep the file up to date and Google will read it again on its own.

Step 5: read the report

Come back after a few days. In Search Console, the Sitemaps report shows when Google last read the file and how many pages it found. Open the page indexing report and filter by your sitemap to see which listed pages are indexed and which are not, with the reason for each.

A gap between submitted and indexed pages is normal on a new site. It is worth a closer look when important pages stay out for weeks. The lesson crawling and indexing, explained simply covers the usual reasons a page is found but not indexed.

This is lesson 3 of the Technical SEO series. When your sitemap is clean, run the free audit on your most important page to check the rest.

That’s lesson 3. Want me to check your own page?

Audit my page
Ona

I work on the technical side of SEO. SEO Expert Tips is where I break that work down into small, practical steps. More about me