# Google Trends Scraper: Interest, Regions & Related Queries (`rowfinch/google-trends-scraper`) Actor

Google Trends data for any term or comparison: interest over time, by country, state and city, and top and rising related queries. Web, YouTube, News, Images and Shopping search. Any period, place and category. $4 per 1,000 searches on Starter.

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

## Pricing

from $2.40 / 1,000 searches

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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 Trends Scraper

Google Trends data for any search term, or up to five compared on one chart: interest over time, interest by country, state, metro and city, and the top and rising related queries. Any period from the past hour to 2004, any country or region, any category, and web, YouTube, News, Image or Shopping search. Paste a Google Trends link and its filters carry over. No login, no API key.

**$4 per 1,000 searches on Apify's Starter plan.** One search is one row with everything the Google Trends page shows for it.

### What it's for

- **Product and niche research**: is demand for a product growing, flat or seasonal, and where is it highest?
- **SEO and content planning**: rising related queries show what people start searching before keyword tools catch up. `Breakout` means growth over 5,000%.
- **Comparing brands or products**: up to five terms on one chart, on the same 0–100 scale.
- **Local marketing**: the states, metros and cities where a term is searched most, with city coordinates.
- **YouTube and shopping trends**: set `searchType` to YouTube or Google Shopping to see what people look for there.
- **Tracking over time**: run it on a schedule and keep a history of how interest moves.

### Input

| Field | What it does |
|---|---|
| `searchTerms` | One chart per term: `pickleball`, `oat milk` |
| `isMultiple` | Commas separate compared terms: `coffee, tea, matcha` is one chart of three terms (up to 5) |
| `startUrls` | Links from trends.google.com/trends/explore. Each keeps its own place, period, category and search type |
| `timeRange` | Past hour, 4 hours, day, 7 days, 30 days, 90 days, 12 months (default), 5 years, or since 2004 |
| `customTimeRange` | Two dates, `2024-01-01 2024-12-31`. Replaces `timeRange` |
| `geo` | A country or region code: `US`, `GB`, `BR`, `US-CA`. Empty is worldwide |
| `category` | One of Google's top categories, like Food & Drink or Shopping |
| `searchType` | Web search (default), `youtube`, `news`, `images` or `froogle` (Google Shopping) |
| `spreadsheetId` | A public Google Sheet's link or ID: its first column is read as search terms, without the header row |
| `maxItems` | Most searches in the run (0 means no limit) |

```json
{
  "searchTerms": ["pickleball", "padel, pickleball"],
  "isMultiple": true,
  "geo": "US",
  "timeRange": "today 3-m"
}
```

Coming from apify/google-trends-scraper? It takes the same input fields (`searchTerms`, `isMultiple`, `timeRange`, `customTimeRange`, `geo`, `category`, `startUrls`, `spreadsheetId`, `maxItems`) and gives the same output fields, so saved inputs and code that reads the dataset keep working.

### Output

One row per search. Real output for `pickleball` in the US over the past 90 days, with each list cut to its first entries:

```json
{
  "inputUrlOrTerm": "pickleball",
  "searchTerm": "pickleball",
  "geo": "US",
  "timeRange": "today 3-m",
  "category": 0,
  "searchType": "",
  "interestOverTime_timelineData": [
    {
      "time": "1794096000",
      "formattedTime": "Nov 8, 2026",
      "formattedAxisTime": "Nov 8",
      "value": [
        63
      ],
      "hasData": [
        true
      ],
      "formattedValue": [
        "63"
      ]
    },
    {
      "time": "1794182400",
      "formattedTime": "Nov 9, 2026",
      "formattedAxisTime": "Nov 9",
      "value": [
        54
      ],
      "hasData": [
        true
      ],
      "formattedValue": [
        "54"
      ],
      "isPartial": true
    }
  ],
  "interestOverTime_averages": [],
  "interestBy": [],
  "interestBySubregion": [
    {
      "geoCode": "US-HI",
      "geoName": "Hawaii",
      "value": [
        100
      ],
      "formattedValue": [
        "100"
      ],
      "maxValueIndex": 0,
      "hasData": [
        true
      ]
    },
    {
      "geoCode": "US-CO",
      "geoName": "Colorado",
      "value": [
        89
      ],
      "formattedValue": [
        "89"
      ],
      "maxValueIndex": 0,
      "hasData": [
        true
      ]
    }
  ],
  "interestByMetro": [],
  "interestByCity": [
    {
      "geoName": "Bellevue",
      "coordinates": {
        "lat": 47.610377,
        "lng": -122.2006786
      },
      "value": [
        100
      ],
      "formattedValue": [
        "100"
      ],
      "maxValueIndex": 0,
      "hasData": [
        true
      ]
    }
  ],
  "relatedQueries_top": [
    {
      "query": "pickleball paddle",
      "value": 100,
      "formattedValue": "100",
      "link": "https://trends.google.com/trends/explore?q=pickleball+paddle&date=today+3-m&geo=US"
    },
    {
      "query": "pickleball courts",
      "value": 88,
      "formattedValue": "88",
      "link": "https://trends.google.com/trends/explore?q=pickleball+courts&date=today+3-m&geo=US"
    }
  ],
  "relatedQueries_rising": [
    {
      "query": "maria ford pickleball",
      "value": 5350,
      "formattedValue": "Breakout",
      "link": "https://trends.google.com/trends/explore?q=maria+ford+pickleball&date=today+3-m&geo=US"
    },
    {
      "query": "veolia pickleball national championships",
      "value": 1300,
      "formattedValue": "+1,300%",
      "link": "https://trends.google.com/trends/explore?q=veolia+pickleball+national+championships&date=today+3-m&geo=US"
    }
  ],
  "relatedTopics_top": [],
  "relatedTopics_rising": [],
  "url": "https://trends.google.com/trends/explore?q=pickleball&geo=US&date=today+3-m&hl=en-US"
}
```

