Facebook Ads Library | No Login avatar

Facebook Ads Library | No Login

Pricing

from $5.00 / 1,000 ads

Go to Apify Store
Facebook Ads Library | No Login

Facebook Ads Library | No Login

Scrape public ads from the Meta Ad Library by keyword, country and ad type. Returns adArchiveId, pageName and adText. No login. Pay per ad.

Pricing

from $5.00 / 1,000 ads

Rating

0.0

(0)

Developer

Technical Dost Solutions

Technical Dost Solutions

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

0

Monthly active users

a day ago

Last modified

Security

Limited permissions

Share

Find and export public ads from Meta's Facebook Ad Library without logging in, buying an API key, or configuring a paid proxy. Search by keyword, advertiser, or Page name and receive structured creative, advertiser, delivery, platform, and transparency data.

Use this Actor for competitor ad research, creative inspiration, campaign monitoring, offer analysis, brand intelligence, and political-ad transparency research.

Input

FieldTypeRequiredDefaultDescription
querystringYesnike (prefill)Search term, advertiser, or Page name.
countrystringNoUSTwo-letter country code, such as US, GB, or DE.
adTypestringNoallall or political_and_issue_ads.
activeStatusstringNoallall, active, or inactive.
maxAdsintegerNo50Maximum unique ads to return, from 1 to 200.

Example input:

{
"query": "nike",
"country": "US",
"adType": "all",
"activeStatus": "all",
"maxAds": 50
}

Output

Each dataset item contains:

  • adArchiveId, pageName, and pageId — Meta Ad Library and advertiser identifiers
  • adText and title — the primary creative copy
  • ctaText, ctaType, linkUrl, and displayUrl — call-to-action and destination data
  • images — image URLs found in the creative
  • videos — video asset metadata exposed by Meta
  • startDate and endDate — ISO 8601 delivery dates
  • isActive and platforms — current status and publisher platforms
  • impressionsText and spendText — transparency ranges when Meta publishes them

Example output:

{
"adArchiveId": "123456789012345",
"pageName": "Example Brand",
"pageId": "123456789",
"adText": "Discover our latest collection.",
"title": "Shop new arrivals",
"ctaText": "Shop now",
"ctaType": "SHOP_NOW",
"linkUrl": "https://example.com/new",
"displayUrl": "example.com",
"images": ["https://scontent.example/image.jpg"],
"videos": [],
"startDate": "2026-07-01T07:00:00.000Z",
"endDate": "",
"isActive": true,
"platforms": ["FACEBOOK", "INSTAGRAM"],
"impressionsText": "",
"spendText": ""
}

Run locally

Use Node.js 20 or newer:

npm install
npm start

For local Apify storage, save the input as storage/key_value_stores/default/INPUT.json before starting the Actor. Results are written to storage/datasets/default/.

Data source and cost

The Actor reads Meta's free, public Ad Library web data with native fetch. It uses the legacy async search response when available and Meta's current anonymous Relay response when the endpoint variant changes. It does not require Facebook login credentials, paid APIs, or paid proxy services. Use of the data remains subject to Meta's applicable terms and policies.

How to use Facebook Ads Library

  1. Open Facebook Ads Library on Apify Store and click Try for free.
  2. Fill in the input (the form is prefilled with a working example) and click Start.
  3. Watch results appear in the Output tab, then download them as JSON, CSV, Excel or HTML, or read them through the API.
  4. Optional: save the input as a task and add a schedule to run it automatically, or connect it to your tools with integrations and webhooks.

Use Facebook Ads Library with AI agents (MCP)

Give Claude, ChatGPT, Cursor, VS Code or any MCP client this Actor as a tool through the hosted Apify MCP server. The agent sees the input fields with descriptions and example values, runs the Actor, and reads the results.

MCP server URL (this Actor only):

https://mcp.apify.com/?tools=technicaldost/facebook-ads-library-scraper

Claude Code:

$claude mcp add --transport http apify "https://mcp.apify.com/?tools=technicaldost/facebook-ads-library-scraper" --header "Authorization: Bearer YOUR_APIFY_TOKEN"

Cursor, VS Code, Claude Desktop and other clients (mcp.json or the client's MCP settings):

{
"mcpServers": {
"apify": {
"url": "https://mcp.apify.com/?tools=technicaldost/facebook-ads-library-scraper",
"headers": { "Authorization": "Bearer YOUR_APIFY_TOKEN" }
}
}
}

Clients that support sign-in (such as Claude.ai connectors) can use the URL without a token and log in to Apify instead. Get your token in Apify Console → Settings → API & Integrations, or generate a ready config for your client at mcp.apify.com. In the agent the tool is named technicaldost--facebook-ads-library-scraper; ask it, for example, to "run Facebook Ads Library with {"query": "nike"}".

AI agents without an Apify account can also run and pay for this Actor per request with x402 agentic payments.

Run Facebook Ads Library via API

Run the Actor and get its results in one call (replace YOUR_APIFY_TOKEN):

curl -X POST "https://api.apify.com/v2/acts/technicaldost~facebook-ads-library-scraper/run-sync-get-dataset-items?token=YOUR_APIFY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"query": "nike"}'

Python (pip install apify-client):

from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("technicaldost/facebook-ads-library-scraper").call(run_input={"query": "nike"})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
print(item)

JavaScript / TypeScript (npm install apify-client):

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_APIFY_TOKEN' });
const run = await client.actor('technicaldost/facebook-ads-library-scraper').call({"query": "nike"});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Long runs: start them with POST /v2/acts/technicaldost~facebook-ads-library-scraper/runs and fetch the dataset when the run finishes, or receive a webhook.

Integrations

Facebook Ads Library works with Make, Zapier, n8n, LangChain, Google Sheets, Slack, GitHub and webhooks. Schedule runs in Apify Console and send new results straight to your apps, spreadsheets or AI pipelines.

FAQ

Can I use Facebook Ads Library with AI agents like Claude or ChatGPT?

Yes. Connect the Apify MCP server with ?tools=technicaldost/facebook-ads-library-scraper (see above) and the agent can run the Actor and read its results on its own.

Can I call Facebook Ads Library from my own code?

Yes. Use the REST API, or the official Python and JavaScript clients shown above. Results are available as JSON, CSV, Excel, XML or HTML.

How do I run it on a schedule?

Save your input as a task in Apify Console and add a schedule (for example, daily). Use webhooks or integrations to send each run's results onward.

It works with publicly available data. Make sure your use complies with the source website's terms and with data protection laws such as GDPR, especially for personal data.

Something doesn't work or I need a feature. What should I do?

Open an issue in the Issues tab on this Actor's page with an example input, and we'll look into it.

More tools from the same developer that work well together with this one: