---
title: "How to get Google Trends data"
description: "Get Google Trends interest over time for up to five keywords, rising queries and trending searches as JSON, by country and region. The official alpha’s status, code and prices."
canonical_url: https://groundsocial.dev/guides/how-to-get-google-trends-data
---
# How to get Google Trends data

> Get Google Trends interest over time for up to five keywords, rising queries and trending searches as JSON, by country and region. The official alpha’s status, code and prices.

_Checked 2026-11-27._

Google’s official Trends API is an alpha open only to approved testers, and pytrends breaks whenever Google changes the page. A data API reads the same series the Trends site draws: one GET returns interest over time (0–100) for up to five keywords, by country or region, 3 credits.

> **Checked 27 November 2026** Every request on this page was run against the live API on that date, and the sample response is from that run. Official-API facts link to the platform’s own pages.

## The official Google Trends API

Google announced a Google Trends API on 24 July 2025, as an alpha.

- Access is by application, for a limited number of testers.
- It returns consistently scaled search interest (not absolute volumes) over a rolling five-year window, by day, week, month or year and by region.
- There is no self-serve sign-up or published price.

Sources: [Google Trends API alpha](https://developers.google.com/search/apis/trends), [Announcement, 24 Jul 2025](https://developers.google.com/search/blog/2025/07/trends-api).

## Quick start

1. **Get a key.** [Sign up](https://groundsocial.dev/app/sign-in?new=1) with an email code: 100 free credits, no card. An agent can sign itself up with `POST https://api.groundsocial.dev/v1/agent/signup`.
2. **Set it in your shell.** `export GROUNDSOCIAL_API_KEY=gs_live_…`
3. **Make the call.** Interest over time: `GET /v1/googletrends/explore`, 3 credits.

cURL:

```bash
curl "https://api.groundsocial.dev/v1/googletrends/explore?keywords=coffee,tea&location=US" \
  -H "Authorization: Bearer $GROUNDSOCIAL_API_KEY"
```

TypeScript:

```ts
const res = await fetch('https://api.groundsocial.dev/v1/googletrends/explore?keywords=coffee,tea&location=US', {
  headers: { Authorization: `Bearer ${process.env.GROUNDSOCIAL_API_KEY}` },
})
if (!res.ok) throw new Error((await res.json()).error.hint)
const data = await res.json()
```

Python:

```python
import os, requests

res = requests.get(
    "https://api.groundsocial.dev/v1/googletrends/explore?keywords=coffee,tea&location=US",
    headers={"Authorization": f"Bearer {os.environ['GROUNDSOCIAL_API_KEY']}"},
)
res.raise_for_status()
data = res.json()
```

## Sample response

Trimmed from the real response on 27 November 2026: lists cut to their first items and long strings shortened. Every field is described in the [tutorial](https://groundsocial.dev/tutorials/googletrends/interest-over-time/python).

```json
{
  "keywords": [
    "coffee",
    "tea"
  ],
  "geo": "US",
  "time": "2025-11-27 2026-11-27",
  "timelineData": [
    {
      "time": "1763856000",
      "formattedTime": "Nov 23 – 29, 2025",
      "value": [
        77,
        34
      ],
      "hasData": [
        true,
        true
      ],
      "formattedAxisTime": "Nov 23, 2025",
      "formattedValue": [
        "77",
        "34"
      ]
    },
    {
      "time": "1764460800",
      "formattedTime": "Nov 30 – Dec 6, 2025",
      "value": [
        73,
        37
      ],
      "hasData": [
        true,
        true
      ],
      "formattedAxisTime": "Nov 30, 2025",
      "formattedValue": [
        "73",
        "37"
      ]
    }
  ],
  "averages": [
    79,
    37
  ]
}
```

## What else you can get from Google Trends

| What you get | Endpoint | Credits |
| --- | --- | --- |
| [Interest over time](https://groundsocial.dev/tutorials/googletrends/interest-over-time/python) | `GET /v1/googletrends/explore` | 3 |
| [Related and rising queries](https://groundsocial.dev/tutorials/googletrends/rising-queries/python) | `GET /v1/googletrends/rising` | 3 |
| [Trending now](https://groundsocial.dev/tutorials/googletrends/trending-now/python) | `GET /v1/googletrends/trending` | 3 |

Each row links to its tutorial. Every Google Trends endpoint and price: [Google Trends API](https://groundsocial.dev/googletrends-api).

## Tips

- Values are 0–100, relative to the highest point for these keywords in this window; compare keywords in one call, not across calls.
- `timeframe=past_5_years` for long trends; `location=US-CA` for a state.
- Trends category ids (`category=71` is Food & Drink) narrow ambiguous words.

## Use it from Claude or Cursor (MCP)

Every endpoint is also an MCP tool on the remote server `https://api.groundsocial.dev/mcp`. The `?platforms=googletrends` below loads only the Google Trends tools. The client signs in with OAuth, or send your key as a Bearer token. Tools used in this guide: `googletrends_explore_get`, `googletrends_rising_get`, `googletrends_trending_get`.

Claude Code:

```bash
claude mcp add --transport http groundsocial "https://api.groundsocial.dev/mcp?platforms=googletrends"
```

Cursor:

```json
{
  "mcpServers": {
    "groundsocial": {
      "url": "https://api.groundsocial.dev/mcp?platforms=googletrends"
    }
  }
}
```

Claude.ai:

```text
Customize → Connectors → + Add → Add custom connector
URL: https://api.groundsocial.dev/mcp?platforms=googletrends
```

> **Then ask** “Compare Google Trends interest in “coffee” and “matcha” in the US over the past 5 years.”

Setup for ChatGPT, VS Code, Windsurf, n8n and others: [MCP client setup](https://groundsocial.dev/mcp).

## Pricing

Pay per call from prepaid credits; no subscription. 100 free credits cover the examples on this page. Costs below are at the [credit packs](https://groundsocial.dev/pricing)’ highest and lowest rates.

| Job | Credits | Cost |
| --- | --- | --- |
| 1,000 keyword comparisons | 3,000 | $3.00 → $1.20 |
| Rising queries for 100 seeds | 300 | $0.30 → $0.12 |

## FAQ

### Is it the same data as the Trends website?

Yes: the same series the Explore page draws, read when you call.

### Are failed calls charged?

No. A target that does not exist answers `404 target_not_found`, an upstream failure answers `503`, and neither costs anything. Credits never expire.

### Is Groundsocial official?

No. Groundsocial is an independent API that reads what the platform shows a logged-out visitor. Google Trends is a trademark of Google LLC. We are not affiliated with or endorsed by Google.

## Go deeper

- [Google Trends tutorials: 3 endpoints in six languages](https://groundsocial.dev/tutorials/googletrends)
- [Is there a Google Trends API?](https://groundsocial.dev/answers/is-there-a-google-trends-api)
- [Trend detection API](https://groundsocial.dev/use-cases/trend-detection-api)

## Related guides

- [How to get Pinterest data](https://groundsocial.dev/guides/how-to-get-pinterest-data)
- [How to get Google Maps data](https://groundsocial.dev/guides/how-to-get-google-maps-data)

Google Trends is a trademark of Google LLC. We are not affiliated with or endorsed by Google.

_Canonical HTML: https://groundsocial.dev/guides/how-to-get-google-trends-data_

## Site Navigation

### Global Hub
- [Home](https://groundsocial.dev/index.md)
- [Pricing](https://groundsocial.dev/pricing.md)
- [Endpoints](https://groundsocial.dev/endpoints.md)
- [For agents](https://groundsocial.dev/agents.md)
- [Docs](https://groundsocial.dev/docs.md)
- [Compare](https://groundsocial.dev/compare.md)
- [Blog](https://groundsocial.dev/blog.md)
- [Tutorials](https://groundsocial.dev/tutorials.md)
- [Changelog](https://groundsocial.dev/changelog.md)
- [llms.txt](https://groundsocial.dev/llms.txt)
- [Agent skill](https://groundsocial.dev/SKILL.md)

### On This Topic
- [Groundsocial: Social data in one API call](https://groundsocial.dev/index.md)
- [Pricing](https://groundsocial.dev/pricing.md)
- [Playground](https://groundsocial.dev/playground.md)
- [Use cases](https://groundsocial.dev/use-cases.md)
- [Brand monitoring API](https://groundsocial.dev/use-cases/brand-monitoring-api.md)
- [Social listening API](https://groundsocial.dev/use-cases/social-listening-api.md)
- [Comment scraping API](https://groundsocial.dev/use-cases/comment-scraping-api.md)
- [Influencer discovery API](https://groundsocial.dev/use-cases/influencer-discovery-api.md)
- [Video transcript API](https://groundsocial.dev/use-cases/video-transcript-api.md)
- [Ad library API](https://groundsocial.dev/use-cases/ad-library-api.md)
- [Review monitoring API](https://groundsocial.dev/use-cases/review-monitoring-api.md)
- [Trend detection API](https://groundsocial.dev/use-cases/trend-detection-api.md)
- [Social lead generation API](https://groundsocial.dev/use-cases/lead-generation-api.md)
- [Market research API](https://groundsocial.dev/use-cases/market-research-api.md)

## Structured data

```json
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://groundsocial.dev/"},{"@type":"ListItem","position":2,"name":"Guides","item":"https://groundsocial.dev/guides"},{"@type":"ListItem","position":3,"name":"How to get Google Trends data","item":"https://groundsocial.dev/guides/how-to-get-google-trends-data"}]}
```
