Polyglot Data

Home / China / Bilibili Scraper

Bilibili Scraper: videos, search, comments and trending

A Bilibili scraper for the public guest API of bilibili.com, the biggest video site in China ("China YouTube"). Five modes: Bilibili search, video details and stats, Bilibili comments, the popular (trending) list, and the latest uploads of a channel. No login, no cookies from you, no browser.

  • Search: keywords in Chinese or English, order by best match, plays, newest, danmaku or favorites, optional duration filter, up to 50 pages (1,000 results) per keyword.
  • Video details: views, likes, coins, favorites, shares, danmaku (bullet comments), comment count, tags, uploader, publish time, duration.
  • Comments: text, likes, time, user name and level, reply count, with replies. See the guest limit below.
  • Popular: the current trending list with full stats.
  • Channels: latest uploads of any uploader (space.bilibili.com/<id>).
  • Accepts bilibili.com/video/BV... links, bare BV ids, and b23.tv short links.
  • Pay per event: $2.00 per 1,000 videos, $0.50 per 1,000 comments. Error items are free.

Run it on ApifySee pricing

What data you get

Video item (search, videos, popular, channels):

FieldDescription
bvid, aid, urlVideo ids and page link
title, description, coverUrl, tagsTitle (highlight tags removed), description, cover, tags (videos mode)
authorName, authorMid, authorUrlUploader
durationSeconds, publishedAt, categoryLength, publish time (ISO), Bilibili category
views, danmaku, comments, likes, favoritesCounters
coins, sharesCounters, in videos and popular modes
source, keyword, scrapedAtsearch / video / popular / channel, the keyword that found it

Comment item (comments mode): rpid, videoBvid, videoUrl, videoTitle, text, likes, publishedAt, userName, userMid, userLevel, replyCount, isReply, parentRpid, location (when shown).

Fields Bilibili does not show are null.

Example output illustrative

Real field names from the Actor. Values are an example and change with every run.

{
  "type": "video",
  "bvid": "BV1KoWBzwE7T",
  "url": "https://www.bilibili.com/video/BV1KoWBzwE7T",
  "title": "最薄的iPhone...代价呢?国行iPhone Air上手体验",
  "authorName": "影视飓风",
  "authorMid": "946974",
  "durationSeconds": 642,
  "publishedAt": "2025-10-17T01:00:00.000Z",
  "views": 6987667,
  "danmaku": 9147,
  "comments": 9173,
  "likes": 126213,
  "favorites": 20944,
  "source": "search",
  "keyword": "iphone 17"
}

Input example

  1. Pick a Mode.
  2. search: add Keywords. videos, comments: add video links. channels: add space links or user ids. popular: nothing to add.
  3. Set Max items. It is split evenly between inputs; an input with fewer results hands its share to the next ones.
  4. Click Start. Download JSON, CSV, Excel or HTML, or use the API.
{ "mode": "comments", "urls": ["https://www.bilibili.com/video/BV1WvykzsEmt", "https://b23.tv/AbCdEf"], "maxItems": 80, "includeReplies": true }

Pricing

EventPricePer 1,000Charged when
Video saved$0.002$2.00 per 1,000Charged once for each video saved (search, videos, popular, channels modes). Error items and duplicates are never charged.
Comment saved$0.0005$0.50 per 1,000Charged once for each comment or reply saved (comments mode). Error items and duplicates are never charged.

Pay per event: $0.002 per video and $0.0005 per comment saved, plus a tiny start fee. Error items and duplicates are never charged. 100 videos cost about $0.20. Set a maximum cost per run to cap spending.

Prices are USD per event, as published on the Actor's Apify page. Apify platform usage may apply on top; check the Pricing tab on Apify before large runs.

Honest limits

Bilibili restricts what logged-out visitors can read. This Actor never logs in, so:

  • Comments: about 3 top-level comments per video per sort order (hot and latest, so up to ~6), then the first 20 replies under each of them. Deeper pages come back empty for guests. A video yields roughly 40 to 100 comments at most, however many it has. The IP location label is not shown to guests, so location is usually null.
  • Search never goes beyond 50 pages (1,000 results) per keyword, a Bilibili cap. Use more specific keywords or filters for deeper coverage.
  • Channels use a public archive list that shows only the view count for each video (no likes, coins, comment count, uploader name). Run videos mode on the links for full stats.
  • The popular list is the one Bilibili serves to guests; it changes through the day.
  • Bilibili has strict risk control. The Actor is deliberately slow (1 to 2 seconds per request), and stops with a BLOCKED item instead of hammering the site. On Apify it uses residential proxy and switches IP automatically.
  • Only public content: no members-only or paid videos, no private data.

Error items

One free item explains why an input gave nothing: NO_RESULTS, NOT_FOUND, NO_COMMENTS, INVALID_INPUT, NO_KEYWORDS, NO_URLS, UNAVAILABLE, and BLOCKED (risk control kept answering even after switching IPs; run again later).

Use cases

Trend and creator research on Chinese video, tracking views and danmaku of a topic, competitor and influencer monitoring, comment sentiment samples, content discovery for translators and clippers.

Try Bilibili Scraper on Apify

Run it from your browser, schedule it, or call it from the Apify API. Output downloads as JSON, CSV, Excel or HTML.

Open on the Apify Store

Related Actors

Douyin Scraper

Extract Douyin hot-search trends, or use video/profile URLs or IDs for comments and creator profiles. Get heat ranks, likes and follower counts for China social media monitoring. No login.

$0.001 / trend + $0.003 / profile + $0.0005 / comment

Details Open on Apify

1688 Scraper

Extract 1688.com products by English or Chinese keyword: CNY wholesale prices, MOQ tiers, sold counts and suppliers. Find China sourcing leads and compare prices. No login or cookies.

$0.0025 / product

Details Open on Apify

AliExpress Scraper

Extract AliExpress products by keyword and reviews by product ID or URL: prices, sold counts, ratings and photos for dropshipping research. Choose currency and ship-to country; no login.

$0.002 / product + $0.0005 / review

Details Open on Apify