Sitemap
Discover and parse a domain's sitemap into a URL list with lastmod, changefreq and priority.
https://api.rankparse.com/v1/sitemap2 credits (refunded when no sitemap is found)API keyFinds a domain's sitemap, walks sitemap indexes, and returns the URLs it lists. Use it to inventory a website's indexable pages or to check what a website tells crawlers. This is a live fetch of the website's own files, not link graph data.
Query parameters
domainstringrequiredBare domain such as stripe.com. No scheme, path or port. A missing or invalid value returns 400 invalid_url (or private_ip) before any charge.
limitintegerdefault 100Maximum URLs returned in data. Clamped to 1 to 1000. A missing, 0 or non-numeric value falls back to 100. It is not echoed in the response.
Response
domainstringThe normalized domain you queried.
dataarrayUp to limit URL entries. Empty when no sitemap was found or read.
Show propertiesHide properties
urlstringThe <loc> value.
lastmodstringThe <lastmod> value, as written. Absent (not null) when missing.
changefreqstringThe <changefreq> value. Absent when missing.
prioritystringThe <priority> value, as a string. Absent when missing.
totalintegerURLs collected from every document read during the walk, so it can be higher than limit (one urlset of 142 URLs gives total: 142 even with limit=50). The walk stops reading new documents once limit URLs are gathered, so on a large website this is below the true URL count. Check truncated.
sitemap_urlstring | nullThe first sitemap document that could be read. When sitemaps were found but none could be read, the first one found (with source: "none"). null when none was found.
sitemap_typestringsitemap (a urlset), sitemap_index or none. Describes the document at sitemap_url.
child_sitemapsarray of stringsChild sitemap URLs discovered in indexes, capped at 200 entries. When robots.txt lists several sitemaps and none is an index, the other listed sitemaps appear here.
child_sitemaps_totalintegerNumber of child sitemaps discovered, before the 200 cap.
child_sitemaps_fetchedarray of stringsThe children that were actually read for this response.
truncatedbooleantrue when a bound stopped the walk early (see below) or the child list was capped. data and total then under-report the website.
sourcestringsitemap, or none when no sitemap was found or readable.
credits_usedinteger2, or 0 when source is none.
credits_remainingintegerYour balance after billing and any refund.
Behavior and limits
Discovery order
- Every
Sitemap:line in/robots.txt. If there is at least one, these are the roots and nothing else is tried. - Otherwise
/sitemap.xml, then/sitemap_index.xml, accepted only if the document contains aurlsetorsitemapindex.
Only 2xx answers count. A root on another host is fetched under the same public-host rules as Page SEO.
The walk is bounded
- Sitemap indexes are followed breadth-first, three tiers at most (root, child index, urlset).
- At most 16 documents are read per request, 5 at a time, within a 12 second budget. Root documents get 8 seconds each, children 5.
- Children of a child index (the third tier): each index contributes at most 5, and at most 10 are read in total. Children of a root index are limited only by the 16 document cap. Up to 16 roots from
robots.txtare used. - Each document must be 2 MB or smaller. A larger one is skipped like an unreachable one.
- When any bound is hit, or
limitis reached while work remains,truncatedistrue. - A document that fails to load is skipped without failing the request.
Billing
- Credits: 2, charged up front. When no sitemap is found or readable (
source: "none"), the 2 credits are refunded andcredits_usedis0. - Other non-2xx responses after the charge are refunded. Invalid domains are rejected before billing. No caching.
- Rate limit: 60 requests per minute per key. See Rate limiting.
Legacy route
GET /v1/url-index redirects (301) to /v1/sitemap, forwarding domain and limit.
Errors
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_url | domain is missing, not a bare domain, or longer than 253 characters. |
| 400 | private_ip | The domain is a private, reserved or local host. |
| 401 | invalid_api_key | Missing, invalid or revoked API key. |
| 402 | insufficient_credits | Balance is lower than 2 credits. |
| 402 | spend_cap_reached | Your monthly spend cap is reached. |
| 429 | rate_limited | More than 60 requests in a minute. |
An unreachable website or one without a sitemap is not an error: it returns 200 with source: "none" and is not charged. See Errors for the shared error format.
Related
MCP tool: get_sitemap (arguments domain and optional limit, default 100).