# Bilibili Scraper (B站): Video Stats, Search & UP主 Creators (`rowfinch/bilibili-scraper`) Actor

Search Bilibili (哔哩哔哩, B站) videos by keyword, creator or link. Export views, likes, coins, favorites, shares, comments, danmaku, tags and UP主 followers, filtered by date and length. No login or cookies. $2 per 1,000 videos.

- **URL**: https://apify.com/rowfinch/bilibili-scraper.md
- **Developed by:** [Rowfinch](https://apify.com/rowfinch) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 videos

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

## Bilibili Scraper (哔哩哔哩 / B站)

Turn Bilibili into a spreadsheet: views, likes, coins, favorites, shares, comments, danmaku, tags and length of every video, with its creator (UP主) and their followers. Search by keyword, follow creators or paste video links. No account, no cookies.

**$2 per 1,000 videos, full stats included.**

### Who uses it

- **Brands and game studios**: every new video about your product, and the creators behind it.
- **Influencer (KOL) discovery**: compare UP主 by followers, likes and engagement before reaching out.
- **Competitor research**: a rival channel's whole upload history, with stats.
- **Research and AI datasets**: titles, descriptions and tags of thousands of Chinese videos, dated and measured.

### What you get

| | Fields |
|---|---|
| Video | link, BV id, title, description, thumbnail, length, publish date, category, tags |
| Engagement | views, likes, coins (投币), favorites (收藏), shares, comments, danmaku (弹幕) |
| Creator | name, link and followers on every video; with a creator profile also following, video count, total likes, level and verification |

### Examples

**Monitor a topic.** Schedule this daily and get each day's new videos:

```json
{ "searchTerms": ["原神", "崩坏星穹铁道"], "sort": "newest", "publishedFrom": "1 day", "maxVideos": 1000 }
```

**Vet creators.** Profiles plus the 50 latest uploads of each, with full stats:

```json
{ "creatorUrls": ["https://space.bilibili.com/19226160"], "maxVideos": 50, "fullStats": true }
```

**Refresh stats for your own list.** Video links, BV ids or b23.tv short links:

```json
{ "videoUrls": ["BV13a8d69EDe", "https://www.bilibili.com/video/BV1WFpB6TEAD"] }
```

### Output

```json
{
  "type": "video",
  "id": "BV13a8d69EDe",
  "url": "https://www.bilibili.com/video/BV13a8d69EDe",
  "title": "2026 MacBook 全系选购指南",
  "thumbnail": "https://i2.hdslb.com/bfs/archive/8fe4fc86….jpg",
  "durationSeconds": 894,
  "publishedAt": "2026-08-26T03:41:08.000Z",
  "category": "数码",
  "tags": ["MacBook", "Apple", "笔记本"],
  "views": 670436,
  "likes": 21764,
  "coins": 4924,
  "favorites": 4648,
  "shares": 2447,
  "comments": 1783,
  "danmaku": 1798,
  "creator": { "id": 19226160, "name": "橙红Iris", "url": "https://space.bilibili.com/19226160", "followers": 855967 },
  "searchTerm": "macbook"
}
```

Bilibili's search and creator listings leave out coins, shares and the creator's followers, and creator listings also leave out likes and tags. Turn on **Full stats for every video** to fill them in; otherwise they are `null`.

Creator profiles come as `"type": "creator"` items, listed apart in the dataset's **Creators** view. Export everything as Excel, CSV or JSON.

### Pricing

- **$2 per 1,000 videos**, with or without full stats
- **$3 per 1,000 creator profiles**

| Run | Cost |
|---|---|
| 1,000 newest videos about a game | $2.00 |
| 20 creators with their 50 latest videos | $2.06 |

The run stops at **Videos per search term or creator**, so that number caps the cost. Apify's free plan credit covers about 2,500 videos a month.

### Tips

- Chinese terms find far more videos: 原神 rather than Genshin Impact.
- Bilibili shows at most 1,000 results per search. Split a broad topic into several terms or date ranges to go further.
- For creator profiles alone, set videos to 0.
- Leave the proxy on: Bilibili limits busy networks, and the Actor switches IPs when it pushes back.

### FAQ

**Can I use it as a Bilibili API?**
Yes: call it from Python, JavaScript or any HTTP client (see the API tab), or connect it to Make, Zapier or n8n.

**Does it get comments or danmaku text?**
It gets their counts. The text isn't available yet, because Bilibili shows only a few comments to visitors without an account. Tell us in the Issues tab if you need it.

**Is it legal?**
It collects public data that Bilibili shows to anyone without an account. Respect Bilibili's terms and privacy laws such as China's PIPL and the GDPR when you store or use information about people.

### 中文说明

采集B站视频和UP主数据：按关键词搜索、按UP主抓取投稿，或输入视频链接，获取播放、点赞、投币、收藏、分享、评论、弹幕数和标签。无需登录，无需 Cookie。每 1,000 条视频 2 美元。

# Actor input Schema

## `searchTerms` (type: `array`):

Chinese terms find far more: 原神 rather than Genshin Impact.

## `creatorUrls` (type: `array`):

Profile links (space.bilibili.com/…) or UIDs. Returns the profile and the latest uploads.

## `videoUrls` (type: `array`):

Video links, BV ids or b23.tv short links.

## `maxVideos` (type: `integer`):

Bilibili shows at most 1,000 results per search. Set 0 to get creator profiles only.

## `fullStats` (type: `boolean`):

Adds coins, shares, every tag and the creator's followers to search and creator results. Takes longer.

## `sort` (type: `string`):

Newest with a date range is the way to monitor a topic.

## `publishedFrom` (type: `string`):

China time (UTC+8). A period like 7 days counts back from today, for scheduled runs.

## `publishedTo` (type: `string`):

China time (UTC+8).

## `duration` (type: `string`):

Bilibili's own length buckets.

## `proxy` (type: `object`):

Bilibili limits busy networks; the proxy keeps long runs with full stats going.

## Actor input object example

```json
{
  "searchTerms": [
    "macbook"
  ],
  "maxVideos": 10,
  "fullStats": false,
  "sort": "relevance",
  "duration": "any",
  "proxy": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `videos` (type: `string`):

No description

## `creators` (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 = {
    "searchTerms": [
        "macbook"
    ],
    "maxVideos": 10,
    "proxy": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("rowfinch/bilibili-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 = {
    "searchTerms": ["macbook"],
    "maxVideos": 10,
    "proxy": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("rowfinch/bilibili-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 '{
  "searchTerms": [
    "macbook"
  ],
  "maxVideos": 10,
  "proxy": {
    "useApifyProxy": true
  }
}' |
apify call rowfinch/bilibili-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,rowfinch/bilibili-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/2lj9eBmVSv4aq2fS5/builds/9LZhgW8KRVsaeiYZS/openapi.json
