Updated
How to Find All Pages of a Website (Sitemap, robots.txt, Bulk)
1. Find the sitemaps
curl -s https://example.com/robots.txt | grep -i '^sitemap:'
curl -sI https://example.com/sitemap.xml
curl -sI https://example.com/sitemap_index.xmlA file that starts with <sitemapindex> is an index: each <loc> inside is another sitemap to open. Files ending in .xml.gz must be decompressed first. Beware of HTML pages whose address ends in .xml: they are not sitemaps.
What four real sites returned on 2 December 2026: apify.com names /sitemap.xml in robots.txt (HTTP 200); developers.cloudflare.com names /sitemap-index.xml (with a hyphen, so guessing /sitemap_index.xml gives 404); lemonde.fr lists three sitemaps, including news sitemaps, and has no /sitemap.xml; python.org declares none and both standard paths return 404. Always read robots.txt before guessing paths.
2. Read the URLs and their dates
curl -s https://example.com/sitemap.xml | grep -o '<loc>[^<]*' | sed 's/<loc>//'Each <url> may also carry <lastmod> (last change), <changefreq>, <priority>, image entries and hreflang alternates for other languages. Dates come in several W3C formats; convert them to one ISO 8601 form before comparing.
3. Keep only new or updated pages
To follow a competitor's blog, a documentation site or a news section, keep the URLs whose lastmod is after a date, or store the list and compare it with the next run: new URLs, changed dates and URLs that disappeared. Note that some sites set every lastmod to today; a stable list comparison is then more reliable than dates.
4. Do it in bulk
For many sites, or sites with hundreds of thousands of URLs, a tool that handles indexes, gzip, date formats and errors saves the scripting. We compared two tools on the Apify Store on the same 5 public sites on 1 December 2026:
| Plainprobe | apify/sitemap-extractor | |
|---|---|---|
| Sitemap URLs found | 1,191 / 1,191 | 1,191 / 1,191 |
| Non-sitemap URLs mixed in | 0 | 5,865 |
| Sites with no sitemap | Explicit error row, free | Empty, no error |
| Fields per URL | lastmod, changefreq, priority, images, hreflang | URL only |
| Time | 2.9 s | 24 s (stopped at cap) |
Same 5 sites (python.org, ovh.com, djangoproject.com, rust-lang.org, debian.org), default settings, run on Apify the same day. The other tool was stopped at a $0.25 cap. Sitemap counts were checked by hand with curl.
Where the other tool does more: it also follows links found in HTML pages, which helps if you want a crawl rather than a sitemap inventory. On ovh.com, pages ending in .xml are HTML pages, and parsing them as sitemaps produced 5,865 extra URLs.
Plainprobe Sitemap URL Extractor returns one JSON row per URL with lastmod, hreflang and images, filters by date or pattern, and lists removed URLs in monitor mode, at $0.10 per 1,000 URLs.
Limits to keep in mind
- A sitemap lists what the owner declares: orphan or forgotten pages may be missing, and some listed URLs may redirect or return errors (see how to find broken links).
- Some sites publish no sitemap at all; a polite crawler that respects robots.txt is then the only option.
- Check that the sitemap URLs belong to the site you asked for: an index can point to other hosts.
FAQ
How do I find all the pages of a website?
Start with its XML sitemaps: robots.txt usually lists them, otherwise try /sitemap.xml and /sitemap_index.xml. They list the pages the owner wants indexed, often with a last modification date. A crawler that follows links finds pages missing from the sitemap, but is slower and heavier on the site.
Where is a website's sitemap?
Look for Sitemap: lines in https://example.com/robots.txt. If there are none, try /sitemap.xml, /sitemap_index.xml and /sitemap.xml.gz. Large sites use a sitemap index that points to many child sitemaps.
How many URLs can a sitemap contain?
The sitemaps.org protocol allows up to 50,000 URLs and 50 MB uncompressed per sitemap file; bigger sites split their URLs across several files listed in a sitemap index.
How can I see which pages were added or updated recently?
Read the lastmod date of each URL in the sitemap and keep those after your date, or save the list and compare it with the next one to see new, updated and removed pages.