# Google Trends Scraper (Fast, No Browser) (`fabricalabs/google-trends-fast`) Actor

Interest over time, interest by region and related queries from Google Trends for any search term or comparison of up to 5 terms. Direct API calls instead of a browser: fast, cheap and patient with rate limits. You pay only for results delivered.

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

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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 (Fast, No Browser)

Get **interest over time**, **interest by region** and **related queries** from Google Trends for any search term, or compare up to 5 terms on the same chart, exactly like the Compare box on trends.google.com.

### Why this Actor

- **Fast and cheap to run.** It calls the same JSON endpoints the Google Trends website uses, instead of opening a browser. A search term takes seconds, not minutes.
- **Patient with rate limits.** Google Trends refuses requests that come too often. This Actor spaces requests out, and when Google says no it switches to a fresh IP and new cookies and backs off before trying again. If Google refuses several terms in a row, the run stops early instead of burning time.
- **One bad term doesn't stop the run.** A term that fails, or that Google has no data for, is recorded as a row that explains what happened, and the run carries on with the rest of your list.
- **Safe restarts.** If the platform moves your run to another server, it resumes where it stopped instead of starting over.
- **Familiar input.** It uses the same field names and value formats as the most popular Google Trends scraper: `searchTerms`, `isMultiple`, `timeRange` (empty means the past 12 months), `customTimeRange`, `geo`, `category` (an id such as `"47"`), `startUrls` and `maxItems`.

### What you get

For each search term (or each comparison), one dataset item with:

| Field | What it is |
|---|---|
| `searchTerms` | The term, or the terms compared |
| `interestOverTime` | Popularity from 0 to 100 per day, week or hour, per term. The last period is flagged `isPartial` while it is still running |
| `interestByRegion` | Popularity per country, or per subregion when you pick a country. For comparisons, each term's share in each region |
| `relatedQueries` | Top and rising related searches per term, with Google's growth figures such as `+800%` or `Breakout` |
| `relatedTopics` | Top and rising topics, for single terms when Google provides them |
| `exploreUrl` | The same query on trends.google.com, to check any number yourself |

### Use cases

- **Keyword and content research**: find which topics are growing and what people search for next to them.
- **Brand and product comparison**: compare up to 5 terms on the same scale, over any period since 2004.
- **Regional targeting**: see where interest is highest, down to regions of a country.
- **Seasonality**: time launches and campaigns with years of weekly data.
- **Dashboards and AI agents**: schedule runs and send the data to spreadsheets, BI tools or agents.

### Input example

```json
{
  "searchTerms": ["bitcoin, ethereum", "inteligencia artificial"],
  "isMultiple": true,
  "geo": "ES",
  "timeRange": "today 3-m"
}
```

- One line per result. With **Compare terms on the same line** on, `bitcoin, ethereum` is one comparison.
- `geo`: a country code (`US`, `ES`, `BR`) or region code (`US-CA`). Empty means worldwide.
- `timeRange`: `now 1-H`, `now 4-H`, `now 1-d`, `now 7-d`, `today 1-m`, `today 3-m`, `today 12-m`, `today 5-y` or `all`. Or set `customTimeRange` to `2024-01-01 2024-06-30`.
- `searchProperty`: `web`, `images`, `news`, `shopping` or `youtube`.
- `startUrls`: paste Google Trends explore URLs to reuse terms and filters set up in the browser.
- Switch sections off with `includeInterestOverTime`, `includeInterestByRegion`, `includeRelatedQueries` and `includeRelatedTopics`.

### Output example

Trimmed from a real run (Spain, past 90 days):

```json
{
  "searchTerms": ["bitcoin", "ethereum"],
  "geo": "ES",
  "timeRange": "today 3-m",
  "category": 0,
  "searchProperty": "web",
  "exploreUrl": "https://trends.google.com/trends/explore?date=today+3-m&geo=ES&q=bitcoin%2Cethereum",
  "interestOverTime": [
    {"time": "2026-06-27T00:00:00Z", "formattedTime": "Jun 27, 2026", "values": {"bitcoin": 49, "ethereum": 5}, "isPartial": false}
  ],
  "interestByRegion": [
    {"geoCode": "ES-RI", "geoName": "La Rioja", "values": {"bitcoin": 94, "ethereum": 6}}
  ],
  "relatedQueries": {
    "bitcoin": {
      "top": [{"query": "bitcoin precio", "value": 100, "formattedValue": "100", "link": "https://trends.google.com/trends/explore?q=bitcoin+precio&date=today+3-m&geo=ES"}],
      "rising": [{"query": "how to buy bitcoin safely", "value": 800, "formattedValue": "+800%", "link": "https://trends.google.com/trends/explore?q=how+to+buy+bitcoin+safely&date=today+3-m&geo=ES"}]
    }
  },
  "relatedTopics": {},
  "scrapedAt": "2026-09-27T12:08:58Z"
}
```