| Field | What it is |
|---|---|
| `interestOverTime_timelineData` | Interest from 0 to 100 per hour, day, week or month (the period sets which). `value` has one number per compared term; `isPartial` marks a period still in progress |
| `interestOverTime_averages` | Each compared term's average over the period (comparisons only) |
| `interestBy` | Worldwide searches: interest by country |
| `interestBySubregion` | Searches in a country: interest by state or province |
| `interestByMetro` | Searches in a US state: interest by metro area |
| `interestByCity` | Searches in a country or region: interest by city, with coordinates |
| `relatedQueries_top` | The most searched queries related to the term, 0 to 100 |
| `relatedQueries_rising` | The fastest-growing related queries, in percent growth |
| `url` | The same chart on trends.google.com |

In a comparison, every related query has a `searchTerm` field saying which of the terms it belongs to.

Places where Google has too little data are left out of the lists, as on the Google Trends page.

`relatedTopics_top` and `relatedTopics_rising` are kept for compatibility with other Google Trends scrapers. They come back empty: Google Trends doesn't serve related topics to API clients.

A search that can't be read gets a free row with `error` and the reason, so one bad search doesn't fail the run.

### Price

Per 1,000 searches, by your Apify plan, with the timeline, every place list and the related queries included:

| | Free | Starter | Scale | Business |
|---|---|---|---|---|
| Searches | $5.00 | $4.00 | $3.20 | $2.40 |

Error rows are free. On Apify's free plan a run returns up to 100 searches.

| Run, on Starter | Cost |
|---|---|
| One term, or one comparison of up to 5 terms | $0.004 |
| 250 keywords from a Google Sheet | $1.00 |

### FAQ

**What do the numbers mean?** Google Trends doesn't give search counts. 100 is the point of highest interest on the chart, for that place and period, and every other value is relative to it. In a comparison all terms share the scale, so they can be compared directly.

**Why do two runs give slightly different numbers?** Google computes Trends from a sample of searches, and the sample changes from day to day, as it does on the Google Trends site.

**Can I get daily data for a whole year?** Google sets the step from the period: days for up to 9 months, weeks up to 5 years, months beyond that. For daily values over a long period, run it once per quarter with `customTimeRange`.

**How fast is it?** About a hundred searches in five minutes. Past that Google starts refusing some requests, so the actor slows down and tries those again a minute later: in our test, a batch of 150 took about half an hour and 135 came back. Searches that still fail get a free error row; run them again later.

**Which IPs does it use?** Apify's datacenter proxy first, then US residential IPs for any session Google keeps refusing. Pick a proxy in the input to use only that one.

# Actor input Schema

## `searchTerms` (type: `array`):

One chart per term. Turn on Compare terms to put several terms on one chart, like coffee, tea.

## `isMultiple` (type: `boolean`):

Commas separate the terms of one comparison, up to 5: coffee, tea, matcha.

## `startUrls` (type: `array`):

Links copied from trends.google.com/trends/explore. Each keeps its own place, period, category and search type.

## `timeRange` (type: `string`):

How far back the chart goes. Google sets the step: hours, days, weeks or months.

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

Two dates, like 2024-01-01 2024-12-31. Replaces the period above.

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

A country or region code: US, GB, BR, US-CA. Empty is worldwide.

## `category` (type: `string`):

Only searches in one of Google's top categories.

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

Where the searches were made.

## `spreadsheetId` (type: `string`):

A public sheet's link or ID. Its first column is read, without the header row.

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

0 reads every search.

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

By default, Apify datacenter IPs, moving to US residential ones when Google slows them down. Pick a proxy here to use only that one.

## Actor input object example

```json
{
  "searchTerms": [
    "pickleball"
  ],
  "isMultiple": false,
  "timeRange": "",
  "geo": "",
  "category": "",
  "searchType": "",
  "maxItems": 0,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

No description

# 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 = {
    "searchTerms": [
        "pickleball"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("rowfinch/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 = {
    "searchTerms": ["pickleball"],
    "proxyConfiguration": { "useApifyProxy": True },
}

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

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,rowfinch/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/QT6LfNXLFFRpo4Pbd/builds/CsvbQK8v7imAMEFCg/openapi.json
