Lianjia Scraper: Resale Listings, Price, Community avatar

Lianjia Scraper: Resale Listings, Price, Community

Pricing

from $2.50 / 1,000 property listings

Go to Apify Store
Lianjia Scraper: Resale Listings, Price, Community

Lianjia Scraper: Resale Listings, Price, Community

Scrape Lianjia (链家) resale listings across 12 major Chinese cities. Get total price, price per sqm, community, area, and layout. Perfect for Excel, Google Sheets, or any BI tool. Skip manual copy-pasting or expensive broker fees. $2.50 per 1,000 results.

Pricing

from $2.50 / 1,000 property listings

Rating

0.0

(0)

Developer

GetAScraper

GetAScraper

Maintained by Community

Actor stats

0

Bookmarked

3

Total users

2

Monthly active users

3 days ago

Last modified

Share

Get live Beijing and Shanghai resale housing data: total price, price per square meter, community, area, and floor. Ready for your spreadsheet in under 60 seconds.

Lianjia (链家) is the dominant real estate platform in China, run by KE Holdings (parent of Beike 贝壳找房). This Actor pulls public resale listings (二手房) into clean datasets for 12 major Chinese cities. No login. No API key. No headless browser overhead.

What does Lianjia Real Estate Scraper do?

The Actor extracts structured property data from the public Lianjia desktop search and detail pages and saves it to the Apify dataset. You get the same 30-row pages a regular browser would render, parsed and normalized for analysis.

Two operations, one actor:

  • Resale Housing List: walk paginated listing cards by city. 30 rows per page, up to 100 pages per run (3,000 rows max).
  • Resale Housing Detail: fetch one full property record by houseCode (the numeric listing ID, e.g. 101137699747).

Each row carries a public m.ke.com mobile URL you can open in any browser to verify the listing in one click.

Who is this for

  • I am a China property market analyst building city-level and neighborhood-level price maps across Beijing, Shanghai, Shenzhen, and 9 other metros. I need clean per-㎡ prices, area, and bedroom counts delivered to my dashboard on schedule.
  • I am a cross-border real estate investor comparing China resale housing against my US and UK datasets. I need the same schema across all my property pipelines and a pay-per-result cost model that fits my research budget.
  • I am a real estate lead generation operator pulling agent names and property context for brokerage, mortgage, or relocation outreach. I need fresh listings every morning and a public mobile URL I can hand to my sales team.
  • I am a proptech builder training an automated valuation model. I need average unit price per community plus on-sale inventory counts to feed my comps engine.
  • I am a developer integrating China real estate data into a Notion dashboard or Airtable base. I need clean JSON with stable field names and a simple Node.js or Python client to call.

