How to extract a sitemap from a website

To extract a sitemap from a live website, check the standard locations first: try the URL paths /sitemap.xml, /sitemap_index.xml, or /sitemap.html. If those return nothing, check the site's robots.txt file, which almost always lists the sitemap location. Third-party tools like Screaming Frog can also find and download it automatically.
Key takeaways
- The most reliable first step is visiting
yourdomain.com/robots.txt, search engines require this file, so it exists on almost every live site, and it typically includes aSitemap:directive pointing to the exact file path. - XML sitemaps can be nested: a sitemap index file (
sitemap_index.xml) links to several child sitemaps, each covering a different content type (pages, posts, images, videos). - Google Search Console shows you the sitemaps a site owner has submitted, which is more reliable than guessing URL patterns, provided you have access to the property.
- If you need a sitemap that does not appear to exist, a crawler such as Screaming Frog SEO Spider can generate one by crawling the live site, though this takes longer on larger sites.
- Extracting a competitor's sitemap is legal and common practice in SEO; the files are publicly accessible by design because they are intended for search engine bots.
What is a website sitemap, and why would you want to extract one?
A sitemap is a structured file, usually in XML format, that lists every important URL on a website alongside optional metadata such as the date the page was last modified. Its primary purpose is to guide search engine crawlers to content they might otherwise miss.
You might want to extract one for several reasons. If you are auditing a site you have just taken over, the sitemap tells you immediately what the previous team considered indexable content. If you are doing competitor research, the sitemap hands you a complete list of every product page, blog post or landing page without you having to manually browse the site. SEO practitioners and AEO agency teams also use extracted sitemaps as a starting point for content gap analysis.
Where to look first: the standard URL patterns
Most content management systems generate sitemaps at predictable paths. Try these in order.
https://www.example.com/sitemap.xml, the default for the majority of WordPress sites running Yoast SEO or Rank Math.https://www.example.com/sitemap_index.xml, common when the site has multiple child sitemaps.https://www.example.com/sitemap.html, a human-readable HTML version, less useful for bulk extraction but still informative.https://www.example.com/page-sitemap.xmlor/post-sitemap.xml, child sitemaps WordPress plugins generate when content is split by type.
If the site returns a 404 at all of these, the sitemap either does not exist or lives at a non-standard path, which is where the next method becomes essential.
How to find a sitemap via robots.txt
The robots.txt file is the fastest and most reliable route. Every properly configured site has one, and the convention for listing the sitemap location inside it is near-universal.
Visit https://www.example.com/robots.txt in your browser. Scan the file for a line beginning with Sitemap:. It will look like this:
Sitemap: https://www.example.com/sitemap_index.xml
Copy that URL and open it directly. If the site has more than one sitemap, you may see multiple Sitemap: lines.
Using Google Search Console to find submitted sitemaps
If you have verified ownership of the site in Google Search Console, go to the Sitemaps report under Index. This shows every sitemap the site owner has submitted and whether Google was able to process it. This is particularly useful when taking over a site, because you can confirm at a glance which sitemap is actually registered with Google rather than which one merely exists in the file system.
If you do not have access to the property, Search Console is not an option. Move straight to a crawler instead.
Using Screaming Frog to extract a sitemap from any live site
Screaming Frog SEO Spider is the tool of choice when the above manual checks fail, or when you need to extract the sitemap contents into a spreadsheet for analysis.
- Open Screaming Frog and enter the site's root URL.
- Before crawling, go to Mode and select List if you want to crawl only the URLs inside a known sitemap. Alternatively, leave it in Spider mode to discover URLs and generate a new sitemap.
- Under Configuration, choose Spider and then Crawl Linked XML Sitemaps to pull in sitemap URLs automatically.
- Once the crawl completes, go to Sitemaps in the top menu and select XML Sitemap. You can export the full URL list as a CSV.
Screaming Frog's free tier crawls up to 500 URLs. For larger sites, the paid licence costs £259 per year (as of 2026) and removes that limit.
What if a website has no sitemap at all?
Some sites, particularly older or poorly maintained ones, have no sitemap. In that case, a full spider crawl using Screaming Frog or a similar tool will discover URLs by following internal links. The resulting URL list acts as a working substitute, though it will miss pages that are orphaned (no internal links pointing to them) or blocked by robots.txt.
Our existing guide on how to make an XML sitemap covers how to build one if you find the site is missing it entirely, which is a separate but related task.
Limitations worth knowing before you start
Extracting a sitemap gives you the URLs the site owner chose to declare, not every URL that exists. Pages intentionally excluded from the sitemap (thin content, duplicate pages, staging URLs) will not appear. Treat an extracted sitemap as a curated list, not a complete inventory.
Large e-commerce or publisher sites can have sitemap index files pointing to dozens of child sitemaps containing hundreds of thousands of URLs. Downloading and processing all of them requires either a crawler or scripting; a browser alone is not practical at that scale.
Frequently asked questions
Can I extract a sitemap from a competitor's website without their permission? Yes. Sitemaps are publicly accessible files placed on web servers specifically so that crawlers can find them. Viewing or downloading one is no different from reading any other public web page and requires no permission.
Why does the sitemap.xml URL return a 404 on some sites?
Either the site has not generated a sitemap (common on older or custom-built sites) or the sitemap lives at a non-standard path. Always check robots.txt before concluding that no sitemap exists, because the file path may simply differ from the default.
What is a sitemap index file, and how is it different from a regular sitemap?
A sitemap index file is a parent file that lists the locations of multiple child sitemaps rather than listing URLs directly. It follows the same XML structure but contains <sitemap> elements instead of <url> elements. Sites use them when their total URL count exceeds 50,000 (the per-file limit) or when separating content types improves organisation.
Does extracting a sitemap show me pages that are blocked from Google?
No. Pages excluded via robots.txt or a noindex meta tag may still appear in the sitemap file if the owner made an error, but a well-maintained sitemap should only list pages intended for indexing. Check the robots.txt separately if you want to see what has been blocked.
Which sitemap format should I expect to find: XML, HTML or RSS? XML is overwhelmingly the standard for machine-readable sitemaps submitted to search engines. HTML sitemaps are occasionally used as navigational aids for human visitors. RSS and Atom feeds can function as sitemaps for news or blog content but are rarely labelled as sitemaps. In practice, start with XML and you will find what you need on the vast majority of sites.
Written by the Revolve team, a digital marketing agency based in Banbury, Oxfordshire, delivering SEO, AEO and paid advertising for UK small and mid-sized businesses.
Last updated: 19 October 2026
By Revolve
Need expert support on search, paid media or measurement?
Get in Touch →