Better Fetch

Facebook Ad Library Scraper

Search Meta's public Ad Library, discover advertisers, inspect individual public ads, and transcribe public video creatives without login.

Socialv0.2.9~50 credits/runSource on GitHub

Workspace

Configure

Inputs stay here while results become exportable artifacts.

Start from an example

Meta Ad Library ID.

Meta Ad Library URL containing an id query parameter.

Search ads, list company ads, discover companies, inspect one ad, or transcribe one public video ad.

Keyword or advertiser search query.

Ad activity filter.

ALL or a 2-letter country code.

Meta advertiser page ID.

Optional spoken-language hint for ad_transcript mode; omit for detection.

Media filter.

Maximum records to return.

Keyword matching mode.

Maximum visible ad-copy characters per result.

Sign in and run
~50 credits/run10 runs/minute

Results

Preview, inspect, copy, or export the complete output.

Your result will become an artifact

Run the tool to inspect structured rows, raw JSON, execution details, and downloadable JSON, CSV, and Markdown files.

adadsmodecountcompaniessource_urltranscripttotal_matches

Overview

Facebook Ad Library Scraper reads Meta's official public Ad Library without a Facebook account. It returns stable library IDs, activity state, start dates, advertiser page IDs and names, visible ad copy, destinations, and public creative assets when Meta exposes them.

Last validated: Jul 15, 2026

Input

idstring

Meta Ad Library ID.

urlstring

Meta Ad Library URL containing an id query parameter.

mode"search_ads" | "company_ads" | "search_companies" | "ad" | "ad_transcript"required

Search ads, list company ads, discover companies, inspect one ad, or transcribe one public video ad.

querystring

Keyword or advertiser search query.

status"ALL" | "ACTIVE" | "INACTIVE"default: "ACTIVE"

Ad activity filter.

countrystringdefault: "ALL"

ALL or a 2-letter country code.

page_idstring

Meta advertiser page ID.

languagestring

Optional spoken-language hint for ad_transcript mode; omit for detection.

media_type"ALL" | "IMAGE" | "VIDEO" | "MEME" | "IMAGE_AND_MEME" | "NONE"default: "ALL"

Media filter.

max_resultsintegerdefault: 10

Maximum records to return.

search_type"keyword_unordered" | "keyword_exact_phrase"default: "keyword_unordered"

Keyword matching mode.

max_body_charsintegerdefault: 3000

Maximum visible ad-copy characters per result.

Output

adobject

Resolved individual ad.

ad.urlstring

Public Ad Library URL.

ad.bodystring

Visible ad copy.

ad.page_idstring

Linked advertiser page ID.

ad.page_urlstring

Public advertiser page URL.

ad.is_activeboolean

Visible activity state.

ad.page_namestring

Advertiser page name.

ad.page_handlestring

Public advertiser handle when Meta links by handle instead of numeric ID.

ad.ad_archive_idstring

Stable Meta Library ID.

ad.body_truncatedboolean

True when visible ad copy exceeded max_body_chars.

ad.page_image_urlstring

Public advertiser image.

ad.destination_urlstring

Visible off-Facebook destination URL.

ad.started_runningstring

Visible start-date label.

ad.creative_image_urlstring

Public creative image.

ad.creative_video_urlstring

Public video creative rendition when Meta exposes one.

adsobject[]required

Public Meta ad cards.

modestringrequired

Resolved operation.

countintegerrequired

Primary record count.

companiesobject[]required

Unique advertisers found in the returned ads.

source_urlstringrequired

Fetched Meta Ad Library URL.

transcriptobject

Speech transcript generated from the public video creative.

transcript.textstring

Normalized spoken text.

transcript.languagestring

Detected or requested language code.

transcript.duration_secondsnumber

Media duration in seconds.

transcript.language_probabilitynumber

Language-detection confidence when available.

total_matchesinteger

Visible total result count when exact.

transcript_segmentsobject[]

Timed transcript segments.

Examples

search-ads

{
  "mode": "search_ads",
  "query": "Cholesterol Relief Community",
  "country": "IN",
  "max_results": 5
}

search-companies

{
  "mode": "search_companies",
  "query": "Cholesterol Relief Community",
  "country": "IN",
  "max_results": 5
}

company-ads

{
  "mode": "company_ads",
  "status": "ALL",
  "country": "ALL",
  "page_id": "866655706540346",
  "max_results": 5
}

ad-details

{
  "id": "866569929827744",
  "mode": "ad",
  "query": "Cholesterol Relief Community",
  "country": "IN"
}

video-ad-transcript

{
  "id": "866569929827744",
  "mode": "ad_transcript",
  "query": "Cholesterol Relief Community",
  "country": "IN",
  "language": "en"
}

Use cases

Competitor creative monitoring

Track source-linked ad copy, destinations, imagery, and activity state for public advertisers.

Advertiser discovery

Search a market phrase and group matching ads into stable advertiser page identities.

Ad verification

Resolve a known Meta Ad Library ID to the current public ad card and source URL.

FAQ

Does this require Facebook login?

No. It reads only data exposed by Meta's official public Ad Library without login.

Is every Facebook ad included?

No. Coverage follows Meta's public library, selected country, status, and media filters.

Does advertiser search return page IDs?

It returns Meta's numeric page ID when the public link exposes one; otherwise it returns the advertiser's public Facebook handle and page URL.

Use it anywhere

MCP (Claude, ChatGPT, Codex)

# After connecting https://betterfetch.co/api/mcp, ask your AI to:
1. Call search_tools for "Facebook Ad Library Scraper"
2. Call run_tool with:
   name: "facebook_ad_library_scraper"
   input: {"mode":"search_ads","query":"Cholesterol Relief Community","country":"IN","max_results":5}

REST

curl -sS -X POST "https://betterfetch.co/api/tools/facebook_ad_library_scraper/run" \
  -H "Authorization: Bearer bf_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"input": {"mode":"search_ads","query":"Cholesterol Relief Community","country":"IN","max_results":5}}'

Run locally

git clone https://github.com/better-fetch/tools/tree/main/tools/facebook-ad-library-scraper && cd facebook-ad-library-scraper && npm i
BETTER_FETCH_API_KEY=bf_your_key_here npx bf-tool run --input '{"mode":"search_ads","query":"Cholesterol Relief Community","country":"IN","max_results":5}'