# TikTok Scraper API: Posts, Profiles, Videos & Hashtags (`clair-api/tiktok-scraper-api`) Actor

Public TikTok posts, profiles, an account's recent videos, and a hashtag's videos as JSON. No login. Views, likes, shares, music, and author stats.

- **URL**: https://apify.com/clair-api/tiktok-scraper-api.md
- **Developed by:** [Clair API](https://apify.com/clair-api) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 1,000 posts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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 Scraper API: Posts, Profiles, Videos & Hashtags

Public TikTok posts, profiles, an account's recent videos, and a hashtag's videos as JSON. No login. Views, likes, shares, music, and author stats.

Built on [TikTok API](https://clair.im/apis/tiktok?utm_source=apify\&utm_medium=store\&utm_campaign=tiktok-scraper-api), a production
API that answers from live pages. Each input is one API call; calls run in
parallel, and every row lands in the dataset as soon as it is read.

### What it returns

#### Posts

video_id takes the post id or a tiktok.com/@user/video/ or /photo/ link. Share links (vm.tiktok.com, tiktok.com/t/) hide the id: open one and pass the address it lands on. Counts are as the post page shows them, which rounds large numbers (35,200 likes). A post that is gone or never existed returns 404.

Input `posts`: a post id, or a tiktok.com/@user/video/ or /photo/ link. Typical time: 1-3 s per call.

Sample row:

```json
{
  "input": "6718335390845095173",
  "endpoint": "tiktok",
  "video_id": "6718335390845095173",
  "url": "https://www.tiktok.com/@scout2015/video/6718335390845095173",
  "type": "video",
  "description": "Scramble up ur name & I’ll try to guess it😍❤️ #foryoupage #petsoftiktok #aesthetic",
  "published_at": "2019-07-27T13:32:38.000Z",
  "duration_ms": 10000,
  "cover": "https://p19-common-sign.tiktokcdn-us.com/tos-maliva-p-0068/2367c7d45cf54a1397abd0e72bf22eac~tplv-tiktokx-origin.image...",
  "images": [],
  "hashtags": [
    "foryoupage",
    "petsoftiktok",
    "… 1 more"
  ],
  "mentions": [],
  "language": "en",
  "country": "US",
  "is_ad": false,
  "ai_generated": false,
  "views_count": 159700,
  "likes_count": 35200,
  "comments_count": 5843,
  "shares_count": 1518,
  "saves_count": 649,
  "reposts_count": 0,
  "author": {
    "user_id": "53279706535428096",
    "username": "scout2015",
    "nickname": "Scout, Suki & Stella",
    "verified": true,
    "avatar": "https://p16-common-sign.tiktokcdn-us.com/tos-useast8-avt-0068-tx2/4cbe05e194623e3f19aef975d9fdf26c~tplv-tiktokx-cropc...",
    "url": "https://www.tiktok.com/@scout2015",
    "followers_count": 9000000,
    "likes_count": 108300000,
    "videos_count": 3079
  },
  "music": {
    "music_id": "6689804660171082501",
    "title": "original sound",
    "author": "tiff",
    "original": true,
    "duration_ms": 10000
  }
}
```

#### Profiles

username takes a name, @name, or a tiktok.com/@name link. Counts are exact. The account’s posts are the Videos endpoint. An account that is gone, banned, or never existed returns 404.

Input `profiles`: a username, @username, or tiktok.com/@name link. Typical time: 1-3 s per call.

Sample row:

```json
{
  "input": "nasa",
  "endpoint": "tiktok-profile",
  "user_id": "7664638705177150477",
  "sec_uid": "MS4wLjABAAAAU9BRVzC8oCaegVnia8IbqWhPb_-dbU7s00Y3wS1_Nx8g5RUaYvyXrpejgjdxTwd6",
  "username": "nasa",
  "nickname": "NASA",
  "url": "https://www.tiktok.com/@nasa",
  "bio": "Making the seemingly impossible, possible.✨",
  "bio_link": "https://science.nasa.gov/feature/artemis-ii-preliminary-lunar-science-report",
  "avatar": "https://p16-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/e5143212a59c09a008bf50f487d54d1f~tplv-tiktokx-cropce...",
  "verified": true,
  "private": false,
  "organization": true,
  "language": "en",
  "created_at": "2026-07-20T15:55:49.000Z",
  "followers_count": 2142079,
  "following_count": 23,
  "likes_count": 11400811,
  "videos_count": 60
}
```

#### Account videos

username takes a name, @name, or a tiktok.com/@name link. One request opens the profile in a browser and scrolls it, which takes 20 to 40 seconds and returns the posts that loads: all of a small account’s, about the 130 most recent of a large one. Pinned posts come first, then newest first. There is no next page. A private account returns its profile and no posts.

Input `accountVideos`: a username whose recent posts to list (about 130 at most). Typical time: 19-37 s per call.

Sample row:

```json
{
  "input": "nasa",
  "endpoint": "tiktok-videos",
  "profile": {
    "user_id": "7664638705177150477",
    "sec_uid": "MS4wLjABAAAAU9BRVzC8oCaegVnia8IbqWhPb_-dbU7s00Y3wS1_Nx8g5RUaYvyXrpejgjdxTwd6",
    "username": "nasa",
    "nickname": "NASA",
    "url": "https://www.tiktok.com/@nasa",
    "bio": "Making the seemingly impossible, possible.✨",
    "bio_link": "https://science.nasa.gov/feature/artemis-ii-preliminary-lunar-science-report",
    "avatar": "https://p16-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/e5143212a59c09a008bf50f487d54d1f~tplv-tiktokx-cropce...",
    "verified": true,
    "private": false,
    "organization": true,
    "language": "en",
    "created_at": "2026-07-20T15:55:49.000Z",
    "followers_count": 2181891,
    "following_count": 23,
    "likes_count": 11692402,
    "videos_count": 66
  },
  "position": 1,
  "video_id": "7665075736742530317",
  "url": "https://www.tiktok.com/@nasa/video/7665075736742530317",
  "type": "video",
  "description": "Something big just landed on TikTok.",
  "published_at": "2026-07-21T20:09:02.000Z",
  "duration_ms": 25000,
  "cover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-p-0068-tx/oAUhkWfCZC7g6ALj2HZgOeELFvIrALeFYOoGI4~tplv-tiktokx-or...",
  "images": [],
  "hashtags": [],
  "mentions": [],
  "language": "en",
  "country": null,
  "is_ad": false,
  "ai_generated": false,
  "views_count": 1800000,
  "likes_count": 111300,
  "comments_count": 3333,
  "shares_count": 3383,
  "saves_count": 8079,
  "reposts_count": 0,
  "author": {
    "user_id": "7664638705177150477",
    "username": "nasa",
    "nickname": "NASA",
    "verified": true,
    "avatar": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/e5143212a59c09a008bf50f487d54d1f~tplv-tiktokx-cropce...",
    "url": "https://www.tiktok.com/@nasa",
    "followers_count": 2200000,
    "likes_count": 11700000,
    "videos_count": 66
  },
  "music": {
    "music_id": "7665075815390645006",
    "title": "original sound",
    "author": "NASA",
    "original": true,
    "duration_ms": 25000
  }
}
```

#### Hashtags

hashtag takes a name, #name, or a tiktok.com/tag/ link. One request opens the hashtag in a browser and scrolls it, which takes 20 to 40 seconds and returns the posts TikTok shows a signed-out visitor: about 100 to 120, in TikTok’s own order, which favours popular posts. There is no next page. A hashtag nobody has used returns 404.

Input `hashtags`: a hashtag, with or without #, or a tiktok.com/tag/ link. Typical time: 22-37 s per call.

Sample row:

```json
{
  "input": "espresso",
  "endpoint": "tiktok-hashtag",
  "hashtag": {
    "hashtag_id": "667423",
    "name": "espresso",
    "url": "https://www.tiktok.com/tag/espresso",
    "description": null,
    "videos_count": 1530380,
    "views_count": 23813411517
  },
  "position": 1,
  "video_id": "7610593206064925959",
  "url": "https://www.tiktok.com/@zizi.ziza0/video/7610593206064925959",
  "type": "video",
  "description": "Espresso - Sabrina Carpenter #music #sabrinacarpenter #espresso #lyrics #foryou ",
  "published_at": "2026-02-25T23:00:03.000Z",
  "duration_ms": 175000,
  "cover": "https://p19-common-sign.tiktokcdn-us.com/tos-alisg-p-0037/oIQA5TtIQEIAfAjdbYgAJXQDRCMfDPA0f84nM4~tplv-tiktokx-origin....",
  "images": [],
  "hashtags": [
    "music",
    "sabrinacarpenter",
    "… 3 more"
  ],
  "mentions": [],
  "language": "en",
  "country": null,
  "is_ad": false,
  "ai_generated": false,
  "views_count": 536900,
  "likes_count": 23300,
  "comments_count": 247,
  "shares_count": 2403,
  "saves_count": 4667,
  "reposts_count": 0,
  "author": {
    "user_id": "7531412411753890834",
    "username": "zizi.ziza0",
    "nickname": "The final voice",
    "verified": false,
    "avatar": "https://p16-common-sign.tiktokcdn-us.com/tos-alisg-avt-0068/f78208cfcf42d9acbf945e5a4f2767b5~tplv-tiktokx-cropcenter:...",
    "url": "https://www.tiktok.com/@zizi.ziza0",
    "followers_count": 225300,
    "likes_count": 4500000,
    "videos_count": 259
  },
  "music": {
    "music_id": "7364498342501435408",
    "title": "Espresso",
    "author": "Sabrina Carpenter",
    "original": false,
    "duration_ms": 60000
  }
}
```

### Pricing

Pay per row, nothing for a run's time. You are charged only for rows with
data:

- **Post**: One public TikTok post with its counts, author, and music.
- **Profile**: One public TikTok account with its exact counts.
- **Listed video**: One video from an account's posts or a hashtag's posts.

An input that does not exist (a deleted post, an unknown username) or that
fails after three tries comes back as a free row with `error` and
`message` set. Set a spending limit on the run and it stops there.

### Use it from code

Every input field is in the API tab. Prefer plain HTTP? The same data is
the [TikTok API](https://clair.im/apis/tiktok?utm_source=apify\&utm_medium=readme\&utm_campaign=tiktok-scraper-api), with a free monthly
allowance.

### Notes

- Unofficial: not affiliated with or endorsed by TikTok. It reads what
  the site shows a signed-out visitor, and nothing behind a login.
- Rows are JSON objects; export them as JSON, CSV, Excel, or through the API.

# Actor input Schema

## `posts` (type: `array`):

One per line: a post id, or a tiktok.com/@user/video/ or /photo/ link. Each is one call to Post (/v1/tiktok/video). One public TikTok post: a video or a photo post.

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

One per line: a username, @username, or tiktok.com/@name link. Each is one call to Profile (/v1/tiktok/profile). One public TikTok account.

## `accountVideos` (type: `array`):

One per line: a username whose recent posts to list (about 130 at most). Each is one call to Videos (/v1/tiktok/videos). A public account’s recent posts, with the profile.

## `hashtags` (type: `array`):

One per line: a hashtag, with or without #, or a tiktok.com/tag/ link. Each is one call to Hashtag (/v1/tiktok/hashtag). A hashtag’s posts, with its view and post counts.

## `maxConcurrency` (type: `integer`):

Inputs called at once, 1 to 10.

## Actor input object example

```json
{
  "posts": [
    "6718335390845095173"
  ],
  "maxConcurrency": 5
}
```

# Actor output Schema

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

One row per post, profile, or listed video. An input without data gets a free row with error set.

# 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 = {
    "posts": [
        "6718335390845095173"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("clair-api/tiktok-scraper-api").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 = { "posts": ["6718335390845095173"] }

# Run the Actor and wait for it to finish
run = client.actor("clair-api/tiktok-scraper-api").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 '{
  "posts": [
    "6718335390845095173"
  ]
}' |
apify call clair-api/tiktok-scraper-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,clair-api/tiktok-scraper-api"
        }
    }
}
```

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/Ot2emdnbogNZf0k8r/builds/bcFpMaiqe0TTgNcnp/openapi.json