How to use

  1. Pick an operation (or use Start URLs). You can either use the dropdown options or provide custom Start URLs representing a pre-filtered search (e.g. https://bj.ke.com/ershoufang/chaoyang/p3/) copied straight from your browser.
  2. Set the city (if not using Start URLs). Pick from the 12-city dropdown or type any Beike city ID.
  3. Set the page range. maxPages from 0 to 100. 30 rows per page. Default 5 pages (150 rows).
  4. Run. The Actor crawls the pages, parses each card with Cheerio, and pushes rows to the dataset.
  5. Export. Download JSON, CSV, or Excel from the Apify dataset tab.

For the Detail operation, you can either paste a detail page URL as a Start URL (e.g. https://bj.ke.com/ershoufang/101137699747.html) or use the dropdown with a numeric houseCode.

Input

FieldTypeRequiredDescription
startUrlsarrayNoOptional. List of custom pre-filtered search list or detail URLs, e.g. https://bj.ke.com/ershoufang/chaoyang/p3/. Supports all 670+ Chinese subdomains.
operationstringYesresaleHousingList or resaleHousingDetail (ignored if startUrls is provided).
cityIdstringNoBeike city ID (e.g. 110000 for Beijing). Ignored if startUrls is provided.
houseCodestringFor DetailNumeric listing ID, e.g. 101137699747. Ignored if startUrls is provided.
maxPagesintegerNoMax pages for list operation. 30 rows per page. Default 5, range 0 to 100.
proxyConfigurationobjectNoApify Residential proxy is required for stability at scale. Default: RESIDENTIAL group.

Example: custom pre-filtered list search

{
"startUrls": [
{ "url": "https://bj.ke.com/ershoufang/chaoyang/p3/" }
],
"maxPages": 5
}

Example: Beijing 5 pages of resale listings

{
"operation": "resaleHousingList",
"cityId": "110000",
"maxPages": 5
}

Example: one Shanghai property by houseCode

{
"operation": "resaleHousingDetail",
"cityId": "310000",
"houseCode": "101137699747"
}

Output

Every row includes the public mobile URL pointing to the live m.ke.com listing, so you can verify the data in one click.

Resale Housing List row

{
"_operation": "resaleHousingList",
"houseCode": "101133627586",
"listingTitle": "此房是南北通透三居室,满五唯一",
"communityName": "加州水郡四期",
"priceTotal": 179,
"priceTotalDisplay": "179 万",
"unitPrice": 19551,
"unitPriceDisplay": "19,551元/平",
"area": 91.56,
"bedroomNum": 3,
"hallNum": 1,
"orientation": "南",
"yearBuilt": "2011年",
"decoration": "",
"followInfo": "225人关注 / 8月前发布",
"agentName": "",
"cityId": "110000",
"cityName": "北京",
"subdomain": "bj",
"listingUrl": "https://m.ke.com/bj/ershoufang/101133627586.html",
"scrapedAt": "2026-06-12T04:34:18.741Z"
}

Resale Housing Detail row adds floorState, buildingType, elevator, ownership, publishTime, and tags[].

You can download the dataset in JSON, HTML, CSV, or Excel from the Apify dataset tab.

Data table

FieldTypeDescription
_operationstringWhich operation produced this row
houseCodestringBeike listing ID, e.g. 101133627586
listingTitlestringPublic listing title (Chinese, e.g. "此房是南北通透三居室,满五唯一")
communityNamestringCommunity / neighborhood name (小区)
priceTotalnumberTotal price in 万 (10,000 RMB), e.g. 179 = ¥1,790,000
priceTotalDisplaystringFormatted total price string, e.g. 179 万
unitPricenumberPrice per square meter in RMB, e.g. 19551
unitPriceDisplaystringFormatted unit price string, e.g. 19,551元/平
areanumberFloor area in ㎡, e.g. 91.56
bedroomNumnumberNumber of bedrooms
hallNumnumberNumber of halls / living rooms
orientationstringBuilding orientation, e.g. / 西南
yearBuiltstringYear built, e.g. 2011年
decorationstringDecoration level, e.g. 毛坯 / 简装 / 精装
followInfostringRaw followInfo field from Lianjia (engagement + post date)
agentNamestringPublic listing agent name when displayed
cityIdstringBeike city ID (e.g. 110000)
cityNamestringCity name in Chinese, e.g. 北京
subdomainstringLianjia subdomain, e.g. bj, sh
listingUrlstringPublic mobile URL on m.ke.com
scrapedAtstringISO 8601 timestamp of the scrape run
floorStatestring(Detail only) e.g. 中楼层/共23层
buildingTypestring(Detail only) e.g. 板楼 / 塔楼
elevatorstring(Detail only) 有电梯 / 无电梯
ownershipstring(Detail only) Property ownership type
publishTimestring(Detail only) Listing publish timestamp
tagsstring[](Detail only) Highlight tags from the listing

API quickstart

Curl

curl --request POST \
--url "https://api.apify.com/v2/acts/getascraper~lianjia-real-estate-scraper/runs?token=YOUR_API_TOKEN" \
--header 'Content-Type: application/json' \
--data '{
"operation": "resaleHousingList",
"cityId": "110000",
"maxPages": 5
}'

Python

from apify_client import ApifyClient
client = ApifyClient('YOUR_API_TOKEN')
run = client.actor('getascraper/lianjia-real-estate-scraper').call(
run_input={
'operation': 'resaleHousingList',
'cityId': '110000',
'maxPages': 5,
}
)
for item in client.dataset(run['defaultDatasetId']).iterate_items():
print(item)

Node.js

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_API_TOKEN' });
const run = await client
.actor('getascraper/lianjia-real-estate-scraper')
.call({
operation: 'resaleHousingList',
cityId: '110000',
maxPages: 5,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Pricing

Pay-per-result and billed per row successfully saved to your dataset. Empty runs and captcha-blocked requests cost exactly $0.00.

  • Rate: $2.50 per 1,000 results ($0.0025 per result)
  • 100 listings typically cost $0.25
  • 1,000 listings cost exactly $2.50
  • 3,000 listings (the max single run) cost exactly $7.50
  • No fixed monthly subscriptions or hidden maintenance fees

Your Apify subscription tier applies an automatic volume discount on top of the per-result rate.

FAQ

Does it get blocked?

The public Lianjia search returns HTTP 302 to a captcha challenge after the first request from any single IP. The default input schema routes every request through the Apify Residential proxy group, which rotates IPs per call and keeps the scraper stable across full pagination runs.

How fresh is the data?

Every row reflects a live scrape. Lianjia updates inventory throughout the day, and this Actor hits the live search and detail pages. There is no cached data layer between you and the source. Each row carries a scrapedAt ISO 8601 timestamp so you know exactly when it was pulled.

Which cities are supported?

Twelve major Chinese metros are in the dropdown: Beijing (110000), Shanghai (310000), Guangzhou (440100), Shenzhen (440300), Hangzhou (330100), Chengdu (510100), Nanjing (320100), Wuhan (420100), Xi'an (610100), Tianjin (120000), Chongqing (500000), and Shenyang (210100). You can also type any Beike city ID to scrape additional cities.

Does it extract agent phone numbers?

No. Phone reveal on Lianjia requires an authenticated app session and is out of scope. The Actor exposes only what is publicly visible on the public listing page, including the agent's display name when shown.

Tips and advanced options

  • Schedule daily runs for the same cityId and operation to track price movement and inventory depth over time.
  • Narrow by houseCode instead of paginating when you already have a short list. The Detail operation costs one row per call.
  • Dedupe by houseCode when stitching results across multiple runs. Listings can be delisted, so fresh houseCodes are guaranteed unique.
  • Cross-reference with our other China real estate Actors in the actorstack portfolio to combine Lianjia resale data with adjacent platforms.

This Actor only extracts data that is publicly visible on the public Lianjia search and detail pages. Users must comply with Lianjia's terms of service, Chinese PIPL, GDPR, and CCPA where applicable. Beike and Lianjia are trademarks of KE Holdings Inc; this is an independent scraping tool and is not affiliated with, endorsed by, or sponsored by KE Holdings.

Support

Open an issue on the Issues tab for bugs, feature requests, or city additions. We respond within 48 hours.