What a TikTok scraper does
A TikTok scraper turns what you see in the app into rows you can work with: a video’s caption, views, likes, comments and shares; a creator’s bio, follower count and every post; the comments under a video; the results of a search. People scrape TikTok to find creators, track competitors, research trends, monitor their own brand and build datasets for analysis or AI.
There are three ways to do it. You can write your own scraper with a headless browser or an open-source library, use a no-code scraping platform, or call a scraper API that already handles TikTok and returns JSON. This guide covers all three honestly, then shows how to scrape each kind of TikTok data with working code.
Three ways to scrape TikTok
| Approach | How it works | Good for | What breaks |
|---|---|---|---|
| Your own scraper | Playwright or Selenium loads tiktok.com, or a library such as TikTokApi calls the web endpoints | Learning, small one-off pulls | Signatures (X-Bogus, msToken), IP blocks, login walls, layout changes |
| No-code platforms | A hosted actor runs a browser for you and saves the results to a dataset | Occasional exports without code | Slow runs, compute-based pricing, results only after the run ends |
| Scraper API | One HTTPS request per item; the provider runs devices, signing and egress | Products, pipelines, anything that must keep working | You depend on the provider, so pick one that does not bill failures |
If you only need a few hundred videos once, any of the three works. If the data feeds a product, a dashboard or a daily job, the maintenance cost of a home-made scraper is the real price, and that is where an API pays for itself.
What you can scrape
| Data | Endpoint | Cost per call | Plan |
|---|---|---|---|
| Video details and stats | /v1/video | 1 req | Every plan |
| Up to 50 videos at once | /v1/video/batch | 1 req / item | Every plan |
| Profile: bio, counts, links | /v1/user | 1 req | Every plan |
| Every post of a profile | /v1/user/posts | 1 req per page | Every plan |
| Comments and replies | /v1/video/comments, /comments/replies | 1 req per page | Every plan |
| Followers and followings | /v1/user/followers, /followings | 2 reqs per page | Every plan |
| Search: videos, users, LIVE, sounds, places | /v1/search | 1 req per page | Every plan |
| Hashtag and its videos | /v1/hashtag | 1 req | Every plan |
| Sound and the videos using it | /v1/music | 1 req | Every plan |
| Transcript of a video | /v1/video/transcript | 1 req | Every plan |
| Video file without watermark | /v1/video/no-watermark | 1 req | Every plan |
| LIVE rooms and chat | /v1/live/room, /v1/live/chat | 2 reqs | Every plan |
Everything is read from TikTok’s mobile app API, the same data the app shows, so counts match what users see and fields like sec_uid and aweme_id are the IDs TikTok itself uses.
Try it on a real creator
Type any public @username. This runs the creator audit endpoint live and shows the account’s engagement rate, posting cadence and reach from its recent posts. No signup needed.
GET /v1/user/audit.Free in your browser — 15 live runs every 10 minutes, zero signup required. Automating at scale? Start Free (100 requests) →
Your first request
Create a free key at tikultra.com/signup, then call /v1/user/posts with a username. The examples below are generated from the live endpoint definition: the TypeScript and Python SDKs, cURL, plain Python and JavaScript.
import { TikUltra } from 'tikultra'
const client = new TikUltra({ apiKey: process.env.TIKULTRA_KEY })
const res = await client.user.posts({ username: 'tiktok' })
console.log(res.data)GET /v1/user/posts · 1 req per call| Parameter | Type | Required | What it does |
|---|---|---|---|
username | string | one of these | The @username, without the @. e.g. tiktok |
sec_uid | string | one of these | The stable account ID used by the mobile API. |
cursor | string | No | The cursor from the previous page. Omit it for the first page. |
count | integer | No | Items per page. e.g. 20 |
sort | string | No | latest or popular. e.g. latest |
{
"context_id": "ctx_d6f929112c074f698e32",
"cursor": null,
"has_more": false,
"items": [
{
"aweme_id": "7693184538704416031",
"desc": "Real conversations happen on TikTok, and protecting the integrity of elections is a top priority. 🗳️🔐 Through dedicated in-app Election Centers and global fact-checking partnerships, TikTok connects y...",
"music_id": "7693184700604599071",
"author_uid": "107955",
"author_unique_id": "tiktok",
"collect_count": 2334,
"comment_count": 4608,
"cover_url": "https://p16-common-sign.tiktokcdn-eu.com/tos-useast8-p-0068-tx2/oUqGIH7EADEdBAAAQXXCfFX46EVf7QkZR6wJMA~tplv-tiktokx-cropcenter-q:300:400:q70.heic?dr=9232&refresh_token=1c86ab1d&x-expires=1794499200&x-...",
"create_time": 1791209149,
"digg_count": 23887
},
{
"aweme_id": "7694797676306615583",
"desc": "this summer gave us pop songs, glam routines, and a few main-character habits. @McCall Mirabella breaks down this summer's souvenirs 🐬☀️",
"music_id": "7694797733856660255",
"author_uid": "107955",
"author_unique_id": "tiktok",
"collect_count": 2004,
"comment_count": 6115,
"cover_url": "https://p16-common-sign.tiktokcdn-us.com/tos-useast8-p-0068-tx2/osDEKIayAATxid4XIifhL1BBXAZ8wiCZcATiAJ~tplv-tiktokx-cropcenter-q:300:400:q70.heic?dr=8596&refresh_token=3472f9e6&x-expires=1794495600&x-...",
"create_time": 1791584711,
"digg_count": 21728
}
],
"posts": [
{
…
}Every list endpoint answers in the same shape: the items, a cursor and has_more. Pass the cursor back to get the next page until has_more is false. One pagination loop works for posts, comments, followers and search.
Scrape a profile and all its posts
This is the most common job: a creator’s profile plus every video they have posted. Install the SDK with pip install tikultra, set TIKULTRA_KEY, and run:
import csv
from tikultra import TikUltra
client = TikUltra()
username = "tiktok"
profile = client.user.profile(username)["user"]
print(profile["nickname"], profile["follower_count"], "followers")
rows = []
for page in client.paginate("/v1/user/posts", params={"username": username, "count": 50}):
for v in page["items"]:
rows.append({
"aweme_id": v["aweme_id"],
"created": v["create_time"],
"caption": v["desc"],
"likes": v["digg_count"],
"comments": v["comment_count"],
"saves": v["collect_count"],
})
with open(f"{username}_posts.csv", "w", newline="", encoding="utf-8") as f:
w = csv.DictWriter(f, fieldnames=rows[0].keys())
w.writeheader()
w.writerows(rows)
print(len(rows), "posts saved")client.paginate follows the cursor for you and stops when has_more is false. count asks for up to 50 items per page, which keeps the number of calls low. Pass sort="popular" to get a creator’s most-liked posts first.
Scrape videos from links
If you already have links, from a spreadsheet, a campaign brief or a list of mentions, use /v1/video with the link or the numeric aweme_id. Short links (vm.tiktok.com, vt.tiktok.com) work too. For many videos, /v1/video/batch takes up to 50 IDs in one request and bills per video.
links = [
"https://www.tiktok.com/@tiktok/video/7693184538704416031",
"https://vm.tiktok.com/ZMexample/",
]
for link in links:
v = client.video.get(url=link)
print(v["aweme_id"], v["statistics"]["play_count"], "plays")
# many IDs at once (up to 50 per call)
batch = client.video.batch(["7693184538704416031", "7694797676306615583"])To turn any link or @handle into typed IDs first, call /v1/resolve. It recognizes video, profile, LIVE, sound, hashtag and Shop links.
Scrape search results and hashtags
/v1/search covers every tab of TikTok search: top, videos, users, LIVE, hashtags, sounds, photos and places. Filter by publish_time to keep only recent videos and set sort_type=1 for the most liked.
GET /v1/search · 1 req per call| Parameter | Type | Required | What it does |
|---|---|---|---|
keyword | string | Yes | What to search for. e.g. capcut template |
type | string | No | What to search. e.g. videos |
sort_type | string | No | 0 relevance, 1 most liked. e.g. 0 |
publish_time | string | No | 0 any time, 1 day, 7 week, 30 month, 90 or 180. e.g. 0 |
cursor | string | No | The cursor from the previous page. Omit it for the first page. |
count | integer | No | Items per page. e.g. 20 |
seen = {}
for page in client.paginate("/v1/search", params={
"keyword": "desk setup",
"type": "videos",
"publish_time": "7", # last 7 days
"count": 50,
}, max_pages=10):
for r in page["results"]:
v = r["aweme_info"]
seen[v["aweme_id"]] = v["statistics"]["play_count"]
top = sorted(seen.items(), key=lambda x: x[1], reverse=True)[:20]
print(top)For hashtags, /v1/hashtag returns the hashtag’s view count and its videos; /v1/hashtag/trending returns what is trending by category. /v1/music does the same for sounds, which is how trend tools spot a sound before it peaks. See the trends guide for a full trend tracker.
Comments, followers and transcripts
Comments page exactly like posts: /v1/video/comments with an aweme_id, then /v1/video/comments/replies for threads. Follower lists come from /v1/user/followers and /v1/user/followings. Transcripts come from /v1/video/transcript as time-coded segments, which is the fastest way to know what a video actually says. Each has its own guide:
- TikTok comment scraper: export every comment and reply to CSV, pick giveaway winners, find buying questions.
- TikTok follower scraper: export follower lists, compare two audiences, spot fake followers.
- TikTok transcript API: captions and speech-to-text for any public video.
Scraping at scale
There are two ways to run large jobs. For steady pipelines, call the API concurrently up to your plan’s rate limit. For big one-off pulls, submit a batch job of up to 500 tasks and get a webhook when it is done.
| Plan | Rate limit | Requests a month | Standard reads a day at full rate |
|---|---|---|---|
| Starter | 20 req/s | 40,000 | 1,728,000 |
| Growth | 75 req/s | 175,000 | 6,480,000 |
| Scale | 250 req/s | 750,000 | 21,600,000 |
import asyncio
from tikultra import AsyncTikUltra
async def main(usernames):
client = AsyncTikUltra()
sem = asyncio.Semaphore(15) # stay under your plan's req/s
async def one(u):
async with sem:
return await client.user.profile(u)
results = await asyncio.gather(*(one(u) for u in usernames), return_exceptions=True)
await client.aclose()
return results
profiles = asyncio.run(main(["tiktok", "zachking", "khaby.lame"]))tasks = [{"path": "/v1/user", "query": {"username": u}} for u in usernames[:500]]
job = client.jobs.submit(tasks, webhook_url="https://example.com/hooks/tikultra")
print(job["id"], job["state"])
done = client.jobs.wait(job["id"], timeout=600) # or wait for the webhook
for r in done["results"]:
...Batch jobs are on Starter and up. Each task is billed like the same call made directly, and failed tasks are refunded.
Why home-made TikTok scrapers break
If you have tried scraping TikTok yourself, you have probably met one of these. They are why most open-source TikTok scrapers stop working a few weeks after their last update.
- Request signatures. The web app signs requests with
X-Bogus,X-Gnarlyand a rotatingmsToken. The mobile app signs every request withX-Argus,X-Gorgon,X-KhronosandX-Ladon, computed from the device and the request body. Wrong or stale signatures return empty lists rather than errors, which is easy to miss. - Device identity. Mobile endpoints expect a registered device (device ID and install ID) with a believable history. Fresh or reused IDs get thinner results or verification challenges.
- IP reputation. Datacenter IPs are throttled or blocked quickly. Residential proxies help but cost money per gigabyte and still get flagged when overused.
- Login walls. Some lists, such as followers and parts of search, return less data, or nothing, to logged-out web sessions.
- Expiring media. Video and image URLs are signed and expire, so storing a URL is not the same as storing the file.
A scraper API solves these once for everyone. Tikultra runs real mobile device contexts with their own signing and egress, picks a working region for each call and retries on its side, so your code only sees a clean response or a clear error. If you would rather keep your own scraper and only need signatures, the X-Argus signing guide covers that route.
Understanding the data
| Field | What it is | Tip |
|---|---|---|
aweme_id | The video ID, a 19-digit number | Its first bits encode the upload time; the ID converter decodes it |
unique_id | The @username | Can change; do not use it as a primary key |
sec_uid | Stable account ID used by the mobile API | Store this to follow an account across username changes |
uid | Numeric user ID | Also stable; some endpoints accept it |
create_time | Unix time in seconds | Convert with datetime.fromtimestamp(t, tz=timezone.utc) |
digg_count | Likes (TikTok calls them diggs) | collect_count is saves, share_count shares |
cursor, has_more | Pagination | Keep looping while has_more is true |
What scraping TikTok costs
Requests are the unit. Most reads cost 1 req; heavier calls such as followers and LIVE cost 2 reqs. A few examples on Growth:
| Job | Requests | Cost on Growth |
|---|---|---|
| 1,000 creators: profile plus their latest 150 posts | 4,000 | $3.63 |
| Every comment on 200 videos (20 pages each) | 4,000 | $3.63 |
| A keyword search checked every hour for 50 keywords | 1,200 a day | $1.09 a day |
| Plan | Monthly price | Requests included | Per 1,000 calls | Rate limit |
|---|---|---|---|---|
| Starter | $49 | 40,000 | $1.22 | 20 req/s |
| Growth | $159 | 175,000 | $0.91 | 75 req/s |
| Scale | $499 | 750,000 | $0.67 | 250 req/s |
Errors and retries
Failed calls are never billed. Retry on 429, 502 and 504 with a short backoff; a 404 means the video or profile is gone, private or region-locked, and retrying will not help.
| Status | Code | Meaning | Retry? |
|---|---|---|---|
| 400 | invalid_request | A parameter is missing or malformed. | No. Fix the request. |
| 401 | unauthorized | The key is missing, wrong or revoked. | No. |
| 402 | out_of_credits | Your balance can’t cover this call. | After a top-up. |
| 403 | forbidden | Your plan doesn’t include this endpoint. | No. Upgrade. |
| 404 | not_found | The video, profile or product doesn’t exist or isn’t visible. | No. |
| 409 | session_expired | A connected account needs to sign in again. | After re-connecting. |
| 429 | rate_limited | Over your plan’s requests per second. | Yes, after retry-after. |
| 502 | upstream_error | TikTok returned an error after our retries. | Yes, with backoff. |
| 504 | upstream_timeout | TikTok didn’t answer in time. | Yes, with backoff. |
TikTok scraper options compared
| Option | Pricing model | Speed | Notes |
|---|---|---|---|
| Tikultra | From $49/month, per request | Real-time, one call per item | Mobile API data, failed calls free, also Shop, LIVE and managed accounts |
| Apify TikTok actors | Per result or compute unit | Batch runs, minutes | No-code, results arrive when the run finishes |
| Bright Data | Per record, plus datasets | Batch collection | Large catalog of ready datasets, enterprise contracts |
| ScrapeCreators | Prepaid credit packs | Real-time | Many platforms, fewer TikTok endpoints; see the comparison |
| Open-source (TikTokApi, Playwright) | Free, plus proxies | Depends on you | Breaks when signatures or layouts change |
| Capability | Tikultra | TikAPI | EnsembleData | ScrapeCreators |
|---|---|---|---|---|
| TikTok endpoints | 233 | ≈ 60 | 20 | 28 |
| Price per 1,000 requests | $0.67–$1.22 standard (1 req) | ~$0.58–$3.00 (€0.53–€2.78) | $0.93–$2.22 (daily units) | $0.99–$1.88 |
| Failed or empty upstream calls | Never billed (0 reqs / $0) | — | Free | — |
| Free to start | 500 requests · 180 req/min (no card) | 5-day trial | 50 units / day | 100 requests |
| Native mobile request signing | 8 apps, 50+ releases (<1 ms) | — | — | — |
Prices checked 19 Nov 2026 on each vendor’s public pricing page; capabilities from their public API docs. A dash means the vendor’s public docs don’t list it (checked 19 Nov 2026). Full comparison
Is it legal to scrape TikTok?
Scraping publicly available data is lawful in many countries. In the US, the Ninth Circuit held in hiQ v. LinkedIn that scraping public pages is not unauthorized access under the CFAA. That does not make every use fine. Usernames and comments are personal data under laws like the GDPR, TikTok’s terms restrict automated access, and copyright applies to the videos themselves. Collect what you need, keep it secure, do not use it to harass or spam people, and get legal advice for your situation. Tikultra only reads public data and does not access private accounts or hidden lists.