# Weibo Scraper (`piotrv1001/weibo-scraper`) Actor

The Weibo Scraper efficiently extracts posts from Weibo's main feed, capturing likes, comments, shares, text content, images, videos, and profile data. It allows setting a maximum number of posts to fetch, making it ideal for social media analysis, trend monitoring, and engagement tracking

- **URL**: https://apify.com/piotrv1001/weibo-scraper.md
- **Developed by:** [FalconScrape](https://apify.com/piotrv1001) (community)
- **Categories:** Social media, Lead generation, Automation
- **Stats:** 237 total users, 7 monthly users, 97.3% runs succeeded, 8 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

$5.00 / 1,000 posts

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

### 🚀 Weibo Scraper

Scrape Weibo (微博) without logging in. One Actor, five modes:

- 🔥 **Hot timeline**: posts from Weibo's hot feed with likes, comments, shares, text, images, videos and author.
- 📈 **Hot search (热搜)**: the live hot-search board, with rank, heat, label and the pinned topics.
- 📝 **Post details**: full posts from any Weibo post link, with long posts expanded to their full text.
- 💬 **Post comments**: comments on any post, each with its first replies, like counts and the commenter's location and follower count.
- 👤 **User profiles**: followers, following, post count, verification, lifetime likes/comments/reposts, registration date, company and school.

No account, cookies or API key needed.

### ⚙️ Input

| Field | Used by | Description |
|---|---|---|
| `mode` | all | `hotTimeline` (default), `hotSearch`, `postDetails`, `postComments` or `userProfiles`. |
| `postUrls` | postDetails, postComments | `weibo.com/{user}/{id}`, `m.weibo.cn/detail/{id}`, `m.weibo.cn/status/{id}` links or bare post ids. |
| `users` | userProfiles | `weibo.com/u/{uid}` links, custom links like `weibo.com/rmrb`, `weibo.com/n/{name}` links, numeric ids or screen names (`人民日报`). |
| `maxCommentsPerPost` | postComments | Comments per post. Defaults to `100`. |
| `commentsSort` | postComments | `newest` (default) reaches much deeper into a thread; `hot` returns Weibo's top comments first. |
| `limit` | all | Maximum results in the whole run. Defaults to `100`. |
| `proxyConfiguration` | all | Defaults to Apify Proxy. Weibo does not answer Apify's shared platform IPs, so keep a proxy on. |

Comments on one post:

```json
{
    "mode": "postComments",
    "postUrls": ["https://weibo.com/1763990660/RjANMzWLc"],
    "maxCommentsPerPost": 500
}
```

Profiles:

```json
{
    "mode": "userProfiles",
    "users": ["https://weibo.com/u/2803301701", "新浪新闻", "https://weibo.com/rmrb"]
}
```

### ⚠️ Limits

- Keyword search and a user's full post timeline need a logged-in Weibo account, so this Actor does not offer them.
- Weibo shows logged-out visitors only part of a comment thread, so expect most but not all comments. In our tests: 182 of 217 on a small thread, 1,000+ on a post with 139k comments.
- Some authors switch on comment curation (评论精选); only the comments they pick are public, and the run log says so.
- Every row has a `type` field (`post`, `hotSearch`, `comment`, `profile`). Each row in the dataset counts as one result.

### 📊 Sample output

Hot timeline / post details:

```json
{
    "type": "post",
    "postId": "5333950818946673",
    "postUrl": "https://weibo.com/1762648251/RefdnBxrb",
    "author": {
        "id": "1762648251",
        "name": "暖豆豆呀",
        "profileImage": "https://tvax1.sinaimg.cn/crop.0.0.1080.1080.1024/690fe0bbly8i9rjnqv43pj20u00u079o.jpg",
        "profileUrl": "https://weibo.com/u/1762648251",
        "verified": true,
        "followersCount": null
    },
    "createdAt": "Thu Aug 20 11:27:18 +0800 2026",
    "text": "当时李响和孙骁骁在一起八年，曾当众求婚表白……",
    "likes": 1313,
    "comments": 99,
    "shares": 24,
    "images": [],
    "videos": ["http://f.video.weibocdn.com/o0/V20IWYuYlx08A91dDCiI01041200v2cB0E010.mp4"],
    "location": "河北"
}
```

Hot search:

```json
{
    "type": "hotSearch",
    "rank": 2,
    "pinned": false,
    "keyword": "拾荒老人不知自己每月养老金3700元",
    "heat": 1248435,
    "label": "热",
    "category": null,
    "searchUrl": "https://s.weibo.com/weibo?q=%E6%8B%BE%E8%8D%92...",
    "postUrl": null
}
```

Comment:

```json
{
    "type": "comment",
    "postId": "5346697028567358",
    "postUrl": "https://weibo.com/1763990660/RjANMzWLc",
    "commentId": "5346697106425782",
    "text": "秋晚想见，和曾舜晞",
    "createdAt": "Thu Sep 24 15:36:30 +0800 2026",
    "likes": 1966,
    "location": "浙江",
    "author": {
        "id": "7884193234",
        "name": "今天也要为曾舜晞拼命",
        "profileUrl": "https://weibo.com/u/7884193234",
        "verified": true,
        "followersCount": 13482
    },
    "replyCount": 3,
    "replies": [
        {
            "commentId": "5346697141027365",
            "text": "相见…",
            "createdAt": "Thu Sep 24 15:36:37 +0800 2026",
            "likes": 905,
            "location": "浙江",
            "author": { "id": "7884193234", "name": "今天也要为曾舜晞拼命" }
        }
    ]
}
```

Profile:

```json
{
    "type": "profile",
    "userId": "2803301701",
    "screenName": "人民日报",
    "profileUrl": "https://weibo.com/u/2803301701",
    "description": "人民日报法人微博。参与、沟通、记录时代。",
    "location": "北京",
    "gender": "m",
    "verified": true,
    "verifiedType": 3,
    "verifiedReason": "《人民日报》法人微博",
    "followersCount": 158011384,
    "followingCount": 3096,
    "postsCount": 153651,
    "totalInteractions": 3983382781,
    "totalLikes": 2527276776,
    "totalComments": 276425095,
    "totalReposts": 1179680910,
    "registeredAt": "2012-07-22 02:28:35",
    "company": "人民日报社",
    "education": null,
    "credit": "阳光信用极好"
}
```

# Actor input Schema

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

hotTimeline: posts from Weibo's hot feed. hotSearch: the live 热搜 hot-search board with heat. postDetails: full posts from the URLs below. postComments: comments (with first replies) on the posts below. userProfiles: follower counts, verification, registration date and totals for the users below.

## `postUrls` (type: `array`):

For postDetails and postComments. Accepts weibo.com/{user}/{id}, m.weibo.cn/detail/{id}, m.weibo.cn/status/{id} links or bare post ids.

## `users` (type: `array`):

For userProfiles. Accepts weibo.com/u/{uid} links, numeric user ids, weibo.com/n/{name} links or screen names (e.g. 人民日报).

## `maxCommentsPerPost` (type: `integer`):

For postComments. Newest-first order reaches whole threads of several hundred comments; the largest posts (100k+ comments) are cut off by Weibo for logged-out visitors.

## `commentsSort` (type: `string`):

For postComments. newest reaches much deeper into a thread; hot returns Weibo's top comments first but stops near 300.

## `limit` (type: `integer`):

Maximum number of results in the whole run (posts, topics, comments or profiles).

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

Required. Weibo does not respond to Apify's shared platform IPs, so the Actor cannot run without a proxy. The default datacenter proxy works; switch to Residential only if you start seeing blocks.

## Actor input object example

```json
{
  "mode": "hotTimeline",
  "maxCommentsPerPost": 100,
  "commentsSort": "newest",
  "limit": 100,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# 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": "hotTimeline",
    "limit": 100,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("piotrv1001/weibo-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": "hotTimeline",
    "limit": 100,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("piotrv1001/weibo-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 '{
  "mode": "hotTimeline",
  "limit": 100,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call piotrv1001/weibo-scraper --silent --output-dataset

```

## MCP server setup

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