# Google Political Ads Spend & Transparency Exporter (`crawlyth-forge/google-political-ads-spend`) Actor

Export Google's official political ad transparency bundle: advertiser lifetime spend, weekly spend, advertiser-by-state spend, state and district totals, creative spend ranges with targeting, and California/New Zealand declared advertiser filings. Public data, no login.

- **URL**: https://apify.com/crawlyth-forge/google-political-ads-spend.md
- **Developed by:** [crawlyth forge](https://apify.com/crawlyth-forge) (community)
- **Categories:** Automation, News, Other
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.49 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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 Political Ads Spend & Transparency Exporter

Export Google's official political advertising transparency bundle as clean JSON. This actor turns
the same public data behind Google's political ads report into advertiser spend leaderboards,
weekly spend series, advertiser-by-state totals, country/state/district totals, ad-level creative
disclosures and California/New Zealand declared advertiser filings.

No login, cookie, API key, browser or proxy is needed. The source is Google's public bulk download,
refreshed daily.

### Modes

| Mode | What it returns |
|---|---|
| `advertisers` | One row per verified election advertiser: lifetime spend in every published currency, total creatives, regions, public IDs, first/last spend week, recent vs prior trend and optional 52-week history. |
| `weeklySpend` | One row per advertiser per week with the week's spend by currency and the advertiser's regions. |
| `advertiserRegionSpend` | One row per advertiser per US state (plus the one UK row Google publishes) with spend by currency. |
| `regionSpend` | Country, state and congressional-district totals with a geography level and the official report link. |
| `creatives` | One row per election creative: format, serving dates, impression bucket and bounds, first/last served timestamp, age/gender/geo targeting, Google Ad Grants flag and the spend range in the ad's serving currency. |
| `declaredAdvertisers` | California and New Zealand declared advertiser filings: declared name, regulatory ID, scope, promoter name and address. |

### Input

| Field | Default | What it does |
|---|---|---|
| `mode` | `advertisers` | Table to export: advertiser totals, weekly spend, advertiser region spend, region totals, creatives or declared filings. |
| `country` | `any` | Keep one of Google's 12 election-ad regions: US, BR, IN, AR, AU, CL, IL, GB, MX, TW, NZ, ZA. |
| `dateFrom` | – | Start date (YYYY-MM-DD). Weekly rows use the week start; creatives match any ad active in the window; advertiser totals require weekly activity in the window. |
| `dateTo` | – | End date (YYYY-MM-DD), inclusive. |
| `advertiserNameContains` | – | Case-insensitive advertiser name substring, e.g. Senate, PAC or a candidate. |
| `advertiserIds` | – | AR... advertiser IDs or pasted Ads Transparency Center advertiser URLs. |
| `creativeIds` | – | CR... creative IDs or pasted creative URLs; used by `creatives`. |
| `currency` | `USD` | Currency used for spend filters, `spendLocal`, and spend sorting. One of Google's 21 published currencies. |
| `minSpend` | – | Minimum spend in the selected currency. Creatives match when the top of Google's range reaches it. |
| `maxSpend` | – | Maximum spend in the selected currency. Creatives match when the bottom of Google's range is at or below it. |
| `adType` | `any` | Creative format: `TEXT`, `IMAGE` or `VIDEO` (only `creatives`). |
| `fundedByGoogleAdGrants` | `any` | Keep creatives funded (`yes`) or not funded (`no`) by Google Ad Grants (only `creatives`). |
| `trendWindowWeeks` | `4` | Weeks in the recent window and again in the prior window for advertiser trends. |
| `surgeOnly` | `false` | Keep only advertisers that doubled recent spend or just started spending. |
| `includeWeeklyHistory` | `false` | Attach up to 52 recent weekly rows per advertiser, in the selected currency. |
| `sortBy` | `spendDesc` | `spendDesc`, `spendAsc`, `dateNewest`, `dateOldest` or `nameAsc`. Date sorts fall back to name where a mode has no dates. |
| `maxItems` | `50` | Stop after this many records (1–2000). |

If a spend filter is set and a row has no published amount in the selected currency, the row does
not match. Google never publishes a cross-currency conversion, so this actor never invents one.

### Examples

Top 25 US advertisers by lifetime spend, with a four-week trend:

```json
{
  "mode": "advertisers",
  "country": "US",
  "currency": "USD",
  "sortBy": "spendDesc",
  "maxItems": 25
}
```

Advertisers that just doubled their recent spend:

```json
{
  "mode": "advertisers",
  "country": "US",
  "surgeOnly": true,
  "trendWindowWeeks": 4,
  "maxItems": 50
}
```

Weekly spend for one advertiser in 2024:

```json
{
  "mode": "weeklySpend",
  "advertiserIds": ["AR03821862303154831361"],
  "dateFrom": "2024-01-01",
  "dateTo": "2024-12-31",
  "sortBy": "dateOldest",
  "maxItems": 52
}
```

Where a Senate campaign spent by state:

```json
{
  "mode": "advertiserRegionSpend",
  "advertiserNameContains": "for Senate",
  "minSpend": 1000,
  "sortBy": "spendDesc",
  "maxItems": 50
}
```

District totals in a state:

```json
{
  "mode": "regionSpend",
  "country": "US",
  "maxItems": 100
}
```

Large video creatives in Brazil, priced in BRL:

```json
{
  "mode": "creatives",
  "country": "BR",
  "currency": "BRL",
  "adType": "VIDEO",
  "minSpend": 10000,
  "sortBy": "spendDesc",
  "maxItems": 20
}
```

### Output

Every record has `recordType`, `sourceUrl`, `sourceFile`, `sourceLastModified`,
`reportDataUpdatedAt` and `scrapedAt`. Empty values are omitted, never null.

Advertiser rows add `advertiserId`, `advertiserName`, `advertiserUrl`, `publicIds`, `regions`,
`elections`, `totalCreatives`, `spendByCurrency`, `spendUsd`, `spendLocal`, `spendCurrency`,
`primaryCurrency`, `firstSpendWeek`, `lastSpendWeek`, `weeksWithSpend`, `recentSpend`,
`priorSpend`, `changePct`, `trend`, `trendWindowWeeks`, `latestIncludedWeek`, optional
`weeklySpend` and optional `declaredFilings`.

Weekly rows add `weekStartDate`, spend fields, `regions`, `elections`, `totalCreatives` and
`latestIncludedWeek`.

Advertiser-region rows add `country`, `countryName`, `regionCode`, `regionName` and spend fields.

Region rows add `country`, `countryName`, `regionCode`, `regionName`, `districtName`, `geoLevel`,
`reportUrl` and spend fields. `geoLevel` is `country`, `subdivision` or `district`.

Creative rows add `adId`, `adUrl`, `adType`, `regions`, `advertiserId`, `advertiserName`,
`advertiserUrl`, `dateRangeStart`, `dateRangeEnd`, `daysActive`, `impressionsBucket`,
`impressionsMin`, `impressionsMax`, `firstServedAt`, `lastServedAt`, `ageTargeting`,
`genderTargeting`, `geoIncluded`, `geoExcluded`, `geoIncludedCount`, `geoExcludedCount`,
`isFundedByGoogleAdGrants`, `spendRanges`, and `spendCurrency`, `spendRangeMin`,
`spendRangeMax` for the selected currency when the ad served in that currency's region.

Declared rows add `advertiserId`, `advertiserName`, `advertiserUrl`, `declaredRegion`,
`declaredRegionName`, `declaredName`, `regulatoryId`, `declaredScope`, `promoterName` and
`promoterAddress`.

### How Google reports spend

- Amounts are Google's published figures, typically rounded to the nearest 100 in the advertiser's
  reporting currency.
- Each row carries its own currency. `spendByCurrency` keeps every non-zero published currency;
  `spendLocal` is the amount in the `currency` you selected. No exchange-rate conversion is made.
- Creative spend is a range. `spendRanges` keeps the range for the ad's serving currency only,
  because Google fills the other currency columns with placeholder low buckets that are not
  spend disclosure.
- Impressions are buckets. `impressionsBucket` is Google's label; `impressionsMin` and
  `impressionsMax` are parsed numeric bounds, and `impressionsMax` is omitted for the open-ended
  top bucket.
- The latest week may still be filling in when you run. `latestIncludedWeek` and
  `reportDataUpdatedAt` tell you how fresh the file is.

### Data source

Google's "Political advertising on Google" transparency bundle:
`https://storage.googleapis.com/political-csv/google-political-ads-transparency-bundle.zip`.
Google publishes it for researchers, journalists and the public. The actor reads only the members
a run needs, using standard HTTP range requests; the creative table is downloaded in full because
it is 270 MB compressed. It identifies itself with a User-Agent and does not bypass access controls,
use Google pages, or read private data.

This actor is not affiliated with or endorsed by Google. Google, YouTube and Google Ads are
trademarks of Google LLC.

### Limitations

- Google's public bundle has country, state/subdivision and congressional-district spend. It does
  not publish postal/ZIP-level spend.
- Google retired the EU political ads report in September 2025, so EU coverage is historical; the
  bundle still publishes GB and the other regions listed above.
- The `google-political-ads-top-keywords-history.csv` and
  `google-political-ads-campaign-targeting.csv` files are deprecated and contain only headers, so
  they are not exposed as modes.
- Creative rows link to Google's Transparency Center viewer. This actor does not download ad media
  files.
- Advertiser `Elections` is often empty upstream; the field is omitted when empty.
- Google's figures can be revised. For official campaign-finance records, use the FEC or the
  relevant election authority.

### FAQ

**Do I need a Google account, cookie or proxy?** No. The source is a public bulk file.

**Does this return commercial ad spend?** No. Google discloses spend only for election ads. This
actor exports that disclosure.

**Can I get a USD total for a Brazilian advertiser?** Only if Google published a USD amount for
that advertiser. Google does not publish exchange rates or a converted total, so none is invented.

**How fresh is the data?** Google refreshes the bundle daily. Each record carries the bundle's
publication timestamp and the HTTP Last-Modified time.

**Why is a creative's EUR range missing for a US ad?** Google fills non-serving currency columns
with placeholder buckets. Only the range for the ad's serving currency is real spend disclosure.

# Actor input Schema

## `mode` (type: `string`):

Official table to export. Advertisers returns lifetime totals with trends; Weekly spend returns one row per advertiser per week; Advertiser region spend returns advertiser by state; Region spend returns country, state and district totals; Creatives returns ad-level spend ranges and targeting; Declared advertisers returns California and New Zealand filings.

## `country` (type: `string`):

Only rows for this country. Leave on Any country for global coverage. Google publishes election-ad data for these 12 regions.

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

Start date (YYYY-MM-DD). Weekly spend uses the week start date; creatives match any ad active in the window; advertiser totals require weekly spend activity in the window. Leave empty for all dates.

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

End date (YYYY-MM-DD), inclusive. Leave empty for all dates.

## `advertiserNameContains` (type: `string`):

Case-insensitive substring match on the advertiser name, for example Senate, PAC or a candidate name. Not used by Region spend mode, which has no advertiser column.

## `advertiserIds` (type: `array`):

Google advertiser IDs (AR...) or pasted Ads Transparency Center advertiser URLs. Empty means all advertisers. Not used by Region spend mode.

## `creativeIds` (type: `array`):

Google creative IDs (CR...) or pasted Ads Transparency Center creative URLs. Only used by Creatives mode.

## `currency` (type: `string`):

Currency used for minSpend, maxSpend, spendLocal and spend sorting. Google publishes spend in the advertiser's local reporting currency and never converts it.

## `minSpend` (type: `number`):

Only rows with at least this amount in the selected currency. Creatives match when the top of Google's spend range reaches it; aggregates use the exact published total.

## `maxSpend` (type: `number`):

Only rows with at most this amount in the selected currency. Creatives match when the bottom of Google's spend range is at or below it.

## `adType` (type: `string`):

Filter creatives by format. Only used by Creatives mode.

## `fundedByGoogleAdGrants` (type: `string`):

Keep only creatives funded or not funded by a Google Ad Grants in-kind donation. Only used by Creatives mode.

## `trendWindowWeeks` (type: `integer`):

Advertiser totals compare the last N weeks of spend with the N weeks before. Only used by Advertiser totals mode.

## `surgeOnly` (type: `boolean`):

Keep only advertisers whose recent spend doubled versus the prior window or who just started spending. Only used by Advertiser totals mode.

## `includeWeeklyHistory` (type: `boolean`):

Attach up to 52 most recent weekly spend rows per advertiser, in the selected currency. Only used by Advertiser totals mode.

## `sortBy` (type: `string`):

Order of the returned rows. Spend sorts use spendLocal for aggregates and the top of Google's spend range for creatives. Date sorts fall back to name in modes without dates.

## `maxItems` (type: `integer`):

Stop after this many matching records. Lower values keep runs fast and cheap.

## Actor input object example

```json
{
  "mode": "advertisers",
  "country": "US",
  "advertiserIds": [],
  "creativeIds": [],
  "currency": "USD",
  "adType": "any",
  "fundedByGoogleAdGrants": "any",
  "trendWindowWeeks": 4,
  "surgeOnly": false,
  "includeWeeklyHistory": false,
  "sortBy": "spendDesc",
  "maxItems": 2
}
```

# Actor output Schema

## `records` (type: `string`):

Dataset containing the selected Google political advertising table as clean JSON records.

# 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 = {
    "mode": "advertisers",
    "country": "US",
    "advertiserIds": [],
    "creativeIds": [],
    "currency": "USD",
    "adType": "any",
    "fundedByGoogleAdGrants": "any",
    "trendWindowWeeks": 4,
    "surgeOnly": false,
    "includeWeeklyHistory": false,
    "sortBy": "spendDesc",
    "maxItems": 2
};

// Run the Actor and wait for it to finish
const run = await client.actor("crawlyth-forge/google-political-ads-spend").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 = {
    "mode": "advertisers",
    "country": "US",
    "advertiserIds": [],
    "creativeIds": [],
    "currency": "USD",
    "adType": "any",
    "fundedByGoogleAdGrants": "any",
    "trendWindowWeeks": 4,
    "surgeOnly": False,
    "includeWeeklyHistory": False,
    "sortBy": "spendDesc",
    "maxItems": 2,
}

# Run the Actor and wait for it to finish
run = client.actor("crawlyth-forge/google-political-ads-spend").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 '{
  "mode": "advertisers",
  "country": "US",
  "advertiserIds": [],
  "creativeIds": [],
  "currency": "USD",
  "adType": "any",
  "fundedByGoogleAdGrants": "any",
  "trendWindowWeeks": 4,
  "surgeOnly": false,
  "includeWeeklyHistory": false,
  "sortBy": "spendDesc",
  "maxItems": 2
}' |
apify call crawlyth-forge/google-political-ads-spend --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,crawlyth-forge/google-political-ads-spend"
        }
    }
}
```

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/MGHbG8Ea3FXPXsqPd/builds/fMfcTAkzo1mfuIQok/openapi.json
