Skip to content
ZenoCloud
Applications

How to Configure Magento 2 Sitemap?

Complete guide to generating and configuring XML sitemaps in Magento 2 for better search engine indexing.

How to Configure Magento 2 Sitemap?

An XML sitemap helps search engines discover and index all pages on your Magento 2 store. Here's how to set it up correctly.

What is an XML Sitemap?

An XML sitemap is a file that lists all the URLs on your website. Search engines like Google use it to discover and crawl your pages more efficiently.

How to Configure Sitemap in Magento 2

  • Log in to your Magento 2 Admin panel
  • Go to Marketing > SEO & Search > XML Sitemap
  • Click "Add Sitemap"
  • Enter filename (usually sitemap.xml)
  • Select store view
  • Click Save

Generating the Sitemap

After creating the sitemap entry, Magento automatically generates it. You can also:

  • Use cron jobs for automatic generation
  • Generate manually in the admin panel
  • Use command line to trigger sitemap generation directly on your server using Magento's CLI tools

Sitemap Configuration Settings

  • Include products
  • Include categories
  • Include CMS pages
  • Change frequency
  • Priority settings

What Should Be Included

  • Product pages
  • Category pages
  • CMS pages
  • Blog pages
  • Exclude search results
  • Exclude duplicate URLs

What to Exclude

  • Checkout pages
  • Customer account pages
  • Search pages
  • Filter pages
  • Private pages

Submitting Your Sitemap to Search Engines

  • Google Search Console: Add sitemap URL
  • Bing Webmaster Tools: Submit sitemap
  • Add to robots.txt: Sitemap: your-sitemap-url

Monitoring Sitemap Performance

  • Check Search Console for crawl stats
  • Monitor indexation rates
  • Track coverage
  • Check for errors
Next step

Apply the lesson to a real environment.

Browse all field notes
Quote request

What should we quote?

Describe the configuration or problem, location and timing.

Add company or phone
Replies go to your work email. Add a phone number only if you want a call.