### How much does it cost?

**The Actor is free during launch.** You only pay Apify for the platform usage of your runs, and Apify's free plan includes $5 of usage every month, with no credit card.

In our test runs, one search term cost about $0.0006 of platform usage with the default residential proxy, so the free plan covers roughly 9,000 terms a month. Costs vary a little with your plan and with how often Google asks the Actor to slow down.

### Good to know

- Google Trends numbers are relative: 100 is the peak popularity within the chart, not a search count. Google also samples its data, so repeated runs can differ by a point or two, just like on the website.
- Google does not provide related topics for comparisons, and sometimes withholds them for single terms too. The list is empty then; everything else is unaffected.
- Very rare terms may have too little data for Google to show anything. You then get a row with empty lists and a `note`, not an error.
- Comparisons with a different country or time range per term are not supported yet.

### FAQ

**Do I need a Google account?** No.

**Why are the numbers between 0 and 100?** That is how Google Trends reports interest: 100 is the peak within the chart, not a number of searches.

**Can I run it on a schedule?** Yes. Save your input as a task and schedule it in Apify, daily or weekly.

**Can AI agents use it?** Yes, through the Apify MCP server, as a tool that takes search terms.

**Is it legal to collect this data?** The Actor collects only the public, aggregated and anonymous statistics Google publishes, with no personal data. Check the terms that apply to your use case.

### Use it from your code or AI agent

Run it through the Apify API, on a schedule, or from AI agents through the Apify MCP server, where it appears as a tool your agent can call with a search term.

This Actor collects the public, aggregated and anonymous statistics shown on trends.google.com. It is not affiliated with or endorsed by Google.

# Actor input Schema

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

One search term per line. Each line becomes one result. To compare terms on the same chart, put them on one line separated by commas and turn on 'Compare terms on the same line'.

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

When on, commas separate up to 5 terms that are compared against each other, exactly like the Compare box on the Google Trends website.

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

Optional. Paste Google Trends explore URLs (trends.google.com/trends/explore?...) to reuse the terms and filters you set up in the browser.

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

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

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

Optional. Start and end date separated by a space, e.g. 2024-01-01 2024-06-30. Overrides the time range above.

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

Two-letter country code (US, ES, BR, DE...) or a region code such as US-CA. Leave empty for worldwide.

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

Google Trends category id, e.g. 47 for Autos & Vehicles. It appears as cat= in Google Trends URLs. Leave empty for all categories.

## `searchProperty` (type: `string`):

Which Google search the interest comes from.

## `includeInterestOverTime` (type: `boolean`):

Popularity from 0 to 100 for each period of the time range.

## `includeInterestByRegion` (type: `boolean`):

Popularity per country, or per subregion when a country is selected. For comparisons, each term's share in each region.

## `includeRelatedQueries` (type: `boolean`):

Top and rising searches related to each term.

## `includeRelatedTopics` (type: `boolean`):

Top and rising topics for single terms. Google does not provide topics for comparisons and sometimes withholds them; the list is empty then.

## `language` (type: `string`):

Language of topic names and dates, e.g. en-US, es, pt-BR.

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

Stop after this many search terms or comparisons. 0 means no limit.

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

Google Trends limits how often one IP can ask. The default residential proxy keeps runs reliable.

## Actor input object example

```json
{
  "searchTerms": [
    "bitcoin, ethereum",
    "artificial intelligence"
  ],
  "isMultiple": true,
  "timeRange": "",
  "geo": "",
  "category": "",
  "searchProperty": "web",
  "includeInterestOverTime": true,
  "includeInterestByRegion": true,
  "includeRelatedQueries": true,
  "includeRelatedTopics": true,
  "language": "en-US",
  "maxItems": 0,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

One row per search term or comparison, with a link to the same query on Google Trends.

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

Every section you switched on: interest over time, interest by region, related queries and related topics.

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

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

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

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fabricalabs/google-trends-fast"
        }
    }
}
```

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/4S3ZucKQoZNMPnHnF/builds/mKHwJq7ZZ5QKQJkdX/openapi.json
