# Zillow Scraper (`magicfingers/zillow-scraper`) Actor

Scrape Zillow listings with full details: price, beds, baths, sqft, price history, tax history, schools, Zestimate, photos, agent info and more. Search by city, ZIP, address, or map coordinates. Filter by property type, price range, listing status.

- **URL**: https://apify.com/magicfingers/zillow-scraper.md
- **Developed by:** [abdulrahman alrashid](https://apify.com/magicfingers) (community)
- **Categories:** E-commerce
- **Stats:** 34 total users, 3 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

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

## Zillow Real Estate Scraper

Apify Actor for scraping Zillow real estate listings. Extract property data including price history, tax history, schools, Zestimate, photos, agent info, and 30+ data fields per listing.

### Features

- **Search by location** — city, ZIP code, neighborhood, or full address
- **Search by URL** — paste any Zillow search URL with pre-configured filters
- **Map bounding box** — search by geographic coordinates (north/south/east/west)
- **Filter support** — property type, price range, beds, baths, sqft, listing status
- **Full detail scraping** — visits each listing page for complete data
- **Photo URLs** — captures all listing photo URLs
- **Recently sold** — scrape sold properties in any area
- **Automatic pagination** — handles multi-page result sets

### Data Fields

Each listing includes up to 50+ fields:

| Category | Fields |
|----------|--------|
| **Basic** | zpid, address, city, state, zip, latitude, longitude |
| **Property** | price, beds, baths, sqft, lot size, year built, property type, stories |
| **Listing** | listing status, days on Zillow, date posted, date sold |
| **Valuation** | Zestimate, rent Zestimate, tax assessed value |
| **Financial** | HOA fees, price history (all events), tax history (all years) |
| **Details** | description, heating, cooling, parking, appliances, flooring, roof |
| **Scores** | walk score, transit score, bike score |
| **Schools** | nearby schools with ratings, grades, distance, type |
| **Agent** | agent name, phone, brokerage name, MLS ID |
| **Media** | all photo URLs with captions |

### Input Configuration

#### Search by Location (default)

```json
{
    "searchType": "location",
    "location": "San Francisco, CA",
    "listingStatus": "forSale",
    "propertyType": ["Houses", "Condos"],
    "minPrice": 500000,
    "maxPrice": 1500000,
    "minBeds": 2,
    "maxResults": 100,
    "scrapeDetails": true,
    "scrapePhotos": true
}
```

#### Search by Zillow URL

```json
{
    "searchType": "url",
    "searchUrls": [
        "https://www.zillow.com/san-francisco-ca/?searchQueryState=..."
    ],
    "maxResults": 200,
    "scrapeDetails": true
}
```

#### Search by Map Bounding Box

```json
{
    "searchType": "mapBounds",
    "mapBounds": {
        "north": 37.8120,
        "south": 37.7080,
        "east": -122.3549,
        "west": -122.5170
    },
    "listingStatus": "recentlySold",
    "maxResults": 500
}
```

#### Search Recently Sold

```json
{
    "searchType": "location",
    "location": "Austin, TX 78701",
    "listingStatus": "recentlySold",
    "maxResults": 100,
    "scrapeDetails": true
}
```

#### Search Rentals

```json
{
    "searchType": "location",
    "location": "Miami, FL",
    "listingStatus": "forRent",
    "minPrice": 2000,
    "maxPrice": 5000,
    "minBeds": 1,
    "maxResults": 50
}
```

### Output Example

```json
{
    "zpid": "15077598",
    "address": "123 Main St, San Francisco, CA 94102",
    "streetAddress": "123 Main St",
    "city": "San Francisco",
    "state": "CA",
    "zipcode": "94102",
    "price": 1250000,
    "currency": "USD",
    "beds": 3,
    "baths": 2,
    "sqft": 1850,
    "lotSize": 2500,
    "yearBuilt": 1925,
    "propertyType": "SINGLE_FAMILY",
    "listingStatus": "FOR_SALE",
    "daysOnZillow": 14,
    "zestimate": 1280000,
    "rentZestimate": 5200,
    "hoaFee": null,
    "description": "Charming Victorian home in the heart of...",
    "walkScore": 95,
    "transitScore": 88,
    "bikeScore": 82,
    "heating": "Central, Gas",
    "cooling": "None",
    "parking": "Garage - Attached, 1 space",
    "agentName": "Jane Smith",
    "brokerageName": "Compass",
    "priceHistory": [
        {
            "date": "2024-01-15",
            "event": "Listed for sale",
            "price": 1250000,
            "source": "MLS"
        }
    ],
    "taxHistory": [
        {
            "year": 2023,
            "taxPaid": 12500,
            "taxAssessment": 980000
        }
    ],
    "nearbySchools": [
        {
            "name": "Lincoln Elementary",
            "rating": 8,
            "level": "Elementary",
            "distance": 0.3,
            "type": "Public"
        }
    ],
    "photos": [
        {
            "url": "https://photos.zillowstatic.com/fp/...",
            "caption": "Front of house"
        }
    ],
    "url": "https://www.zillow.com/homedetails/123-Main-St/15077598_zpid/",
    "scrapedAt": "2024-01-20T10:30:00.000Z"
}
```

### Proxy Requirements

**Residential proxies are strongly recommended.** Zillow uses PerimeterX anti-bot protection that blocks datacenter IPs. The default configuration uses Apify's residential proxy group.

### Pricing

**Pay-Per-Event:** $2.00 per 1,000 results ($0.002 per result)

### Tips

1. **Start small** — test with `maxResults: 10` to verify your filters work before running large scrapes
2. **Use URLs** — set up complex filters on Zillow's website, copy the URL, and use `searchType: url` for exact results
3. **Lower concurrency** — if you're getting blocked, reduce `maxConcurrency` to 1-2
4. **Skip details for speed** — set `scrapeDetails: false` for basic listing data at 10x speed
5. **Map bounds for precision** — use bounding box coordinates for exact geographic coverage

### Technical Notes

- Uses Playwright with stealth configuration to avoid detection
- Extracts data from Zillow's `__NEXT_DATA__` embedded state and GraphQL responses
- Deduplicates results by ZPID across pagination
- Automatic retry on rate limiting with exponential backoff
- Resource blocking (analytics, fonts) for faster page loads

# Actor input Schema

## `searchType` (type: `string`):

How to search for listings.

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

City, ZIP code, neighborhood, or full address to search. Examples: 'San Francisco, CA', '90210', 'Austin TX 78701'.

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

Direct Zillow search URLs. Set up filters on Zillow, copy the URL, and paste here. Overrides location and filters if provided.

## `mapBoundsNorth` (type: `number`):

North latitude of the bounding box (e.g., 37.8199).

## `mapBoundsSouth` (type: `number`):

South latitude of the bounding box (e.g., 37.7034).

## `mapBoundsEast` (type: `number`):

East longitude of the bounding box (e.g., -122.3517).

## `mapBoundsWest` (type: `number`):

West longitude of the bounding box (e.g., -122.5147).

## `listingStatus` (type: `string`):

Filter by listing status.

## `propertyType` (type: `array`):

Filter by property type(s). Leave empty for all types.

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

Minimum listing price.

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

Maximum listing price.

## `minBeds` (type: `integer`):

Minimum number of bedrooms.

## `maxBeds` (type: `integer`):

Maximum number of bedrooms.

## `minBaths` (type: `integer`):

Minimum number of bathrooms.

## `maxBaths` (type: `integer`):

Maximum number of bathrooms.

## `minSqft` (type: `integer`):

Minimum square footage.

## `maxSqft` (type: `integer`):

Maximum square footage.

## `maxResults` (type: `integer`):

Maximum number of listings to scrape. Set 0 for unlimited.

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

Visit each listing page for full details (price history, tax history, schools, description, etc.). Slower but more data.

## `scrapePhotos` (type: `boolean`):

Include photo URLs for each listing.

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

Proxy settings. Residential proxies strongly recommended for Zillow.

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

Maximum number of pages to process in parallel. Lower values reduce chance of blocking.

## Actor input object example

```json
{
  "searchType": "location",
  "location": "San Francisco, CA",
  "listingStatus": "forSale",
  "maxResults": 5,
  "scrapeDetails": true,
  "scrapePhotos": true,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  },
  "maxConcurrency": 3
}
```

# 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 = {
    "searchType": "location",
    "location": "San Francisco, CA",
    "listingStatus": "forSale",
    "maxResults": 5,
    "scrapeDetails": true,
    "scrapePhotos": true,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    },
    "maxConcurrency": 3
};

// Run the Actor and wait for it to finish
const run = await client.actor("magicfingers/zillow-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 = {
    "searchType": "location",
    "location": "San Francisco, CA",
    "listingStatus": "forSale",
    "maxResults": 5,
    "scrapeDetails": True,
    "scrapePhotos": True,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
    "maxConcurrency": 3,
}

# Run the Actor and wait for it to finish
run = client.actor("magicfingers/zillow-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 '{
  "searchType": "location",
  "location": "San Francisco, CA",
  "listingStatus": "forSale",
  "maxResults": 5,
  "scrapeDetails": true,
  "scrapePhotos": true,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  },
  "maxConcurrency": 3
}' |
apify call magicfingers/zillow-scraper --silent --output-dataset

```

## MCP server setup

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