Facebook Ads Library Scraper — Meta Ad Library API avatar

Facebook Ads Library Scraper — Meta Ad Library API

Pricing

from $2.40 / 1,000 ad scrapeds

Go to Apify Store
Facebook Ads Library Scraper — Meta Ad Library API

Facebook Ads Library Scraper — Meta Ad Library API

Scrape the Facebook Ads Library (Meta Ad Library) by keyword, Page or URL: ad copy, creatives, CTA, dates, winner score. For ad research. $3.001 per 1,000 ads.

Pricing

from $2.40 / 1,000 ad scrapeds

Rating

0.0

(0)

Developer

Muhammad Afzal

Muhammad Afzal

Maintained by Community

Actor stats

0

Bookmarked

9

Total users

3

Monthly active users

18 days ago

Last modified

Features

Limited permissions

Share

Facebook Ads Library Scraper exports ads from the public Meta Ad Library (the Facebook Ads Library) by keyword, advertiser Page, or Ad Library URL: ad copy, headline, call to action, landing page, image and video links, platforms, start and end dates, days running, and a winner score. It is built for performance marketers, agencies, and e-commerce researchers who study competitor ads, and costs USD 3.001 per 1,000 ads at the Apify FREE tier (USD 2.40 per 1,000 on GOLD and above).

No Facebook login, cookies, or Meta developer token are needed. The Actor handles data access to the public Ad Library and returns one flat JSON record per ad through the Apify API, MCP, or a dataset export (JSON, CSV, Excel).

What data does the Facebook Ads Library Scraper return?

Every ad is one record. Values the Ad Library does not show are null or an empty list, never guessed.

Data groupFields
Ad identityadId, adSnapshotUrl (link to the ad in the Ad Library), adLibraryUrl, sourceUrl
AdvertiserpageName, pageId, pageUrl, pageProfilePictureUrl, pageLikeCount, pageVerified, pageCategory, categories
Ad copyadText, headline, linkDescription, wordCount, hashtags, emojiCount
Call to actionctaText, ctaType, ctaUrl (landing page), detectedCtas (CTA phrases found in the copy)
CreativedisplayFormat, mediaType, imageUrls, videoUrls (HD, SD, preview), carouselCards
Deliveryplatforms (for example FACEBOOK, INSTAGRAM, MESSENGER, AUDIENCE_NETWORK), isActive, startDate, endDate, daysRunning
Transparency dataspend, impressions, euTotalReach, demographicDistribution: filled only when the Ad Library discloses them, mainly for political and issue ads
SignalswinnerScore (0-100), winnerTier, winnerSignals, adCategory, containsAiMedia, containsSensitiveContent
Run metadatascrapedAt

pageInstagramUser and pageInstagramFollowers are kept in the schema but are currently always null.

How do I see all active ads of a competitor?

Put the competitor's Facebook Page URL (or numeric Page ID) in pageUrls, set adActiveStatus to ACTIVE, and choose a country or ALL. The Actor returns the public ads that Page is running, up to maxResults, with copy, creatives, and dates.

{
"pageUrls": ["https://www.facebook.com/nike"],
"adActiveStatus": "ACTIVE",
"country": "US",
"maxResults": 200
}

Other input modes:

  • Keyword search: "searchTerms": ["running shoes", "protein powder"]. Each keyword runs as its own search.
  • Ad Library URL: set filters on facebook.com/ads/library, then paste the URL into adLibraryUrls. URLs with q=, view_all_page_id=, or id= are supported; country, status, and media filters in the URL are kept.
  • Filters: country (52 countries or ALL), adActiveStatus (ALL, ACTIVE, INACTIVE), adType (ALL or POLITICAL_AND_ISSUE_ADS), and mediaType (ALL, IMAGE, VIDEO, MEME, NONE).

Ads are deduplicated by adId within a run, so the same ad found by two keywords is delivered and charged once.

