# Google Ads Transparency Scraper (`sarel-data/google-ads-transparency-scraper`) Actor

Scrape ads from the Google Ads Transparency Center by advertiser name, domain or advertiser ID. Format, first/last shown dates, regions, image/video/text creatives and landing URLs. Fast JSON API, no browser.

- **URL**: https://apify.com/sarel-data/google-ads-transparency-scraper.md
- **Developed by:** [Sarel Data](https://apify.com/sarel-data) (community)
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.80 / 1,000 ad scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Google Ads Transparency Scraper

Scrape ads from the [Google Ads Transparency Center](https://adstransparency.google.com) by **advertiser name, domain, or advertiser ID (AR…)**. It calls the site's public JSON endpoints directly, so it runs with no browser on 256 MB and downloads no images or video.

### Input

| Field | Description |
|---|---|
| `advertisers` | Names (`Nike`), domains (`nike.com`), IDs (`AR16735076323512287233`) or Transparency Center URLs. A name expands to every advertiser entity whose name matches it exactly, ignoring Inc/LLC/Srl and similar suffixes. |
| `region` | ISO-2 code (`US`, `DE`, `IL`…), a Google geo ID, or `anywhere`. |
| `dateFrom` / `dateTo` | Keeps ads that were shown inside this range. Google's own date filter only accepts recent ranges. When it returns nothing, the actor filters by first/last shown on its side. |
| `format` | `all`, `text`, `image` or `video`. Filtered by Google, then checked again by the actor. |
| `maxAds` | The most ads to save for each input or resolved advertiser. |
| `fetchDetails` | (default on) Gets per-region dates and parses the creative preview for ad text, image and YouTube URLs, and the landing URL. Turn it off for a fast list of ads. |
| `maxConcurrency` | Number of detail requests sent in parallel (default 8). |
| `proxyConfiguration` | **Used only after a block.** Requests go direct first. When Google blocks them, the actor tries the Apify datacenter proxy, then this proxy (residential by default). After 2 minutes it tries direct again. |

### Output (one dataset item per ad)

`advertiserName, advertiserId, adId, format, firstShown, lastShown, daysShown, domain, regions[], regionStats[{region, firstShown, lastShown}], adText[], imageUrls[], videoUrls[], landingUrl, landingUrlSource (creative | advertiser-domain), previewUrl, adUrl, variations, searchInput, scrapedAt`

See `sample-output.json`. The run statistics (requests, blocks, highest proxy tier used) are saved to the key-value store record `RUN_STATS`.

### Notes

- Google publishes only a domain for most ads. A creative-level landing URL appears only when the preview contains it. Otherwise `landingUrl` is the advertiser's domain and `landingUrlSource` is `advertiser-domain`.
- Pricing is pay-per-event. You are charged per ad saved (`ad-scraped`), and the actor stops when your max total charge is reached.

# Actor input Schema

## `advertisers` (type: `array`):

Advertiser names (e.g. Nike), domains (e.g. nike.com), advertiser IDs (AR...) or adstransparency.google.com URLs.

## `region` (type: `string`):

ISO-2 country code (US, GB, DE, IL...) or a Google geo ID. Use 'anywhere' for all regions.

## `dateFrom` (type: `string`):

Only ads shown on/after this date.

## `dateTo` (type: `string`):

Only ads shown on/before this date.

## `format` (type: `string`):

Filter by creative format.

## `maxAds` (type: `integer`):

Maximum ads saved for each input.

## `fetchDetails` (type: `boolean`):

Fetch per-ad region stats and parse the creative preview for ad text, video and landing URL. Turn off for the fastest/cheapest listing.

## `maxConcurrency` (type: `integer`):

Parallel detail requests. Lower it if Google starts blocking.

## `proxyConfiguration` (type: `object`):

Requests go DIRECT first. This proxy is only used if Google blocks the direct connection.

## Actor input object example

```json
{
  "advertisers": [
    "nike.com"
  ],
  "region": "anywhere",
  "format": "all",
  "maxAds": 100,
  "fetchDetails": true,
  "maxConcurrency": 8,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `results` (type: `string`):

Ads from the Google Ads Transparency Center (dataset items).

## `runStats` (type: `string`):

Requests, blocks, proxy use and ads saved.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "advertisers": [
        "nike.com"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("sarel-data/google-ads-transparency-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "advertisers": ["nike.com"],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("sarel-data/google-ads-transparency-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "advertisers": [
    "nike.com"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call sarel-data/google-ads-transparency-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,sarel-data/google-ads-transparency-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/Del00ddbbzsiRBxQV/builds/lEuaeFYejlSg0ZofK/openapi.json
