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

Extract data from TikTok videos, hashtags, and users. Use URLs or search queries to scrape TikTok profiles, hashtags, posts, URLs, shares, followers, hearts, names, video, and music-related data. Export scraped data, run the scraper via API, schedule and monitor runs or integrate with other tools.

- **URL**: https://apify.com/clockworks/tiktok-scraper.md
- **Developed by:** [Clockworks](https://apify.com/clockworks) (Apify)
- **Categories:** Social media, Videos
- **Stats:** 229,490 total users, 19,514 monthly users, 93.5% runs succeeded, 2,175 bookmarks
- **User rating**: 4.79 out of 5 stars

## Pricing

from $1.70 / 1,000 results

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### What does TikTok Scraper do?

TikTok Scraper can extract multiple data points from TikTok and export them into the format of your choice. You can then use this data in your own data projects, business reports, and as a basis for new applications.

- Get data from **chosen hashtags** including top videos, timestamps, views, shares, comments, and video count
- Extract all posts from chosen **user profiles** including details like name, nickname, ID, bio, followers/following numbers, play, shares, and comment count
- **Video posts** from specific profiles
- Enter **specific keywords** in your search query
- Download **TikTok videos,** subtitles, and thumbnails
- Download **TikTok profiles' followers and following** lists with names
- Get information on **related videos**
- Export data in multiple formats: **JSON, CSV, Excel, or HTML**
- Connect TikTok Scraper to any AI chatbot using **Apify MCP server**
- Export via SDKs (Python & Node.js), use **API Endpoints**, **webhooks**, or integrate with workflows

### What data can you get from TikTok

TikTok Scraper can gather any kind of data from the social media app, such as:

<table>
<tr>
<td>👤 Profile name</td>
<td>❤️ Likes</td>
<td>🔁 Shares</td>
</tr>
<tr>
<td>▶️ Plays</td>
<td>🔗 Video URL</td>
<td>🌐 Profile URL</td>
</tr>
<tr>
<td>📝 Video description</td>
<td>💬 Video subtitles</td>
<td>🈹 Text language</td>
</tr>
<tr>
<td>📜 Bio</td>
<td>👥 Followers / Following count</td>
<td>📋 Followers / Following list</td>
</tr>
<tr>
<td>🏷️ Hashtags used</td>
<td>📢 Ad post?</td>
<td>📌 Pinned post?</td>
</tr>
<tr>
<td>💰 Sponsored?</td>
<td>📍 Location of creation</td>
<td>🎵 Music meta</td>
</tr>
</table>

### How to scrape TikTok with TikTok Scraper?

TikTok Scraper is user-friendly, offering a smooth start even for those who have never extracted data from TikTok before. Here’s how to scrape TikTok with TikTok Scraper in 5 steps:

1. [Create](https://console.apify.com/actors/GdWCkxBtKWOsKjdch/) a free Apify account using your email.
2. Open [TikTok Scraper](https://apify.com/clockworks/tiktok-scraper).
3. Add search terms / hashtags / URLs / profiles that you want to scrape.
4. Click the “Start” button and wait for the data to be extracted.
5. Download your data in JSON, XML, CSV, Excel, or HTML.

For more information, read this [step-by-step guide](https://blog.apify.com/how-to-scrape-tiktok-tutorial/) or watch our [short video tutorial](https://www.youtube.com/watch?v=WwdmQzv_w54). It also applies to our [TikTok Data Extractor](https://apify.com/clockworks/free-tiktok-scraper).

https://www.youtube.com/watch?v=WwdmQzv\_w54

### Input

To start scraping TikTok, fill in the input form. TikTok Scraper recognizes the following input parameters:

- **hashtags:** scrapes TikTok for hashtags
- **profiles:** scrapes TikTok profiles
- **search:** scrapes specific keywords and extract videos and profiles that contain it
- **video URLs:** scrapes specific TikTok videos

<a href="https://console.apify.com/actors/GdWCkxBtKWOsKjdch/">
<img src="https://github.com/apify-projects/actor-readme-images/blob/master/tiktok-scraper-input.png?raw=true" alt="TikTok Scraper input" style="width:70%;">
</a>

#### Input JSON

```json
{
    "excludePinnedPosts": false,
    "hashtags": ["bananas"],
    "proxyCountryCode": "None",
    "resultsPerPage": 3,
    "scrapeRelatedVideos": false,
    "shouldDownloadAvatars": false,
    "shouldDownloadCovers": false,
    "shouldDownloadMusicCovers": false,
    "shouldDownloadSlideshowImages": false,
    "shouldDownloadSubtitles": false,
    "shouldDownloadVideos": false,
    "profileScrapeSections": ["videos"],
    "profileSorting": "latest",
    "searchSection": "",
    "maxProfilesPerQuery": 10
}
```

### Output

The results will be wrapped into a dataset which you can find in the **Storage** tab. Here's an excerpt from the dataset you'd get if you apply the “bananas” hashtag:

<a href="https://console.apify.com/actors/GdWCkxBtKWOsKjdch/">
<img src="https://github.com/apify-projects/actor-readme-images/blob/master/tiktok-scraper-output.png?raw=true" alt="TikTok Scraper output" style="width:70%;">
</a>

Here is what it looks like in JSON:

```json
{
    "authorMeta.avatar": "https://p16-common-sign-useastred.tiktokcdn-eu.com/tos-useast2a-avt-0068-euttp/61a7494d9eda0eb86828eead52022359~tplv-tiktokx-cropcenter:720:720.jpeg?dr=10399&refresh_token=a65e63ff&x-expires=1755694800&x-signature=XOOMwKmEYLBn69h5QqvfQ1AIWJA%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=no1a",
    "authorMeta.name": "bruniela_",
    "text": "🤣🤣🤣🤣🤣 #comeramabanana ",
    "diggCount": 5344,
    "shareCount": 701,
    "playCount": 55700,
    "commentCount": 24,
    "collectCount": 291,
    "videoMeta.duration": 16,
    "musicMeta.musicName": "som original",
    "musicMeta.musicAuthor": "fox_rus0",
    "musicMeta.musicOriginal": true,
    "createTimeISO": "2025-08-02T18:45:03.000Z",
    "webVideoUrl": "https://www.tiktok.com/@bruniela_/video/7534061113365859586"
}
```

#### Scraped TikTok search queries

The structure of each search query looks like this:

```
  {
    "id": "7543693751290481942",
    "text": "ootd ☁️☁️\n\n#foruyou #fürdich #outfit #fit #viralvideos ",
    "textLanguage": "en",
    "createTime": 1756403075,
    "createTimeISO": "2025-08-28T17:44:35.000Z",
    "isAd": false,
    "authorMeta": {
      "id": "6733984297591636998",
      "name": "gretalynnhihi",
      "profileUrl": "https://www.tiktok.com/@gretalynnhihi",
      "nickName": "Greta Lynn",
      "verified": false,
      "signature": "hellouu\nfashion | beauty | lifestyle",
      "bioLink": null,
      "originalAvatarUrl": "https://p16-sign-va.tiktokcdn.com/tos-maliva-avt-0068/3b43a9f163774c65e26adaec1f967e47~tplv-tiktokx-cropcenter:720:720.jpeg?dr=14579&refresh_token=fcabb4ab&x-expires=1756886400&x-signature=d8CUReHcX4aowTaVF0IEyBjmR%2FU%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=my",
      "avatar": "https://p16-sign-va.tiktokcdn.com/tos-maliva-avt-0068/3b43a9f163774c65e26adaec1f967e47~tplv-tiktokx-cropcenter:720:720.jpeg?dr=14579&refresh_token=fcabb4ab&x-expires=1756886400&x-signature=d8CUReHcX4aowTaVF0IEyBjmR%2FU%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=my",
      "privateAccount": false,
      "following": 269,
      "friends": 0,
      "fans": 51200,
      "heart": 3000000,
      "video": 259,
      "digg": 194800
    },
    "musicMeta": {
      "musicName": "original sound",
      "musicAuthor": "WYA ADRIAN | DJ",
      "musicOriginal": true,
      "playUrl": "https://v16-webapp-prime.tiktok.com/video/tos/alisg/tos-alisg-v-27dcd7/ooAABQ65hGAfoXtbJMFsDAveXADIAI8mOQfK7e/?a=1988&bti=ODszNWYuMDE6&ch=0&cr=0&dr=0&er=0&lr=default&cd=0%7C0%7C0%7C0&br=250&bt=125&ds=5&ft=GNDpcInz7ThIGk1KXq8Zmo&mime_type=audio_mpeg&qs=13&rc=am9zb3U5cnd3NDMzODU8NEBpam9zb3U5cnd3NDMzODU8NEBzLXNgMmRrLXJhLS1kMS1zYSNzLXNgMmRrLXJhLS1kMS1zcw%3D%3D&btag=e00048000&expire=1756719062&l=20250901163023662894E4DEC436DB346D&ply_type=3&policy=3&signature=38ed21c64984e54c193163a1082b1510&tk=0",
      "coverMediumUrl": "https://p16-sign-sg.tiktokcdn.com/tos-alisg-avt-0068/10da069b962f021877c87e22cd0a822d~tplv-tiktokx-cropcenter:720:720.jpeg?dr=14579&refresh_token=9e5b092f&x-expires=1756886400&x-signature=wG3JIjPN95oTAjFu11TJXQvbiQ4%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=my",
      "originalCoverMediumUrl": "https://p16-sign-sg.tiktokcdn.com/tos-alisg-avt-0068/10da069b962f021877c87e22cd0a822d~tplv-tiktokx-cropcenter:720:720.jpeg?dr=14579&refresh_token=9e5b092f&x-expires=1756886400&x-signature=wG3JIjPN95oTAjFu11TJXQvbiQ4%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=my",
      "musicId": "7529403355681147665"
    },
    "webVideoUrl": "https://www.tiktok.com/@gretalynnhihi/video/7543693751290481942",
    "mediaUrls": [],
    "videoMeta": {
      "height": 1024,
      "width": 576,
      "duration": 15,
      "coverUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-p-0037-no/oYBpoCBE0YVCIgAE5AiiVAwanII7vSLAqBYBl~tplv-tiktokx-origin.image?dr=14575&x-expires=1756886400&x-signature=Y20ebi0TvRDw0ssEvFXKTAUIAxc%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=my",
      "originalCoverUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-p-0037-no/oYBpoCBE0YVCIgAE5AiiVAwanII7vSLAqBYBl~tplv-tiktokx-origin.image?dr=14575&x-expires=1756886400&x-signature=Y20ebi0TvRDw0ssEvFXKTAUIAxc%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=my",
      "definition": "540p",
      "format": "mp4"
    },
    "diggCount": 23400,
    "shareCount": 145,
    "playCount": 145900,
    "collectCount": 1637,
    "commentCount": 46,
    "mentions": [],
    "detailedMentions": [],
    "hashtags": [
      {
        "id": "4982299",
        "name": "foruyou",
        "title": "",
        "cover": ""
      },
    "effectStickers": [],
    "isSlideshow": false,
    "isPinned": false,
    "searchQuery": "ootd"
  },
```

#### Scraped TikTok profiles

The structure of each TikTok profile looks like this:

```json
 {
    "id": "7535448384170331414",
    "text": "",
    "textLanguage": "un",
    "createTime": 1754483302,
    "createTimeISO": "2025-08-06T12:28:22.000Z",
    "isAd": false,
    "authorMeta": {
      "id": "7002169437214213125",
      "name": "shaiie_foeva",
      "profileUrl": "https://www.tiktok.com/@shaiie_foeva",
      "nickName": "Shaiie_Foeva",
      "verified": false,
      "signature": "SHOP THE E-BOOK OUT NOW",
      "bioLink": "https://fkrtrz-v0.myshopify.com/collections/all",
      "originalAvatarUrl": "https://p16-common-sign-va.tiktokcdn-us.com/tos-maliva-avt-0068/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=985e467d&x-expires=1756886400&x-signature=NeHTiZJsr7cp6ijWQkiNso544Zg%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=f20df69d&idc=useast5",
      "avatar": "https://p16-common-sign-va.tiktokcdn-us.com/tos-maliva-avt-0068/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=985e467d&x-expires=1756886400&x-signature=NeHTiZJsr7cp6ijWQkiNso544Zg%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=f20df69d&idc=useast5",
      "commerceUserInfo": {
        "commerceUser": false
      },
      "privateAccount": false,
      "roomId": "",
      "ttSeller": false,
      "following": 0,
      "friends": 0,
      "fans": 2200000,
      "heart": 126000000,
      "video": 1036,
      "digg": 143
    },
    "musicMeta": {
      "musicName": "original sound - Shaiie_Foeva",
      "musicOriginal": false,
      "coverMediumUrl": "",
      "originalCoverMediumUrl": "",
      "musicId": "0"
    },
    "webVideoUrl": "https://www.tiktok.com/@shaiie_foeva/video/7535448384170331414",
    "mediaUrls": [],
    "videoMeta": {
      "height": 0,
      "width": 0,
      "duration": 0,
      "coverUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-i-photomode-no/cead98ba6871473581e3b54fd7d4928d~tplv-photomode-image.jpeg?dr=10375&x-expires=1756886400&x-signature=PJ6XcL7snSio5PVn4c4y87AvDP8%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=9b759fb9&idc=no1a&ftpl=1",
      "originalCoverUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-i-photomode-no/cead98ba6871473581e3b54fd7d4928d~tplv-photomode-image.jpeg?dr=10375&x-expires=1756886400&x-signature=PJ6XcL7snSio5PVn4c4y87AvDP8%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=9b759fb9&idc=no1a&ftpl=1"
    },
    "diggCount": 3951,
    "shareCount": 38,
    "playCount": 348100,
    "collectCount": 105,
    "commentCount": 111,
    "mentions": [],
    "detailedMentions": [],
    "hashtags": [],
    "effectStickers": [
      {
        "ID": "1286923318",
        "name": "Green Screen",
        "stickerStats": {
          "useCount": 0
        }
      }
    "isSlideshow": true,
    "slideshowImageLinks": [
      {
        "tiktokLink": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-i-photomode-no/cead98ba6871473581e3b54fd7d4928d~tplv-photomode-image.jpeg?dr=10375&x-expires=1756886400&x-signature=PJ6XcL7snSio5PVn4c4y87AvDP8%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=9b759fb9&idc=no1a&ftpl=1",
        "downloadLink": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-i-photomode-no/cead98ba6871473581e3b54fd7d4928d~tplv-photomode-image.jpeg?dr=10375&x-expires=1756886400&x-signature=PJ6XcL7snSio5PVn4c4y87AvDP8%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=9b759fb9&idc=no1a&ftpl=1"
      }
    ],
    "isPinned": true,
    "isSponsored": false,
    "input": "shaiie_foeva",
    "fromProfileSection": "videos"
  },
```

When you use the Followers and following profiles add-on, you get also this:

```json
"connectedTo": {
      "id": "7002169437214213125",
      "name": "shaiie_foeva",
      "profileUrl": "https://www.tiktok.com/@shaiie_foeva",
      "nickName": "Shaiie_Foeva",
      "verified": false,
      "signature": "SHOP THE E-BOOK OUT NOW",
      "bioLink": "https://fkrtrz-v0.myshopify.com/collections/all",
      "originalAvatarUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=10399&refresh_token=8fe904c4&x-expires=1756886400&x-signature=6%2BIU4BT7Xgt0N5x7ZcrOun%2BI%2BOs%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=f20df69d&idc=no1a",
      "avatar": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=10399&refresh_token=8fe904c4&x-expires=1756886400&x-signature=6%2BIU4BT7Xgt0N5x7ZcrOun%2BI%2BOs%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=f20df69d&idc=no1a",
      "commerceUserInfo": {
        "commerceUser": false
      },
      "privateAccount": false,
      "roomId": "",
      "ttSeller": false,
      "following": 0,
      "friends": 0,
      "fans": 2200000,
      "heart": 126000000,
      "video": 1036,
      "digg": 143
    },
    "connectionType": "follower",
    "connectionDescription": "anthonnytabach12 is a follower of shaiie_foeva"
```

#### Scraped TikTok video URLs

The structure of each video URL looks like this:

```json
  {
    "id": "7533731959172861206",
    "text": "",
    "textLanguage": "un",
    "createTime": 1754083665,
    "createTimeISO": "2025-08-01T21:27:45.000Z",
    "locationCreated": "GB",
    "isAd": false,
    "authorMeta": {
      "id": "7002169437214213125",
      "name": "shaiie_foeva",
      "profileUrl": "https://www.tiktok.com/@shaiie_foeva",
      "nickName": "Shaiie_Foeva",
      "verified": false,
      "signature": "SHOP THE E-BOOK OUT NOW",
      "bioLink": "https://fkrtrz-v0.myshopify.com/collections/all",
      "originalAvatarUrl": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=10399&refresh_token=8fe904c4&x-expires=1756886400&x-signature=6%2BIU4BT7Xgt0N5x7ZcrOun%2BI%2BOs%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=no1a",
      "avatar": "https://p16-pu-sign-no.tiktokcdn-eu.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=10399&refresh_token=8fe904c4&x-expires=1756886400&x-signature=6%2BIU4BT7Xgt0N5x7ZcrOun%2BI%2BOs%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=no1a",
      "privateAccount": false,
      "roomId": "",
      "ttSeller": false,
      "following": 0,
      "friends": 0,
      "fans": 2200000,
      "heart": 126000000,
      "video": 1036,
      "digg": 143,
      "commerceUserInfo": {
        "commerceUser": false
      }
    },
    "musicMeta": {
      "musicName": "original sound",
      "musicAuthor": "Shaiie_Foeva",
      "musicOriginal": true,
      "playUrl": "https://v16m.tiktokcdn-us.com/affaffc8161ba7cf237d6a76a848f2c3/68b5aeb4/video/tos/no1a/tos-no1a-v-2370-no/o8IMeA0AQE7AIqXARcrE7Ym8CKeTDnoGaILegz/?a=1233&bti=ODszNWYuMDE6&ch=0&cr=0&dr=0&er=0&lr=default&cd=0%7C0%7C0%7C0&br=250&bt=125&ds=5&ft=GSDrKInz7ThNbk1KXq8Zmo&mime_type=audio_mpeg&qs=13&rc=anR1ZHk5cm5tNTMzbzU8NUBpanR1ZHk5cm5tNTMzbzU8NUBzbS5kMmRzLzNhLS1kMTFzYSNzbS5kMmRzLzNhLS1kMTFzcw%3D%3D&vvpl=1&l=202509010832109DA1069212B8B50032D4&btag=e00050000",
      "coverMediumUrl": "https://p16-common-sign-no.tiktokcdn-us.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=cec345e5&x-expires=1756886400&x-signature=8VL5b49uYMv3HPTXq5LPcNLlx0U%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
      "originalCoverMediumUrl": "https://p16-common-sign-no.tiktokcdn-us.com/tos-no1a-avt-0068c001-no/a76fbd25290f391d7ad8b61fe5fa99e8~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=cec345e5&x-expires=1756886400&x-signature=8VL5b49uYMv3HPTXq5LPcNLlx0U%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
      "musicId": "7533731952105392918"
    },
    "webVideoUrl": "https://www.tiktok.com/@shaiie_foeva/video/7533731959172861206",
    "mediaUrls": [],
    "videoMeta": {
      "height": 1024,
      "width": 576,
      "duration": 74,
      "coverUrl": "https://p16-common-sign-no.tiktokcdn-us.com/tos-no1a-p-0037-no/oUIRDkoATOwuGrtNDFEI5jF2j0BBqgfeEMEJ2V~tplv-tiktokx-origin.image?dr=9636&x-expires=1756886400&x-signature=iO442BQBu6RpBX8qAj5wAfWg0tA%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
      "originalCoverUrl": "https://p16-common-sign-no.tiktokcdn-us.com/tos-no1a-p-0037-no/oUIRDkoATOwuGrtNDFEI5jF2j0BBqgfeEMEJ2V~tplv-tiktokx-origin.image?dr=9636&x-expires=1756886400&x-signature=iO442BQBu6RpBX8qAj5wAfWg0tA%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
      "definition": "540p",
      "format": "mp4",
      "subtitleLinks": [
        {
          "language": "kor-KR",
          "downloadLink": "https://v16m-webapp.tiktokcdn-us.com/8f5a52f5d0320b9592c0a3af90aaedc3/68b7fd54/video/tos/useast5/tos-useast5-v-0068c799-tx/3db5dadedd20436ab0dda7dfeb98857e/?a=1988&bti=ODszNWYuMDE6&ch=0&cr=3&dr=0&lr=all&cd=0%7C0%7C0%7C&cv=1&br=11970&bt=5985&ds=4&ft=4KLMeMzm8Zmo0sgHfI4jVKYidpWrKsd.&mime_type=video_mp4&qs=13&rc=anM7Z3g5cnRtNTMzbzczNUBpanM7Z3g5cnRtNTMzbzczNUBqZWlrMmRzLjNhLS1kMTFzYSNqZWlrMmRzLjNhLS1kMTFzcw%3D%3D&l=202509010832109DA1069212B8B50032D4&btag=e00050000",
          "tiktokLink": "https://v16m-webapp.tiktokcdn-us.com/8f5a52f5d0320b9592c0a3af90aaedc3/68b7fd54/video/tos/useast5/tos-useast5-v-0068c799-tx/3db5dadedd20436ab0dda7dfeb98857e/?a=1988&bti=ODszNWYuMDE6&ch=0&cr=3&dr=0&lr=all&cd=0%7C0%7C0%7C&cv=1&br=11970&bt=5985&ds=4&ft=4KLMeMzm8Zmo0sgHfI4jVKYidpWrKsd.&mime_type=video_mp4&qs=13&rc=anM7Z3g5cnRtNTMzbzczNUBpanM7Z3g5cnRtNTMzbzczNUBqZWlrMmRzLjNhLS1kMTFzYSNqZWlrMmRzLjNhLS1kMTFzcw%3D%3D&l=202509010832109DA1069212B8B50032D4&btag=e00050000",
          "source": "MT",
          "sourceUnabbreviated": "machine translation",
          "version": "4"
        },
    "diggCount": 25900,
    "shareCount": 352,
    "playCount": 573900,
    "collectCount": 1356,
    "commentCount": 346,
    "mentions": [],
    "detailedMentions": [],
    "hashtags": [],
    "effectStickers": [
      {
        "name": "Green Screen",
        "ID": "308867"
      }
    ],
    "isSlideshow": false,
    "isPinned": false,
    "isSponsored": false,
    "submittedVideoUrl": "https://www.tiktok.com/@shaiie_foeva/video/7533731959172861206"
  }
```

#### How to download TikTok videos

You can also download TikTok videos using this scraper. All data will be stored in the key-value store, from where it can be downloaded at any time.

<a href="https://console.apify.com/actors/GdWCkxBtKWOsKjdch/">
<img src="https://github.com/apify-projects/actor-readme-images/blob/master/

download-tiktok-videos.png?raw=true" alt="Download TikTok videos" style="width:70%;"> </a>

The following data can be extracted:

<table>
<tr>
<td>🎬 Whole TT videos</td>
<td>🖼️ Thumbnails</td>
<td>🔤 Subtitles</td>
</tr>
<tr>
<td>📽️ Slideshow images</td>
<td>👤 Profile avatars</td>
<td>🎧 Sound covers</td>
</tr>
</table>

### How can I use the data extracted from TikTok with TikTok Scraper?

- ✨ Observe and track trends and **predict emerging influencers**
- 📋 Create a pipeline of top-of-the-line [**marketing leads**](https://blog.apify.com/marketing-leads-scraping-with-apify/)
- \#️ Simplify market research for planning advertisement campaigns and **hashtag challenges**
- 🪧 Prepare for an upcoming **TikTok marketing campaign**: start and promote your own channel or collaborate with an influencer
- 📚 Scan the market for authentic **reviews** and **sentiment analysis**
- 🔬 Get data for [**research**](https://blog.apify.com/tiktok-user-behavior-with-apify/) and **social listening** experiments
- 📈 Analyze **viral campaigns** and trends
- **✅Identify unverified content** and inaccurate information with high public value

### Scrape any TikTok data you need with dedicated scrapers

<table>
<tr>
<td>🎹 <a href="https://apify.com/clockworks/free-tiktok-scraper">Tiktok Data Extractor</a></td>
<td>📹 <a href="https://apify.com/clockworks/tiktok-video-scraper">Tiktok Video Scraper</a></td>
<td>🧛 <a href="https://apify.com/clockworks/tiktok-profile-scraper">TikTok Profile Scraper</a></td>
</tr>
<tr>
<td>🎙 <a href="https://apify.com/clockworks/tiktok-comments-scraper">TikTok Comments Scraper</a></td>
<td>🛍 <a href="https://apify.com/clockworks/tiktok-ads-scraper">Tiktok Hashtag Analytics Scraper</a></td>
<td>#️⃣ <a href="https://apify.com/clockworks/tiktok-hashtag-scraper">TikTok Hashtag Scraper</a></td>
</tr>
<tr>
<td>🎸<a href="https://apify.com/clockworks/tiktok-sound-scraper">Tiktok Sound Scraper</a></td>
<td>🔍<a href="https://apify.com/clockworks/tiktok-discover-scraper">TikTok Discover Scraper</a></td>
<td>🎙 <a href="https://apify.com/clockworks/tiktok-user-search-scraper">TikTok User Search Scraper</a></td>
</tr>
</table>

We also have put together a few AI agents that will help you extract data from social media and turn it into actionable information:

- [Comments Analyzer Agent](https://apify.com/apify/comments-analyzer-agent)
- [Influencer Discovery Agent](https://apify.com/apify/influencer-discovery-agent)
- [Local Lead Generation Agent](https://apify.com/apify/local-lead-generation-agent)

### Error items

When the scraper cannot retrieve data for a given input — for example a profile is private or a post has been deleted — it pushes an **error item** to the dataset instead of silently skipping it. Normal output items are never affected; you can tell them apart by the presence of an `errorCode` field.

#### Error item structure

```json
{
    "url": "https://www.tiktok.com/@someuser",
    "input": "someuser",
    "error": "Profile is private",
    "errorCode": "PROFILE_PRIVATE"
}
```

#### Error codes reference

| `errorCode`                      | Meaning                                                        |
| -------------------------------- | -------------------------------------------------------------- |
| `NOT_FOUND`                      | Profile or hashtag does not exist                              |
| `POST_NOT_FOUND_OR_PRIVATE`      | Post URL is gone or private                                    |
| `POST_SENSITIVE`                 | Post is flagged as sensitive content                           |
| `NO_TRENDING_FOR_HASHTAG`        | No ads found for this hashtag                                  |
| `MUSIC_NOT_FOUND`                | No videos found for the music tag                              |
| `SEARCH_QUERY_NOT_FOUND`         | No videos found for the search query                           |
| `SEARCH_QUERY_PROFILE_NOT_FOUND` | No profiles found for the search query                         |
| `FILTER_NO_PASS`                 | Videos exist but none match the active date/popularity filters |
| `PROFILE_EMPTY`                  | Profile has no videos (or is behind a login wall)              |
| `PROFILE_REPOSTS_EMPTY`          | Profile has no reposts (or is behind a login wall)             |
| `PROFILE_FOLLOWING_EMPTY`        | Profile is not following anyone                                |
| `PROFILE_FOLLOWERS_EMPTY`        | Profile has no followers                                       |
| `PROFILE_PRIVATE`                | Profile is private                                             |
| `GOOGLE_RUN_NO_RESULTS`          | Google-assisted run returned no results                        |
| `TRENDING_EMPTY`                 | Trending page returned no results                              |
| `INVALID_INPUT`                  | Actor failed due to bad configuration (run is also terminated) |
| `INVALID_URLS`                   | One or more start URLs were malformed                          |

***

### FAQ

#### How much does it cost to use TikTok Scraper?

TikTok Scraper uses the **pay-per-event** (PPE) pricing model. You’re charged a fixed price for specific events. Your costs can be easily calculated using the information in the Actor’s [pricing tab](https://apify.com/clockworks/tiktok-scraper/pricing). Note that on the paid plans a discount is applied; read our [pricing page](https://apify.com/pricing) for more details.

#### Can I use integrations with TikTok Scraper?

You can integrate TikTok Scraper with almost any cloud service or web app. We offer integrations with **Make, Zapier, Slack, Airbyte, GitHub, Google Sheets, Google Drive**, [and plenty more](https://docs.apify.com/integrations).

Alternatively, you could use [webhooks](https://docs.apify.com/integrations/webhooks) to carry out an action whenever an event occurs, such as getting a notification whenever TikTok Scraper successfully finishes a run.

#### Can I use TikTok Scraper with the Apify API?

The Apify API gives you programmatic access to the Apify platform. The API is organized around RESTful HTTP endpoints that enable you to manage, schedule, and run Apify Actors. The API also lets you access any datasets, monitor Actor performance, fetch results, create and update versions, and more.

To access the API using Node.js, use the `apify-client` [NPM package](https://apify.com/clockworks/tiktok-scraper/api/javascript). To access the API using Python, use the `apify-client` [PyPI package](https://apify.com/clockworks/tiktok-scraper/api/python).

Click on the [API tab](https://apify.com/clockworks/tiktok-scraper/api/python) for code examples, or check out the [Apify API reference](https://docs.apify.com/api/v2) docs for all the details.

#### Can I use TikTok Scraper through an MCP Server?

With Apify API, you can use almost any Actor in conjunction with an MCP server. You can connect to the MCP server using clients like ClaudeDesktop and LibreChat, or even build your own. Read all about how you can [set up Apify Actors with MCP](https://blog.apify.com/how-to-use-mcp/).

For TikTok Scraper, go to the [MCP tab](https://apify.com/clockworks/tiktok-scraper/api/mcp) and then go through the following steps:

1. Start a Server-Sent Events (SSE) session to receive a `sessionId`
2. Send API messages using that `sessionId` to trigger the scraper
3. The message starts the TikTok Scraper with the provided input
4. The response should be: `Accepted`

#### Is it legal to scrape TikTok with TikTok Scraper?

Our [TikTok scrapers](https://apify.com/store?search=tiktok) are ethical and **do not extract any private user data, such as email addresses, gender, or location.** They can only extract what the user has chosen to share publicly. However, you should be aware that your results might contain personal data.

Personal data is protected by GDPR in the European Union and other laws and regulations around the world. You should not scrape personal data unless you have a legitimate reason to do so. If you’re unsure whether your reason is legitimate, consult your lawyers. You can also read our blog post on the [legality of web scraping](https://blog.apify.com/is-web-scraping-legal/) and [ethical scraping](https://blog.apify.com/what-is-ethical-web-scraping-and-how-do-you-do-it/).

#### Your feedback

We’re always working on improving the performance of our Actors. If you have any technical feedback for TikTok Scraper or found a bug, please create an issue in the [Issues tab](https://apify.com/clockworks/tiktok-scraper/issues/open).

# Actor input Schema

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

Just add one or more TikTok hashtags and the scraper will collect data about videos containing this hashtag: likes, users, followers and more. <br> You can enter the hashtags one by one, or use the <strong>Bulk edit</strong> section to add a prepared list.

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

Add the number of tiktoks you want to scrape per hashtag, profile, or search query. This field is applicable to <strong>#️⃣ Hashtags</strong>, <strong>😎 Profiles</strong>, and <strong>🔍 Search</strong>.

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

Add one or multiple TikTok usernames or user IDs you want to scrape. You can enter the usernames one by one, or use the <strong>Bulk edit</strong> section to add a prepared list.

## `profileScrapeSections` (type: `array`):

If a profile has reposted videos, you can scrape them by selecting 'Reposts'

## `profileSorting` (type: `string`):

Select Latest to scrape the most recent videos first, Oldest - the oldest videos first, Popular - the most popular videos first. Date filters only work with Latest and Oldest. Only supported for Videos section. Note: Popular sorting is limited by TikTok to approximately 400–500 videos per profile and may return significantly fewer results than Latest or Oldest.

## `excludePinnedPosts` (type: `boolean`):

Tick to exclude pinned posts from profiles. Pinned posts are usually the first videos on a profile's page.

## `oldestPostDateUnified` (type: `string`):

Optional charged filter. Only videos uploaded after or on this date will be scraped. Alternatively, specify how old the scraped videos should be in days. Putting <code>1</code> will get you only today's posts, <code>2</code> - yesterday's and today's, and so on.

## `newestPostDate` (type: `string`):

Optional charged filter. Only videos uploaded before or on this date will be scraped.

## `mostDiggs` (type: `integer`):

Optional charged filter. Scrapes only videos with less hearts than the number you add. Doesn't work with date filters

## `leastDiggs` (type: `integer`):

Optional charged filter. Scrapes only videos with no less hearts than the number you add. Doesn't work with date filters

## `maxFollowersPerProfile` (type: `integer`):

Scrapes number of 'Followers' profiles requested from the inputted profiles. You can find the link to the dataset under the followDatasetUrl field in the output. If you want to scrape only Followers/Following profiles, go to our TikTok Followers Scraper.

## `maxFollowingPerProfile` (type: `integer`):

Scrapes number of 'Following' profiles requested from the inputted profiles. You can find the link to the dataset under the followDatasetUrl field in the output. If you want to scrape only Followers/Following profiles, go to our TikTok Followers Scraper.

## `searchQueries` (type: `array`):

Your keyword will apply to both videos <strong>and</strong> profiles. Use the <strong>Search sorting</strong> field below to specify whether you want your search to apply to top content, videos or users. <br> As for your query's format, you can use any query that works on TikTok.

## `searchSection` (type: `string`):

By default, this scraper will sort the search results by whatever shows up in the <strong>Top</strong> section of TikTok search. <br> But you can narrow it down: if you want to apply your search query to just videos, use <strong>Video</strong>, just profiles - <strong>Profile</strong>.

## `maxProfilesPerQuery` (type: `integer`):

Only applies to profile searches. In this case ignore the <strong> 💯 Number of videos </strong> section and choose the number of profiles you want to scrape here.

## `videoSearchSorting` (type: `string`):

Optional charged filter. Select how you want the search results to be sorted when searching for videos. Only valid with `/video` search section.

## `videoSearchDateFilter` (type: `string`):

Optional charged filter. Select a date range in which to search for videos. Only valid with `/video` search section.

## `scrapeRelatedSearchWords` (type: `boolean`):

Tick to include the keywords TikTok shows in the 'Others also searched for' section on the search results page. The words will be added to every video result.

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

Add the URLs of tiktok videos you want to scrape. You can paste video URLs one by one, or use the <strong>Bulk edit</strong> section to add a prepared list.

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

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

- The maximum number of scraped related videos is set by the `resultsPerPage` count.
- Note that this only works for direct video URLs from the `postURLs` field.

## `scrapeAdditionalAuthorMeta` (type: `boolean`):

Tick to fetch full author profile data (createTime, roomId) for each scraped video. Note: when scraping by profile URL, this data is already included by default — this option only makes a difference for other search types (e.g. hashtags, keywords).

## `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).

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

Tick to download TikTok slideshow images.

## `shouldDownloadAvatars` (type: `boolean`):

Tick to download authors' profile pictures.

## `shouldDownloadMusicCovers` (type: `boolean`):

Tick to download cover images of sounds used in posts.

## `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.

## `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.

## `commentsPerPost` (type: `integer`):

The number of comments extracted from every result. Due to TikTok API limitations, the actual number of scraped comments may differ, especially for posts with thousands of comments. The link to the dataset will be under a field commentsDatasetURL in the output.

## `topLevelCommentsPerPost` (type: `integer`):

The maximum number of top-level (non-reply) comments you want from a single post.

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

The maximum number of replies you want from a single comment.

Note: Successful extraction of all desired replies is currently not guaranteed.

## `proxyCountryCode` (type: `string`):

Country to use with proxy. Use it in case you want to scrape posts only available for some country.

## Actor input object example

```json
{
  "hashtags": [
    "fyp"
  ],
  "resultsPerPage": 100,
  "profileScrapeSections": [
    "videos"
  ],
  "profileSorting": "latest",
  "excludePinnedPosts": false,
  "searchSection": "",
  "maxProfilesPerQuery": 10,
  "videoSearchSorting": "MOST_RELEVANT",
  "videoSearchDateFilter": "ALL_TIME",
  "scrapeRelatedSearchWords": false,
  "scrapeRelatedVideos": false,
  "scrapeAdditionalAuthorMeta": false,
  "shouldDownloadVideos": false,
  "shouldDownloadCovers": false,
  "shouldDownloadSlideshowImages": false,
  "shouldDownloadAvatars": false,
  "shouldDownloadMusicCovers": false,
  "downloadSubtitlesOptions": "NEVER_DOWNLOAD_SUBTITLES",
  "proxyCountryCode": "None"
}
```

# 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 = {
    "hashtags": [
        "fyp"
    ],
    "resultsPerPage": 100,
    "maxFollowersPerProfile": 0,
    "maxFollowingPerProfile": 0,
    "commentsPerPost": 0,
    "topLevelCommentsPerPost": 0,
    "maxRepliesPerComment": 0,
    "proxyCountryCode": "None"
};

// Run the Actor and wait for it to finish
const run = await client.actor("clockworks/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 = {
    "hashtags": ["fyp"],
    "resultsPerPage": 100,
    "maxFollowersPerProfile": 0,
    "maxFollowingPerProfile": 0,
    "commentsPerPost": 0,
    "topLevelCommentsPerPost": 0,
    "maxRepliesPerComment": 0,
    "proxyCountryCode": "None",
}

# Run the Actor and wait for it to finish
run = client.actor("clockworks/tiktok-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "hashtags": [
    "fyp"
  ],
  "resultsPerPage": 100,
  "maxFollowersPerProfile": 0,
  "maxFollowingPerProfile": 0,
  "commentsPerPost": 0,
  "topLevelCommentsPerPost": 0,
  "maxRepliesPerComment": 0,
  "proxyCountryCode": "None"
}' |
apify call clockworks/tiktok-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=clockworks/tiktok-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/acts/GdWCkxBtKWOsKjdch/builds/ayeKtNaVfKlO77hJx/openapi.json
