# Bilibili Scraper — Videos, Comments & Users (No Login) (`datasiphon/bilibili-scraper`) Actor

Bilibili scraper: search videos by keyword, get popular videos, video comments and user profiles with plays, danmaku, likes and followers. No login, no cookies. Export JSON, CSV or Excel.

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

## Pricing

$10.00 / 1,000 rows

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 — videos, popular list, comments and users (no login)

**Bilibili Scraper** searches Bilibili videos by keyword, returns the **popular (hot) list**, **user profiles** and video comments — plays, **danmaku** (bullet comments), likes, favorites, tags and followers. No login, no cookies. Export JSON, CSV or Excel.

### What does it do?

Use it for **China social-media research**, trend and creator discovery, content analysis, competitor and market monitoring, and datasets of Chinese video content. Search works in Chinese or English.

### Features

- **Video search** by keyword with sorting (relevance, most played, newest, most danmaku, most favorited) and duration filter; up to 1,000 videos per keyword.
- **Popular videos** list.
- **User profiles** by user ID: name, followers, following, level, verification title, archive count.
- **Video comments** by BV id/URL (logged-out Bilibili exposes only the top few per video).
- Fields per video: title, description, author and ID, **plays, danmaku, comments, favorites, likes**, duration, publish time, tags, category, cover.
- `maxItems` cap, **incremental mode** (`onlyNew`).

### How to scrape Bilibili

1. Add **keywords** (e.g. python, 美食) and/or switch on popular videos, add user IDs or video links.
2. Choose sorting and limits.
3. Run and export.

### Input

`searchQueries`, `maxVideosPerQuery`, `order`, `duration`, `popular`, `popularCount`, `videoUrls`, `maxCommentsPerVideo`, `commentSort`, `userIds`, `maxItems` (default 100), `onlyNew`, `proxyConfiguration`.

### Example output (real run)

```json
{
  "type": "video",
  "id": "BV1sfa965ENG",
  "bvid": "BV1sfa965ENG",
  "aid": 117357229902293,
  "url": "https://www.bilibili.com/video/BV1sfa965ENG",
  "title": "美国富人区最顶级美食！连吃24小时！老钱吃得有多离谱？",
  "description": "各位觉得美国富人区哪餐更符合你的口味? 顺便还体验了一把TCL x NFL橄榄球嘉年华互动游戏，\n竟然输给了饲养员，快来看看怎么回事吧！\n我是子文想吃遍全世界各国美食！\n喜欢的话就点点赞和关注！\n十分感谢各位的大力支持！…",
  "author": "子文又饿了",
  "authorId": 8894411,
  "plays": 407502,
  "danmaku": 2469,
  "comments": 634,
  "favorites": 3683,
  "likes": 19063,
  "duration": "23:29",
  "publishedAt": "2026-09-30T09:00:00+00:00",
  "tags": [
    "SQD Mini LED",
    "国外美食",
    "美食探店"
  ],
  "category": "美食侦探",
  "cover": "https://i2.hdslb.com/bfs/archive/b5f01bd0bae0b41fed3ae68f5630403f1b6f940b.jpg",
  "query": "美食",
  "schemaVersion": 1
}
```

### Pricing

Pay per event: **$10 per 1,000 rows** ($0.01 each). Errors are free.

### Use cases

China trend research · creator and KOL discovery · content analysis · market research · social listening on Chinese video.

### FAQ

**Do I need a Bilibili account?** No.
**Why so few comments per video?** Without login Bilibili returns only the top comments; video and user data are complete.
**Can I search in English?** Yes, but Chinese keywords return the most results.

### Limitations

Logged-out Bilibili exposes only the top few comments per video, so comment depth is limited; video details come from search and popular lists. Some endpoints throttle and are retried.

### Also useful for

A Bilibili video scraper and data API: search videos, scrape popular lists, user profiles and comments, and export them as JSON, CSV or Excel.

### Is it legal? No login, no cookies

This Actor only reads **publicly available** pages. It never asks for a cookie, password or account and does not access private data. You are responsible for using the data in line with the source site's terms and applicable law (GDPR/CCPA for personal data).

### Related scrapers by the same author

[YouTube Transcript Scraper](https://apify.com/datasiphon/youtube-transcript-scraper) · [YouTube Email Scraper](https://apify.com/datasiphon/youtube-email-scraper) · [Reddit Scraper](https://apify.com/datasiphon/reddit-scraper) · [Google News Scraper](https://apify.com/datasiphon/google-news-scraper) · [Bilibili Scraper](https://apify.com/datasiphon/bilibili-scraper) · [Airbnb Scraper](https://apify.com/datasiphon/airbnb-scraper)

# Actor input Schema

## `searchQueries` (type: `array`):

Keywords to search Bilibili videos for (Chinese or English).

## `maxVideosPerQuery` (type: `integer`):

How many videos to return per keyword (20 per page, up to 50 pages).

## `order` (type: `string`):

Relevance, most played, newest, most danmaku, most favorited.

## `duration` (type: `integer`):

0 any, 1 under 10 min, 2 10-30 min, 3 30-60 min, 4 over 60 min.

## `popular` (type: `boolean`):

Add Bilibili's current popular (hot) list.

## `popularCount` (type: `integer`):

How many popular videos to add.

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

bilibili.com/video/BV… links or BV ids; their comments are returned.

## `maxCommentsPerVideo` (type: `integer`):

Cap per video.

## `commentSort` (type: `string`):

Most liked or newest comments.

## `userIds` (type: `array`):

Numeric Bilibili user IDs; returns profile, followers and level.

## `maxItems` (type: `integer`):

Overall cap on billed rows (cost control).

## `onlyNew` (type: `boolean`):

Skip rows already returned by a previous run.

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

Optional datacenter proxy. Residential is not supported (uneconomic at this price).

## Actor input object example

```json
{
  "searchQueries": [
    "python"
  ],
  "maxVideosPerQuery": 40,
  "order": "totalrank",
  "duration": 0,
  "popular": false,
  "popularCount": 20,
  "maxCommentsPerVideo": 50,
  "commentSort": "top",
  "maxItems": 100,
  "onlyNew": false
}
```

# Actor output Schema

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

All rows as JSON/CSV/Excel.

# 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 = {
    "searchQueries": [
        "python"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("datasiphon/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 = { "searchQueries": ["python"] }

# Run the Actor and wait for it to finish
run = client.actor("datasiphon/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 '{
  "searchQueries": [
    "python"
  ]
}' |
apify call datasiphon/bilibili-scraper --silent --output-dataset

```

## MCP server setup

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