spareroom.co.uk APIspareroom.co.uk ↗
Access SpareRoom UK flatshare listings by city with prices, locations, images, and links. Also retrieve the top flatsharing cities in the UK.
curl -X GET 'https://api.parse.bot/scraper/cbca23db-ebaa-4a82-a40d-a790ec09434e/search_listings?city=London&page=1' \ -H 'X-API-Key: $PARSE_API_KEY'
Search for flat listings in a specific city or area on SpareRoom. Returns paginated results with up to 100 listings per page.
| Param | Type | Description |
|---|---|---|
| cityrequired | string | City or area to search in (e.g. London, Manchester, Brighton). |
| page | string | Page number for pagination. |
{
"type": "object",
"fields": {
"city": "string — the city searched",
"page": "integer — current page number",
"listings": "array of listing objects with title, price, location, image_url, and link",
"total_count": "string — total number of matching listings"
},
"sample": {
"data": {
"city": "London",
"page": 1,
"listings": [
{
"link": "https://www.spareroom.co.uk/flatshare/flatshare_detail.pl?advert_id=17456540",
"price": "1350 pcm",
"title": "Spacious Double Room with En Suite, in Ealing",
"location": "Ealing (W5)",
"image_url": "https://photos2.spareroom.co.uk/images/flatshare/listings/large/93/38/93382267.jpg"
}
],
"total_count": "15301"
},
"status": "success"
}
}About the spareroom.co.uk API
The SpareRoom API covers 2 endpoints for accessing UK flatshare data: search_listings returns paginated room and flat listings for any city, including title, price, location, image URL, and a direct listing link, while get_top_cities returns the curated list of top flatsharing cities from the SpareRoom homepage. Each search result page delivers up to 100 listings along with a total_count so you can page through the full result set.
Searching Flatshare Listings
The search_listings endpoint accepts a required city parameter (e.g. London, Manchester, Brighton) and an optional page parameter for pagination. Each response includes the searched city, the current page number, a total_count string indicating how many listings matched, and a listings array. Every listing object carries a title, price, location, image_url, and link back to the full SpareRoom listing page. With up to 100 listings per page, you can iterate through large result sets using the total_count to calculate how many pages exist.
Discovering Top Flatsharing Cities
The get_top_cities endpoint requires no inputs and returns a top_cities array. Each entry contains a name (the city name as it appears on SpareRoom) and a url pointing to that city's SpareRoom listings page. This endpoint is useful for building location pickers, seeding city-level searches, or staying current with which UK cities SpareRoom actively curates.
Coverage and Scope
Coverage is UK-wide, scoped to whatever cities and areas SpareRoom indexes. The search_listings endpoint reflects live listing inventory — the total_count field gives you the current volume at query time. Data returned is limited to the listing card level: title, price, location, image, and link. Full listing details such as room descriptions, availability dates, or landlord/tenant preferences are not included in the search response.
- Build a UK flatshare search tool that lets users filter by city and page through live SpareRoom listings.
- Track average room prices across multiple UK cities by aggregating the
pricefield fromsearch_listingsresponses. - Populate a city selector dropdown for a rental app using the
nameandurlfields fromget_top_cities. - Monitor listing volume in a specific area over time by recording the
total_countfrom repeatedsearch_listingscalls. - Generate city-by-city flatshare inventory reports by querying
search_listingsfor each city returned byget_top_cities. - Feed listing images and links into a property aggregator using the
image_urlandlinkfields from the listings array.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does SpareRoom have an official developer API?+
What does the `search_listings` endpoint return beyond basic listing info?+
title, price, location, image_url, and link. The response also includes city, page, and total_count so you can paginate. Detailed room descriptions, availability dates, house rules, and advertiser contact details are not included in the search results.Does the API cover individual listing detail pages — descriptions, availability, or landlord preferences?+
How does pagination work with `search_listings`?+
page parameter to retrieve subsequent pages. Each page returns up to 100 listings. The total_count field in the response tells you the total number of matching listings, which you can use to calculate how many pages are available for a given city.Does the API cover flatshares outside the UK, such as Ireland or the US?+
get_top_cities endpoint also returns UK cities only. You can fork this API on Parse and revise it to target other regional flatshare platforms if you need non-UK coverage.