# Leboncoin Scraper (`lergassy/leboncoin-scraper`) Actor

Scrape Leboncoin.fr ads by keyword, city, department, category or any search URL: title, price as a number, postcode and coordinates, posting date, full description, attributes like surface or mileage, seller type and rating, photos. Export JSON/CSV, call the API, schedule new-ads feeds.

- **URL**: https://apify.com/lergassy/leboncoin-scraper.md
- **Developed by:** [Matvey](https://apify.com/lergassy) (community)
- **Categories:** E-commerce, Real estate, Lead generation
- **Stats:** 5 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.69 / 1,000 ads

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?

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

### What is Leboncoin Scraper?

**Leboncoin Scraper** extracts ads from [leboncoin.fr](https://www.leboncoin.fr), France's largest classifieds site — cars, flats for rent and for sale, phones, furniture, bikes, jobs and everything else people sell in France. Type a keyword, pick a city, department or region, or paste any Leboncoin search URL, and get every ad as a clean row: **title, price as a number, category, city, postcode, department, region, GPS coordinates, posting date, full description, category attributes (surface, rooms, energy class, mileage, year, brand, condition…), all photos, seller type (particulier / pro), seller name and rating**.

No login, no browser, no cookies to copy. Results come straight from Leboncoin's own search data, so a search of 1,000 ads finishes in about 20 seconds. Export to JSON, CSV or Excel, call it from the API, or put it on a schedule and receive only new ads.

### What data can it extract?

| Field | Example |
|---|---|
| `title`, `url`, `id` | IPhone 15 Pro Max & iPhone 14 Pro Max · https://www.leboncoin.fr/ad/telephones_objets_connectes/3108012318 |
| `price`, `priceText`, `oldPrice`, `currency` | 460 · "460 €" · 650 · EUR |
| `category`, `categoryId` | Téléphones & Objets connectés · 17 |
| `location`, `city`, `zipcode` | Paris 75009 · Paris · 75009 |
| `department`, `departmentId`, `region`, `regionId` | Paris · 75 · Ile-de-France · 12 |
| `latitude`, `longitude` | 48.8711 · 2.33229 |
| `postedAt`, `updatedAt`, `expiresAt` | 2026-09-14T08:40:36.000Z (ISO, UTC) |
| `description` | Full ad text written by the seller |
| `attributes` | `{ "phone_model": "iPhone 15 Pro Max", "condition": "Très bon état" }`, for flats `square`, `rooms`, `energy_rate`…, for cars `brand`, `model`, `regdate`, `mileage`, `fuel`, `gearbox`… |
| `pricePerSquareMeter` | Price per m² on real estate for sale |
| `images`, `imageCount`, `thumbnail` | All photo links in large size |
| `sellerType`, `sellerName`, `sellerId`, `storeId`, `sellerSiren` | pro · DBC PARIS 17 BIS · Leboncoin user id · 48404386 · 922178488 |
| `sellerRating`, `sellerRatingCount` | 4.9 (out of 5) · 296 reviews |
| `hasPhone`, `shippingAvailable`, `shippingType` | true · false · face_to_face |
| `isUrgent`, `isBoosted`, `isFeatured` | Paid visibility options of the ad |
| `searchQuery`, `searchUrl`, `position`, `scrapedAt` | Where and when the row came from |

Fields an ad does not have are left out of its row (an ad without a price has no `price`), so there are no empty columns full of `null`.

### How much does it cost to scrape Leboncoin?

You pay only for ads delivered — **pay per event, no start fee, no monthly rent**:

| Apify plan | Price per ad | Ads per $1 |
|---|---|---|
| Free / Starter (Bronze) | $0.00104 | ~960 |
| Scale (Silver) | $0.0009 | ~1,110 |
| Business (Gold) and higher | $0.00069 | ~1,450 |

The description, attributes, seller and photos are **included** — there is no extra charge per ad page, seller profile or "detail" add-on. Notice rows (no results, unknown place, ad gone) are free. The Apify Free plan gives you $5 of credit every month — about 4,800 Leboncoin ads. Set **Max cost per run** and the Actor stops by itself, green, exactly at your budget.

### How to scrape Leboncoin

1. Click **Try for free** and open the Actor's input.
2. Type one or more **keywords** (`iphone 15`, `appartement t3`, `vélo électrique`) and a **location** (`Paris`, `69001`, `Gironde`, `Bretagne`) — or paste Leboncoin **search URLs** with all your filters already set on the site.
3. Optionally pick a **category**, a price range, private or pro sellers, and the sort order.
4. Set **Max ads per search** and click **Start**.
5. Download the dataset as JSON, CSV or Excel, or read it through the API.

### ⬇️ Input

```json
{
    "searchQueries": ["iphone 15"],
    "location": "Paris",
    "category": "telephones",
    "minPrice": 200,
    "maxPrice": 700,
    "sellerType": "private",
    "sortBy": "newest",
    "maxItems": 100
}
```

Or start from Leboncoin links — every filter set on the site (category, place and radius, price, surface, rooms, mileage, fuel, brand, sorting) is kept:

```json
{
    "startUrls": [
        { "url": "https://www.leboncoin.fr/recherche?category=10&locations=Lyon__45.76_4.83_5000_10000&real_estate_type=2&square=30-60&rooms=2-3" },
        { "url": "https://www.leboncoin.fr/c/voitures/u_car_brand:BMW" },
        { "url": "https://www.leboncoin.fr/ad/velos/3293417213" }
    ],
    "maxItems": 200
}
```

**Location** accepts a city (`Lyon`), a postcode (`69003`), a department number or name (`33`, `Gironde`), a region (`Bretagne`, `Auvergne-Rhône-Alpes`, `La Réunion`) or several places separated by commas (`Paris, Lyon`). With an empty input the Actor runs a short demo: 30 "iphone 15" ads in Paris.

### ⬆️ Output

A real row from a run on `"iphone 15"` in Paris (description and photo list shortened):

```json
{
  "type": "ad",
  "id": "3108012318",
  "url": "https://www.leboncoin.fr/ad/telephones_objets_connectes/3108012318",
  "title": "IPhone 15 Pro Max & iPhone 14 Pro Max / OFFRE 2026 🥳",
  "price": 460,
  "priceText": "460 €",
  "currency": "EUR",
  "oldPrice": 650,
  "category": "Téléphones & Objets connectés",
  "categoryId": "17",
  "adType": "offer",
  "status": "active",
  "location": "Paris 75009",
  "city": "Paris",
  "zipcode": "75009",
  "department": "Paris",
  "departmentId": "75",
  "region": "Ile-de-France",
  "regionId": "12",
  "latitude": 48.8711,
  "longitude": 2.33229,
  "postedAt": "2026-09-14T08:40:36.000Z",
  "updatedAt": "2026-10-22T19:11:06.000Z",
  "expiresAt": "2026-11-13T08:40:36.000Z",
  "description": "Je vends mon iPhone 15 Pro Max & iPhone 14 Pro Max séparément en bon état, toujours protégés.…",
  "attributes": {
    "condition": "Très bon état",
    "phone_product": "Smartphone",
    "phone_brand": "Apple",
    "phone_model": "iPhone 15 Pro Max",
    "phone_color": "Autre",
    "phone_memory": "256 Go"
  },
  "images": [
    "https://img.leboncoin.fr/api/v1/lbcpb1/images/a8/e8/9b/a8e89b5bfe66af65c3611a662221863640cc3ace.jpg?rule=ad-large"
  ],
  "imageCount": 4,
  "sellerType": "pro",
  "sellerName": "DBC PARIS 17 BIS",
  "storeId": "48404386",
  "sellerSiren": "922178488",
  "hasPhone": true,
  "shippingAvailable": false,
  "shippingType": "face_to_face",
  "isBoosted": true,
  "searchQuery": "iphone 15",
  "position": 4,
  "scrapedAt": "2026-10-23T00:08:30.177Z"
}
```

### Use cases

#### Resellers and e-commerce

Track prices of phones, consoles, furniture or bikes across France, spot under-priced ads and follow how fast items sell. `price`, `oldPrice` and `condition` make price comparison a one-line filter.

#### Real estate agents and investors

Pull every flat or house for rent or sale in a city, department or radius, with surface, rooms, energy class (DPE), charges, price per m² and pro / private seller — the raw material for a "pige immobilière", market studies and rental yield maps.

#### Car dealers

Monitor used cars by brand, model, year, mileage and fuel; find private sellers (`sellerType: private`) in your area and react to new ads within the hour.

#### Lead generation

List professional sellers (`sellerType: pro`, `sellerName`, `sellerSiren`, `storeId`) active in a category and region.

#### Data analysts and researchers

Build datasets of second-hand prices, regional supply and demand, or category trends with clean numbers and ISO dates.

#### AI agents and automations

One call with a keyword and a place returns structured JSON an LLM can read directly — ideal for agents that answer "what does a used iPhone 15 cost in Lyon?" or watch the market on a schedule.

### Integrations

- **API** — start runs and read results over REST: `POST https://api.apify.com/v2/acts/lergassy~leboncoin-scraper/run-sync-get-dataset-items?token=YOUR_TOKEN` with the input as JSON body.
- **Python / JavaScript** — the `apify-client` packages run the Actor and fetch the dataset in a few lines.
- **n8n, Make, Zapier, Google Sheets** — use the Apify app / node to send new ads to a sheet, Slack, e-mail or your CRM.
- **MCP** — AI assistants (Claude, ChatGPT, Cursor) can call the Actor as a tool through the Apify MCP server.
- **Schedules** — run every hour with **Only new ads** set, and pay only for ads you have not received yet.

### Migrating from another Leboncoin scraper?

| Other scrapers' input | This Actor |
|---|---|
| `searchQuery`, `text`, `keyword` | `searchQueries` (a list — several keywords in one run) |
| `searchUrl`, `startUrls` | `startUrls` (search, `/c/` category and `/ad/` links) |
| `adDetailUrls`, `adIds` | `startUrls` with ad links |
| `location`, `locations` | `location` (city, postcode, department, region, comma-separated) |
| `category`, `category_id` | `category` (list) or `categoryId` (any number) |
| `price_min_filter` / `price_max_filter` | `minPrice` / `maxPrice` |
| `seller_type`, `ownerType` | `sellerType` (`all`, `private`, `pro`) |
| `search_in_title_only` | `titleOnly` |
| `adLimit`, `limit`, `maxItems` | `maxItems` (per search) |
| `mode: monitor` | `onlyNewRowsStore` + an Apify schedule |

### Troubleshooting

- **"Leboncoin has no ads for …"** — the search really matched nothing. Try a broader keyword, fewer filters, or check the spelling of the place; a postcode such as `69001` always works.
- **"Leboncoin does not know the place …"** — the city name was not recognised, so the Actor wrote nothing rather than ads from all of France. Use a postcode, department or region.
- **Fewer ads than Max ads** — Leboncoin serves at most 3,500 ads per search (tested: the 3,501st is never returned). Split a big search by department, category or price range.
- **Keyword ads from another category** — Leboncoin also searches descriptions. Turn on **Search in titles only** or pick a **Category**.
- **Sorting looks slightly off** — "Newest first" follows the date an ad was last republished, exactly like the site.

### ❓ FAQ

#### Is it legal to scrape Leboncoin?

The Actor reads only public ads that anyone can see on leboncoin.fr without an account. It does not log in and does not collect phone numbers. Ads can contain personal data (seller names), so if you store or process them, the GDPR applies: have a legitimate purpose, keep only what you need, and do not use the data for unsolicited marketing. When in doubt, ask a lawyer.

#### Do I need a Leboncoin account or cookies?

No. The Actor needs no login, no cookies and no proxy setup.

#### Does it get the full description and all photos?

Yes — every row has the full description, all attributes and all photo links, at no extra cost.

#### Can it get the seller's phone number?

No. Phone numbers are shown only to logged-in users; the Actor tells you whether the ad has one (`hasPhone`).

#### Can I get only new ads every day?

Yes. Give **Only new ads — memory name** any name, schedule the Actor, and each run writes and charges only ads that the earlier runs did not deliver.

#### Which categories work?

All of them: real estate (ventes immobilières, locations, colocations, locations saisonnières), vehicles, electronics, home, fashion, leisure, jobs, services. Pick the most common in **Category** or any other by **Category id**.

### Your feedback

Something missing, a field you need, or a search that does not work as on the site? Open an issue on the Actor's **Issues** tab — we read every one and usually fix within days.

### You might also like

| Actor | What it does |
|---|---|
| [Kleinanzeigen Scraper](https://apify.com/lergassy/kleinanzeigen-scraper) | The same for Kleinanzeigen.de, Germany's biggest classifieds site |
| [Craigslist Scraper](https://apify.com/lergassy/craigslist-scraper) | Listings from Craigslist in the US and worldwide |
| [ImmoScout24 Scraper](https://apify.com/lergassy/immoscout24-scraper) | Flats and houses for rent and sale from ImmoScout24 |

# Actor input Schema

## `searchQueries` (type: `array`):

Give this or <code>startUrls</code>. One or more keywords, searched one after another on Leboncoin — the same words you would type into the search box, e.g. <code>iphone 15</code>, <code>vélo électrique</code>, <code>appartement t3</code>. Combine with <b>Location</b>, <b>Category</b>, price and seller filters below.

## `titleOnly` (type: `boolean`):

On: keywords must appear in the ad title (Leboncoin's “Rechercher dans le titre uniquement”). Off (default): titles and descriptions are searched, which finds more ads but also some that only mention the word.

## `location` (type: `string`):

Where to search: a city (<code>Lyon</code>), a postcode (<code>69001</code>), a department number or name (<code>33</code>, <code>Gironde</code>) or a region (<code>Bretagne</code>, <code>Île-de-France</code>). Several places separated by commas are searched together, e.g. <code>Paris, Lyon</code>. Leave empty for all of France. Used with keywords or a category.

## `category` (type: `string`):

Limit keyword searches to one Leboncoin category. Works alone too: a category + a location lists everything in it (e.g. all rentals in Lyon). For any other category use <b>Category id</b> in the advanced section.

## `minPrice` (type: `integer`):

Only ads priced at least this many euros. Applied by Leboncoin itself and checked again on every row; ads without a price are left out when a price filter is set.

## `maxPrice` (type: `integer`):

Only ads priced at most this many euros. Applied by Leboncoin itself and checked again on every row.

## `sellerType` (type: `string`):

<b>Private</b> = private individuals only (particuliers), <b>Pro</b> = dealers, agencies and shops only (professionnels), <b>All</b> = both.

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

Order of keyword and category searches. <b>Most relevant</b> (default) is what the site shows first; <b>Newest first</b> suits monitoring new ads. Start URLs keep the sorting chosen on the site.

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

Maximum ads to return for each keyword or start URL. Leboncoin itself serves at most 3,500 ads per search — split bigger searches by department, category or price range to get more.

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

Give this or <code>searchQueries</code>. Search or category links copied from leboncoin.fr — every filter you set on the site (category, place, price, surface, mileage, sorting…) is kept, e.g. <code>https://www.leboncoin.fr/recherche?category=10\&locations=Lyon</code>. Ad links (<code>/ad/…/123456789</code>) return that one ad.

## `onlyNewRowsStore` (type: `string`):

Give this run a name — <code>my-lyon-flats</code> — and the Actor remembers every ad it delivered under that name. Every later run with the same name writes and charges <b>only ads you have not received before</b>. Schedule the Actor (e.g. hourly) to get a feed of new ads. Leave empty to get everything found, every time.

## `categoryId` (type: `string`):

Any Leboncoin category by its number, taken from a search URL (<code>…\&category=41</code> → <code>41</code>, Jeux & Jouets). Overrides <b>Category</b>. Examples: 28 Animaux, 41 Jeux & Jouets, 40 Collection, 57 Matériel agricole, 11 Colocations.

## `maxConcurrency` (type: `integer`):

How many result pages are loaded at the same time. The default is fast and polite; lower it if you see errors.

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

Leave empty: the Actor picks French residential addresses by itself (Leboncoin refuses datacenter addresses). Set a proxy here only if you must use your own — it is then used as given.

## Actor input object example

```json
{
  "searchQueries": [
    "iphone 15"
  ],
  "titleOnly": false,
  "location": "Paris",
  "category": "all",
  "sellerType": "all",
  "sortBy": "relevance",
  "maxItems": 30,
  "maxConcurrency": 4
}
```

# Actor output Schema

## `ads` (type: `string`):

One row per Leboncoin ad: title, price, category, city, postcode, department, region, coordinates, posting date, description, attributes, photos, seller type, name and rating. Free notice rows explain empty searches.

## `runStats` (type: `string`):

JSON counters for the run: searches, API pages, ads delivered, duplicates and filtered ads skipped, and which connection route served the requests.

# 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 = {
    "searchQueries": [
        "iphone 15"
    ],
    "location": "Paris",
    "maxItems": 30
};

// Run the Actor and wait for it to finish
const run = await client.actor("lergassy/leboncoin-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 = {
    "searchQueries": ["iphone 15"],
    "location": "Paris",
    "maxItems": 30,
}

# Run the Actor and wait for it to finish
run = client.actor("lergassy/leboncoin-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 '{
  "searchQueries": [
    "iphone 15"
  ],
  "location": "Paris",
  "maxItems": 30
}' |
apify call lergassy/leboncoin-scraper --silent --output-dataset

```

## MCP server setup

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