Meta Ad Library Multi Search Scraper
Pricing
from $9.00 / 1,000 results
Meta Ad Library Multi Search Scraper
Scrape Facebook and Instagram ads from Meta Ad Library. Extract competitor ad creatives, copy, CTA links, and platform data with multi-keyword search. Supports 22+ countries, date filters, and media type filters.
Pricing
from $9.00 / 1,000 results
Rating
5.0
(1)
Developer

Juyeop Park
Actor stats
0
Bookmarked
22
Total users
14
Monthly active users
6 days ago
Last modified
Categories
Share
Meta Ad Library Scraper
Scrape Facebook and Instagram ads from Meta Ad Library — the only tool that lets you search multiple keywords in a single run and optionally target specific advertisers by Facebook Page ID for precise results. Extract ad creatives, videos, images, ad copy, CTA links, and more from 22+ countries without writing a single line of code.
What is Meta Ad Library Scraper?
Meta Ad Library Scraper is an Apify Actor that automates data extraction from Meta's Ad Library. Instead of manually browsing and copy-pasting ad data, this scraper collects structured ad information at scale.
Meta Ad Library is Facebook's public database of all ads running across Facebook, Instagram, Messenger, and Audience Network. This scraper turns that public data into structured, exportable datasets you can use for competitor analysis, market research, and creative inspiration.
What can this scraper do?
- Multi-keyword search — Search up to 5 keywords (brand names, products, topics) in a single run. No need to run the scraper multiple times.
- Target specific advertisers by Page ID — Pair any keyword with a Facebook Page ID to restrict results to that exact advertiser's page. Ideal when multiple brands share a similar name and you only want one.
- 22+ countries supported — Target ads in specific countries: US, UK, Germany, Japan, South Korea, and more. Or search all countries at once.
- Advanced filters — Filter by active/inactive status, media type (image, video, meme), date range, and sort order.
- Complete ad data extraction — Get ad creatives (images & videos), ad copy, CTA destination URLs, advertiser info, platform targeting, start dates, and Library IDs.
- Automatic deduplication — No duplicate ads in your results, even when scrolling loads the same ad multiple times.
- Export anywhere — Download results as JSON, CSV, or Excel. Connect to Google Sheets, Airtable, Zapier, Make, or access via REST API.
Why use this scraper instead of browsing manually?
| Feature | Manual browsing | This scraper |
|---|---|---|
| Speed | ~2 min per ad | 100+ ads in minutes |
| Multi-keyword | One search at a time | Up to 5 keywords per run |
| Data format | Copy-paste | Structured JSON/CSV/Excel |
| CTA links | Click each ad | Extracted automatically |
| Video URLs | Not downloadable | Direct video URLs |
| Scheduling | Manual effort | Automate with Apify schedules |
| API access | None | Full REST API |
Use cases
- Competitor analysis — Monitor how competitors advertise on Facebook and Instagram. Track their ad creatives, messaging, and CTA strategies.
- Market research — Discover what types of ads are running in your industry across different countries.
- Creative inspiration — Build a swipe file of high-performing ad creatives for your team.
- Brand monitoring — Track how your brand (or clients' brands) appear in ads across Meta platforms.
- Agency pitches — Gather ad intelligence to support client proposals and competitive analyses.
How to scrape Meta Ad Library
- Go to the Meta Ad Library Scraper page on Apify Store.
- Click Try for free to open the Actor in Apify Console.
- Enter your search keywords (e.g., "Nike", "Adidas").
- (Optional) Enter a Facebook Page ID for each keyword to restrict results to a specific advertiser's page.
- Select your target country and filters.
- Click Start and wait for the results.
- Download your data as JSON, CSV, or Excel — or connect to Google Sheets, Airtable, Zapier, or Make.
No coding, no API keys, no setup required.
Input parameters
| Parameter | Type | Description | Default |
|---|---|---|---|
keywords | array | Search keywords — brand names, product names, or topics (max 5 per run). Pair with pageIds to target a specific advertiser's page. | Required |
pageIds | array | (Optional) Facebook Page IDs matched by index to keywords. If you want to collect ads from a specific advertiser with precision, provide the exact view_all_page_id value of that advertiser's Facebook Page. When provided, the search is restricted to that page, significantly improving the accuracy of collected data. Leave an entry blank to use keyword-only search at that position. (max 5) | - |
country | string | Country code (US, KR, JP, GB, DE, FR, and 16 more) | KR |
adType | string | "all" or "political_and_issue_ads" | all |
activeStatus | string | "all", "active", or "inactive" | all |
mediaType | string | "all", "image", "meme", "video", "none" | all |
startDateMin | string | Filter ads started on or after this date (YYYY-MM-DD) | - |
startDateMax | string | Filter ads started on or before this date (YYYY-MM-DD) | - |
sortBy | string | "relevancy_monthly_grouped" (Most Recent) or "total_impressions" (Highest Impressions) | relevancy_monthly_grouped |
maxResults | integer | Maximum ads to collect per keyword (1–200) | 100 |
proxy | object | Proxy configuration (Residential proxy required — datacenter IPs are rate-limited by Facebook) | Apify Proxy (RESIDENTIAL) |
Example input
{"keywords": ["Nike", "Adidas", "Puma"],"pageIds": ["", "123456789", ""],"country": "US","activeStatus": "active","mediaType": "video","maxResults": 50}
Using Page IDs for precise advertiser targeting
pageIds is an optional field. You do not need to provide it for the scraper to work — keyword-only search is the default behavior.
However, if you want to collect ads from a specific advertiser with precision, you can provide the view_all_page_id value of that advertiser's Facebook Page. When a Page ID is set for a keyword, the scraper restricts the search to that exact page, which significantly improves the accuracy of collected data — eliminating ads from other brands that happen to match the same keyword.
How to find a view_all_page_id:
- Go to Meta Ad Library and search for the advertiser by name.
- Click on the advertiser's name in the results to open their Ad Library page.
- The URL will contain
view_all_page_id=XXXXXXXXX— copy that number.
Alternatively, open the advertiser's Facebook Page and look for the numeric ID in the page URL or page source.
Rules:
pageIdsis index-matched tokeywords:pageIds[0]corresponds tokeywords[0],pageIds[1]tokeywords[1], and so on.- Leave an entry as
""(empty string) to use keyword-only search for that position. - If
pageIdsis shorter thankeywords, the remaining keywords use keyword-only search. - Only provide the numeric ID value (e.g.
"123456789"). Any blank or non-numeric-looking entry is ignored and will not be added to the URL.
Example — mixing keyword-only and Page ID search:
{"keywords": ["Nike", "Adidas", "Puma"],"pageIds": ["", "123456789", ""]}
In this example, "Nike" and "Puma" use keyword-only search, while "Adidas" is restricted to the page with ID 123456789. Only "Adidas"'s own ads will be collected for that keyword.
What data can you extract from Meta Ad Library?
Each ad in the output includes:
| Field | Type | Description |
|---|---|---|
libraryID | string | Unique Meta Ad Library identifier |
keyword | string | Search keyword that found this ad |
pageId | string|null | Facebook Page ID used to target a specific advertiser. null if no Page ID was provided. |
brand | string | Advertiser name |
brandImg | string | Advertiser profile image URL |
body | string | Ad copy / text content |
startDate | string | When the ad started running (YYYY-MM-DD) |
isActive | boolean | Whether the ad is currently running |
platforms | array | Platforms — Facebook, Instagram, Messenger, Audience Network, Threads |
images | array | Image URLs from the ad (carousel supported) |
videos | array | Video URLs with poster images |
ctaLink | string | Call-to-action destination URL (decoded) |
scrapeDate | string | When the data was collected (ISO 8601) |
Example output
{"libraryID": "123456789012345","keyword": "Nike","pageId": "123456789","brand": "Nike","brandImg": "https://scontent.xx.fbcdn.net/v/...","body": "Just Do It. Shop the latest Nike Air Max collection.","startDate": "2024-01-15","isActive": true,"platforms": ["Facebook", "Instagram"],"images": [{ "url": "https://scontent.xx.fbcdn.net/v/..." }],"videos": [{ "url": "https://video.xx.fbcdn.net/v/...", "posterUrl": "https://scontent.xx.fbcdn.net/v/..." }],"ctaLink": "https://nike.com/air-max","scrapeDate": "2024-01-20T10:30:00.000Z"}
Integrations
Connect your scraped data to the tools you already use:
- Google Sheets — Auto-sync results to a spreadsheet
- Airtable — Build a searchable ad database
- Zapier — Trigger workflows when new ads are found
- Make (Integromat) — Automate complex data pipelines
- Webhooks — Send data to your own backend in real time
- REST API — Access results programmatically from any language
- Slack / Email — Get notifications when scraping completes
You can also schedule this scraper to run daily or weekly to track ad changes over time.
Supported countries
| Code | Country | Code | Country |
|---|---|---|---|
| US | United States | KR | South Korea |
| GB | United Kingdom | JP | Japan |
| DE | Germany | FR | France |
| CA | Canada | AU | Australia |
| BR | Brazil | IN | India |
| MX | Mexico | ES | Spain |
| IT | Italy | NL | Netherlands |
| SG | Singapore | TW | Taiwan |
| HK | Hong Kong | TH | Thailand |
| VN | Vietnam | ID | Indonesia |
| PH | Philippines | MY | Malaysia |
| ALL | All Countries |
How much does it cost to scrape Meta Ad Library?
This Actor uses pay-per-result pricing — you only pay for the ads you successfully extract.
| Event | Price |
|---|---|
| Actor start | $0.02 per run |
| Per ad extracted | $0.015 |
Cost examples
| Scenario | Keywords | Ads/keyword | Total ads | Estimated cost |
|---|---|---|---|---|
| Quick test | 1 | 10 | 10 | ~$0.17 |
| Standard use | 3 | 100 | 300 | ~$4.52 |
| Full scan | 5 | 200 | 1,000 | ~$15.02 |
No results = no charge. If a keyword returns 0 ads, you only pay the $0.02 Actor start fee.
Proxy costs
This Actor requires Apify Proxy with RESIDENTIAL group to access Meta Ad Library. Facebook aggressively rate-limits GraphQL pagination requests from datacenter IPs (error code 1675004) — the initial page loads but infinite-scroll fails silently and no new ads are fetched. Residential proxy is set as the default and must not be changed to datacenter.
| Proxy type | Price | Note |
|---|---|---|
| Residential | ~$12.50/GB | Required — the only option that works for pagination |
| Datacenter | ~$0.04/GB | Will NOT work — GraphQL pagination is blocked |
Estimated proxy cost per run: $0.10–$0.50 depending on data volume.
Tips for best results
- Use specific keywords — Brand names ("Nike", "Coca-Cola") work better than generic terms ("shoes", "drinks").
- Use a Page ID for exact advertiser targeting —
pageIdsis optional, but if you want to collect ads from a specific advertiser with precision, provide their exactview_all_page_idvalue. This restricts results to that advertiser's page only, significantly improving data accuracy. Find the Page ID by searching the advertiser in Meta Ad Library and copying the numeric ID from the URL (view_all_page_id=XXXXXXXXX). - Start small — Test with
maxResults: 5to verify results before running large extractions. - Filter by active status — Use "active" to focus on currently running ads.
- Use date filters — Narrow results to recent ads for the freshest insights.
- Try different countries — The same brand may run different ad creatives in different markets.
FAQ
Is this legal?
Yes. Meta Ad Library is a publicly accessible database that Meta provides for transparency. This scraper only accesses publicly available data. However, please ensure your use case complies with Meta's Terms of Service and applicable laws in your jurisdiction.
Will Meta block the scraper?
This scraper includes built-in proxy support and anti-detection measures. It uses Apify Proxy with RESIDENTIAL group by default, which is required for reliable access. Do not switch to datacenter proxies — Facebook rate-limits GraphQL pagination from datacenter IPs, causing the scraper to collect zero ads beyond the initial page load.
How long does it take?
Typical run times:
- 10 ads: ~1–2 minutes
- 100 ads: ~5–10 minutes
- 1,000 ads (5 keywords × 200 each): ~20–40 minutes
Can I schedule automatic runs?
Yes. Apify supports scheduled runs — set the scraper to run daily, weekly, or at any custom interval to monitor ad changes over time.
Does it extract ad spend or impressions data?
Meta only makes spend and impression data publicly available for political and issue ads. For regular commercial ads, this data is not available in the Ad Library.
Support
- Issues & feature requests: GitHub Issues
- Apify documentation: docs.apify.com
- Apify community: discord.gg/apify
Legal notice
This Actor accesses publicly available data from Meta Ad Library. It does not access private data, bypass authentication, or violate Meta's Terms of Service. Users are responsible for ensuring their use of extracted data complies with applicable laws and regulations.