# Idealista Scraper — Italian Homes for Sale & Rent, Cheap (`fabrikit/idealista-scraper`) Actor

Idealista Scraper: search idealista.it by city, price, size, rooms, features and listing age, for sale or rent. Prices, addresses, agency, full details. Spain and Portugal via pasted URLs. No login. From US$0.60 per 1,000 listings.

- **URL**: https://apify.com/fabrikit/idealista-scraper.md
- **Developed by:** [Fabrikit](https://apify.com/fabrikit) (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.60 / 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.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Idealista Scraper — Italian Homes for Sale & Rent

Collect property listings from **idealista.it** without a browser and without a login. Search one or many Italian cities, for sale or rent, and filter by price, area, number of rooms, features (terrace, garden, balcony, pool, garage, top floor, to be renovated) and how recently the listing was published. You get one clean row per listing: title, address, zone, price, price per m², area, rooms, floor, elevator, agency, photos and more. Turn on **full details** to add the complete description, all feature lists, bathrooms, condition, energy class, building fees, reference code and every photo URL.

Spain (idealista.com) and Portugal (idealista.pt) are supported **best-effort through pasted search URLs** (they are protected much harder and need the residential proxy).

Typical uses: price tracking, investment screening, rental market research, lead lists of Italian real-estate agencies, and feeding listings into your own app.

### What you get

| Field | Example |
| --- | --- |
| `id`, `url`, `country`, `operation` | `35960897`, listing link, `it`, `sale` / `rent` |
| `propertyType`, `title`, `street`, `zone`, `city` | `Appartamento`, `Gallaratese`, `Milano` |
| `price`, `pricePeriod`, `oldPrice`, `priceDropPercent`, `pricePerM2` | `625000`, `null` (sale) or `month`, `645000`, `3` |
| `areaM2`, `rooms`, `floor`, `hasElevator` | `141`, `5`, `6º piano con ascensore`, `true` |
| `agencyName`, `agencyUrl`, `isProfessional`, `isFeatured` | professional advertisers only |
| `imageUrl`, `imageCount`, `hasVirtualTour`, `hasFloorPlan` | media flags |
| With details: `description`, `features`, `bathrooms`, `condition`, `energyClass`, `heating`, `builtYear`, `communityFeesMonthly`, `referenceCode`, `updatedText`, `photos` | full listing page |

Agencies (businesses) are included. Names and phone numbers of private advertisers are **not** collected.

### Input

```json
{
  "operation": "rent",
  "propertyCategory": "homes",
  "locations": ["Milano", "Torino"],
  "priceMax": 1500,
  "areaMin": 50,
  "rooms": ["2", "3"],
  "features": ["balcony"],
  "publishedWithin": "week",
  "sortBy": "newest",
  "includeDetails": false,
  "maxItems": 200
}
```

- **locations**: Italian city names (`Milano`, `Roma`). For small towns use `Town, Province` (`Sesto San Giovanni, Milano`), a province as `Provincia di Milano`, or the slug from an idealista URL.
- **propertyCategory**: homes, rooms (rent), garages, land (sale), offices, shops.
- **startUrls**: paste idealista search or listing URLs (Italy, Spain, Portugal). Your own filters in the URL are kept.
- **maxItems**: exact limit. One search reaches about 1,800 listings; bigger requests are split into price bands automatically (Italy) and de-duplicated.

### Pricing

Pay per event, no subscription:

| Event | Price |
| --- | --- |
| Listing scraped | US$0.60 per 1,000 |
| Listing details (add-on, only with "Include full listing details") | US$1.00 per 1,000 |

### FAQ

**Does it need a login or API key?** No.

**Does it work for Spain and Portugal?** Italy is the verified, supported market. For Spain and Portugal paste search URLs; those sites block most traffic, so use the default Apify proxy (it switches to residential IPs of that country automatically) and expect lower reliability.

**Why are some fields empty?** Fields marked "details only" are filled with `includeDetails`. Private advertisers have no agency.

**How do I get only new listings?** Sort by newest, set "Published within" and schedule the Actor.

**Is it legal?** It collects public listing data. You are responsible for using it in line with idealista's terms and data-protection rules (GDPR).

### En español

Scraper de **idealista.it** (Italia): compra y alquiler por ciudad, con filtros de precio, m², habitaciones, características y antigüedad del anuncio. Devuelve precio, precio por m², superficie, zona, agencia y fotos; con detalles completos añade descripción, características, baños, estado, clase energética y gastos de comunidad. España y Portugal funcionan con URLs pegadas (mejor esfuerzo, requieren proxy residencial). No recoge nombres ni teléfonos de particulares. Precio: US$0,60 por 1.000 anuncios (+ US$1,00 por 1.000 detalles).

# Actor input Schema

## `operation` (type: `string`):

Properties for sale (vendita) or for rent (affitto).

## `propertyCategory` (type: `string`):

What to search for. Rooms are only available for rent, land only for sale.

## `locations` (type: `array`):

City names, one search per entry (for example: Milano, Roma, Torino). For small towns use 'town, province' (for example: Sesto San Giovanni, Milano) or the slug from an idealista URL (sesto-san-giovanni-milano). Use 'Provincia di Milano' for a whole province.

## `priceMin` (type: `integer`):

Minimum sale price, or minimum monthly rent.

## `priceMax` (type: `integer`):

Maximum sale price, or maximum monthly rent.

## `areaMin` (type: `integer`):

Minimum area in square metres.

## `areaMax` (type: `integer`):

Maximum area in square metres.

## `rooms` (type: `array`):

Only properties with these numbers of rooms (5 means five or more). Leave empty for any.

## `features` (type: `array`):

Only properties with these features.

## `publishedWithin` (type: `string`):

Only listings published in this period.

## `sortBy` (type: `string`):

Order of the results.

## `startUrls` (type: `array`):

Paste idealista search result pages (Italy, Spain or Portugal) or single listing pages. Spain and Portugal need the residential proxy and are best-effort.

## `includeDetails` (type: `boolean`):

Open every listing to add the full description, all features, bathrooms, condition, energy class, building fees, reference and all photos. Billed as a separate add-on event and slower.

## `maxItems` (type: `integer`):

Maximum number of listings to save. One search reaches about 1,800 listings; larger requests are split into price bands automatically (Italy).

## `proxyConfiguration` (type: `object`):

Apify Proxy is recommended. The Actor starts with datacenter IPs and switches to residential IPs of the right country automatically if it gets blocked.

## Actor input object example

```json
{
  "operation": "sale",
  "propertyCategory": "homes",
  "locations": [
    "Milano"
  ],
  "sortBy": "newest",
  "includeDetails": false,
  "maxItems": 50,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

All listings collected during the run

# 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 = {
    "locations": [
        "Milano"
    ],
    "maxItems": 50,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("fabrikit/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 = {
    "locations": ["Milano"],
    "maxItems": 50,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("fabrikit/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 '{
  "locations": [
    "Milano"
  ],
  "maxItems": 50,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call fabrikit/idealista-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fabrikit/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/sOv4oeJxFcLr6qnGy/builds/FQ91RMeBZxZk7mYVz/openapi.json
