How to Scrape TikTok Search Results
To scrape TikTok search results, put your search terms in the keywords input of apidojo's TikTok Scraper on Apify, choose a sortType and a location country, and run it.

To scrape TikTok search results, put your search terms in the keywords input of apidojo’s TikTok Scraper on Apify, choose a sortType and a location country, and run it. It returns every matching video with its views, likes, comments, shares, saves, hashtags, sound and the creator’s profile, at $0.30 per 1,000 posts. You can also paste TikTok search page URLs into startUrls.
TikTok search shows results one swipe at a time and can’t be exported. This guide covers keyword inputs, sorting and country targeting, turning video results into a list of creators, and costs. Searching in the app is covered in how to search on TikTok. Every other collection task is mapped in how to scrape TikTok data.
How Do You Scrape TikTok Search Results by Keyword?
You scrape search results by listing one or more keywords and letting the actor run each search. Listed below are the 4 steps.
- Open TikTok Scraper.
- Add your search terms to
keywords, one per line. - Set
sortType,locationandmaxItems. - Run it and download the results as JSON, CSV, Excel or XML.
{
"keywords": ["protein breakfast", "high protein snacks"],
"sortType": "MOST_LIKED",
"location": "GB",
"includeSearchKeywords": true,
"maxItems": 2000
}
includeSearchKeywords adds the keyword that found each video, so results from several searches stay separable (Apify).
How Do You Sort and Target TikTok Search Results?
The sortType and location inputs mirror TikTok’s own search filters and country targeting. The table shows the options (Apify).
| Input | Options | Use it for |
|---|---|---|
sortType |
RELEVANCE |
What TikTok’s search shows first |
sortType |
MOST_LIKED |
The best-performing videos on a topic |
sortType |
DATE_POSTED |
The newest videos, for trends and monitoring |
location |
ISO country code, such as US, GB, DE |
Results as seen in that country |
sortType applies only to keywords, not to startUrls. Each search should return at least 10 posts.
How Do You Scrape TikTok Search Page URLs?
If you’ve already built a search on tiktok.com, paste its URL into startUrls; search URLs are one of the URL types the actor accepts, alongside profiles, hashtags, sounds and locations. Use keywords when you want to control sorting and country from the input instead.
How Do You Turn Video Results Into a List of Creators?
Every video result carries a channel object with the creator’s username, follower count, bio and verification, so de-duplicating those objects turns a keyword search into a creator list. This is the fastest way to find accounts active in a niche.
from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("apidojo/tiktok-scraper").call(run_input={
"keywords": ["sourdough baking"],
"sortType": "MOST_LIKED",
"maxItems": 1000,
})
creators = {}
for post in client.dataset(run.default_dataset_id).iterate_items():
ch = post["channel"]
c = creators.setdefault(ch["username"], {"followers": ch["followers"], "videos_found": 0, "views": 0})
c["videos_found"] += 1
c["views"] += post["views"]
for name, c in sorted(creators.items(), key=lambda x: -x[1]["views"])[:20]:
print(name, c)
Narrowing that list to the right creators is covered in how to find TikTok influencers by niche with data, and checking individual accounts in how to find someone on TikTok.
What Does Scraping TikTok Search Results Cost?
TikTok Scraper costs $0.30 per 1,000 posts, so 10 keywords with 1,000 results each cost $3. For many small, frequent searches, TikTok Scraper API charges $0.006 per query, including the first 10 to 20 posts, then $0.0003 per post (Apify).
| Searches | Results each | TikTok Scraper cost |
|---|---|---|
| 1 | 1,000 | $0.30 |
| 10 | 1,000 | $3 |
| 50 | 2,000 | $30 |
Why Does a TikTok Search Scrape Return Few Results?
A search returns few results when maxItems is low, the keyword is very narrow, or the country has little content for it. The actor’s documentation suggests checking maxItems, testing a broader or more popular term, and checking the location code (Apify). Splitting a broad topic into several specific keywords also helps each search stay relevant. More on limits is in TikTok scraping limits.
Questions people ask
Can you scrape TikTok search results for hashtags?
Yes, but hashtag pages give fuller results; see how to scrape TikTok hashtag pages.
Can you scrape TikTok user search results?
Collect video results and de-duplicate the creators, as shown above, or check known profiles by URL with TikTok User Scraper.
Can you scrape TikTok search results by date?
Yes, the dateRange input applies TikTok's own search date filter to keyword searches, with options such as YESTERDAY, THIS_WEEK, THIS_MONTH, LAST_THREE_MONTHS and LAST_SIX_MONTHS. Combine it with sortType: DATE_POSTED for the newest first, and filter by uploadedAtFormatted in the export (Apify).