# TikTok Video Scraper (`clockworks/tiktok-video-scraper`) Actor

Scrape TikTok video metadata and details from any TikTok URL: views, likes, comments, shares, saves, captions, hashtags, music, upload date, and creator info. Add subtitles, AI transcripts, video downloads, and related videos. Use it for video analytics, trend research, and competitor tracking.

- **URL**: https://apify.com/clockworks/tiktok-video-scraper.md
- **Developed by:** [Clockworks](https://apify.com/clockworks) (Apify)
- **Categories:** Social media, Videos
- **Features:** Limited permissions
- **Stats:** 21,922 total users, 2,901 monthly users, 99.5% runs succeeded, 207 bookmarks
- **User rating**: 4.60 out of 5 stars

## Pricing

from $1.00 / 1,000 videos

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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

### What is TikTok Video Scraper?

TikTok Video Scraper is a TikTok video metadata extractor. Paste one or more TikTok video URLs and get one structured record per video with engagement metrics, captions, music, and creator details, whether you need to check a single video's info or scrape data from thousands of videos in one run. It works without the official TikTok API or an API key.

> 💡 TikTok Video Scraper works with video URLs only. To scrape videos from a creator's profile, use [TikTok Profile Scraper](https://apify.com/clockworks/tiktok-profile-scraper). To combine profiles, hashtags, search keywords, and video URLs in one run, use [TikTok Scraper](https://apify.com/clockworks/tiktok-scraper).

### What data can I get with TikTok Video Scraper?

For each video, you get:

- 📊 **Engagement metrics:** views (plays), likes (hearts), comments, shares, saves, and reposts
- 🎬 **Video details:** caption, upload date and time, duration, and country of creation
- \#️⃣ **Hashtags and mentions:** every hashtag and tagged account in the video
- 🏷️ **Commercial flags:** whether a video is an ad, sponsored, or links a TikTok Shop product
- 🎵 **Music metadata:** sound name and author
- 👤 **Creator info:** username, bio, verified status, followers, total likes, and video count
- ⬇️ **Video downloads (add-on):** MP4 files with a direct download link
- 📝 **Subtitles and AI transcripts (add-on):** TikTok's own subtitles, or AI transcripts for videos without them
- 🔗 **Related videos (optional):** extra videos for each URL, up to the number you set

### What can you use TikTok video data for?

- 📈 **Engagement analysis:** compare views, likes, comments, shares, and saves across videos to calculate engagement rates and find which hooks, sounds, and formats perform best.
- 🕵️ **Competitor tracking:** follow how competitor videos and viral campaigns perform over time by running the same URLs on a schedule.
- 💬 **Social listening and sentiment analysis:** pull captions and transcripts from product reviews and reaction videos for [sentiment analysis](https://apify.com/use-cases/sentiment-analysis) and research.
- 🤖 **AI and content pipelines:** feed transcripts and metadata into [LLM workflows](https://apify.com/use-cases/data-for-generative-ai), or [analyze videos for creative intelligence](https://blog.apify.com/analyze-social-media-videos-for-creative-intelligence/) and content repurposing.
- 🎨 **Creative research:** save a shortlist of top-performing videos, such as competitor ads or UGC, as MP4 files with transcripts so your team can study hooks, scripts, and editing styles.

### How to scrape TikTok video data

1. [Create](https://console.apify.com/sign-up) a free Apify account using your email. The free plan includes $5 of monthly usage.
2. Open [TikTok Video Scraper](https://apify.com/clockworks/tiktok-video-scraper).
3. Add one or more TikTok video URLs. Enter them one by one, or upload or link to a text file.
4. Optionally, turn on video downloads, subtitles and transcripts, or related videos.
5. Click **Start** and wait for the run to finish.
6. Download your data in JSON, CSV, Excel, XML, or HTML.
7. Optionally, run the scraper on a [schedule](https://docs.apify.com/platform/schedules), connect it to other tools via [Apify integrations](https://apify.com/integrations), run it programmatically via the [API](https://apify.com/clockworks/tiktok-video-scraper/api), or use the [Apify MCP server](https://apify.com/mcp) to run it directly from AI assistants like Claude or ChatGPT.

Watch this tutorial to see how to extract TikTok video data step by step:

https://www.youtube.com/watch?v=B9mZpnVgG5s

### Run TikTok Video Scraper from an AI assistant

To run TikTok Video Scraper from an AI assistant, add `https://mcp.apify.com` as a custom connector in [Claude](https://docs.apify.com/integrations/claude-desktop) or [ChatGPT](https://docs.apify.com/integrations/chatgpt). The [Apify MCP server](https://docs.apify.com/mcp) gives the assistant access to every Actor in Apify Store, so you can ask for TikTok video data in plain language:

```
Use clockworks/tiktok-video-scraper to get the views, likes, shares, saves, and upload date for these videos and rank them by engagement rate: [video URL 1], [video URL 2], [video URL 3]
```

```
Use clockworks/tiktok-video-scraper to transcribe this TikTok video and summarize its hook and main talking points: [video URL]
```

```
Use clockworks/tiktok-video-scraper to check which of these TikTok videos are ads or sponsored, and which link a TikTok Shop product: [video URL 1], [video URL 2]
```

### Input

The only required input is one or more full TikTok video URLs. Links with tracking parameters work, but a bare video ID returns an `INVALID_URLS` error item. See the [Input schema](https://apify.com/clockworks/tiktok-video-scraper/input-schema) for all other options.

![TikTok Video Scraper Input](https://raw.githubusercontent.com/apify-projects/actor-readme-images/master/tiktok-video-scraper_input.png)

The same input in JSON:

```json
{
    "postURLs": ["https://www.tiktok.com/@apifytech/video/7398101551744552225"],
    "scrapeRelatedVideos": true,
    "resultsPerPage": 5,
    "shouldDownloadVideos": true,
    "shouldDownloadCovers": false,
    "downloadSubtitlesOptions": "DOWNLOAD_AND_TRANSCRIBE_VIDEOS_WITHOUT_SUBTITLES",
    "shouldDownloadSlideshowImages": false,
    "videoKvStoreIdOrName": "tiktok-videos"
}
```

#### Subtitles and transcription options

| Option                                             | What it does                                                                                                          |
| -------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| `NEVER_DOWNLOAD_SUBTITLES`                         | No subtitles or transcripts (default).                                                                                |
| `DOWNLOAD_SUBTITLES`                               | Downloads TikTok's own subtitles as .vtt files where available. Videos without subtitles return no text.              |
| `DOWNLOAD_AND_TRANSCRIBE_VIDEOS_WITHOUT_SUBTITLES` | Downloads subtitles where available and generates AI transcripts (.txt) for the rest. Recommended for most use cases. |
| `TRANSCRIBE_ALL_VIDEOS`                            | Generates AI transcripts for every video, even ones that have subtitles.                                              |

AI transcription is a paid add-on charged per started minute of video. For transcripts at scale, see the dedicated [TikTok Transcript Extractor](https://apify.com/clockworks/tiktok-transcript-extractor).

### Output

Results are saved to a dataset, with one item per video. In Apify Console, you can preview and download them from the **Output** tab in JSON, CSV, Excel, XML, or HTML. When you run the Actor via the API or the Apify MCP server, you get the same items as JSON.

Here's what the Output tab looks like:

![TikTok Video Scraper Output](https://raw.githubusercontent.com/apify-projects/actor-readme-images/master/tiktok-video-scraper_output.png)

Below is a single video result:

```json
{
    "text": "📣 Yes, you can scrape job listings #data in a minute!! #webscraping #techtiktok #job #automation",
    "createTimeISO": "2024-08-01T09:32:32.000Z",
    "locationCreated": "CZ",
    "webVideoUrl": "https://www.tiktok.com/@apifytech/video/7398101551744552225",
    "playCount": 592,
    "diggCount": 21,
    "commentCount": 0,
    "shareCount": 1,
    "collectCount": 1,
    "isAd": false,
    "isSponsored": false,
    "authorMeta": {
        "name": "apifytech",
        "verified": false,
        "fans": 3587
    },
    "musicMeta": {
        "musicName": "original sound"
    },
    "videoMeta": {
        "duration": 23,
        "subtitleLinks": [
            {
                "language": "eng-US",
                "downloadLink": "https://api.apify.com/v2/key-value-stores/.../subtitle-...-eng-US.vtt"
            }
        ],
        "downloadAddr": "https://api.apify.com/v2/key-value-stores/.../video-...-7398101551744552225.mp4",
        "transcriptionLink": null
    }
}
```

Each output item contains the following key fields (see the [Output schema](https://apify.com/clockworks/tiktok-video-scraper/output-schema) for the full list):

| Field                         | Type    | Description                                                                    |
| ----------------------------- | ------- | ------------------------------------------------------------------------------ |
| `playCount`                   | number  | Number of views                                                                |
| `diggCount`                   | number  | Number of likes (hearts)                                                       |
| `collectCount`                | number  | Number of saves (bookmarks)                                                    |
| `locationCreated`             | string  | Country code of where the video was posted                                     |
| `isAd` / `isSponsored`        | boolean | Whether the video is an ad or a sponsored post                                 |
| `videoMeta.downloadAddr`      | string  | Direct link to the downloaded MP4 (video download add-on only)                 |
| `videoMeta.subtitleLinks`     | array   | Subtitle files with language and download link (subtitles option only)         |
| `videoMeta.transcriptionLink` | string  | Link to the AI transcript .txt file, or `null` if the video wasn't transcribed |
| `originalVideoDetail`         | object  | For related videos only: the input video they were found from                  |

### How much does it cost to scrape TikTok videos?

TikTok Video Scraper uses [pay-per-event pricing](https://help.apify.com/en/articles/10700066-what-is-pay-per-event), so you only pay for the videos you scrape and the add-ons you turn on. Platform usage is included. On the Free plan, the prices are:

- **Video:** $3.00 per 1,000 videos, including related videos
- **Video download (add-on):** $1.30 per 1,000 videos downloaded as MP4
- **AI transcript (add-on):** $0.048 per started minute of video

Every Apify account includes $5 of free monthly usage, which covers roughly 1,600 videos without add-ons. Rates are lower on paid plans. See the [Pricing tab](https://apify.com/clockworks/tiktok-video-scraper/pricing) for all plans.

### Other TikTok scrapers

Use the dedicated scrapers below to scrape **specific TikTok data**.

| Actor                                                                                      | Best for                                                                   |
| ------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------- |
| 🎵 [TikTok Scraper](https://apify.com/clockworks/tiktok-scraper)                           | videos from profiles, hashtags, search keywords, and video URLs in one run |
| 👤 [TikTok Profile Scraper](https://apify.com/clockworks/tiktok-profile-scraper)           | all videos and profile stats from TikTok creators                          |
| 👥 [TikTok Followers Scraper](https://apify.com/clockworks/tiktok-followers-scraper)       | followers and following lists of TikTok accounts                           |
| 💬 [TikTok Comments Scraper](https://apify.com/clockworks/tiktok-comments-scraper)         | comments from TikTok videos                                                |
| 📝 [TikTok Transcript Extractor](https://apify.com/clockworks/tiktok-transcript-extractor) | subtitles and AI transcripts from TikTok videos at scale                   |
| 🔍 [TikTok User Search Scraper](https://apify.com/clockworks/tiktok-user-search-scraper)   | creator profiles found by search keyword                                   |
| #️⃣ [TikTok Hashtag Scraper](https://apify.com/clockworks/tiktok-hashtag-scraper)           | videos posted under specific hashtags                                      |
| 🎶 [TikTok Sound Scraper](https://apify.com/clockworks/tiktok-sound-scraper)               | videos that use a specific sound                                           |
| 🧭 [TikTok Explore Scraper](https://apify.com/clockworks/tiktok-explore-scraper)           | trending videos from TikTok Explore categories                             |
| 💡 [TikTok Discover Scraper](https://apify.com/clockworks/tiktok-discover-scraper)         | related videos, similar trends, and subtopics for hashtags                 |
| 🛍️ [TikTok Shop Scraper](https://apify.com/clockworks/tiktok-shop-scraper)                 | TikTok Shop product listings, prices, and sales data                       |

### Your feedback

We're always working on improving TikTok Video Scraper. If you've found a bug or have a feature request, please create an issue on the [Issues tab](https://apify.com/clockworks/tiktok-video-scraper/issues/open). We monitor it actively.

### Error items

When TikTok Video Scraper can't retrieve data for an input, it pushes an error item to the dataset instead of silently skipping it. Other items in the same run aren't affected. You can recognize error items by the `errorCode` field.

```json
{
    "url": "https://www.tiktok.com/@apifytech/video/7000000000000000000",
    "error": "Post not found or private.",
    "errorCode": "POST_NOT_FOUND_OR_PRIVATE"
}
```

| `errorCode`                 | Meaning                                                                        |
| --------------------------- | ------------------------------------------------------------------------------ |
| `INVALID_URLS`              | One or more inputs aren't valid TikTok video URLs, for example a bare video ID |
| `POST_NOT_FOUND_OR_PRIVATE` | The video was deleted or is private                                            |
| `POST_SENSITIVE`            | TikTok flags the video as sensitive content                                    |
| `INVALID_INPUT`             | The run failed because of a bad configuration, and the run is terminated       |

### FAQ

#### Is there an official TikTok API for video data?

TikTok's official [Research API](https://developers.tiktok.com/docs/en/research-api-faq) gives access to public video data, but only to approved researchers who submit a research proposal. Commercial users aren't eligible. TikTok Video Scraper works as a TikTok video API alternative: give it video URLs and get structured data back, with no TikTok API key or approval needed.

#### Can I use TikTok Video Scraper as a TikTok scraper API?

Yes. The [API tab](https://apify.com/clockworks/tiktok-video-scraper/api) has ready-to-use code examples for Node.js, Python, and the CLI. You can also use the [JavaScript](https://docs.apify.com/api/client/js/) and [Python](https://docs.apify.com/api/client/python/) API clients, or run the Actor from AI assistants via the Apify MCP server.

#### Can I schedule TikTok video scraping?

Yes. Use [schedules](https://docs.apify.com/platform/schedules) to run TikTok Video Scraper automatically, for example daily, to track how the same videos perform over time.

#### Can I integrate TikTok Video Scraper with other apps?

Yes. TikTok Video Scraper connects with [Make](https://apify.com/integrations/make), [n8n](https://apify.com/integrations/n8n), [Zapier](https://apify.com/integrations/zapier), [Lovable](https://apify.com/integrations/lovable), [Google Drive](https://docs.apify.com/platform/integrations/drive), [Slack](https://docs.apify.com/platform/integrations/slack), and more. You can also use [webhooks](https://docs.apify.com/platform/integrations/webhooks) to trigger an action when a run finishes.

#### Is it legal to scrape TikTok?

TikTok Video Scraper only extracts publicly available data, such as video stats and public profile details. It doesn't extract private data like email addresses. Your results might still contain personal data, which is protected by GDPR in the EU and by other laws worldwide, so only scrape it if you have a legitimate reason. If you're unsure, consult your lawyers. Read more about the [legality of web scraping](https://blog.apify.com/is-web-scraping-legal/) and [ethical web scraping](https://blog.apify.com/what-is-ethical-web-scraping-and-how-do-you-do-it/).

# Changelog

This Actor's version history is a separate document: https://apify.com/clockworks/tiktok-video-scraper/changelog.md

# Actor input Schema

## `postURLs` (type: `array`):

Add the URLs of posted videos you want to scrape. You can enter URLs one by one, or you can upload or link to a text file.

## `scrapeRelatedVideos` (type: `boolean`):

Use to scrape related videos for the post URLs you provide.

- The maximum number of scraped related videos is set by the `resultsPerPage` count.

## `resultsPerPage` (type: `integer`):

Add the number of related videos you want to scrape for each post URL. This field is applicable when the <strong>Scrape related videos</strong> option is enabled.

## `shouldDownloadVideos` (type: `boolean`):

This is a charged add-on. Tick to download TikTok videos.

## `shouldDownloadCovers` (type: `boolean`):

Tick to download TikTok video cover images (thumbnails).

## `downloadSubtitlesOptions` (type: `string`):

Choose how to handle subtitles and audio transcription for input videos. Subtitles are provided by TikTok for some videos, and transcription means that this Actor will use speech-to-text AI to generate video transcript. Transcripts are charged as an extra event according to your plan.

## `shouldDownloadSlideshowImages` (type: `boolean`):

Tick to download TikTok slideshow images.

## `videoKvStoreIdOrName` (type: `string`):

Name (or ID) of the Key Value Store where the videos and other media like thumbnails will be stored. Omit to store in the default one. Using this option will provide a named Key-Value store can help bypass data retention and store the content forever until the store is manually deleted.<br><br>The Key-Value store's name can consist of a versatile combination of uppercase letters, lowercase letters, digits, or hyphens, all without any spaces.

## Actor input object example

```json
{
  "postURLs": [
    "https://www.tiktok.com/@apifylife/video/7200360993149553925"
  ],
  "scrapeRelatedVideos": false,
  "resultsPerPage": 100,
  "shouldDownloadVideos": false,
  "shouldDownloadCovers": false,
  "downloadSubtitlesOptions": "NEVER_DOWNLOAD_SUBTITLES",
  "shouldDownloadSlideshowImages": false,
  "videoKvStoreIdOrName": "tiktok-videos"
}
```

# Actor output Schema

## `dataset` (type: `string`):

Dataset containing all scraped data

# 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 = {
    "postURLs": [
        "https://www.tiktok.com/@apifylife/video/7200360993149553925"
    ],
    "resultsPerPage": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("clockworks/tiktok-video-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 = {
    "postURLs": ["https://www.tiktok.com/@apifylife/video/7200360993149553925"],
    "resultsPerPage": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("clockworks/tiktok-video-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 '{
  "postURLs": [
    "https://www.tiktok.com/@apifylife/video/7200360993149553925"
  ],
  "resultsPerPage": 100
}' |
apify call clockworks/tiktok-video-scraper --silent --output-dataset

```

## MCP server setup

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