ai toolkit icon

Semrush One — Stay Ahead in AI Search & Traditional SEO

Discover More

How to create an XML sitemap?

Author:Semrush Team
1 min read
Sep 16, 2025

You create an XML sitemap by listing your website's important pages in a file that helps search engines find and index your content more efficiently.

For small websites (under 500 pages):

  • Use CMS plugins for easy creation. WordPress users can install Yoast or Rank Math to automatically generate sitemaps
  • Include only important, public pages. Add pages you want search engines to index, excluding login pages, thank you pages, or duplicate content
  • Save as sitemap.xml in your root directory. Place it at yoursite.com/sitemap.xml so search engines can easily find it

For larger websites:

  • Use crawling tools like Screaming Frog. These tools automatically scan your site and generate comprehensive sitemaps
  • Set up automatic updates. Configure your sitemap to refresh when you add new content or remove old pages
  • Create multiple sitemaps if needed. Large sites can use sitemap index files that organize content by type or section

After creating your sitemap, add it to your robots.txt file and submit it through Google Search Console and Bing Webmaster Tools for faster discovery.

Keep your sitemap updated by removing broken links and adding new pages regularly to maintain its effectiveness.

Share
Author Photo

The Semrush Team brings together AI visibility experts, SEO specialists, data analysts, and product practitioners to help businesses grow and manage their online visibility. We publish research, experiments, and practical guidance grounded in real data from the Semrush platform, covering search, content marketing, and the broader digital marketing landscape.

Most popular pages