# Idealista Scraper — Spain, Portugal & Italy listings (`amitaviv/idealista-scraper`) Actor

Scrape idealista.com, idealista.pt and idealista.it from any search URL: price, m², rooms, floor, agency, photos, full details and energy class. Anti-bot handled. Pay per listing.

- **URL**: https://apify.com/amitaviv/idealista-scraper.md
- **Developed by:** [Amit Aviv](https://apify.com/amitaviv) (community)
- **Categories:** Real estate, Lead generation, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.40 / 1,000 listing scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Idealista Scraper — Spain, Portugal and Italy listings from any search URL

Extract property listings from **idealista.com** (Spain), **idealista.pt** (Portugal) and **idealista.it** (Italy) — the largest real-estate portals in all three countries — from any search URL you paste in. Sale and rent, flats, houses, rooms, offices, garages, land, new developments; every filter and sort order idealista offers. Also scrapes individual property pages.

No proxy configuration, no cookies, no login. Anti-bot handling is built in. Pay only for the listings you get.

### What you get

One clean JSON record per property:

- **Core**: id, url, title, price (EUR), price per m², previous price and price-drop percentage when the price was lowered, site and country
- **Property**: rooms, size in m², floor (number and original text), elevator, exterior/interior, parking included, listing tags (luxury, exclusive, renovated, new development...)
- **Advertiser**: private or professional, agency name and agency page URL
- **Media**: main image, all listing images, image count, whether the listing has a floor plan, 3D tour or video
- **Search context**: the search URL and result page the listing came from, scrape timestamp

Turn on **Fetch full property details** and every record additionally gets:

- Full description text
- Location (neighbourhood, city), typology and operation (sale / rent)
- Bathrooms, year built, condition, orientation, heating, equipment — every feature idealista lists, grouped under idealista's own headings (`features`) and as a flat list (`featureList`)
- Energy certificate class (A+ … G), consumption and emissions
- Advertiser name, advertiser page, listing reference, last-update text
- All full-size photos (`images`) and floor plans (`floorPlans`) separately, with photo labels (living room, kitchen, terrace...)

### How to use it

1. Go to idealista.com, idealista.pt or idealista.it and search with any filters you want — operation, type, location, price, size, rooms, features, sort order.
2. Copy the URL of the results page, for example:
   - `https://www.idealista.com/venta-viviendas/madrid-madrid/con-precio-hasta_300000,de-dos-dormitorios/`
   - `https://www.idealista.pt/arrendar-casas/lisboa/com-preco-max_1500/`
   - `https://www.idealista.it/vendita-case/milano-milano/con-prezzo_400000/`
3. Paste one or more URLs into **Idealista search URLs**, set **Max listings per search URL**, and run.

To scrape specific properties, paste their URLs (`https://www.idealista.com/inmueble/112367425/`, `https://www.idealista.pt/imovel/35081413/`, `https://www.idealista.it/immobile/35555810/`) into **Individual property URLs**. These always return full details.

Idealista shows at most 60 result pages (1,800 listings) per search. To collect a large area completely, split it into several searches (by district, price band or property type) and pass all the URLs in one run — duplicates are removed automatically.

### Example output

```json
{
  "id": 112367425,
  "url": "https://www.idealista.com/inmueble/112367425/",
  "title": "Piso en Calle de Pelayo, Chueca-Justicia, Madrid",
  "price": 1200000,
  "priceText": "1.200.000€",
  "currency": "EUR",
  "pricePerM2": 10000,
  "previousPrice": null,
  "priceDropPercent": null,
  "rooms": 2,
  "sizeM2": 120,
  "floorText": "3ª planta exterior con ascensor",
  "floor": 3,
  "hasElevator": true,
  "isExterior": true,
  "parkingIncluded": false,
  "tags": ["Lujo"],
  "isProfessional": true,
  "agencyName": "Gilmar Centro",
  "agencyUrl": "https://www.idealista.com/pro/gilmar-centro/",
  "isFeatured": true,
  "hasFloorPlan": true,
  "has3DTour": false,
  "hasVideo": false,
  "imageCount": 32,
  "imageUrl": "https://img4.idealista.com/blur/WEB_DETAIL/0/id.pro.es.image.master/95/1c/93/1470614327.jpg",
  "images": ["..."],
  "location": "Chueca-Justicia, Madrid",
  "typology": "home",
  "operation": "sale",
  "bathrooms": 2,
  "builtYear": 1900,
  "energyClass": "C",
  "energyConsumption": "Consumo: 78 kWh/m² año",
  "energyEmissions": "Emisiones: 20 kg CO2/m² año",
  "description": "GILMAR Consulting Inmobiliario pone a su disposición, ubicado en el emblemático barrio de Justicia...",
  "features": {
    "Características básicas": ["120 m² construidos", "2 habitaciones", "2 baños", "Balcón", "Segunda mano/buen estado", "Armarios empotrados", "Orientación sur, este", "Construido en 1900", "Calefacción individual"],
    "Edificio": ["3ª planta exterior", "Con ascensor"],
    "Equipamiento": ["Aire acondicionado"],
    "Certificado energético": ["Consumo: 78 kWh/m² año", "Emisiones: 20 kg CO2/m² año"]
  },
  "reference": "AG223210",
  "advertiserName": "Gilmar Centro",
  "advertiserType": "professional",
  "updatedText": "Anuncio actualizado el 5 de septiembre",
  "floorPlans": ["https://img4.idealista.com/blur/WEB_DETAIL/0/id.pro.es.image.master/41/09/ba/1470991594.jpg"],
  "site": "idealista.com",
  "country": "ES",
  "searchUrl": "https://www.idealista.com/venta-viviendas/madrid-madrid/",
  "page": 1,
  "scrapedAt": "2026-09-05T17:24:01.789Z"
}
```

Download the dataset as JSON, CSV, Excel or XML from the run's **Output** tab, or through the API.

### Pricing

Pay per event, no subscription:

- **Listing** — one property returned from a search (all fields from the results page).
- **Detail** — extra event per property when *Fetch full property details* is on, or when you pass individual property URLs.

Nothing is charged for pages that fail, and duplicates within a run are never charged twice. Platform usage (compute, proxy) is included in the price.

### Use cases

- **Market analysis**: price per m² by district, price drops, time on market, new-development pipeline.
- **Lead generation**: agencies and private advertisers by area, with their listing portfolio.
- **Deal alerts**: run on a schedule with a filtered search URL and push new listings to Slack, email, Google Sheets or your CRM via Apify integrations.
- **Data products**: feed valuation models, rental-yield dashboards or investment screeners.

### Limitations

- Phone numbers are not extracted (idealista reveals them only after a click that requires a logged-in user).
- Exact GPS coordinates are shown by idealista only on the map, not in the listing page; the `location` field gives neighbourhood and city.
- A search returns at most 1,800 listings (60 pages). Split large searches with filters.

### API example

```bash
curl -X POST "https://api.apify.com/v2/acts/amitaviv~idealista-scraper/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"searchUrls": ["https://www.idealista.com/venta-viviendas/madrid-madrid/"], "maxItemsPerSearch": 60, "fetchDetails": true}'
```

Node.js, Python and other clients are available in the **API** tab of the actor.

### Issues and requests

If idealista changes its layout or you need extra fields, open an issue on the **Issues** tab. Bugs are usually fixed within a day.

# Actor input Schema

## `searchUrls` (type: `array`):

Paste one or more idealista search result URLs from idealista.com (Spain), idealista.pt (Portugal) or idealista.it (Italy), with any filters and sort order. Examples: https://www.idealista.com/venta-viviendas/madrid-madrid/con-precio-hasta\_300000/ or https://www.idealista.pt/arrendar-casas/lisboa/

## `maxItemsPerSearch` (type: `integer`):

Stop after this many listings for each search URL (30 per page). Idealista shows at most 60 pages (1,800 listings) per search; narrow the search with filters to get everything.

## `fetchDetails` (type: `boolean`):

Also open every property page to get the full description, all features (bathrooms, year built, heating, orientation, condition...), energy certificate, reference, advertiser and all photos. Charged as an extra 'detail' event per listing.

## `propertyUrls` (type: `array`):

Scrape specific properties by URL, e.g. https://www.idealista.com/inmueble/112367425/ — always returns full details.

## `debug` (type: `boolean`):

Save blocked pages to the key-value store for troubleshooting.

## Actor input object example

```json
{
  "searchUrls": [
    "https://www.idealista.com/venta-viviendas/madrid-madrid/"
  ],
  "maxItemsPerSearch": 60,
  "fetchDetails": false,
  "propertyUrls": [],
  "debug": false
}
```

# Actor output Schema

## `listings` (type: `string`):

All scraped listings as JSON, one object per property.

## `listingsCsv` (type: `string`):

All scraped listings as a CSV file.

## `listingsExcel` (type: `string`):

All scraped listings as an Excel file.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchUrls": [
        "https://www.idealista.com/venta-viviendas/madrid-madrid/"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("amitaviv/idealista-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "searchUrls": ["https://www.idealista.com/venta-viviendas/madrid-madrid/"] }

# Run the Actor and wait for it to finish
run = client.actor("amitaviv/idealista-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchUrls": [
    "https://www.idealista.com/venta-viviendas/madrid-madrid/"
  ]
}' |
apify call amitaviv/idealista-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,amitaviv/idealista-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/4NMdTz9AzCJMOVwlH/builds/oWUyV0QbE829797QE/openapi.json
