# TikTok Scraper: Profiles, Videos & Comments (`tortuga/tiktok-scraper`) Actor

Get TikTok profile stats, video stats and comments for usernames and video URLs, logged out. Does not search or list a profile's videos. Track follower and video counts on a schedule.

- **URL**: https://apify.com/tortuga/tiktok-scraper.md
- **Developed by:** [Trevor Ortega](https://apify.com/tortuga) (community)
- **Categories:** Social media, Videos
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.60 / 1,000 profiles

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## TikTok Profile Stats, Video Stats & Comments Scraper

Get public TikTok **profile stats**, **video stats** and **comments** for the usernames and video URLs you already have. Logged out, no cookies, no account, JSON/CSV/Excel/API output.

**What it does not do (read this first):** it does **not** search TikTok, it does **not** scrape hashtag or sound pages, and it does **not** list a profile's videos. TikTok only serves those lists to signed, in-app requests, and this Actor does not forge signatures, log in or solve challenges. If you need "all videos of @creator" or "everything under #travel", use a different Actor. If you have the usernames and the video links, this one is cheaper.

### What you can do with it

- **Bulk creator vetting**: paste hundreds of usernames, get followers, following, total likes, video count, bio, bio link, verified flag, account creation date, region (when TikTok shows one) in one table.
- **Track creators over time**: schedule it with `onlyNewOrChanged` and get a row only when a creator's followers, video count, bio, name or verified status changed.
- **Video stats for known URLs**: plays, likes, comments, shares, saves, caption, hashtags, mentions, sound, duration, posting date and the author's follower count.
- **Comment export**: top-level comments and optionally replies for any video URL, with author username, likes, reply count and date.

### Input

| Field | Meaning |
|---|---|
| `profiles` | Usernames, `@handles` or profile URLs, one per line |
| `videoUrls` | Video or photo-post URLs (or numeric video IDs), one per line |
| `includeVideoStats` | On by default. Turn off for comments only (no video row, no video charge) |
| `maxCommentsPerVideo` | Top-level comments per video URL. `0` (default) = none |
| `includeReplies`, `maxRepliesPerComment` | Also export replies under each exported comment |
| `maxItems` | Hard cap on rows for the whole run (profiles + videos + comments + replies), default 100 |
| `onlyNewOrChanged`, `monitoringKey` | Monitoring mode, see below |
| `proxyConfiguration` | Apify datacenter proxy by default |

Short links (`vm.tiktok.com`, `vt.tiktok.com`), `/tag/`, `/search` and `/music/` URLs are not supported and are reported in the run summary.

Example input:

```json
{
  "profiles": ["tiktok", "khaby.lame", "https://www.tiktok.com/@nasa"],
  "videoUrls": ["https://www.tiktok.com/@tiktok/video/7106594312292453675"],
  "maxCommentsPerVideo": 100,
  "includeReplies": false,
  "maxItems": 500
}
```

### Output

Every row has a `type`: `profile`, `video` or `comment`. The dataset has one view per type.

#### Profile rows

| Field | Example |
|---|---|
| `username`, `userId`, `secUid`, `nickname` | `tiktok`, `107955`, ... , `TikTok` |
| `followerCount`, `followingCount`, `likeCount`, `videoCount`, `friendCount` | exact integers |
| `bio`, `bioLink` | text and the link in the bio |
| `verified`, `privateAccount`, `isOrganization`, `isCommerceAccount`, `category` | flags / business category |
| `region`, `language` | filled only when TikTok shows them on the page |
| `accountCreatedAt` | ISO date of account creation |
| `avatarUrl`, `profileUrl` | |

Private accounts still return their public card (counts and bio) with `privateAccount: true`.

#### Video rows

`videoId`, `videoUrl`, `text` (caption), `createdAt`, `playCount`, `likeCount`, `commentCount`, `shareCount`, `saveCount`, `repostCount`, `hashtags`, `mentions`, `durationSec`, `width`, `height`, `isPhotoPost`, `isAd`, `locationCreated`, `categories`, `musicId`, `musicTitle`, `musicAuthor`, `musicIsOriginal`, `coverUrl`, `authorUsername`, `authorId`, `authorNickname`, `authorVerified`, `authorFollowerCount`, `authorUrl`.

Example (shortened):

```json
{
  "type": "video",
  "videoId": "7106594312292453675",
  "text": "how many frogs did you find? #Minecraft @Gorillo",
  "createdAt": "2022-06-07T20:15:29Z",
  "playCount": 593900,
  "likeCount": 98900,
  "commentCount": 1268,
  "shareCount": 361,
  "saveCount": 59268,
  "hashtags": ["minecraft"],
  "authorUsername": "tiktok"
}
```

#### Comment rows

`commentId`, `videoId`, `videoUrl`, `text`, `createdAt`, `likeCount`, `replyCount`, `isReply`, `parentCommentId`, `language`, `isPinned`, `likedByCreator`, `authorUsername`, `authorNickname`, `authorId`, `authorSecUid`, `authorUrl`, `authorAvatarUrl`.

Commenter names and handles are exported as TikTok shows them publicly. Comments come in TikTok's default order (not strictly newest first); TikTok removes some low-quality comments from the list, so the exported count can be a little lower than the comment count shown on the video.

### Pricing

Pay per result, three events:

| Event | Price |
|---|---|
| Profile | $0.002 |
| Video | $0.002 |
| Comment or reply | $0.0007 |

You pay only for rows saved to the dataset. Missing, deleted or unavailable profiles and videos are not charged. Set `maxItems` to cap a run.

### Monitor changes on a schedule

Turn on `onlyNewOrChanged` and put the Actor on an Apify Schedule (save the input as a Task). The Actor remembers what earlier runs returned and outputs only what changed: a profile when its followers, following, video count, bio, name, username, private or verified status changed; a video when its plays, likes, comments, shares or saves changed; a comment only when it is new. Unchanged rows are not output and not charged. Changed rows carry `changeType` (`new` or `changed`) and `previousValues` with the old values, so you can compute growth. Use `monitoringKey` to keep several watches over the same accounts separate. Note that the counts of a busy creator change between almost any two runs, so expect most big accounts to show up as changed on every run; this mode is best for small and mid-size accounts, for new-comment alerts, and for bio/verification changes.

### How to scrape TikTok profile stats without logging in

Paste usernames into `profiles` and run. The Actor reads the public profile page that TikTok serves to any logged-out visitor. No account, session cookie or token is needed from you.

### Does this work without a login?

Yes. It never logs in, never uses cookies of an account, never solves a CAPTCHA and does not compute TikTok's request signatures. It only uses pages and endpoints that answer unsigned requests. That is also why search, hashtags and profile video lists are out of scope.

### How to export TikTok comments

Put video URLs in `videoUrls`, set `maxCommentsPerVideo` (for example 500), optionally turn on `includeReplies`, and switch off `includeVideoStats` if you only want comments. Each comment or reply is one result at $0.0007.

### Is it legal?

It collects only public information that TikTok shows to anyone without an account: profile cards, public video statistics and public comments. Do not use the data to profile private individuals or in ways that break the law that applies to you (GDPR and similar rules cover personal data such as usernames and comment text). Check TikTok's terms and your own use case.

### Limits and honest caveats

- No search, no hashtag pages, no profile video lists, no followers/following lists, no private content.
- TikTok changes its pages and may start requiring signed requests for the comment endpoint; the Actor then reports a clear error in the run summary instead of returning partial junk.
- Counts such as plays are as shown by TikTok at request time (exact numbers, not "1.2M" roundings).
- Region and language are shown only for some accounts.
- Video cover and avatar URLs are signed CDN links that expire after a while; download images soon after the run if you need them.

### Support

Open an issue on the Actor page with a run URL and the input you used.

### Related scrapers

- [YouTube Scraper](https://apify.com/tortuga/youtube-scraper): Channels, Videos, Shorts & Search
- [Twitch Scraper](https://apify.com/tortuga/twitch-scraper): Channels, Streams, Clips & Top Games
- [TikTok Shop Scraper](https://apify.com/tortuga/tiktok-shop-scraper): Products, Prices & Sales
- [Bilibili Scraper](https://apify.com/tortuga/bilibili-scraper): Videos, Comments & Search
- [Naver Scraper](https://apify.com/tortuga/naver-scraper): Blog, Cafe & News Posts from Korea

### Found it useful?

A ★ review on this Actor's Apify Store page helps other users find it and tells us what to improve. Issues and feature requests are welcome in the Actor's **Issues** tab.

# Actor input Schema

## `profiles` (type: `array`):

One per line: a username (`khaby.lame`), an @handle, or a profile URL (`https://www.tiktok.com/@khaby.lame`). Each profile gives one row with followers, following, likes, video count, bio and verified status. The Actor does not list a profile's videos; add video URLs below for those.

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

One per line: video or photo-post URLs (`https://www.tiktok.com/@tiktok/video/7106594312292453675`) or bare numeric video IDs. Each gives one row with plays, likes, comments, shares, saves, caption, hashtags, music, duration, date and author. Short links (vm.tiktok.com) are not supported: open them in a browser and paste the full URL.

## `includeVideoStats` (type: `boolean`):

Turn off to export only comments for the video URLs (no video row, no video page request, no video charge). Needs Max comments per video above 0.

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

Export this many top-level comments for every video URL, in TikTok's default order. 0 = no comments. Each comment is a separate charged result.

## `includeReplies` (type: `boolean`):

Also export the replies under each exported comment (each reply is one charged result with `parentCommentId`).

## `maxRepliesPerComment` (type: `integer`):

With Include replies on: at most this many replies per comment. Leave empty for all replies.

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

Stop the whole run after this many rows (profiles, videos, comments and replies together). This caps your cost.

## `onlyNewOrChanged` (type: `boolean`):

Remember what earlier runs returned and output only new or changed rows. Profiles are reported when followers, following, video count, bio, name or verified status change; videos when plays, likes, comments, shares or saves change; comments only when new. Use with a Schedule; unchanged rows are not charged.

## `monitoringKey` (type: `string`):

Name for this watch, so several schedules on the same accounts stay separate; defaults to a key derived from the input

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

Apify Proxy (datacenter) works for profile pages, video pages and comments and is the cheapest option. Each profile or video page is about 400 KB on the wire; comment pages about 60 KB.

## Actor input object example

```json
{
  "profiles": [
    "tiktok",
    "khaby.lame",
    "nasa"
  ],
  "videoUrls": [
    "https://www.tiktok.com/@tiktok/video/7106594312292453675"
  ],
  "includeVideoStats": true,
  "maxCommentsPerVideo": 20,
  "includeReplies": false,
  "maxItems": 100,
  "onlyNewOrChanged": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

No description

# 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 = {
    "profiles": [
        "tiktok",
        "khaby.lame",
        "nasa"
    ],
    "videoUrls": [
        "https://www.tiktok.com/@tiktok/video/7106594312292453675"
    ],
    "maxCommentsPerVideo": 20,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("tortuga/tiktok-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 = {
    "profiles": [
        "tiktok",
        "khaby.lame",
        "nasa",
    ],
    "videoUrls": ["https://www.tiktok.com/@tiktok/video/7106594312292453675"],
    "maxCommentsPerVideo": 20,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("tortuga/tiktok-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 '{
  "profiles": [
    "tiktok",
    "khaby.lame",
    "nasa"
  ],
  "videoUrls": [
    "https://www.tiktok.com/@tiktok/video/7106594312292453675"
  ],
  "maxCommentsPerVideo": 20,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call tortuga/tiktok-scraper --silent --output-dataset

```

## MCP server setup

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