Skip to content
OSINTtools.io

Meta Ad Library API

Meta's public searchable archive of ads run on Facebook and Instagram, with spend reports and an API for political and issue ads.

Base URL
https://graph.facebook.com
Sign-in
API key
Format
REST
Endpoints
1

Compiled by OSINTtools.io editors from developers.facebook.com · updated Nov 29, 2026Work on this API? Claim it to keep these docs currentReport a mistake

Introduction

The Meta Ad Library API searches the archive of ads shown on Meta technologies. Each ad comes back with its Page, creative text, delivery dates, a snapshot URL and platforms. Political and issue ads add the funding byline, spend, impressions and audience breakdowns; UK and EU ads add targeting and reach fields.

There is one endpoint, GET https://graph.facebook.com/<VERSION>/ads_archive, with an access_token query parameter. The reference page does not say which permissions or verification the token needs; read Meta's Ad Library API pages before applying.

Results are in data, with paging for the next page. An empty data array while paginating means the results have ended. Errors include 100 (invalid parameter), 190 (invalid token), 613 (rate limit exceeded) and 1009 (failed validation).

Quick start

  1. Get a key

    Create an account with Meta Ad Library and copy your api key. Where to get it

  2. Make your first request

    Search archived Meta ads by keyword, Page, country, date, platform and ad type.. Replace YOUR_API_KEY and run it in a terminal, or use Try it on the endpoint.

    curl 'https://graph.facebook.com/v24.0/ads_archive?ad_type=ALL&access_token=YOUR_API_KEY'
  3. Read the response

    A 200 response looks like this, shortened.

    {
      "data": [
        {
          "id": "1000000000000001",
          "page_id": "1000000000000",
          "page_name": "Example Brand",
          "ad_creation_time": "2026-01-02",
          "ad_delivery_start_time": "2026-01-03",
          "ad_creative_bodies": [
            "Example ad text"
          ],
          "ad_snapshot_url": "https://example.com/ad-snapshot",
          "languages": [
            "en"
          ],
          "publisher_platforms": [
            "facebook",
            "instagram"
          ]
        }
      ],
      "paging": {
        "cursors": {
          "after": "CURSOR_VALUE"
    …

Authentication

Send your API key in the access_token query parameter of every request.

OAuth 2.0 access token

Try it on this page keeps your key in your browser; it is never sent to OSINTtools.io.

Rate limits and pricing

Not stated in the docs

Errors

StatusMeaning
400Error codes 100 (invalid parameter), 1009 (failed parameter validation) and 2500 (error parsing graph query)
401Error code 190: invalid OAuth 2.0 access token
429Error code 613: rate limit exceeded

Ad archive

Read only. political and issue ads (ad_type POLITICAL_AND_ISSUE_ADS) accept extra filters (bylines, delivery_by_region, estimated audience size) and return spend, impressions and audience fields. Reach and targeting fields exist only for UK and EU ads or Brazil political ads.

Path parameters

versionstringrequired

Graph API version

Example: v24.0

Query parameters

ad_typestringrequired

Kind of ads to search

Example: ALLDefault: ALLOne of: ALL, EMPLOYMENT_ADS, FINANCIAL_PRODUCTS_AND_SERVICES_ADS, HOUSING_ADS, POLITICAL_AND_ISSUE_ADS
search_termsstringtakes your name

Search text, up to 100 characters

Example: example brand
search_typestring

How search_terms is matched

Example: KEYWORD_UNORDEREDDefault: KEYWORD_UNORDEREDOne of: KEYWORD_UNORDERED, KEYWORD_EXACT_PHRASE
search_page_idsstring

Up to 10 Page IDs

Example: 1000000000000
ad_reached_countriesstring

ISO country codes, or ALL

Example: US
ad_active_statusstring

Which ads to return by delivery status

Example: ALLDefault: ACTIVEOne of: ACTIVE, INACTIVE, ALL
ad_delivery_date_minstring

Earliest delivery date, YYYY-mm-dd, inclusive

Example: 2026-01-01
ad_delivery_date_maxstring

Latest delivery date, YYYY-mm-dd, inclusive

Example: 2026-06-30
media_typestring

Media type of the ad

Example: IMAGEOne of: ALL, IMAGE, MEME, VIDEO, NONE
languagesstring

ISO 639-1 codes, plus CMN and YUE

Example: en
fieldsstring

Comma-separated ArchivedAd fields to return

Example: id,page_name,ad_snapshot_url
Response fields · 13Show

idstring

Library ID of the ad

page_idstring

ID of the Facebook Page that ran the ad

page_namestring

Name of the Page that ran the ad

ad_creation_timestring

UTC time the ad was created

ad_delivery_start_timestring

UTC time delivery starts

ad_delivery_stop_timestring

UTC time delivery stops; blank means until stopped

ad_creative_bodies[]string

Text on each unique ad card

ad_creative_link_titles[]string

Link titles on each ad card

ad_snapshot_urlstring

URL that shows the archived ad

languages[]string

Languages in the ad, ISO 639-1

publisher_platforms[]string

Where the ad appeared, such as Facebook or Instagram

bylinesstring

Funding entity; political and issue ads only

pagingobject

Pagination information

curl 'https://graph.facebook.com/v24.0/ads_archive?ad_type=ALL&access_token=YOUR_API_KEY'
Replace YOUR_API_KEY with your key
Response
{
  "data": [
    {
      "id": "1000000000000001",
      "page_id": "1000000000000",
      "page_name": "Example Brand",
      "ad_creation_time": "2026-01-02",
      "ad_delivery_start_time": "2026-01-03",
      "ad_creative_bodies": [
        "Example ad text"
      ],
      "ad_snapshot_url": "https://example.com/ad-snapshot",
      "languages": [
        "en"
      ],
      "publisher_platforms": [
        "facebook",
        "instagram"
      ]
    }
  ],
  "paging": {
    "cursors": {
      "after": "CURSOR_VALUE"
    }
  }
}