To scrape TikTok comments, give a ready-made Actor a video URL, a profile, a hashtag or a search term, and set how many comments you want per video. It returns each video with its stats and its comments: text, time, likes, reply count and whether the creator liked or pinned the comment. On Scrape.ly that's one input field and one click, or one API call, with no TikTok login and no Research API application.
This guide covers the fields you get, the no-code steps, the same job in curl, Python, Node.js and through an AI agent, real runs from 27 October 2026 (13 comments from the verified Duolingo and NASA accounts, and a fresh National Geographic video that had no comments yet), and the exact costs.
What data you can get from TikTok comments
The TikTok Scraper saves one row per video and, when you ask for comments, attaches them to it (comments) and stores them in their own dataset (commentsDatasetUrl). Each comment carries:
| Field | What it holds |
|---|---|
cid | Comment ID |
text | The comment text |
createTime, createTimeISO | When it was posted |
diggCount | Likes on the comment |
replyCommentTotal | How many replies it has |
likedByAuthor, pinnedByAuthor | Whether the video's creator liked or pinned it |
uid, uniqueId, avatarThumbnail | The commenter's ID, handle and avatar |
The video row around the comments adds the context you need to read them: caption, createTimeISO, playCount, diggCount, shareCount, commentCount, collectCount, hashtags, music and the author's profile with verified and follower count. Set maxRepliesPerComment and the Actor also collects replies under each comment.
How to scrape TikTok comments without code
- Open the TikTok Scraper in the Scrape.ly Store.
- Fill one source: Video URLs (
postURLs) for specific videos, Profiles for an account's newest videos, or Hashtags and Search queries for a topic. The profile preset is a quick start. - Set Max comments per video (
commentsPerPost) to the number you want. It's0, off, by default. This is the input behind the reused run below:
{
"profiles": ["duolingo", "nasa"],
"resultsPerPage": 4,
"excludePinnedPosts": true,
"commentsPerPost": 2
}- Click Start. That run took 15 seconds for eight videos and 13 comments.
- Open the dataset and export it as JSON, CSV or Excel. Each video's comments also sit in their own dataset, linked from
commentsDatasetUrl, so you can export comments alone.
The input fields that matter most:
postURLs: full video links or short share links. The most direct way to get one video's comments.profiles,hashtags,searchQueries: find the videos first;resultsPerPagesets how many per source.commentsPerPost: comments per video, replies included.topLevelCommentsPerPost: a separate cap on top-level comments, when you want more threads and fewer replies.maxRepliesPerComment: replies to collect under each comment.0skips replies.oldestPostDateUnified,excludePinnedPosts: limit a profile to recent videos and skip the pinned ones.proxyCountryCode: browse from a given country through a residential proxy when the audience sits in one market.
How to scrape TikTok comments with the API
Create a token under Settings → API & Integrations in the dashboard and store it as SCRAPELY_TOKEN. Our runs took 7 to 15 seconds, inside the synchronous endpoint's 45-second wait:
curl -X POST "https://api.scrape.ly/v2/actors/echofield~tiktok-scraper/run-sync-get-dataset-items" \
-H "Authorization: Bearer $SCRAPELY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"profiles": ["duolingo"], "resultsPerPage": 3, "excludePinnedPosts": true, "commentsPerPost": 20}'For dozens of videos with hundreds of comments each, start the run asynchronously so a 408 timeout can't tempt you into starting a second run: POST /v2/actors/echofield~tiktok-scraper/runs, poll /v2/actor-runs/RUN_ID?waitForFinish=60 until SUCCEEDED, then read /v2/actor-runs/RUN_ID/dataset/items. The API docs show the full flow.
In Python (pip install scrapely-client-python), this script pulls up to 100 comments from each of a list of videos and writes the most-liked ones to a CSV for audience research, without the commenters' handles:
import csv
import os
from scrapely_client import ScrapelyClient
client = ScrapelyClient(os.environ["SCRAPELY_TOKEN"], api_url="https://api.scrape.ly")
run = client.actor("echofield/tiktok-scraper").call(
run_input={
"postURLs": [
"https://www.tiktok.com/@ACCOUNT_1/video/VIDEO_ID_1",
"https://www.tiktok.com/@ACCOUNT_2/video/VIDEO_ID_2",
],
"commentsPerPost": 100,
}
)
with open("tiktok_comments.csv", "w", newline="") as f:
w = csv.writer(f)
w.writerow(["video", "posted", "likes", "replies", "text"])
for video in client.dataset(run.default_dataset_id).iterate_items():
top = sorted(video.get("comments") or [], key=lambda c: c["diggCount"], reverse=True)
for c in top[:20]:
w.writerow([video["webVideoUrl"], c["createTimeISO"], c["diggCount"], c["replyCommentTotal"], c["text"]])In JavaScript or Node.js (npm install scrapely-client), measure how often a brand engages with its own comment section across its newest videos:
import { ScrapelyClient } from 'scrapely-client';
const client = new ScrapelyClient({ token: process.env.SCRAPELY_TOKEN, baseUrl: 'https://api.scrape.ly' });
const run = await client.actor('echofield/tiktok-scraper').call({
profiles: ['duolingo'],
resultsPerPage: 10,
excludePinnedPosts: true,
commentsPerPost: 30,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
const comments = items.flatMap((v) => v.comments ?? []);
const liked = comments.filter((c) => c.likedByAuthor).length;
console.log(`${comments.length} comments, ${liked} liked by the creator`);The TikTok API page shows the same Actor as a ready-made API, and the Python client docs cover paging through large datasets.
With an AI agent (MCP)
Scrape.ly runs a hosted MCP server at https://mcp.scrape.ly. In Cursor, add it to ~/.cursor/mcp.json:
{
"mcpServers": {
"scrapely": {
"url": "https://mcp.scrape.ly",
"headers": { "Authorization": "Bearer YOUR_TOKEN" }
}
}
}In Claude Code, run claude mcp add --transport http scrapely https://mcp.scrape.ly, then /mcp to sign in with OAuth. Then ask: "Use scrapely to get 50 comments from each of @duolingo's five newest TikTok videos and summarise what viewers ask about most." Our TikTok MCP guide goes deeper on agent workflows, and the MCP docs list every supported client.
Real runs: Duolingo, NASA and a brand-new National Geographic video
We reused a run started earlier on 27 October 2026 for our TikTok MCP guide: four recent videos each from the verified @duolingo and @nasa accounts, two comments per video. It saved 8 videos and 13 comments in 15.1 seconds. Commenters are private people, so we show them as [commenter 1] and so on:
| Commenter | Video by | Posted (UTC) | Likes | Replies | Comment |
|---|---|---|---|---|---|
| [commenter 4] | @duolingo | 2026-10-26 15:40 | 444 | 20 | day 8 of asking duo if he's proud of me |
| [commenter 5] | @duolingo | 2026-10-26 20:38 | 582 | 4 | Every time I try Duolingo I learn nothing |
| [commenter 2] | @duolingo | 2026-10-27 10:27 | 0 | 1 | song name |
| [commenter 10] | @nasa | 2026-10-20 21:01 | 184 | 4 | Is it true that the aliens are on earth |
| [commenter 9] | @nasa | 2026-10-24 19:26 | 7 | 3 | NASA, if there is a sun in space, how can space be dark? |
We also ran the Actor twice on the verified @natgeo account, asking for 8 comments on its newest video. Both runs picked a video posted at 16:06 UTC, three minutes before the first run started. It had 417 plays, 41 likes and no comments yet:
2026-10-27T16:09:33.587Z [Scrapely] Container started (setup 1.3 s)
2026-10-27T16:09:35.128Z [scrapely.proxy_configuration] INFO Platform proxy access check succeeded.
2026-10-27T16:09:43.017Z [scrapely.actor] INFO [Status message]: Saved 1 item.
2026-10-27T16:09:43.476Z [Scrapely] Container state: status=exited exitCode=0 oomKilled=falseWhat the comments and the empty video show:
- The creator rarely joins in. None of the 13 comments was liked or pinned by Duolingo or NASA (
likedByAuthorandpinnedByAuthorwere all false). Across a few hundred comments that ratio becomes a real engagement benchmark between brands. - Reply counts point to the threads that matter. "day 8 of asking duo if he's proud of me" had 20 replies; a NASA comment from a viewer whose mom spotted something at 5 am had 13. Sort by
replyCommentTotal, then rerun those videos withmaxRepliesPerCommentto read the conversations. - Comment sections have themes. Five of NASA's eight comments asked about aliens or what NASA is "hiding". Duolingo's were about the mascot and the videos themselves, plus a "song name" request, which is a signal for the music team. That's what topic clustering on
textpicks up at scale. - Order isn't strictly newest-first. On several videos the first comment returned was older than the second. Sort by
createTimeISOordiggCountyourself rather than relying on position. - You may get fewer than you ask for. One Duolingo video with 3,725 comments returned none in this run, and another returned one of two. TikTok doesn't always hand over comments for every video; ask for a margin and check counts.
- Fresh videos cost almost nothing. The National Geographic runs saved only the video row. No comments, no comment charges.
What it costs
The TikTok Scraper charges per event, platform usage (compute and proxy) included. Prices checked on the Store page on 27 October 2026: $0.00201 per video and $0.000593 per comment ($0.593 per 1,000 comments).
The reused run: 8 × $0.00201 + 13 × $0.000593 = $0.0238 at list price. Each National Geographic run: one video, $0.00201 at list price. The account that ran them has a plan Store discount, so it was billed a little less.
At scale: 100 comments from each of 50 videos is 50 × $0.00201 + 5,000 × $0.000593 = $3.07. Comments are the main cost, so set commentsPerPost to what you'll actually read.
What to watch out for
- TikTok decides how many comments you see. The Actor's docs say "TikTok may return fewer for videos with many comments", and replies aren't always complete either. Plan for samples, not complete archives, on viral videos.
- Brand-new videos have nothing to read. Wait a day or two after posting, or filter with
oldestPostDateUnifiedand run on a schedule so each video is collected once its comment section has filled up. - Private accounts and dead links. They're skipped, named in the run's
OUTPUTrecord underfailedInputs, and never charged. The rest of the input still runs. - Spam and bots. Comment sections include emoji walls, self-promotion and copy-paste spam. Filter short or duplicated texts before you run sentiment on them.
- Handles are personal data.
uniqueId,uidand the avatar identify a person. Drop them unless you truly need them, and never publish them, as we did above.
TikTok's official route is the Research API, which includes a video comments endpoint. Its eligibility page requires applicants to "be independent of commercial interests and able to conduct research on a not-for-profit or non-commercial basis in pursuit of a public-interest mission". If you're a qualifying academic, apply. For brand, marketing and product work, the Actor is the practical path.
Is it legal to scrape TikTok comments?
The Actor reads only public videos and the comments any logged-out visitor can see. TikTok's U.S. Terms of Service (last updated July 15, 2026, read on 27 October 2026) say you may not "scrape, crawl, export or otherwise extract any data or content in any form, for any purpose, from the Platform using any automated system or software, including automated “bots,” except as approved in writing". Whether and how those terms bind you depends on your jurisdiction and your use.
Comments are personal data under the GDPR and similar laws: a handle and a comment history identify a person. Collect only what you need, aggregate where you can, pseudonymise commenters in anything you publish and don't republish comments at scale. Our guide to whether web scraping is legal covers the basics, including the GDPR. This is not legal advice; for a commercial project, ask a lawyer about your case.
Why Scrape.ly for TikTok comments
- No API approval. The Research API is for non-commercial researchers. The Actor needs a Scrape.ly token and nothing from TikTok.
- Videos and comments in one run. Find videos by profile, hashtag, search or URL and collect their comments in the same input, with each comment tied to the video's plays, likes and shares.
- You pay for comments that exist. A video without comments costs one video row, and failed inputs cost nothing.
- One platform for social listening. The same token runs YouTube comments, Instagram and Facebook comments and Pinterest pins and comments; our TikTok scraping and social media scraping guides show the bigger picture.
FAQ
Can you scrape TikTok comments for free?
Yes, for small jobs. The Free plan includes $5 of usage credit every month with no credit card. At list price that's roughly 8,000 comments, minus a fraction of a cent for each video row.
How do I scrape all comments from a TikTok video?
Put the video's URL in postURLs, set commentsPerPost high and add maxRepliesPerComment for replies. TikTok may still return fewer comments than the counter shows on very large videos.
Can I scrape TikTok comment replies?
Yes. Set maxRepliesPerComment to the number of replies you want per comment. They count toward commentsPerPost; use topLevelCommentsPerPost to keep enough room for top-level comments.
Can I scrape comments from a whole profile or hashtag?
Yes. Use profiles or hashtags with resultsPerPage for the number of videos, and commentsPerPost for comments per video. Every video in the run gets its comments.
Do I need a TikTok account or API key?
No. The Actor reads public pages without logging in and uses Scrape.ly's residential proxy, already included in the price.
Can I scrape TikTok comments with Python?
Yes. Install scrapely-client-python and call echofield/tiktok-scraper with commentsPerPost, as in the CSV script above. The scraping runs in the cloud, so you don't maintain TikTok's request signing or proxies.




