Generate Google Sitemap for Magento to boost your search engine ranking. It is mainly designed to crawl pages that may not be otherwise found by web crawlers.
A sitemap can be put together to index all pages and images. When we enable google sitemap, Magneto creates a file known as sitemap.xml.
The sitemap for Magento helps you in setting up the frequency of updates and the order in which the content should be generated.
It is crucial to update content and sitemap simultaneously. If the content of your e-commerce store changes in a day, week or month, update the Magento sitemap with the same frequency.
If your site is still under-development, then you must consider adding instructions in the robots.txt file so that web crawlers don’t index your site.
And when your site is set in motion, you can alter the instructions to permit the Magento store pages to be indexed.
Here is step by step guide on how to generate Google Sitemap for the Magento store:
- Configure the Sitemap
- Generate the Sitemap
- Configure and Enable Robots.txt
- Submit your Sitemap to Search Engines
- Restore Previous Robot Instructions
Step 1- Configure the Sitemap
This step involves setting up what is to be included in the sitemap and how frequently it needs to be updated.
1. Go to the Admin sidebar and select Stores. After that, under Settings go to Configuration.
2. You will see the Catalog option on the left side of the panel. Expand. Choose XML SItemap.
3. On the right side, you will see Categories Options on the top.
- Set your Frequency
- Set your priority from 0.0 to 1.0 (Zero to Highest)
4. Now expand the Products Options tab.
- Set your Frequency.
- Set your Priority from 0.0 to 1.0 (Zero to Highest).
- To control the number of images that are included in the Magento sitemap, set Add Images into Sitemap.
5. Click on CMS Pages Options to expand.
- Set your Frequency.
- Set your Priority from 0.0 to 1.0 (Zero to Highest).
6. After completion, press the Save Configuration button.
7. When you are done with Categories Options, expand the Generation Settings section.
- To create a sitemap XML in Magento, Set Enabled to Yes.
- Set up Start Time at which you want the sitemap to be updated.
- Set your Frequency.
- In the Error Email Recipient field, you have to give the email address at which you want to receive notification in case of error occurrence.
- Set your Error Email Sender.
- Set your Error Email Template
8. After this, you have to Set the Map File Limits.
- Enter the maximum number of URLs that you want to include in your Magento sitemap in the Maximum No of URLs per File field. (Max. 50,000).
- Enter the largest size in bytes that are allocated for Magento sitemap in the Maximum File Size. (Default size- 10,485,460 bytes).
9. The final step is to Set the Search Engine Submission Settings.
- Expand Search Engine Submission Settings/
- If you are using a robots.txt file, then set Enable Submission to Robots.txt to “Yes.”
- After completion, press Save Configuration button.
Step 2- The next step is to generate the Sitemap
1. To do this, go to the Admin menu and choose Marketing.
2. In Marketing, you will see a heading- SEO & Search. Under this, click on the SItemap.
3. Choose Add Sitemap. Then enter the Filename in the given field. For example sitemap.xml
4. After this, enter the Path to decide where the XML file is to be present on the Server. Keep in mind that the path must be writable.
- /sitemap/- This depicts that Magento sitemap file in a directory known as “sitemap.”
- /- This places the sitemap for Magneto at the root of your Magento installation.
5. Once you are done, click on the Save and Generate button.
Step 3- Configure and Enable robots.txt
The default Magento configuration involves instructions for web crawlers and bots to index your site. These instructions are saved in the form of a file under the name of “robots.txt.” It is present in the root of your Magento Installation.
The default setting does not allow web crawlers to index those part of the website that contains files to be used internally by the system. You can either choose the default setting or customize your own.
Steps involved are:-
1. Go to the Admin and click on Content.
2. Under the Design section, select Configuration.
3. In the first row of the grid- find Global configuration. Click Edit.
4. After that, expand the Search Engine Robots section.
5. Customize Default Robots to one of the following:
INDEX, FOLLOW | It allows web crawlers to index both the website and regular updates. |
NOINDEX, FOLLOW | It inhibits web crawlers to index the website but to check back for regular updates. |
INDEX, NOFOLLOW | It allows web crawlers to index the website but not the regular updates. |
NOINDEX, NOFOLLOW | It inhibits web crawlers to index both the website and regular updates. |
6. You can also add custom instructions to Edit Custom instruction of robots.txt file.
7. To restore default instructions, click on Reset to Default.
8. After completion, click on the Save Configuration button.
Step 4- Submit your Sitemap to Search Engines
You can submit your sitemap for Magneto to various search engines by providing them Magento sitemap URL. To copy the link, follow the steps given below:-
- In the sitemap grid, right-click the URL in the Link for Google column.
- Select Copy Link Address on the menu.
Step 5- Restore Previous Robot Instructions
You can restore either default or original instructions according to your requirements.
Wrap Up
That’s it.
You have successfully created and submitted the sitemap for Magento.
If there is any issue, please leave it in the comment box.
1 thought on “How to Generate Google Sitemap for Magento? (In 5 Easy Steps)”
hello, when I Go to Marketing in Magento 2 > SEO & Search, there is no button “Site Map”, only URL rewrites & Search Terms, please advise further?