# OLX Indonesia Listings Scraper (`fauzimatakupan/olx-indonesia-listings-scraper`) Actor

Scrape classified listings from OLX Indonesia (olx.co.id): search and item details with price (IDR), description, condition, location, seller info (masked per UU PDP), and listing dates. Indonesia's top classified-ads marketplace; a real browser passes the Akamai interstitial automatically.

- **URL**: https://apify.com/fauzimatakupan/olx-indonesia-listings-scraper.md
- **Developed by:** [Fauzi Matakupan](https://apify.com/fauzimatakupan) (community)
- **Categories:** E-commerce
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 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

## OLX Indonesia Listings Scraper

Extracts classified listings from [OLX Indonesia](https://www.olx.co.id) — Indonesia's biggest
online classified-ads marketplace — search results and item details with prices in IDR, full
descriptions, condition, location (city, district, coordinates), seller info, and listing dates.
Works for Indonesian e-commerce data collection: product listings, seller activity, and
marketplace monitoring across all olx.co.id categories (mobil bekas, handphone, properti,
elektronik, and more).

The Actor runs a real browser that transparently solves OLX's Akamai interstitial
challenge and captures the JSON OLX's own frontend fetches. No login required.

**Tested in the wild:** one run recovered **52/52 listings (100%)** from a keyword search
with **0 failed requests** (Cloud Runner, residential proxy, Oct 2026).

### Pricing

Pay per event — you only pay for listings actually returned. Platform usage is included.

| Listings | Cost |
|---|---|
| 100 | ~$0.20 |
| 1,000 | $2.00 |
| 10,000 | $20.00 |

Failed pages and empty runs cost almost nothing (a tiny $0.00005 start fee).

### Example task

Try it without configuring anything: [Mechanical Keyboard Search](https://apify.com/fauzimatakupan/mechanical-keyboard-search)
— a pre-configured run against a live OLX search. Open it, press *Start*, and inspect the
output before writing your own input.

### Features

- **Search listings** — point it at any OLX search or category URL
  (`/items/q-mechanical-keyboard`, `/mobil-bekas_c198`, ...) and collect every listing
  with title, price (IDR), condition, city/district, coordinates, seller info, and dates.
- **Pagination** — walks search result pages automatically (`?page=N`) up to
  `maxListingsPerSearch` / `maxSearchPages`.
- **Item details** (optional) — enable *Scrape Item Details* to visit each found ad and
  capture its full description.
- **UU PDP compliant** — seller names are masked (`In***`) before any record is stored;
  no phone numbers or contact details are collected.
- **Anti-bot resilient** — real-browser Akamai handling, adaptive delays, block-page
  detection with automatic retries.
- **Budget-aware** — respects your per-run spending limit: the run stops gracefully
  instead of burning compute once the limit is reached.

### Use with AI agents (MCP)

Expose this Actor as a tool to Claude, Cursor, Codex, or any MCP client:

```
https://mcp.apify.com/?tools=fauzimatakupan/olx-indonesia-listings-scraper
```

The Actor is also discoverable through the official Apify MCP server — AI agents can
search Apify Store and run it automatically. Keywords: OLX Indonesia scraper, olx.co.id
listings, Indonesian classified ads, marketplace Indonesia, e-commerce Indonesia data.

### Example input

```json
{
    "startUrls": [{ "url": "https://www.olx.co.id/items/q-mechanical-keyboard" }],
    "maxListingsPerSearch": 200,
    "maxSearchPages": 10,
    "scrapeListings": true,
    "scrapeDetails": false
}
```

### Example output

```json
{
    "_type": "listing",
    "source": "search",
    "adId": "921246980",
    "name": "Feker ik75 v3 gasket mount keyboard mechanical original",
    "price": 1300000,
    "priceDisplay": "Rp 1.300.000",
    "condition": "Bekas",
    "region": "Jakarta D.K.I.",
    "city": "Jakarta Selatan",
    "district": "Kemang",
    "lat": -6.253,
    "lon": 106.815,
    "sellerId": "235045",
    "sellerName": "In***",
    "createdAtFirst": "2024-06-01T02:27:05.000Z",
    "url": "https://www.olx.co.id/item/feker-ik75-v3-gasket-mount-keyboard-mechanical-original-iid-921246980"
}
```

### Output fields

Each dataset item is one listing (`_type: "listing"`):

| Field | Description |
|---|---|
| `adId` | OLX ad id (`iid`) |
| `name`, `adDescription` | Listing title; full description on detail records |
| `price`, `priceDisplay` | Integer IDR and the displayed string |
| `condition`, `itemType` | Parameter values (e.g. *Bekas*) |
| `region`, `city`, `district` | Resolved location hierarchy |
| `lat`, `lon` | Listing coordinates |
| `sellerId`, `sellerName`, `sellerType`, `sellerKyc` | Seller info, name masked |
| `createdAt`, `createdAtFirst`, `republishedAt`, `validTo` | Listing dates (ISO 8601) |
| `imageUrl`, `imageCount`, `favorites`, `isNew`, `status` | Metadata |
| `source`, `query`, `url` | Provenance |

### FAQ

**Do I need a proxy or an OLX account?** No account needed. On Apify platform runs the
Actor automatically routes through Apify residential proxies (required — OLX/Akamai
tar-pits datacenter IPs). Local runs from clean IPs can disable proxying with
*Use Proxy = off*.

**Which URLs work?** Keyword searches (`/items/q-<keyword>`), categories
(`/mobil-bekas_c198`, `/handphone_g2000007/komputer-laptop_c213`, ...), and single item
pages (`/item/...-iid-<id>`).

**How long does a run take?** Roughly 4–6 minutes for up to ~200 listings across all
result pages of one search, at the default polite delays.

**Why are seller names masked?** Indonesian data-protection law (UU PDP). The Actor
stores seller IDs for deduplication but never names, phones, or contact details.

### Usage notes

- Keep `minDelayMs`/`maxDelayMs` at sane values (defaults 1500–4000 ms) to avoid soft
  rate-limits ("Ada yang tidak beres"). If you hit one anyway, the run retries with
  backoff and reports the block in the log.
- Respect OLX's terms of service and Indonesian data-protection law (UU PDP). This
  Actor intentionally masks seller identities and excludes contact information.

# Actor input Schema

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

OLX Indonesia URLs: search/listing pages (olx.co.id/items/..., e.g. /items/q-mechanical-keyboard or a category like /mobil-bekas_c198) or single item pages (olx.co.id/item/...-iid-<id>).

## `maxListingsPerSearch` (type: `integer`):

Upper bound of listings collected per search URL (across all its result pages).

## `maxSearchPages` (type: `integer`):

How many search result pages to paginate through per search URL.

## `scrapeListings` (type: `boolean`):

Capture listings (title, price, location, seller, dates) from search result pages.

## `scrapeDetails` (type: `boolean`):

Also visit item pages found in search results to capture full descriptions and details. Slower and more requests.

## `maxDetailPages` (type: `integer`):

Upper bound of item detail pages visited when Scrape Item Details is enabled.

## `maxRequestsPerCrawl` (type: `integer`):

Maximum number of page navigations this run may perform.

## `useProxy` (type: `boolean`):

Route traffic through Apify proxies. Disable for cheap runs — OLX may accept clean datacenter IPs; if runs fail with navigation errors, re-enable.

## `minDelayMs` (type: `integer`):

Minimum random delay between page visits, in milliseconds.

## `maxDelayMs` (type: `integer`):

Maximum random delay between page visits, in milliseconds.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.olx.co.id/items/q-mechanical-keyboard"
    }
  ],
  "maxListingsPerSearch": 200,
  "maxSearchPages": 10,
  "scrapeListings": true,
  "scrapeDetails": false,
  "maxDetailPages": 50,
  "maxRequestsPerCrawl": 100,
  "useProxy": true,
  "minDelayMs": 1500,
  "maxDelayMs": 4000
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# 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 = {
    "startUrls": [
        {
            "url": "https://www.olx.co.id/items/q-mechanical-keyboard"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fauzimatakupan/olx-indonesia-listings-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 = { "startUrls": [{ "url": "https://www.olx.co.id/items/q-mechanical-keyboard" }] }

# Run the Actor and wait for it to finish
run = client.actor("fauzimatakupan/olx-indonesia-listings-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 '{
  "startUrls": [
    {
      "url": "https://www.olx.co.id/items/q-mechanical-keyboard"
    }
  ]
}' |
apify call fauzimatakupan/olx-indonesia-listings-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fauzimatakupan/olx-indonesia-listings-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/BN4xo35YPe8cLktpd/builds/bQ7CBZvFiXiK225ZY/openapi.json
