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

Scrape Weibo (微博) hot search trends, verified account profiles and posts with full text, single posts and top comments. No login, pay per result.

- **URL**: https://apify.com/flarewow/weibo-scraper.md
- **Developed by:** [FlareWOW](https://apify.com/flarewow) (community)
- **Categories:** Social media, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.90 / 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 – Hot Search, Posts, Profiles & Comments (微博)

**Weibo Scraper extracts public data from Weibo (微博), China's largest microblogging platform: the live hot search list (热搜), profiles and latest posts of verified accounts, single posts with full text, and their top comments. No login, no cookies to paste.**

### Who is it for?

- **Brand & market research** – track what Chinese brands (Xiaomi, Huawei, Luckin…) post and how audiences react (likes, reposts, comments).
- **Trend monitoring** – save the Weibo hot search list every hour and see what China is talking about right now.
- **Media monitoring & journalism** – collect posts of official media and government accounts with full text, images and video links.
- **AI / NLP datasets** – clean Chinese text with topics (#话题#), timestamps and engagement numbers.

### What data you get

| Record | Fields |
|---|---|
| `trend` | rank, keyword, hotValue, label (热/新/沸), category, topicTag, search URL |
| `profile` | userId, screenName, verifiedReason, description, location, followers, following, postsCount, profileUrl, avatarUrl |
| `post` | postId, url, authorName, text (full text of long posts), createdAt, likes, comments, reposts, topics, imageUrls, videoUrl, videoDurationSec, region, source, isRepost, isPinned |
| `comment` | text, likes, replies, region (IP location), createdAt, likedByAuthor, authorName (only for verified accounts) |

Every record has `recordType` and `scrapedAt`, so you can mix modes in one run and filter later. The dataset has ready-made table views: **Hot search, Posts, Profiles, Comments**.

### How to use it

1. Click **Try for free**.
2. Keep **Hot search** on, and/or add **verified accounts** (profile URL like `https://weibo.com/u/2656274875`, numeric ID, custom domain like `https://weibo.com/cctvxinwen`, or a screen name like `央视新闻`) and/or **post URLs**.
3. Set **Max posts per account** and, if you want, **Top comments per post**.
4. Click **Start** and download the results as JSON, CSV, Excel or HTML – or read them via API.

#### Input example

```json
{
  "hotSearch": true,
  "maxTrends": 50,
  "accounts": ["https://weibo.com/u/2656274875", "小米公司"],
  "maxPostsPerAccount": 10,
  "postUrls": ["https://weibo.com/2656274875/RoWB7E0C7"],
  "maxCommentsPerPost": 10
}
```

#### Output example (real data, shortened)

```json
[
  {"recordType": "trend", "rank": 1, "keyword": "红果红了", "hotValue": 170540, "label": "热", "topicTag": "#红果红了#", "url": "https://s.weibo.com/weibo?q=%23%E7%BA%A2%E6%9E%9C%E7%BA%A2%E4%BA%86%23"},
  {"recordType": "profile", "userId": "1771925961", "screenName": "小米公司", "verifiedReason": "小米科技有限责任公司", "location": "北京 海淀区", "followers": 13933263, "postsCount": 25470},
  {"recordType": "post", "postId": "5359460663170634", "url": "https://weibo.com/1839167003/RoWQidiPg", "authorName": "华为终端", "text": "焕新启程，邀您共赏。6分钟一览华为双十一焕新季全场景新品发布会。#华为Mate90#Pro …", "createdAt": "2026-10-29T12:54:19.000Z", "likes": 76, "comments": 18, "reposts": 4, "topics": ["华为Mate90", "华为Pura90", "华为畅享100"], "videoUrl": "http://f.video.weibocdn.com/o0/wMk51YEYl…"},
  {"recordType": "comment", "postUrl": "https://weibo.com/2656274875/RoWB7E0C7", "text": "在我们国人身上总是有一股侠义之气[good]", "likes": 4, "region": "北京", "createdAt": "2026-10-29T14:10:56.000Z", "authorName": null}
]
```

#### API (Python)

```python
from apify_client import ApifyClient
client = ApifyClient("<YOUR_API_TOKEN>")
run = client.actor("flarewow/weibo-scraper").call(run_input={"hotSearch": True, "accounts": ["小米公司"], "maxPostsPerAccount": 20})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["recordType"], item.get("keyword") or item.get("text", "")[:50])
```

#### API (JavaScript)

```js
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: '<YOUR_API_TOKEN>' });
const run = await client.actor('flarewow/weibo-scraper').call({ hotSearch: true, maxTrends: 20 });
const { items } = await client.dataset(run.defaultDatasetId).listItems();
```

### Pricing (pay per result)

| Event | Price |
|---|---|
| Hot search trend | $1.30 / 1,000 |
| Profile | $2.60 / 1,000 |
| Post | $3.90 / 1,000 |
| Comment | $1.95 / 1,000 |

You pay only for records saved to the dataset. Example: the full hot search list (50 trends) costs $0.065; 1,000 posts cost $3.90. Set **Maximum cost per run** in the run options and the Actor stops cleanly when it is reached.

### Limitations & FAQ

- **No keyword search.** Weibo hides keyword search behind a login, so this Actor does not offer it. Use hot search, accounts and post URLs.
- **Verified accounts only for profiles/feeds.** For privacy reasons the Actor scrapes timelines only of verified organisational/official accounts (media, brands, government, public figures – Weibo `verified_type` 0–7). Other accounts are skipped and listed in the `ERRORS` record.
- **Comments:** logged-out visitors see only the first page of top comments (up to ~20 per post). Commenter names are returned only for verified accounts; for everyone else `authorName` is `null`.
- **Reposts list and follower lists** are not available without login.
- **Errors are never silent:** if Weibo blocks every request, the run ends as FAILED with a clear message instead of an empty "successful" run. Problems with single inputs are listed in the `ERRORS` key-value record.
- **Proxy:** Apify datacenter proxy (default) works; residential is slower and rarely needed.

### Integrations

Use the Actor with **n8n, Make, Zapier**, Google Sheets, webhooks or as an **MCP tool** for AI agents (Claude, ChatGPT). Schedule it hourly to build a hot-search history.

### Responsible use

The Actor collects only publicly visible data, without logging in. It does not collect personal data of private persons (commenters stay anonymous, personal accounts are skipped). You are responsible for using the data in line with Weibo's terms and applicable law (e.g. GDPR, PIPL).

***

### 中文说明

**微博采集器**：无需登录即可采集微博公开数据：

- **微博热搜榜**：排名、关键词、热度值、标签（热/新/沸）、话题链接；
- **认证账号**（媒体、品牌、机构、公众人物）的资料和最新微博：全文（长微博自动展开）、发布时间、点赞/评论/转发数、话题、图片、视频链接、IP 属地；
- **单条微博**（链接）及其**热门评论**（文本、点赞数、IP 属地；普通用户昵称不输出，保护隐私）。

输入：账号可填主页链接、数字 UID、个性域名或昵称（如 `央视新闻`）。按结果计费：热搜每千条 1.3 美元，微博每千条 3.9 美元，评论每千条 1.95 美元。
限制：不支持关键词搜索（微博要求登录）；仅采集认证账号的主页内容。

# Actor input Schema

## `hotSearch` (type: `boolean`):

Scrape the live Weibo hot search list (realtime trending topics with rank, hot value and label).

## `maxTrends` (type: `integer`):

How many hot search entries to save (Weibo shows about 50).

## `accounts` (type: `array`):

Verified Weibo accounts (media, brands, organisations, public figures). Accepts a profile URL (https://weibo.com/u/2656274875), a numeric user ID, a custom domain (https://weibo.com/cctvxinwen) or a screen name (央视新闻). Unverified personal accounts are skipped for privacy reasons.

## `maxPostsPerAccount` (type: `integer`):

How many latest posts to save for each account (0 = profile only).

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

Individual Weibo posts, e.g. https://weibo.com/2656274875/RoVDyrETK or https://m.weibo.cn/detail/5359414326592072. Works for public posts of any account.

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

Save the most popular public comments of every scraped post (0 = no comments). Weibo shows only the first page of top comments to logged-out visitors, so up to ~20 per post. Commenter names are only included for verified accounts.

## `fetchFullText` (type: `boolean`):

Long posts are truncated in feeds; this fetches the complete text (1 extra request per long post).

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

Apify Proxy datacenter works for Weibo in our tests. Switch to RESIDENTIAL only if you see repeated blocks.

## Actor input object example

```json
{
  "hotSearch": true,
  "maxTrends": 50,
  "accounts": [
    "https://weibo.com/u/2656274875"
  ],
  "maxPostsPerAccount": 10,
  "postUrls": [],
  "maxCommentsPerPost": 0,
  "fetchFullText": true,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

No description

## `errors` (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 = {
    "hotSearch": true,
    "maxTrends": 50,
    "accounts": [
        "https://weibo.com/u/2656274875"
    ],
    "maxPostsPerAccount": 10,
    "postUrls": [],
    "maxCommentsPerPost": 0,
    "fetchFullText": true,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("flarewow/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 = {
    "hotSearch": True,
    "maxTrends": 50,
    "accounts": ["https://weibo.com/u/2656274875"],
    "maxPostsPerAccount": 10,
    "postUrls": [],
    "maxCommentsPerPost": 0,
    "fetchFullText": True,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("flarewow/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 '{
  "hotSearch": true,
  "maxTrends": 50,
  "accounts": [
    "https://weibo.com/u/2656274875"
  ],
  "maxPostsPerAccount": 10,
  "postUrls": [],
  "maxCommentsPerPost": 0,
  "fetchFullText": true,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call flarewow/weibo-scraper --silent --output-dataset

```

## MCP server setup

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