# Meta Ads Library Scraper: Facebook & Instagram Ads · $0.40/1K (`pomlabs/meta-ads-library-scraper`) Actor

Facebook & Instagram Ad Library: search by keyword, Page, advertiser, URL or ad ID. Creatives, video, links, days running, variations, winning score, EU reach and demographics, landing page, monitor. No login. Hard cost cap. $0.40 per 1,000 ads.

- **URL**: https://apify.com/pomlabs/meta-ads-library-scraper.md
- **Developed by:** [Pom Labs](https://apify.com/pomlabs) (community)
- **Categories:** Marketing, Social media, Lead generation
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.30 / 1,000 ads delivered

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/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

## Meta Ads Library Scraper: Facebook & Instagram ads

Read the public Meta Ad Library (Facebook, Instagram, Messenger, Audience Network and Threads) without a login. Search by keyword, advertiser, Page, Ad Library URL or ad ID, filter like on the site, and get every ad as a clean row. **$0.40 per 1,000 ads.**

### What you can do

- **Search:** keywords (any order or exact phrase), advertiser names, Page IDs or Page URLs, any pasted Ad Library URL, single ad IDs.
- **Filter:** one, several or ALL countries; active, inactive or all; political, housing, employment and credit ads; image, video, meme or text; platform; language; start date range or last 24 h to 90 days; running for at least N days; sort by relevance, newest or impressions.
- **Count first:** `onlyTotal` returns how many ads each search has.
- **Find the winners:** every ad has `activeDays`, `variationCount` and a `winningScore` (days running × variations).
- **Dig deeper (optional):** EU and UK reach by country, age and gender, targeting, payer and beneficiary, advertiser Page info (likes, Instagram followers, verification, political spend); landing page with final URL, price, e-commerce platform, Meta Pixel and Google tag IDs; saved video and image files.
- **See every version:** `expandVariants` opens the ads Meta groups under one creative and text, one row each.
- **Pull big lists faster:** `parallelSlices` reads one search as several streams at once and still delivers each ad once (2,000 ads: 345 s in one stream, 85 s in parallel, our test of December 2026).
- **Turn the creative into text:** `transcribeVideos` (transcript, language, first 3 seconds as `hook3s`, timed segments) and `ocrImageAds` (`imageText`, the words on the image or video cover).
- **Understand the angle:** `analyzeAds` adds `aiAnalysis`: hook, offer, offer type, marketing angle, emotional trigger, target persona, call to action and a one-line summary.
- **Watch competitors:** `onlyNewAds` returns only what is new since the last run.

### You never pay more than you ask

`maxAds` is a hard cap for the whole run, and `maxCostUsd` stops before your budget. Searches with no ads, searches Meta refuses and invalid inputs are free. A run where Meta refuses everything fails instead of "succeeding" with nothing.

### Example input

```json
{ "searchQueries": ["running shoes"], "country": "US", "mediaType": "video", "longRunningDays": 30, "maxAds": 200 }
```

### Output (one row per ad)

`adArchiveId`, `adLibraryUrl`, `pageId`, `pageName`, `pageUrl`, `pageLikes`, `isActive`, `startDate`, `endDate`, `activeDays`, `variationCount`, `winningScore`, `platforms`, `text`, `title`, `linkDescription`, `ctaText`, `ctaType`, `linkUrl`, `displayFormat`, `images`, `videos` (HD and SD), `cards`, `spend`, `impressions`, `currency` and `paidFor` (where Meta publishes them, mostly political ads), `totalAdsInSearch`, transparency flags (`containsDigitalCreatedMedia`, `containsSensitiveContent`, `hasUserReported`, `pageIsDeleted`, `stateMediaRunLabel`, `isAaaEligible`), and more. A summary per search is in the `SUMMARY` record.

### Prices

| What | Price |
|---|---|
| Ad | $0.40 per 1,000 |
| Ad details (reach, demographics, advertiser) | $0.60 per 1,000 |
| Saved media (per ad, up to 3 videos and 4 images) | $3.00 per 1,000 |
| Landing page analysis | $1.00 per 1,000 |
| Video transcript (only when the video has speech) | $10.00 per 1,000 |
| Text on the image (only when there is text) | $3.00 per 1,000 |
| AI marketing analysis | $5.00 per 1,000 |
| Count of a search (`onlyTotal`) | $0.001 each |

### Good to know

Meta shows spend and impressions only for political and issue ads, and reach and demographics mainly for ads delivered in the EU and UK: fields Meta does not publish come back empty. No login or cookies needed from you.

### Support, feedback and requests

Questions, bug reports, complaints, feature requests, or an idea for a new tool? Email us at **pomexplica+support@gmail.com**, in any language. We read our inbox every day and answer every message. Suggestions and feedback of every kind are welcome: tell us what you need and we will look into it.

# Actor input Schema

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

One search per keyword or phrase, e.g. running shoes. Leave everything empty to try a sample search.

## `urls` (type: `array`):

Paste any Ad Library URL (all its filters are kept), a single ad URL (?id=...) or a Facebook Page URL.

## `pageIds` (type: `array`):

Numeric Facebook Page IDs: all ads of that advertiser.

## `advertisers` (type: `array`):

Advertiser or Page names, e.g. Nike. We find the matching Page and return its ads.

## `adIds` (type: `array`):

Specific ads by Library ID.

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

2-letter code of the country where ads are shown (US, BR, GB, DE...) or ALL.

## `countries` (type: `array`):

Run every keyword, Page and advertiser in each of these countries (overrides Country).

## `maxAds` (type: `integer`):

Hard cap for the whole run. The run never returns or charges more ads than this.

## `maxAdsPerSearch` (type: `integer`):

Cap for each keyword, Page or URL (default: same as the total).

## `maxCostUsd` (type: `string`):

Stop before event charges pass this amount, e.g. 0.50. Optional; works together with the platform's own maximum cost per run.

## `onlyTotal` (type: `boolean`):

Return just the number of ads in the Library for each search (no ads).

## `activeStatus` (type: `string`):

Active, inactive or all ads.

## `adType` (type: `string`):

Category of the ads.

## `mediaType` (type: `string`):

Filter by creative type.

## `platforms` (type: `array`):

Only ads shown on these platforms.

## `languages` (type: `array`):

Content language codes, e.g. en, pt, es.

## `exactPhrase` (type: `boolean`):

Match the keyword as an exact phrase instead of any word order.

## `period` (type: `string`):

Only ads that started in this period.

## `startDateFrom` (type: `string`):

Only ads that started on or after this date (YYYY-MM-DD).

## `startDateTo` (type: `string`):

Only ads that started on or before this date (YYYY-MM-DD).

## `longRunningDays` (type: `integer`):

Only ads that have run N days or more: the ones worth copying.

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

Order of the ads. With a start date filter and "relevance", the newest come first.

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

EU/UK reach by country, age and gender, targeting, payer and beneficiary, advertiser Page info (likes, Instagram followers, verification, political spend). Charged per ad with details.

## `expandVariants` (type: `boolean`):

When Meta groups several ads under one creative and text, return every one of them as its own row (own ID, dates and platforms). Each row is charged as an ad.

## `parallelSlices` (type: `boolean`):

Reads each search as several streams at once (all ads, videos, images, memes) and delivers every ad once. Up to 4x faster on pulls of hundreds or thousands of ads; the order of the rows is mixed. Ignored with maxAdsPerSearch.

## `analyzeLandingPage` (type: `boolean`):

Follow the ad link: final URL, title, price, e-commerce platform, Meta Pixel and Google tag IDs. Charged per page read.

## `transcribeVideos` (type: `boolean`):

Adds the speech of the ad video as text: transcript, language, the words of the first 3 seconds (hook3s) and timed segments. Charged only when the video has speech.

## `ocrImageAds` (type: `boolean`):

Adds imageText: the words written on the ad image (or on the video cover). Charged only when there is text.

## `analyzeAds` (type: `boolean`):

Adds aiAnalysis: hook, offer, offer type, angle, emotional trigger, target persona, call to action and summary. Uses the transcript and image text too when those are on.

## `downloadMedia` (type: `string`):

Save the creatives (videos and images) to storage, since Meta links expire. Charged per ad with saved files.

## `onlyNewAds` (type: `boolean`):

Return only ads not delivered by earlier runs with the same searches (or the same monitor name). Schedule the run to watch competitors.

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

Optional name of the monitor memory.

## `includeRawData` (type: `boolean`):

Add every field Meta returns for the ad.

## `concurrency` (type: `integer`):

How many searches run at once.

## Actor input object example

```json
{
  "searchQueries": [
    "running shoes"
  ],
  "country": "US",
  "maxAds": 30,
  "onlyTotal": false,
  "activeStatus": "active",
  "adType": "all",
  "mediaType": "all",
  "exactPhrase": false,
  "period": "any",
  "sortBy": "relevance",
  "includeAdDetails": false,
  "expandVariants": false,
  "parallelSlices": false,
  "analyzeLandingPage": false,
  "transcribeVideos": false,
  "ocrImageAds": false,
  "analyzeAds": false,
  "downloadMedia": "none",
  "onlyNewAds": false,
  "includeRawData": false,
  "concurrency": 4
}
```

# 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 = {
    "searchQueries": [
        "running shoes"
    ],
    "maxAds": 30
};

// Run the Actor and wait for it to finish
const run = await client.actor("pomlabs/meta-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 = {
    "searchQueries": ["running shoes"],
    "maxAds": 30,
}

# Run the Actor and wait for it to finish
run = client.actor("pomlabs/meta-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 '{
  "searchQueries": [
    "running shoes"
  ],
  "maxAds": 30
}' |
apify call pomlabs/meta-ads-library-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,pomlabs/meta-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/GdbjtWZyzwdbmBq6Q/builds/h7LnDyJH3feOB9AXL/openapi.json
