# TikTok Video Search Scraper: Keyword Results (`deepmine/tiktok-video-search`) Actor

Search TikTok by keyword and get the videos TikTok shows for it, in TikTok's order: plays, likes, comments, shares, caption, hashtags, creator (with followers), sound, cover and post date, plus each video's rank. Keywords in, clean JSON out. No login.

- **URL**: https://apify.com/deepmine/tiktok-video-search.md
- **Developed by:** [DeepMine](https://apify.com/deepmine) (community)
- **Categories:** Social media, Videos
- **Features:** Limited permissions
- **Stats:** 12 total users, 6 monthly users, 99.6% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.17 / 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

## TikTok Video Search Scraper: Keyword Results

**Type keywords, get the videos TikTok's search shows for them, in TikTok's order:** plays, likes, comments, shares, saves, caption, hashtags, the creator and their followers, sound, post date, MP4 link and each video's rank. No login.

**$0.24 per 1,000 videos on the Starter plan ($0.25 Free, $0.21 Scale, $0.17 Business). The prefilled run (100 videos) costs about $0.02.**

<sub>Collected 2026-10-27 by the prefilled run (`street food`, 100 videos, build 0.2.16): 100 videos, 100 charged, 33 s from start to finish on Apify datacenter proxy at 256 MB. One observed run, not a speed promise.</sub>

**Export:** open the run's **Output** tab and click **Export** (CSV, Excel, JSON, XML or HTML), or read `https://api.apify.com/v2/datasets/<datasetId>/items?format=csv` from your code.

| Creator | Caption | ▶️ Plays | ❤️ Likes | 👥 Creator Followers | 📅 Posted | 🏅 Rank |
|---|---|---:|---:|---:|---|---:|
| [@travelfood2659](https://www.tiktok.com/@travelfood2659/video/7690122201709792518) | 하루 12판씩 팔린다는 밀떡볶이?! 석계역 떡볶이 맛집 / Spicy Tteokbokki… | 475,000 | 40,300 | 346,000 | 2026-09-27 | 1 |
| [@street.food.1610](https://www.tiktok.com/@street.food.1610/video/7693562114845248790) | Seven eggs turn Xinchang’s traditional huo la tou… | 6,900,000 | 213,000 | 271,700 | 2026-10-06 | 2 |
| [@grace.andrewsss](https://www.tiktok.com/@grace.andrewsss/video/7688849931993353503) | please forgive me if I didn’t pronounce some thing… | 174,700 | 9,576 | 220,200 | 2026-09-23 | 3 |

### Why this one

- **Up to ~250 videos per keyword.** The Actor pages through the whole search TikTok shows logged-out visitors (216 for "street food", 243 for "skincare routine", 254 for "booktok recommendations" on 2026-09-27), not just the first screen.
- **Rank included.** `rank` is the video's position in TikTok's results, so you can track who ranks for a term over time.
- **Sort by views or date, filter by window.** `sortOrder` sorts everything TikTok's search shows for the keyword by most views or newest first, then keeps your max; `datePosted` keeps the last 24 hours, 7 or 30 days, 3 or 6 months.
- **Creator size on every video.** Each row carries the creator's follower count and verified badge: find creators in a niche straight away.
- **Many keywords per run**, searched in parallel, each with its own limit and summary. Rows come keyword by keyword, in your order.
- **Related keywords.** `relatedKeywords` adds TikTok's own search suggestions for each keyword (for "street food": street food mexico, street food korea, trying street food...), free, to find the next keywords to track.
- **Fails loudly, never silently.** Every run saves a per-keyword summary (`OUTPUT`). If TikTok refuses a keyword on every retry, the run is marked failed instead of quietly returning less.
- **Fast and light.** Plain HTTP, no browser: 5 keywords and 782 videos took 32 seconds in our test.

### Input

| Field | What it does | Default |
|---|---|---|
| `keywords` | Search terms, one per line: `street food`, `skincare routine`, `https://www.tiktok.com/search?q=booktok`. | `street food` |
| `maxVideosPerKeyword` | Videos per keyword, up to 1,000 (but see "How many videos per keyword?"). | 100 |
| `sortOrder` | `relevance` (TikTok's order), `mostRecent` (newest first) or `mostViews`. The two sorts read the keyword's whole search (roughly 150-250 videos), sort it, then keep your max. | `relevance` |
| `datePosted` | `allTime`, `today`, `thisWeek`, `thisMonth`, `3months` or `6months` (the last 24 hours, 7, 30, 90 or 180 days). | `allTime` |
| `postedAfter` | Keep only videos posted after this date (`2026-09-01`, or via the API `30 days`). With `datePosted` too, the later date wins. | all |
| `relatedKeywords` | Also get TikTok's search suggestions for each keyword: a `relatedKeywords` list on every row of the keyword and in the run summary. Free; one small extra request per keyword. | `false` |
| `proxyConfiguration` | Apify Proxy. Datacenter (the default) works and sees TikTok's US results; for another country's results pick **Residential** and that country (see FAQ). | Apify datacenter |

Example:

```json
{
  "keywords": ["street food", "skincare routine"],
  "maxVideosPerKeyword": 200
}
```

The 50 most viewed videos of the last 30 days for a keyword:

```json
{
  "keywords": ["street food"],
  "maxVideosPerKeyword": 50,
  "sortOrder": "mostViews",
  "datePosted": "thisMonth"
}
```

### Output

One row per video, keyword by keyword in your order, each keyword's videos in TikTok's order (`rank` 1, 2, 3...) or in your `sortOrder`. Three table views in the Console:

- **📊 Overview**: 🖼️ Cover, 🏷️ Username, 👤 Creator, 📝 Caption, 🔗 TikTok, ▶️ Plays, ❤️ Likes, 💬 Comments, 🔁 Shares, 👥 Followers, 📅 Posted, 🔍 Keyword, 🏅 Rank
- **📈 Stats**: 🏷️ Username, 🔗 TikTok, ▶️ Plays, ❤️ Likes, 💬 Comments, 🔁 Shares, 🔖 Saves, 🔃 Reposts, 👥 Followers, ⏱️ Duration, 📅 Posted, 🔍 Keyword, 🏅 Rank
- **🔎 Details**: 🖼️ Cover, 🏷️ Username, 🔗 TikTok, ⬇️ Video File, 🤖 AI Label, 💬 Has Captions, 🌐 Caption Language, 📺 Quality, 💾 File Size, ➕ Creator Following, ❤️ Creator Likes, 🎬 Creator Videos, 🎙️ Original Sound

#### Output fields

Every row has these keys, in this order. A value TikTok didn't send is `null` (never an empty string or a made-up 0).

- `cover`: the video's cover image.
- `authorName`: the creator's display name.
- `caption`: the full caption, hashtags included.
- `captionSnippet`: the caption's first 50 characters on one line, for tables.
- `authorUsername`: the creator's TikTok username, without @.
- `videoUrl`: the video's page on TikTok.
- `authorVerified`: the creator has TikTok's verified badge.
- `isAd`: TikTok labels the post as an ad or a paid partnership.
- `plays`: views.
- `likes`: likes.
- `comments`: comments.
- `shares`: shares.
- `saves`: saves (TikTok's Favorites).
- `reposts`: reposts (TikTok's Repost button).
- `authorFollowers`: the creator's followers when the video was collected.
- `durationSeconds`: length in seconds (`null` for photo posts).
- `postedAt`: when it was posted (UTC).
- `rank`: position in TikTok's results for the keyword.
- `hashtags`: hashtags in the caption, without #.
- `soundTitle`: the sound's title ("original sound" is the creator's own audio).
- `soundUrl`: the sound's page on TikTok.
- `videoFileUrl`: the video file (MP4) in the best quality TikTok serves: a direct link anyone can open or download, no login or cookies (often H.265/HEVC, which some browsers don't play; download it to watch). `null` for photo posts.
- `videoFileExpiresAt`: when TikTok's links to the video file expire (UTC), about 2 days after the run: download before then.
- `isPhotoPost`: `true` for a photo post (slideshow); its pictures are in `photos`.
- `isAiGenerated`: TikTok labels the post as AI-generated.
- `hasCaptions`: TikTok has captions (subtitles) for the video.
- `captionLanguages`: the languages TikTok has captions in (`eng-US`, ...).
- `captionLanguage`: the caption text's language as TikTok detects it (`en`, `es`, ...).
- `onScreenText`: text the creator put on the video with TikTok's text stickers (several joined with `|`).
- `placeName`: the place the post is tagged with, when it has one.
- `placeAddress`: the tagged place's address.
- `placeCity`: the tagged place's city, when TikTok gives one.
- `width`: video width in pixels (`null` for photo posts).
- `height`: video height in pixels (`null` for photo posts).
- `definition`: TikTok's quality label (`540p`, `720p`, `1080p`).
- `format`: the video file format (`mp4`).
- `fileSizeBytes`: size of TikTok's standard video file, in bytes.
- `authorAvatar`: the creator's profile picture.
- `authorBio`: the creator's bio.
- `authorFollowing`: accounts the creator follows.
- `authorLikes`: total likes on all the creator's videos.
- `authorVideos`: the creator's public videos.
- `authorPrivate`: the creator's account is private (`null` when TikTok doesn't say).
- `soundAuthor`: the sound's artist or creator.
- `soundAlbum`: the album of a released track, when TikTok names it.
- `soundIsOriginal`: the sound is the creator's own audio, not a released track.
- `soundCover`: the sound's cover art.
- `photos`: the images of a photo post (slideshow); `null` for videos.
- `videoId`: TikTok's video ID.
- `authorId`: TikTok's user ID of the creator.
- `authorSecUid`: the creator's secUid, the ID TikTok's own web API uses.
- `soundId`: TikTok's sound ID.
- `poiId`: TikTok's ID of the tagged place.
- `playlistId`: TikTok's ID of the creator's playlist the video is in, when it's in one.
- `keyword`: the search keyword (your input).
- `relatedKeywords`: TikTok's search suggestions for the keyword (what it offers people who type it), the same on every row of the keyword. Only with `relatedKeywords`.
- `scrapedAt`: when it was collected (UTC).

Example row:

```json
{
  "cover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-p-0068-...",
  "authorName": "nativetyfood",
  "caption": "$6.25 pork roll in Taiwan 🇹🇼 #taiwan #taipei #taipeitaiwan #streetfood #taiwanfood #nativety",
  "captionSnippet": "$6.25 pork roll in Taiwan 🇹🇼 #taiwan #taipei #taip…",
  "authorUsername": "nativetyfood",
  "videoUrl": "https://www.tiktok.com/@nativetyfood/video/7352887253321960746",
  "authorVerified": false,
  "plays": 11800000,
  "likes": 389900,
  "comments": 1720,
  "shares": 3826,
  "saves": 14159,
  "authorFollowers": 1500000,
  "durationSeconds": 99,
  "postedAt": "2024-04-01T14:05:00Z",
  "rank": 2,
  "hashtags": ["taiwan", "taipei", "taipeitaiwan", "streetfood", "taiwanfood", "nativety"],
  "soundTitle": "original sound - Native Ty Food",
  "soundUrl": "https://www.tiktok.com/music/original-sound-native-ty-food-7352887503252163370",
  "photos": null,
  "videoId": "7352887253321960746",
  "keyword": "street food",
  "scrapedAt": "2026-09-27T19:07:35Z"
}
```

Notes:

- `rank` counts every video TikTok returned, including ones a date filter dropped, so gaps are normal with a date filter. It stays TikTok's position when you sort.
- TikTok rounds large counters on its web pages (269.9K plays shows as `269900`); small numbers are exact. Now and then TikTok sends a video's plays, likes, shares and saves as 0 next to real comments; those come as `null`.
- **Image links expire.** `cover` and `photos` are signed by TikTok and stop working about 2 days after the run. Download the images you need soon after the run.

#### Run summary (`OUTPUT`)

```json
{
  "results": 459,
  "inputs": [
    {"input": "street food", "status": "ok", "results": 216, "stopReason": "end", "keyword": "street food"},
    {"input": "skincare routine", "status": "ok", "results": 243, "stopReason": "end", "keyword": "skincare routine"},
    {"input": "porn", "status": "no_results", "results": 0, "stopReason": "no_results", "error": "TikTok shows no results for this keyword (it hides results for some terms)"}
  ]
}
```

`status` per keyword: `ok`, `no_results` (TikTok shows nothing, or hides results for that term), `invalid`, `blocked` (TikTok refused it on every retry; the run fails so you notice), `stopped` (your spending limit). `stopReason`: `max_results`, or `end` when TikTok showed no more videos. `filteredOut` counts videos dropped by `datePosted` or `postedAfter`; with a sort, `sortedFrom` is how many videos were read and sorted. With `relatedKeywords`, each keyword's suggestions are in `relatedKeywords` too.

### How many videos per keyword?

TikTok shows logged-out visitors a fixed list of roughly **150 to 250 videos per search**, and it's the same list for every visitor (three separate visits to "street food" together added only 6%). For more coverage, add related keywords or long-tail variations ("street food bangkok", "street food nyc").

### Pricing

Pay per result, no start fee and no minimum. Example: 1,000 videos cost $0.24 on the Starter plan.

| Your Apify plan | Per 1,000 videos |
|---|---|
| Free | $0.25 |
| Starter | $0.24 |
| Scale | $0.21 |
| Business | $0.17 |

You pay only for rows that reach your dataset. Keywords with no results and invalid inputs cost nothing. When your spending limit is reached, the run stops.

A video found under several keywords in one run is one row and one charge: it comes back once, under the first keyword that found it, and the run summary counts the repeats for each keyword (`alreadyDeliveredUnderEarlierInput`).

### FAQ

**Do I need a TikTok account?** No. The Actor reads only what TikTok shows logged-out visitors.

**Can I sort by date or by views?** Yes: set `sortOrder` to `mostRecent` or `mostViews`. The videos are sorted after collecting, over everything TikTok's search shows for the keyword (roughly 150-250 videos), and then your max is kept, so `maxVideosPerKeyword: 20` with `mostViews` gives the 20 most viewed of the whole search. The run reads the whole search for that, so it takes a little longer; you pay only for the videos you get. `datePosted` keeps a recent window.

**Can I see what ranks in another country?** Yes: TikTok picks the results by the visitor's IP country (its region settings change nothing). In **Proxy**, pick Residential and the country. In our test (2026-10-27, "street food", 20 videos) a German residential IP and a US one shared 3 of 20 videos, while US residential and the default datacenter matched 20 of 20. Datacenter IPs are US only: choosing another country with datacenter fails the run.

**Why did a nonsense keyword return videos?** TikTok falls back to loosely related videos when nothing matches well. Check `caption` and `hashtags` if you need exact matches.

**The same video under two keywords?** It's one row and one charge, under the first keyword that found it (see Pricing).

**Hashtags?** Searching `#booktok` works like any keyword. For a hashtag's own feed plus its total views, use our [TikTok Hashtag Videos API](https://apify.com/deepmine/tiktok-hashtag-videos).

**What next with the videos I found?** Pass the `videoUrl` fields to [TikTok Comments Scraper](https://apify.com/deepmine/tiktok-comments-scraper) for their comments, or the `authorUsername` fields to [TikTok Profile Scraper](https://apify.com/deepmine/tiktok-profile-videos) for each creator's feed and exact profile counts.

### Feedback

Missing a field, or a result that doesn't look right? Open an issue on the **Issues** tab and we'll look into it. If the data helps you, a short review on this page helps other people find it.

# Actor input Schema

## `keywords` (type: `array`):

Search terms, one per line, as you'd type them on TikTok. A tiktok.com/search?q=... URL works too. Example: street food

## `maxVideosPerKeyword` (type: `integer`):

Videos to get per keyword, in TikTok's order. TikTok shows logged-out visitors roughly 150-250 videos per search. You pay per video.

## `sortOrder` (type: `string`):

Relevance keeps TikTok's order. Newest first and Most views sort everything TikTok's search shows for the keyword (roughly 150-250 videos), then keep your max: the run reads the whole search, but you pay only for the videos you get.

## `datePosted` (type: `string`):

Keep only videos posted in this window (a month is 30 days). TikTok's results aren't sorted by date, so a short window can return fewer videos than your max.

## `postedAfter` (type: `string`):

Skip videos posted before this date (YYYY-MM-DD). Via the API you can also pass a relative time such as '30 days'. TikTok's results aren't sorted by date, so this filters the videos TikTok returns. Leave empty for all.

## `relatedKeywords` (type: `boolean`):

Also get TikTok's search suggestions for each keyword (what TikTok offers people who type it): a relatedKeywords list on every row of the keyword and in the run summary. Free; one small extra request per keyword.

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

TikTok is reached through Apify Proxy. Datacenter proxies (the default) work and see TikTok's US results. For another country's results pick Residential and that country (TikTok picks results by the visitor's IP country).

## Actor input object example

```json
{
  "keywords": [
    "street food"
  ],
  "maxVideosPerKeyword": 100,
  "sortOrder": "relevance",
  "datePosted": "allTime",
  "relatedKeywords": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

No description

## `summary` (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 = {
    "keywords": [
        "street food"
    ],
    "maxVideosPerKeyword": 100,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("deepmine/tiktok-video-search").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 = {
    "keywords": ["street food"],
    "maxVideosPerKeyword": 100,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("deepmine/tiktok-video-search").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 '{
  "keywords": [
    "street food"
  ],
  "maxVideosPerKeyword": 100,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call deepmine/tiktok-video-search --silent --output-dataset

```

## MCP server setup

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

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/jYEa8i47xRPBmgg57/builds/gn2wcEtLl57mFRzpl/openapi.json
