A sitemap is a file (usually in XML format), that contains a list of all your website’s pages you want Google to know about. It should be located in the root folder of your website and be accessible to search engine crawlers.
In this post, you will learn the 3 different methods you can use to submit a sitemap to Google.
Submit a Sitemap using the Google Search Console
This is the most popular and recommended method.
Step 1: Make sure that your sitemap is in the root folder of your website and publicly accessible.
Open a new browser window and type the sitemap URL. Usually it has the following format:
https://example.com/sitemap.xml
or https://example.com/sitemap_index.xml
If everything is ok, you will see something like this:
Step 2: Register your website with the Google Search Console
If you have not already done this, you need to create an account and register your website with Google. If you already have an account, move on to step 3.
Step 3: Submit your Sitemap
- Click SITEMAPS (under INDEX)
- Add your sitemap name (with the extension) in the ‘Add a new sitemap’ area
- Click the submit button
If everything is ok you will be promoted with the “Sitemap submitted successfully” message.
That’s all you have to do to let Google know about your sitemap. Google will monitor the sitemap file for changes and add new pages in their index.
Submit a sitemap using the robots.txt file
The robots.txt is a text file that resides in the root folder of your website and gives instructions to search engines as to which files (or parts) of a site they can crawl and index.
One of the elements you can add to your robots is the ‘sitemap’. You can add this anywhere you want in the file and it has the following format:
Sitemap: 'path to your sitemap file'.
Here is an example of how a robots.txt looks with the sitemap element.
When search engines (not just Google) read your robots.txt, they will also crawl and index your sitemap.
User-agent: *
Allow: /
Sitemap: https://example.com/sitemap.xml
Submit a sitemap using command line or programmatically
This is the least popular method you can use but it’s another option you have to make your sitemap available to Google.
You can use the ping command programmatically using the following format:
http://www.google.com/ping?sitemap='path to sitemap file'
For example:
http://www.google.com/ping?sitemap=https://example.com/sitemap.xml
You can also do it through a browser window by pasting the URL. Once submitted you will get a ‘sitemap notification received’.
How to remove a sitemap for Google
If for some reason, you want to remove a sitemap from Google:
- Login to Google Search Console
- Click SITEMAPS (under INDEX)
- Click on the sitemap file you want to remove
- Click the three dots (top right corner) and select REMOVE SITEMAP.
Submitting a Sitemap – FAQ
Here are some of the popular questions’ users ask about sitemaps.
Do I need to submit a sitemap to Google?
Yes. Although Google does a very good job in discovering new websites or updates to existing content, you can make their life easier and speed up the discovery process by submitting a sitemap using one of the three methods described above.
Does Yoast submit a sitemap to Google?
No. Yoast is generating the sitemap for your website and keeps it up-to date but it does not automatically submit the sitemap to Google.
What to include in my sitemap?
You should include only the pages of your website that you want to be part of the Google index and appear in Google search results.
Pages with duplicate or thin content should not be part of your XML sitemap.
Read how to optimize your XML sitemap for all the details.
Do I have to use all three methods for submitting my website to Google?
No. Use only one of the methods. The recommended method is submitting the sitemap through the Google Search Console. This way you’ll be able to check the statistics and also re-submit it if necessary.
Do I have to re-submit sitemap to Google every time I update my website?
No. You only need to submit your sitemap once and Google will monitor the sitemap for changes.
The only cases where you should re-submit the sitemap is when doing a website redesign, changing domain, changing permalink structure or making a lot of changes to the content.
Even if you don’t re-submit the sitemap, Google will pick up the changes eventually, re-submitting will make the process faster.
Key Learnings
A sitemap is a very useful tool for SEO. Through the sitemap you can control which pages of your website you want to be part of a search engine’s index.
You can also use it to give search engines information about your multilingual implementation (in case your website is available in more than one language).
Submitting a sitemap to Google is a straightforward task. You can use any of the above methods to let Google know about your website.
Once submitted, Google will monitor the sitemap file for changes so you don’t have to re-submit it every time you publish or update a post.
Gajraj Singh says
Hii Alex,
Such a nice information. Hope this will works for me.. 🙂
Kuldeep Singh says
Really valuable information you shared about submitting a sitemap to Google.