Facebook Ad Library

Search

Searches the Meta Ad Library by keyword and returns matching ads. Supports filtering by language with a 2-letter code such as EN or ES. Each result includes ad_archive_id, page_name, is_active, publisher_platform, and a snapshot with body text, images, videos, and cta_text. Both GET and POST are supported. Use GET for normal requests. If the cursor becomes too large after extensive pagination, use POST and send the same parameters in the JSON body.

get/v1/facebook/adLibrary/search/ads

Query parameters

querystring required

Keyword to search for

sort_by'total_impressions' | 'relevancy_monthly_grouped'

Sort by impressions (high to low), or Most Recent (relevancy_monthly_grouped). Defaults to impressions.

search_type'keyword_unordered' | 'keyword_exact_phrase'

If you want to search by exact phrase or not

ad_type'all' | 'political_and_issue_ads'

Search for all ads or only political and issue ads

countrystring

This can only be one country. It has to be the 2 letter code for the country. It defaults to ALL.

languagestring

Language to filter ads on. Needs to be a 2 letter language code, such as EN, ES, or FR.

status'ALL' | 'ACTIVE' | 'INACTIVE'

Status of the ad. Defaults to ACTIVE.

media_type'ALL' | 'IMAGE' | 'VIDEO' | 'MEME' | 'IMAGE_AND_MEME' | 'NONE'

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_datestring

Impressions start date. Needs to be in YYYY-MM-DD format.

end_datestring

Impressions end date. Needs to be in YYYY-MM-DD format.

cursorstring

Cursor to paginate through results

trimboolean

Set to true for a trimmed down version of the response

Response

Successful response

Changes

No recorded changes to this endpoint across all 1 revision of this API.