Tiktok Scraper avatar

Tiktok Scraper

Pricing

from $3.70 / 1,000 results

Go to Apify Store
Tiktok Scraper

Tiktok Scraper

Pricing

from $3.70 / 1,000 results

Rating

0.0

(0)

Developer

Sovanza

Sovanza

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

2 days ago

Last modified

Categories

Share

TikTok Scraper

What is TikTok Scraper?

TikTok Scraper is an Apify Actor in this repo that collects public TikTok video metadata (caption, author, counts, music, cover, URL) from:

  • Hashtags (hashtags/tag/...)
  • Profiles (profiles/@...)
  • Search keywords (searchQueries)
  • Direct video URLs (videoUrls / startUrls)

It is built with Playwright in the same spirit as Amazon / Agency Vista actors here (Python + Chromium + Apify dataset).

Reference (feature & pricing model): the well-known Store Actor clockworks/tiktok-scraper. This CloudBots Actor is a separate implementation—not a fork of Clockworks’ code. TikTok changes often; for production scale many teams use the Store Actor or extend this one.

➡️ Provide seeds + limits; the Actor discovers video links on listing pages, opens each video, merges embedded JSON and XHR JSON, and pushes one row per video.

Why use this Actor?

  • Own the code in your monorepo (customize fields, logging, proxy rules).
  • Same deployment pattern as your other Actors (Dockerfile, INPUT_SCHEMA.json, dataset schema).
  • Aligns input ideas with the Store scraper: hashtags, profiles, search, caps per seed, maxItems.

Features

  • Seeds: hashtags, profiles, searchQueries, startUrls / urls, videoUrls.
  • Discovery: scrolls listing pages, collects /video/ links + parses JSON from network and <script> embeds (__UNIVERSAL_DATA_FOR_REHYDRATION__, SIGI_STATE, etc.).
  • Detail pass: per-video page with XHR capture + embedded JSON.
  • Output: webVideoUrl, text, authorMeta, engagement counts, musicMeta, videoMeta, sourceType / sourceValue, error.
  • Apify Proxy: default RESIDENTIAL when available (proxyConfiguration, disableProxy).
  • Optional session: cookies (array) or storageState (Playwright JSON) so you can pass a logged-in browser export when TikTok shows login/captcha; treat values as secrets.

How to use on Apify

  1. Push tiktok-scraper/ as an Actor (or connect Git subfolder).
  2. Build from Dockerfile.
  3. Set input (see below). Use RESIDENTIAL proxy and a long timeout for larger maxItems.
  4. StartDataset.

Input (example)

{
"hashtags": ["bananas"],
"profiles": ["tiktok"],
"searchQueries": ["ootd"],
"resultsPerPage": 15,
"maxItems": 25,
"scrollRoundsPerSeed": 12,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"]
}
}

Local

pip install -r requirements.txt
playwright install chromium
python main.py

Uses INPUT.json when Apify input is empty (same pattern as other CloudBots actors).

Output

One dataset item per video, including:

  • webVideoUrl, id, text, createTimeISO
  • authorMeta: name, nickName, profileUrl, fans, etc.
  • diggCount, playCount, commentCount, shareCount, collectCount
  • musicMeta, videoMeta
  • sourceType / sourceValue (which seed produced the link)
  • error if that video failed after retries

Limitations

  • Apify Proxy on SDK 3.x must use Actor.create_proxy_configuration(actor_proxy_input=...) (keyword-only). If you see takes 1 positional argument but 2 were given in logs, upgrade this Actor’s main.py—proxy was disabled and TikTok will often block.
  • TikTok anti-bot is aggressive; expect blocks without working residential proxy and sober rate limits. Optional cookies / storageState help when you supply a valid session, but cookies expire and IP/proxy must still match what TikTok expects or the session may be rejected.
  • Not feature parity with clockworks/tiktok-scraper (no video file downloads to KV in v0.1, no followers graph, etc.).
  • DOM/API shapes change; empty datasets may need selector/JSON path updates.
  • Respect TikTok ToS, GDPR, and Apify guidelines.

FAQ

How does this relate to clockworks/tiktok-scraper?

Same problem space and similar input concepts; different codebase. Use the Store Actor if you want Apify-maintained scale; use this if you want in-repo control.

Do I need an official TikTok API key?

No; this reads public web data like typical scrapers.

SEO Keywords

tiktok scraper apify
tiktok video metadata
tiktok hashtag scraper

Actor permissions

Designed for limited scope: default dataset + input only.

License

MIT (this Actor code).

Get started

Push to Apify, enable RESIDENTIAL proxy, start with small maxItems, then scale.