# Google Trends API (interest over time, regions, related) (`psypherz/google-trends-api`) Actor

Google Trends data for up to 500 keywords per run: interest over time, interest by region, related and rising queries and topics. 49 countries or worldwide. Reliable API, no blocked runs.

- **URL**: https://apify.com/psypherz/google-trends-api.md
- **Developed by:** [Muhammad Yasin Bin Abdul Rahman](https://apify.com/psypherz) (community)
- **Categories:** SEO tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $9.20 / 1,000 trends requests

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 API (interest over time, regions, related queries)

Get Google Trends data for up to 500 keywords per run. For each keyword: interest over time, interest by region, top and rising related queries, and top and rising related topics. 49 countries or worldwide, web, news, image, YouTube or Shopping search. The data comes through a commercial Google Trends API, so runs do not get blocked or rate-limited the way Trends scrapers often do.

**Price: US$0.01 per keyword report, plus a US$0.003 run fee.** Compare mode scores up to 5 keywords against each other for the same US$0.01, which is US$0.002 per keyword.

### What people use it for

- **Product and niche research:** see if demand for a product is growing, seasonal or fading before you stock or build it.
- **SEO and content planning:** find rising queries to write about before they peak.
- **Market comparison:** compare brands, products or topics on one timeline, like the Google Trends website does.
- **Regional targeting:** see which states or countries search most for a term.
- **Dashboards and AI agents:** clean JSON for scheduled tracking or for an LLM to analyse.

### Example output

Real output from the default input (US, past 12 months, lists shortened here):

| keyword | averageInterest | latestInterest | trendChangePct | peakInterestDate |
|---|---|---|---|---|
| air fryer | 66.2 | 56 | -2.8 | 2026-04-12 |
| standing desk | 32.9 | 15 | 15.2 | 2026-04-12 |

```json
{
  "keyword": "air fryer",
  "country": "US",
  "timeRange": "past_12_months",
  "googleTrendsUrl": "https://trends.google.com/trends/explore?hl=en&geo=US&date=today%2012-m&q=air%20fryer",
  "averageInterest": 66.2,
  "latestInterest": 56,
  "peakInterestDate": "2026-04-12",
  "trendChangePct": -2.8,
  "interestOverTime": [{"date": "2025-10-26", "value": 53}, {"date": "2025-11-02", "value": 54}],
  "interestByRegion": [{"regionCode": "US-WY", "region": "Wyoming", "value": 100}, {"regionCode": "US-KS", "region": "Kansas", "value": 35}],
  "topQueries": [{"query": "air fryer chicken", "value": 100}, {"query": "air fryer oven", "value": 67}],
  "risingQueries": [{"query": "laptop stand", "risePct": 18100}],
  "topTopics": [{"topic": "Deep fryer", "type": "Topic", "value": 62}],
  "risingTopics": [],
  "checkedAt": "2026-10-28T15:53:38+00:00"
}
```

Values are Google's interest scores from 0 to 100, where 100 is the peak for that keyword, place and period. `trendChangePct` compares the last quarter of the period with the first quarter. `risePct` is Google's growth figure for rising queries; very large values are what the Google Trends website shows as "Breakout". Every row has a `googleTrendsUrl` so you can check the same chart on Google.

### Input

| Field | What it does | Default |
|---|---|---|
| `keywords` | Search terms, one per line. Up to 500 per run. | 2 samples |
| `mode` | `report`: a full report for each keyword. `compare`: keywords grouped 5 at a time, in your order, and scored against each other on one timeline (no regions or related data). | `report` |
| `country` | Two-letter country code, or `WORLDWIDE`. | `US` |
| `timeRange` | `past_7_days`, `past_30_days`, `past_90_days`, `past_12_months`, `past_5_years` or `2004_present`. | `past_12_months` |
| `searchType` | `web`, `news`, `images`, `youtube` or `shopping`. | `web` |
| `language` | Two-letter code for topic names. | `en` |

### Pricing

| Event | Price |
|---|---|
| Run fee, once per run | US$0.003 |
| Trends request: one keyword report, or one group of up to 5 compared keywords | US$0.01 |

Examples: 10 keyword reports cost US$0.103. 100 keywords in compare mode (20 groups) cost US$0.203. A request is charged once Google's data comes back, including when Google has too little data for a rare keyword (the row then has a `note`). Requests that fail are listed with the reason and not charged.

### Limits

- Up to 500 keywords per run. Results usually arrive within 1 to 3 minutes.
- Google Trends samples its data, so values can differ by a few points between runs and from the website.
- Regional and related data needs enough searches. Rare keywords may return only a timeline or nothing.
- Free Apify plan: 2 requests per run.

### FAQ

**Is this the same data as the Google Trends website?** Yes. We checked our output against the website: the same timeline (within Google's sampling noise), the same top regions and the same "Breakout" queries.

**Why are compare-mode scores different from report-mode scores?** In compare mode, 100 is the peak of the most searched keyword in the group, so the scores show how the keywords relate to each other. Groups of 5 are scored separately. To compare across groups, repeat one keyword in every group.

**Can an AI agent call it?** Yes. Pass keywords, get compact JSON back, and pay per request.

### More tools from the same developer

Same style: clean JSON output, pay only for results, no charge on failed items.

| Tool | What it does |
|---|---|
| [Bulk Keyword Search Volume](https://apify.com/PsypherZ/keyword-search-volume) | Google Ads search volume, CPC, competition and 12-month trend for up to 10,000 keywords |
| [Google Keyword Ideas](https://apify.com/PsypherZ/google-keyword-ideas) | Hundreds of keyword ideas per seed with volume, CPC, difficulty and search intent |
| [Amazon Keyword Search Volume](https://apify.com/PsypherZ/amazon-keyword-volume) | Monthly Amazon searches for up to 10,000 keywords in 16 markets, plus related keywords |
| [Competitor Keywords](https://apify.com/PsypherZ/competitor-keywords) | Every Google keyword a domain ranks for, with traffic, plus its closest competitors |
| [Google SERP Results](https://apify.com/PsypherZ/google-serp-results) | Organic results, featured snippets and People Also Ask for any keyword, country and device |
| [AI Brand Visibility Tracker](https://apify.com/PsypherZ/ai-brand-visibility) | Which brands ChatGPT, Claude, Gemini and Perplexity recommend, and where yours ranks |
| [Google AI Overview Tracker](https://apify.com/PsypherZ/google-ai-overview-tracker) | Which keywords show an AI Overview, what it says, and whether it cites your site |
| [Audio and Video Transcriber](https://apify.com/PsypherZ/audio-video-transcriber) | Timestamped transcripts from audio and video files in 90+ languages |
| [Subtitle Generator](https://apify.com/PsypherZ/subtitle-generator) | Ready-to-use SRT and WebVTT subtitles from audio and video files |
| [Podcast Transcriber](https://apify.com/PsypherZ/podcast-transcriber) | Timestamped transcripts of podcast episodes from any RSS feed or Apple Podcasts link |
| [Image OCR](https://apify.com/PsypherZ/image-ocr) | Text from images in 20 languages, with confidence scores |
| [AI Image Upscaler](https://apify.com/PsypherZ/image-upscaler) | Upscale photos and artwork 2x, 3x or 4x with Real-ESRGAN AI |
| [PDF to Text and Markdown](https://apify.com/PsypherZ/pdf-to-text-markdown) | Clean text and Markdown from PDFs, with OCR for scanned pages |
| [Bulk PageSpeed Insights Audit](https://apify.com/PsypherZ/bulk-pagespeed-audit) | Core Web Vitals and Lighthouse scores for many pages, mobile and desktop |
| [Email List Validator](https://apify.com/PsypherZ/email-list-validator) | Clean email lists: syntax, domain, mail server, throwaway and role checks, plus typo fixes |
| [HTTP Request Runner](https://apify.com/PsypherZ/http-request-runner) | Send thousands of GET, POST and other API requests and get status, headers and body back |
| [Bulk File Downloader](https://apify.com/PsypherZ/bulk-file-downloader) | Save up to 5,000 direct file links to storage, each with a download link and checksum |
| [Video Frame Extractor](https://apify.com/PsypherZ/video-frame-extractor) | Still images from video files every N seconds, at set times, or evenly spaced |

# Actor input Schema

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

One search term per line. Up to 500 per run.

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

Full report: each keyword gets its own timeline, interest by region, related queries and related topics (one request per keyword). Compare: keywords are grouped 5 at a time in your order and scored against each other on one timeline, like comparing terms on the Google Trends website (one request per group of 5).

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

Two-letter country code, or WORLDWIDE.

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

Google picks the step: hourly for 7 days, daily up to 90 days, weekly up to 5 years, monthly beyond.

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

Which Google search property the interest comes from.

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

Two-letter language code for topic names, for example en, de, es.

## Actor input object example

```json
{
  "keywords": [
    "air fryer",
    "standing desk"
  ],
  "mode": "report",
  "country": "US",
  "timeRange": "past_12_months",
  "searchType": "web",
  "language": "en"
}
```

# Actor output Schema

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

One row per keyword: interest summary, timeline, and in report mode interest by region with related queries and 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 = {
    "keywords": [
        "air fryer",
        "standing desk"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("psypherz/google-trends-api").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": [
        "air fryer",
        "standing desk",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("psypherz/google-trends-api").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": [
    "air fryer",
    "standing desk"
  ]
}' |
apify call psypherz/google-trends-api --silent --output-dataset

```

## MCP server setup

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

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/3NLJUpgHI35Jelpf2/builds/6VuNppG3ebYi8c26q/openapi.json
