# TikTok Ads Library Scraper: EU Ads, Targeting & Reach (`wakeful_outhouse/tiktok-ads-library-scraper`) Actor

Scrape TikTok Ad Library ads shown in the EU, EEA and UK by keyword, advertiser or URL: advertiser, run dates, videos, audience. $0.50 per 1,000 ads; optional CTA, landing page, payer, targeting and impressions by country. Monitor mode returns only new ads. No login.

- **URL**: https://apify.com/wakeful_outhouse/tiktok-ads-library-scraper.md
- **Developed by:** [Roman](https://apify.com/wakeful_outhouse) (community)
- **Categories:** Marketing, Social media, Lead generation
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 1,000 ad records

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

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## TikTok Ads Library Scraper

**Export the ads any brand runs on TikTok in Europe into a spreadsheet.** Search by keyword, exact phrase or advertiser, or paste a search link copied from the TikTok Ad Library. For media buyers, agencies, e-commerce teams and ad researchers. No login, no cookies, no TikTok account.

- ✍️ **Ad text and creatives**: caption, video URLs and cover images of every ad.
- 📅 **How long it ran**: first and last shown date and the number of days.
- 🎯 **Targeting** (optional): ages, gender, countries, regions, interests, audience size, custom and excluded audiences.
- 🔗 **Landing page and payer** (optional): call to action, landing page URL, campaign objective, who paid for the ad and the advertiser's TikTok account with followers.
- 📊 **Impressions by country, age and gender** (optional), as TikTok publishes them under the EU Digital Services Act.
- 🔔 **Monitor mode**: name a search, schedule it, and each run returns only new ads. Old ads are not charged.

**Good to know.** TikTok publishes its Ad Library only for ads shown in the **EU, EEA, Switzerland and the UK**, so ads that ran only in the US or Asia are not there. Impressions and audience are ranges (for example `10K-100K`), and spend is published for very few ads. A keyword search returns at most 5,000 ads, and TikTok sometimes ends a result list earlier than the total it reports.

**Try it in 1 click:** press **Start**. The input is prefilled with the keyword `nike` and 50 ads; the run takes about 40 seconds and costs about $0.03. Then enter your own keywords or advertisers, or set up a search on the Ad Library website and paste its address; its filters are used.

**Price:** $0.50 per 1,000 ads. Ad details (CTA, landing page, payer, targeting, impressions by country) are optional: $5 per 1,000 ads, charged only when TikTok returns them.

Same competitor on Meta or Google? Use the [Facebook Ads Library Scraper](https://apify.com/wakeful_outhouse/facebook-ads-library-scraper) and the [Google Ads Transparency Scraper](https://apify.com/wakeful_outhouse/google-ads-transparency-scraper). Independent tool, not affiliated with TikTok or ByteDance.

### Use cases

- **Competitor research**: see every ad a competitor ran on TikTok in Europe and which creatives ran the longest.
- **Hook and caption swipe files**: export hundreds of TikTok ad captions and CTAs from a niche.
- **Creative inspiration**: collect the videos of the top ads in your market, sorted by impressions.
- **Targeting research**: see which ages, countries and interests competitors target and how big their audiences are.
- **Agency pitches and audits**: show a prospect what their competitors run on TikTok, by country.
- **E-commerce and dropshipping**: find products and landing pages brands keep advertising.

### Input

| Field | Description |
|---|---|
| `queries` | One per line: a keyword or advertiser name (`nike`), an exact phrase in quotes (`"black friday"`), an advertiser business ID (the `advertiserBizId` of a result), a `library.tiktok.com/ads?…` search URL or a single ad URL |
| `country` | Country where the ads were shown, or all countries |
| `lastDays` | Ads shown during the last N days (default 30, up to 365) |
| `dateFrom` / `dateTo` | Ads shown in this date range (wins over `lastDays`) |
| `sortBy` | Last shown, newest, oldest, most or fewest impressions |
| `includeAdDetails` | Add CTA, landing page, objective, payer, the TikTok account, targeting and impressions by country (one extra request per ad) |
| `monitorName` | Name a search to get only new ads on each run (see Monitoring new ads) |
| `maxAdsPerQuery` | Limit per input line (0 = everything) |
| `maxConcurrency` | How many queries run in parallel |

```json
{
  "queries": ["nike", "\"black friday\""],
  "country": "DE",
  "lastDays": 90,
  "sortBy": "most_impressions",
  "includeAdDetails": true,
  "maxAdsPerQuery": 200
}
```

When you paste a search URL from library.tiktok.com, its filters (country, dates, sort order, advertiser) are used, so you can set up a search on the website and copy the address bar.

### Output example

```json
{
  "query": "adidas",
  "adId": "1878040557795473",
  "adLibraryUrl": "https://library.tiktok.com/ads/detail/?ad_id=1878040557795473",
  "advertiserName": "Snipes SE",
  "firstShownDate": "2026-10-04",
  "lastShownDate": "2026-10-06",
  "daysShown": 3,
  "adText": "Ontdek adidas!",
  "estimatedAudience": "0-1K",
  "format": "VIDEO",
  "videoUrls": ["https://library.tiktok.com/api/v1/cdn/.../video/..."],
  "imageUrls": ["https://p16-common-sign.tiktokcdn.com/...jpeg"],
  "previewImageUrl": "https://p16-common-sign.tiktokcdn.com/...jpeg"
}
```

#### With `includeAdDetails`

```json
{
  "callToAction": "Buy now",
  "landingPageUrl": "https://www.snipes.com/nl-nl/b/adidas-825?utm_source=tiktok&...",
  "advertisingObjective": "Sales",
  "topic": "Apparel & Accessories",
  "advertiserSponsor": "SNIPES SE",
  "advertiserBizId": "6876496928549372673",
  "advertiserRegistryLocation": "Germany",
  "tiktokUsername": "snipes",
  "tiktokFollowers": "801.9K",
  "tiktokAccountType": "BLUEV_BA",
  "targetAges": ["18-24", "25-34", "35-44", "45-54"],
  "targetGender": ["female", "male", "unknown"],
  "targetCountries": ["NL"],
  "targetAudienceSize": "6.2M-7.5M",
  "customAudience": "No",
  "excludedAudience": "Yes",
  "impressionsByCountry": [
    {"country": "NL", "impressions": "0-1K",
     "byAgeGender": [{"age": "18-24", "gender": "MALE", "impressions": "0-1K"}]}
  ],
  "totalImpressions": "0-1K",
  "regionsReached": 1
}
```

You are charged the detail fee only for ads where TikTok returned these data.

### Monitoring new ads

Track competitors without paying twice for the same ads:

1. Fill in `queries` and filters as usual and set `monitorName`, for example `competitors-de`.
2. Save the input as a Task and add an Apify **Schedule** (daily or weekly).
3. The first run returns every matching ad. Each later run with the same `monitorName` returns only ads that earlier runs have not returned. Old ads are skipped and **not charged**.

Connect a webhook or the Slack / email integration to the Task to get new ads delivered. The list of seen ads is stored in the `tiktok-ads-monitor` key-value store in your account. To start over, use a new `monitorName` or delete its record from that store.

### Pricing

Pay per event, no subscription:

| Event | Price |
|---|---|
| Ad record | $0.50 per 1,000 ads |
| Ad details (optional, `includeAdDetails`) | $5 per 1,000 ads, only for ads where TikTok returned details |
| Actor start | $0.00005 per run |

Example: 1,000 ads without details cost about $0.50; with details about $5.50. In monitor mode ads you already have are not charged.

Set a maximum cost per run in the Apify Console, and the scraper stops cleanly when it is reached.

### Tips

- Keep Apify Proxy with the **Residential** group, which is the default. TikTok blocks datacenter IPs. Traffic is tiny, about 40 MB per 1,000 ads with details.
- The scraper runs a real browser, because TikTok checks every request with its anti-bot script. Without details it saves hundreds of ads per minute. Details open each ad's page one at a time (faster gets blocked by TikTok), about 15–20 seconds per ad, so 100 ads with details take about 30 minutes. Turn details on for a shortlist, for example `maxAdsPerQuery` 50 sorted by most impressions.
- Big brands have thousands of ads. Narrow with `country`, `lastDays` or dates, or set `maxAdsPerQuery`.
- To get all ads of one advertiser, take `advertiserBizId` from any of its ads and use it as a query.
- Video URLs are signed by TikTok and expire after some time. Download the videos you need soon after the run.
- In monitor mode `maxAdsPerQuery` counts all ads checked, new and old. Leave it at 0 or set it above the advertiser's total so new ads are not missed.

### Integrations, API and MCP

**REST API.** Run the Actor and get the results in one call (replace `YOUR_APIFY_TOKEN`; it's in Console → Settings → API & Integrations):

```bash
curl -X POST "https://api.apify.com/v2/acts/wakeful_outhouse~tiktok-ads-library-scraper/run-sync-get-dataset-items" \
  -H "Authorization: Bearer YOUR_APIFY_TOKEN" -H "Content-Type: application/json" \
  -d '{"queries": ["nike"], "country": "DE", "maxAdsPerQuery": 50}'
```

**Python** (`pip install apify-client`):

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("wakeful_outhouse/tiktok-ads-library-scraper").call(run_input={"queries": ["nike"], "country": "DE", "maxAdsPerQuery": 50})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)
```

**AI agents (MCP).** Give Claude, Cursor or any MCP client this Actor as a tool through the Apify MCP server:

- hosted: `https://mcp.apify.com?tools=wakeful_outhouse/tiktok-ads-library-scraper`
- local: `npx -y @apify/actors-mcp-server --actors wakeful_outhouse/tiktok-ads-library-scraper` (set `APIFY_TOKEN`)

**No-code.** Use the Apify integrations for **Make, Zapier, n8n, Google Sheets, Slack** and **webhooks**: for example, run the Actor on a Schedule and send each new competitor ad to a Slack channel or append the ad captions to a Google Sheet. All formats are available as JSON, CSV, Excel and HTML from the dataset.

### More ad-intelligence tools

Same author, same data format, same pay-per-result pricing:

- [Facebook Ads Library Scraper](https://apify.com/wakeful_outhouse/facebook-ads-library-scraper) — ad copy, creatives, run dates, EU reach and demographics for ads on Facebook, Instagram, Messenger and Threads.
- [Google Ads Transparency Scraper](https://apify.com/wakeful_outhouse/google-ads-transparency-scraper) — ad copy, YouTube IDs, impressions and regions from the Google Ads Transparency Center.
- [LinkedIn Ad Library Scraper](https://apify.com/wakeful_outhouse/linkedin-ad-library-scraper) — B2B ad copy, CTAs, landing pages, media, impressions by country and targeting from the LinkedIn Ad Library.
- [Google Trends Scraper](https://apify.com/wakeful_outhouse/google-trends-scraper) — interest over time, interest by region, related queries and today's trending searches by country, to see which keywords are rising.
- [Pinterest Scraper with AI Image Analysis](https://apify.com/wakeful_outhouse/pinterest-ai-scraper) — pins, images, videos, boards and creators from Pinterest search, with optional AI tags for style, colors, objects and category.

All tools: https://apify.com/wakeful_outhouse

### FAQ

**Is it legal?** The TikTok Ad Library is a public database TikTok publishes under the EU Digital Services Act so anyone can inspect ads. The scraper collects only what the website shows publicly without logging in. You are responsible for how you use the data.

**Why are there no US ads?** TikTok's Ad Library covers only ads shown in the EU, EEA, Switzerland and the UK.

**Why are impressions and spend often empty?** In search results TikTok shows impressions only for some ads and spend almost never. Turn on `includeAdDetails` to get impressions by country, age and gender for every ad.

**Why did a query return fewer ads than "ads match"?** TikTok reports up to 5,000 matches but sometimes ends the list earlier. Narrow the search with a country or a shorter date range and run several queries.

**Something broke?** Open an issue on the Issues tab with the run link. I usually reply within a day.

**Missing a field or filter?** Open an issue on the Issues tab and tell me what you need. **Did it save you time?** A short rating on the Reviews tab helps other people find this tool.

# Actor input Schema

## `queries` (type: `array`):

One per line. A keyword or advertiser name (<code>nike</code>), an exact phrase in quotes (<code>"black friday"</code>), an advertiser business ID (the <code>advertiserBizId</code> field of a result), a <code>library.tiktok.com/ads?…</code> search URL copied from your browser (its filters are used) or a single ad URL (<code>library.tiktok.com/ads/detail/?ad_id=…</code>).

## `country` (type: `string`):

Country where the ads were shown. TikTok publishes ads shown in the EU, EEA, Switzerland and the UK.

## `lastDays` (type: `integer`):

Ads shown during this many days before today. Ignored when Shown from is set.

## `dateFrom` (type: `string`):

Only ads shown on or after this date.

## `dateTo` (type: `string`):

Only ads shown on or before this date. Default: today.

## `sortBy` (type: `string`):

Order of the results, as on the website.

## `includeAdDetails` (type: `boolean`):

Add the ad caption, call to action, landing page, who paid, the advertiser's TikTok account, targeting (ages, gender, countries, interests, audiences) and impressions by country. Makes one extra request per ad. Charged per ad only when TikTok returns these data.

## `monitorName` (type: `string`):

Turn on monitoring: give this search any name, for example <code>competitors-de</code>. Each run then saves only ads that earlier runs with the same name have not returned, so you pay only for new ads. Use it with an Apify Schedule. The first run returns everything. The list of seen ads is kept in the <code>tiktok-ads-monitor</code> key-value store of your account. Leave empty for a normal run.

## `maxAdsPerQuery` (type: `integer`):

Stop after this many ads for each input line. 0 means no limit. In monitor mode this counts all ads checked, new and already seen.

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

How many queries run in parallel.

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

Residential proxy is required: TikTok blocks other IPs.

## Actor input object example

```json
{
  "queries": [
    "nike"
  ],
  "country": "all",
  "lastDays": 30,
  "sortBy": "last_shown",
  "includeAdDetails": false,
  "maxAdsPerQuery": 50,
  "maxConcurrency": 5,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `ads` (type: `string`):

All scraped ads with advertiser, dates, impressions, media and, optionally, ad text, landing page and targeting

# 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 = {
    "queries": [
        "nike"
    ],
    "includeAdDetails": false,
    "maxAdsPerQuery": 50,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("wakeful_outhouse/tiktok-ads-library-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 = {
    "queries": ["nike"],
    "includeAdDetails": False,
    "maxAdsPerQuery": 50,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("wakeful_outhouse/tiktok-ads-library-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 '{
  "queries": [
    "nike"
  ],
  "includeAdDetails": false,
  "maxAdsPerQuery": 50,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call wakeful_outhouse/tiktok-ads-library-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,wakeful_outhouse/tiktok-ads-library-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/pquu54N05NcdQkM5Q/builds/SnrqfH3mCYhqb1IDA/openapi.json