Call it from code

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('muhammadafzal/facebook-ads-library-scraper').call({
searchTerms: ['skincare'],
country: 'US',
adActiveStatus: 'ACTIVE',
mediaType: 'VIDEO',
maxResults: 100,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
const winners = items.filter((ad) => ad.winnerTier === 'high');
from apify_client import ApifyClient
client = ApifyClient("MY_APIFY_TOKEN")
run = client.actor("muhammadafzal/facebook-ads-library-scraper").call(run_input={
"adLibraryUrls": ["https://www.facebook.com/ads/library/?active_status=active&ad_type=all&country=GB&search_type=page&view_all_page_id=1497383683837785"],
"maxResults": 50,
})
ads = client.dataset(run.default_dataset_id).list_items().items

Is this the official Meta Ad Library API?

No. Meta's official Ad Library API needs a verified Meta developer account, and its coverage of ordinary commercial ads is narrower than the public Ad Library website. This Actor gives you API access to what the public Ad Library shows, without a Meta app or token, and adds analysis fields such as days running and a winner score.

Use it from an AI assistant

Facebook Ads Library Scraper works from Claude, ChatGPT, Cursor, or any MCP client through Apify's MCP server. Add https://mcp.apify.com/?tools=muhammadafzal/facebook-ads-library-scraper, then ask, for example: "Pull the active US video ads for 'meal kit' from the Facebook Ads Library and list the ones running longer than 30 days." The assistant sees the inputs and the price per ad before it runs.

What does the output look like?

Two records from a keyword search for adidas (US, all statuses), shortened:

[
{
"adId": "388120997678322",
"pageName": "adidas",
"pageId": "1497383683837785",
"pageUrl": "https://www.facebook.com/1497383683837785",
"pageLikeCount": 43608354,
"adText": "Conheça e compre todas as coleções e os principais lançamentos da adidas …",
"headline": "Chuteira Samba Classic Homem",
"ctaText": "Shop now",
"ctaType": "SHOP_NOW",
"ctaUrl": "http://play.google.com/store/apps/details?id=com.adidas.app",
"displayFormat": "DPA",
"platforms": ["FACEBOOK", "INSTAGRAM", "AUDIENCE_NETWORK", "MESSENGER"],
"isActive": false,
"startDate": "2024-09-26",
"endDate": "2026-05-20",
"daysRunning": 601,
"spend": null,
"euTotalReach": null,
"winnerScore": 70,
"winnerTier": "high",
"winnerSignals": ["long_running", "high_variants", "multiple_variants"],
"adCategory": "ecommerce",
"adSnapshotUrl": "https://www.facebook.com/ads/library/?id=388120997678322",
"scrapedAt": "2026-10-21T07:29:58.114Z"
},
{
"adId": "1016746567807029",
"pageName": "Depop",
"headline": "$79.45| IRO Women's Knee high Boots",
"ctaText": "Install now",
"ctaType": "INSTALL_MOBILE_APP",
"isActive": true,
"startDate": "2026-06-29",
"daysRunning": 113,
"winnerScore": 100,
"winnerTier": "high",
"winnerSignals": ["long_running", "still_active", "high_variants", "multiple_variants", "proven_active"]
}
]

How is the winner score calculated?

The winner score (0-100) rewards ads that advertisers keep paying for. It adds points for running 14, 30, or 60+ days, for still being active, for carousel cards and creative variants, and a bonus for ads active 30+ days. winnerTier is high at 70+, medium at 40-69, and low below 40. It is a heuristic built from public signals, not Meta performance data.

Pricing: how much do 1,000 Facebook ads cost?

You pay per ad delivered, plus a start fee. Platform usage is included in these prices.

EventFREEBRONZESILVERGOLDPLATINUMDIAMOND
Ad scraped$0.003001$0.002925$0.00285$0.0024$0.0024$0.0024
Actor start, per started GB of allocated memory$0.014965$0.01459$0.014216$0.011972$0.011972$0.011972

The default run uses 512 MB, so it pays one start event. Worked totals:

  • 20 ads on FREE: $0.014965 + 20 × $0.003001 = $0.075.
  • 1,000 ads on BRONZE: $0.01459 + 1,000 × $0.002925 = $2.94.
  • 1,000 ads on GOLD: $0.011972 + 1,000 × $0.0024 = $2.41.

A run that finds no ads charges only the start event. Set the run's maximum total charge to at least $0.018 so the start fee and the first ads fit.

When should I use it, and when not?

Use it when you need:

  • a competitor's or brand's live ads, with creatives and landing pages;
  • long-running ("winning") ads in a niche for creative research or dropshipping;
  • a scheduled export of ads into a sheet, database, or AI workflow;
  • political and issue ads with the spend and reach ranges Meta discloses.

Use something else when you need:

Limits and reliability

  • Up to 1,000 ads per run (maxResults; 0 also means 1,000).
  • Results depend on what the public Ad Library shows for the chosen country and filters.
  • Image and video links point to Meta's CDN and can expire, so download creatives soon after the run.
  • Small test runs (3 ads) finished in 4 to 8 seconds. The OUTPUT record lists delivered ads, the stop reason, and warnings such as "no ads matched".

FAQ

Do I need a Facebook account, cookies, or a Meta access token?

No. The Actor reads the public Ad Library, so you only need an Apify account.

Does it show how much an advertiser spends?

Only where the Ad Library discloses it, which is mainly for political and issue ads, and then as ranges. Most commercial ads return null for spend and impressions.

Does it include Instagram ads?

Yes. Ads that run on Instagram are included, and platforms lists every placement the Ad Library reports.

How many ads can I scrape per run?

Up to 1,000 per run on any Apify plan, including the free plan.

Can I monitor a competitor's new ads every day?

Yes. Save the input as an Apify Task, schedule it daily, and compare adId and startDate between runs to spot new creatives.

Which countries are supported?

52 countries, or ALL to search every country at once. An Ad Library URL keeps the country set in the URL.

The Ad Library is a public transparency tool. Use the data for research and analysis, respect Meta's terms and advertisers' copyright in creatives, and follow the privacy rules that apply to you. This is not legal advice.

Compliance note

Collect only public ad data you have a legitimate reason to analyze. Do not republish creatives as your own, and handle any personal data in ad copy under the privacy law that applies to you.

Last verified: 2026-10-26