Facebook Ad Library Search API
Search
for Facebook Ad Library, in one call.
The Search endpoint from ScrapeCreators gives developers reliable access to Facebook Ad Library data without the hassle of building and maintaining scrapers. Our endpoint makes it easy to retrieve search data in real-time for your applications. Search the Facebook (Meta) Ad Library By Keyword. This endpoint will tap out around 1,500 results, beacuse the cursor becomes too big for a GET request. If you need more results, call this endpoint as a POST, and pass the query params in the body.
// Example: Search from the Facebook Ad Library API
const response = await fetch(`https://api.scrapecreators.com/v1/facebook/adLibrary/search/ads`, {
headers: {
'x-api-key': 'YOUR_API_KEY'
}
});
const data = await response.json();
console.log(data); Endpoint spec
What the Search endpoint returns
/v1/facebook/adLibrary/search/ads Parameters
query string
required
Keyword to search for
sort_by select Sort by impressions (high to low), or Most Recent (relevancy_monthly_grouped). Defaults to impressions.
search_type select If you want to search by exact phrase or not
ad_type select Search for all ads or only political and issue ads
country string This can only be one country. It has to be the 2 letter code for the country. It defaults to ALL.
status select Status of the ad. Defaults to ACTIVE.
media_type select Media type of the ad. Defaults to ALL. Meme just means the ad has text and an image. No clue why they call it meme.
start_date string Impressions start date. Needs to be in YYYY-MM-DD format.
end_date string Impressions end date. Needs to be in YYYY-MM-DD format.
cursor string Cursor to paginate through results
trim boolean Set to true for a trimmed down version of the response
Quick start
Search quick start
Sign up, grab your API key, paste this in. First response in under a minute.
// Example: Search from the Facebook Ad Library API
const response = await fetch(`https://api.scrapecreators.com/v1/facebook/adLibrary/search/ads`, {
headers: {
'x-api-key': 'YOUR_API_KEY'
}
});
const data = await response.json();
console.log(data); Why us
Why use this Search endpoint
Real-time data access
Get the most up-to-date Search data without dealing with rate limits or IP blocks.
Simple integration
Clear documentation and a straightforward REST endpoint make it easy to get started in any language.
High reliability
Our infrastructure ensures high uptime and consistent performance for your applications, even at scale.
Comprehensive data
Access comprehensive Search data through our carefully designed endpoint.
Use cases
Search endpoint use cases
Data analysis
Analyze Search data to gain insights and make data-driven decisions.
Content monitoring
Monitor Search content to track changes and updates in real-time.
Integration
Integrate Search data into your applications and services.
Automation
Automate processes using Search data to improve efficiency.
Reporting
Generate reports and analytics using Search data.
Custom solutions
Build custom solutions leveraging Search data for your specific needs.
More Facebook Ad Library endpoints
Keep exploring the Facebook Ad Library API
Use this endpoint with related Facebook Ad Library endpoints when you need profiles, posts, search, comments, and engagement data in one workflow.
Ad Details
GET /v1/facebook/adLibrary/ad Pass the Ad ID and get back details about the ad. Be careful that if an ad has multiple versions, you're actually going to want to get the title from the 'cards' object.
Ad Transcript
GET /v1/facebook/adLibrary/ad/transcript Get the transcript for a Facebook Ad Library video ad by ad ID or URL. Credits are only charged when a transcript is returned.
Company Ads
GET /v1/facebook/adLibrary/company/ads Get all the ads a company has running. If params become too large, make this a POST request and pass the params in the body.
Search for Companies
GET /v1/facebook/adLibrary/search/companies Search for companies by name and get their ad library page id
FAQ
Questions we hear
about this endpoint.
Is the Search endpoint official?
No, ScrapeCreators provides an unofficial Search endpoint that lets you access Facebook Ad Library data through our platform. We handle the complexities of data collection so you can focus on building your application.
How current is the Search data?
We provide real-time Search data from Facebook Ad Library. When you make a request, we fetch the latest information available, so you always get fresh data.
Can I use the Search endpoint in production?
Absolutely. Many businesses rely on ScrapeCreators endpoints for their production applications. Our infrastructure is designed for reliability and performance at scale.
Do I need a credit card to try the Search endpoint?
No credit card required. Sign up for free and you get 100 credits on the house to test the Search endpoint before deciding on a plan. Credits never expire.
What format does the Search endpoint return?
The Search endpoint returns a clean JSON response over HTTPS. Call `GET https://api.scrapecreators.com/v1/facebook/adLibrary/search/ads` with your API key and parse the response like any other REST API.
Get started
Start using Search
100 credits on the house. No credit card. Start pulling search data in under sixty seconds.
Also searched