# Google Trends Scraper (`scrapewell/google-trends-scraper`) Actor

Google Trends interest over time, interest by region, related queries and related topics, plus daily Trending Now. Auto-retries and rotates sessions on rate limits, so runs finish.

- **URL**: https://apify.com/scrapewell/google-trends-scraper.md
- **Developed by:** [Hunter](https://apify.com/scrapewell) (community)
- **Categories:** SEO tools, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

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

### What does Google Trends Scraper do?

Google Trends Scraper collects **Google Trends** data for any list of keywords: **interest over time, interest by
region, related queries and related topics**, plus each country's **Trending Now** searches with traffic and news links.

It is built to finish runs. When Google rate-limits, the scraper rotates its session and retries with backoff instead
of failing, so large keyword lists come back complete.

- Compare up to 5 keywords on one shared 0-100 scale, exactly like the Trends website, or score each keyword alone.
- Any country or region (`US`, `GB`, `US-CA`) or worldwide.
- Preset periods from the past hour to 2004-present, or a custom date range.
- Web, News, Images, YouTube or Google Shopping searches, and any Trends category.

### What data can you extract?

| Result type | What you get |
|---|---|
| `interestOverTime` | Full time series (`date`, `value`, `isPartial`) plus average, peak date and latest value |
| `interestByRegion` | Countries, states, metros or cities ranked by interest |
| `relatedQueries` | Top and rising related searches, including "Breakout" terms |
| `relatedTopics` | Top and rising topics with Knowledge Graph IDs |
| `trendingNow` | Today's trending searches per country, approximate traffic and news articles |

### How to use it

1. Enter your keywords, or only Trending Now countries.
2. Pick location, time range and the data types you need.
3. Click **Start** and export JSON, CSV or Excel, or schedule it and pipe results to Google Sheets, Slack or your API.

### Example output

```json
{
  "type": "interestOverTime",
  "keyword": "bitcoin",
  "geo": "US",
  "timeframe": "today 3-m",
  "comparedWith": ["bitcoin", "ethereum"],
  "average": 47.3,
  "peakDate": "Oct 6, 2026",
  "latestValue": 52,
  "points": [{ "date": "Jul 29, 2026", "timestamp": 1785283200, "value": 47, "isPartial": false }]
}
```

### How much does it cost?

You pay per result row: one keyword with all four data types is four rows. Error rows are free, and each run has a tiny
$0.00005 start charge.

### FAQ

**Are these search volumes?** No. Google Trends publishes a relative 0-100 index, and this scraper returns exactly that.

**Why do compared and single-keyword values differ?** Compared keywords share one scale, so the largest one sets 100.

**Big keyword lists?** Use the residential proxy for the fewest rate limits.

**Need a field or found a problem?** Open an issue on the Issues tab.

# Actor input Schema

## `keywords` (type: `array`):

Search terms. Leave empty if you only want Trending Now.

## `compareKeywords` (type: `boolean`):

On: keywords are compared in groups of up to 5 on one shared 0-100 scale (like the Trends UI). Off: each keyword gets its own 0-100 scale.

## `geo` (type: `string`):

Country or region code, e.g. US, GB, US-CA. Empty = worldwide.

## `timeframe` (type: `string`):

Period to analyse. Ignored when a custom time range is set.

## `customTimeRange` (type: `string`):

Optional. Format: YYYY-MM-DD YYYY-MM-DD, e.g. 2026-01-01 2026-06-30

## `category` (type: `integer`):

Google Trends category ID. 0 = all categories.

## `searchType` (type: `string`):

Search type

## `interestOverTime` (type: `boolean`):

Time series of Google's 0-100 interest index per keyword.

## `interestByRegion` (type: `boolean`):

Regions ranked by interest for each keyword.

## `regionResolution` (type: `string`):

Granularity of the region breakdown.

## `relatedQueries` (type: `boolean`):

Top and rising related searches, including Breakout terms.

## `relatedTopics` (type: `boolean`):

Only available when keywords are not compared.

## `trendingNowGeos` (type: `array`):

Optional. Country codes (e.g. US, GB) to also fetch today's trending searches with traffic and news links.

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

Residential proxy gives the fewest rate limits.

## Actor input object example

```json
{
  "keywords": [
    "bitcoin",
    "ethereum"
  ],
  "compareKeywords": false,
  "geo": "",
  "timeframe": "today 12-m",
  "category": 0,
  "searchType": "web",
  "interestOverTime": true,
  "interestByRegion": true,
  "regionResolution": "",
  "relatedQueries": true,
  "relatedTopics": false,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

All rows in the default dataset (JSON).

## `overview` (type: `string`):

The main fields as a table.

# 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 = {
    "keywords": [
        "bitcoin",
        "ethereum"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapewell/google-trends-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 = {
    "keywords": [
        "bitcoin",
        "ethereum",
    ],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("scrapewell/google-trends-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 '{
  "keywords": [
    "bitcoin",
    "ethereum"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call scrapewell/google-trends-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapewell/google-trends-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/ENCddVAjSG2S4kUQj/builds/5YdgXWrD8gUIs6Kde/openapi.json
