# Zameen Real Estate Scraper (`crawlerbros/zameen-real-estate-scraper`) Actor

Scrape Pakistani real estate listings from zameen.com - houses, plots, and commercial property for sale or rent. Filter by city, price, bedrooms, and area, or fetch full property details by URL.

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

## Pricing

from $3.00 / 1,000 results

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

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#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

## Zameen Real Estate Scraper

Scrape Pakistani real estate listings from [zameen.com](https://www.zameen.com) — houses, plots, and commercial property, for sale or for rent, across every major Pakistani city. No login, no cookies, no proxy required.

### What this actor does

- **Two modes:** `search` (browse listings by city + listing type + filters) and `byUrl` (fetch full detail records for specific property pages)
- **29 curated cities** (Lahore, Karachi, Islamabad, Rawalpindi, Faisalabad, and 24 more) plus a free-text `customLocationSlug` override for any neighborhood/city zameen.com covers
- **6 listing types:** houses/plots/commercial × for-sale/for-rent
- **Filters:** price range (PKR), bedroom range, bathroom range, area range (Marla / Kanal / sq ft / sq m), verified-only, free-text keyword
- **Rich detail mode:** description, amenities, furnishing/occupancy/ownership status, all photos, videos, agency contact
- **Empty fields are omitted** — every record only contains what was actually found

### Output per listing (search mode)

- `propertyId`, `title`, `titleUrdu` (zameen.com's Urdu-language listing title), `purpose` (for-sale / for-rent), `category`
- `price`, `priceCurrency` (PKR), `rentFrequency` (rentals only)
- `areaSqm`, `areaMarla`, `bedrooms`, `bathrooms`
- `city`, `neighborhood`, `locationHierarchy[]`, `latitude`, `longitude`, `hasExactGeography` (true if the pin is an exact address match, false if it's an area-centroid estimate)
- `coverPhotoUrl`, `photoCount`, `videoCount`, `coverVideoUrl` (YouTube link, when the listing has a video tour)
- `agencyName`, `agencyTier`, `agencyProduct`
- `contactName`, `contactPhone`, `contactWhatsapp`
- `isVerified`, `productTier`, `state` (listing lifecycle state, e.g. `live`), `listedAt`, `updatedAt`
- `installmentPlan` (`{remainingInstallments, advanceAmount, monthlyAmount}`) — only present on listings actually sold on a payment/installment plan (common for new-project and commercial listings)
- `shortDescription`, `shortDescriptionUrdu` (zameen.com's own `l1`-locale description field — most sellers write their listing description in English regardless of locale, so this frequently contains the same English text as `shortDescription` rather than an Urdu translation; `titleUrdu` is reliably Urdu since it's algorithmically generated by zameen.com), `sourceUrl`
- `recordType: "listing"`, `scrapedAt`

### Output per property (byUrl mode)

All of the above (where applicable) plus:

- `description` — full listing description
- `furnishingStatus`, `completionStatus`, `occupancyStatus`, `ownershipStatus`
- `photoUrls[]` (up to 20), `videoUrls[]`
- `amenities[]` — flattened feature list (e.g. `"Main Features: Parking Spaces = 1"`)
- `hierarchyPath`, `referenceNumber`
- `recordType: "propertyDetail"`

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | string | `search` | `search` / `byUrl` |
| `city` | string | `Lahore` | Curated city (mode=search) |
| `customLocationSlug` | string | – | Override `city` with any zameen.com location slug |
| `listingType` | string | `housesForSale` | `housesForSale` / `plotsForSale` / `commercialForSale` / `housesForRent` / `plotsForRent` / `commercialForRent` |
| `propertyUrls` | array | – | zameen.com property URLs (mode=byUrl) |
| `minPrice` / `maxPrice` | int | – | PKR price bounds |
| `minBedrooms` / `maxBedrooms` | int | – | Bedroom bounds |
| `minBathrooms` / `maxBathrooms` | int | – | Bathroom bounds |
| `minArea` / `maxArea` | number | – | Area bounds (unit set by `areaUnit`) |
| `areaUnit` | string | `marla` | `marla` / `kanal` / `sqft` / `sqm` |
| `verifiedOnly` | bool | `false` | Only zameen-verified listings |
| `keyword` | string | – | Free-text filter on title/description/location (English and Urdu fields both matched) |
| `sortBy` | string | `popular` | `popular` / `newest` / `priceLowToHigh` / `priceHighToLow` (mode=search) |
| `maxItems` | int | `30` | Hard cap on emitted records (1–2000) |

#### Example: 5+ marla houses for sale in Lahore under 3 crore

```json
{
  "mode": "search",
  "city": "Lahore",
  "listingType": "housesForSale",
  "minArea": 5,
  "areaUnit": "marla",
  "maxPrice": 30000000,
  "maxItems": 50
}
```

#### Example: full detail for specific listings

```json
{
  "mode": "byUrl",
  "propertyUrls": [
    "https://www.zameen.com/Property/lahore_jubilee_town_double_storey_5_marla_house-54210017-766-1.html"
  ]
}
```

### Use cases

- **Property portals / aggregators** — bulk-import Pakistani listings by city and type
- **Market research** — track price-per-marla trends across cities and neighborhoods
- **Lead generation** — pull agency/agent contact details for verified listings
- **Investment analysis** — filter by area/price to find undervalued plots or houses
- **Rental market monitoring** — compare rent-frequency and pricing across cities

### FAQ

**Does this need login or cookies?** No — all data comes from zameen.com's public, server-rendered search and property pages.

**How is area reported?** Zameen's canonical unit is square meters (`areaSqm`); the actor also derives `areaMarla` since Marla is the standard unit in Pakistani real estate. Use `areaUnit` to filter in Marla, Kanal, sq ft, or sq m.

**What if my city isn't in the dropdown?** Use `customLocationSlug` with any zameen.com location slug, e.g. `Lahore_Jubilee_Town-766` (found in a zameen.com search URL: `zameen.com/Homes/<slug>-1.html`).

**Why do some listings have no `price`?** A small share of listings (mostly high-end/exclusive) hide the price on zameen.com — those records omit `price`/`priceCurrency` rather than showing a fake value.

**Is `sortBy` supported?** Yes — `sortBy` (`popular` / `newest` / `priceLowToHigh` / `priceHighToLow`) is sent as zameen.com's own `sort=` search-page query param, so pages are walked in that server-side order *before* the price/bedroom/area/keyword filters below run client-side. Useful with a low `maxItems` to get e.g. the 30 cheapest matching listings instead of an arbitrary relevance-ranked slice.

**How current is the data?** Real-time — every run fetches zameen.com's live search results at request time.

# Actor input Schema

## `mode` (type: `string`):

`search` browses listings by city + listing type + filters. `byUrl` fetches full detail records for specific zameen.com property URLs.

## `city` (type: `string`):

Pakistani city to browse. Use `customLocationSlug` instead for a city/area not in this list.

## `customLocationSlug` (type: `string`):

Override `city` with any zameen.com location slug, e.g. `Lahore_Jubilee_Town-766` or `Lahore-1` (found in a zameen.com search URL like zameen.com/Homes/<slug>-1.html). Leave empty to use `city`.

## `listingType` (type: `string`):

Property super-category and sale/rent purpose.

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

Full zameen.com property page URLs, e.g. `https://www.zameen.com/Property/<slug>.html`.

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

Drop listings priced below this (Pakistani Rupees). Listings without a parseable price are kept.

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

Drop listings priced above this (Pakistani Rupees). Listings without a parseable price are kept.

## `minBedrooms` (type: `integer`):

Drop listings with fewer bedrooms than this. Plots and listings without a parseable bedroom count (not every zameen.com listing reports one) are kept.

## `maxBedrooms` (type: `integer`):

Drop listings with more bedrooms than this. Plots and listings without a parseable bedroom count (not every zameen.com listing reports one) are kept.

## `minBathrooms` (type: `integer`):

Drop listings with fewer bathrooms than this. Plots and listings without a parseable bathroom count are kept.

## `maxBathrooms` (type: `integer`):

Drop listings with more bathrooms than this. Plots and listings without a parseable bathroom count are kept.

## `minArea` (type: `number`):

Drop listings smaller than this (unit set by `areaUnit`). Listings without a parseable area are kept.

## `maxArea` (type: `number`):

Drop listings larger than this (unit set by `areaUnit`). Listings without a parseable area are kept.

## `areaUnit` (type: `string`):

Unit for `minArea` / `maxArea`.

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

Result ordering, applied server-side by zameen.com before the price/bedroom/area/keyword filters below run. `popular` (default) is zameen.com's own relevance/featured ranking. Useful with a low `maxItems` to get e.g. the 30 cheapest or 30 newest matching listings instead of an arbitrary relevance-ranked slice.

## `verifiedOnly` (type: `boolean`):

Only emit listings zameen.com has marked as verified.

## `keyword` (type: `string`):

Only emit listings whose title/description/location contains this text (case-insensitive). Matches both the English and Urdu title/description fields, so Urdu-script keywords work too.

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

Hard cap on emitted records.

## Actor input object example

```json
{
  "mode": "search",
  "city": "Lahore",
  "listingType": "housesForSale",
  "propertyUrls": [],
  "areaUnit": "marla",
  "sortBy": "popular",
  "verifiedOnly": false,
  "maxItems": 30
}
```

# Actor output Schema

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

Dataset containing all scraped zameen.com listings/properties.

# 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 = {
    "mode": "search",
    "city": "Lahore",
    "listingType": "housesForSale",
    "propertyUrls": [],
    "areaUnit": "marla",
    "sortBy": "popular",
    "verifiedOnly": false,
    "maxItems": 30
};

// Run the Actor and wait for it to finish
const run = await client.actor("crawlerbros/zameen-real-estate-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 = {
    "mode": "search",
    "city": "Lahore",
    "listingType": "housesForSale",
    "propertyUrls": [],
    "areaUnit": "marla",
    "sortBy": "popular",
    "verifiedOnly": False,
    "maxItems": 30,
}

# Run the Actor and wait for it to finish
run = client.actor("crawlerbros/zameen-real-estate-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "mode": "search",
  "city": "Lahore",
  "listingType": "housesForSale",
  "propertyUrls": [],
  "areaUnit": "marla",
  "sortBy": "popular",
  "verifiedOnly": false,
  "maxItems": 30
}' |
apify call crawlerbros/zameen-real-estate-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=crawlerbros/zameen-real-estate-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/TVA3VeZMI9G7oqGZ4/builds/sPAdovBAjjxxunNKO/openapi.json
