100 free credits. No credit card required.Start building
Logo
Google Trends logo
100 free credits. No credit card required

Google Trends Explore API

Returns Google Trends interest over time for up to five keywords: dated points scored 0 to 100 per keyword, plus each keyword's average over the window.

GET /v1/google_trends/explore

Last updated November 2026Maintained by the SocialCrawl team

When to use the Google Trends Explore API

Use it to size a search term or compare several terms head to head over a chosen period, region, and category.

From the API reference

Returns Google Trends interest-over-time for up to 5 keywords in one call. Response is { series, averages }: series is one entry per keyword, each with dated points ({ date, datetime, value, partial }) where value is Google's 0-100 relative-popularity score; averages is the per-keyword mean over the window. partial is true on a bucket Google is still accumulating, which is normally the last point: treat it as an incomplete count rather than a fall in interest, and drop it before charting a trend. Compare terms head-to-head (values are normalised across the keyword set) and scope by location, timeframe, and category. A keyword set with no measurable search interest returns 404 and costs 0 credits, so a dead term is never billed. A billed refresh is typically 5-9s and the slow tail reaches about 30s, so set a client timeout of at least 60s: this surface reads Google Trends live and Google itself is the slow part. Exact repeats may use the 2-minute search cache and return in milliseconds at 0 credits.

Searching 69 platforms in parallel

·TikTok logoTikTok·Instagram logoInstagram·YouTube logoYouTube·Facebook logoFacebook·X logoX·LinkedIn logoLinkedIn·Reddit logoReddit·Threads logoThreads·Pinterest logoPinterest·Twitch logoTwitch·Truth Social logoTruth Social·Snapchat logoSnapchat·Kick logoKick·Bluesky logoBluesky·Kwai logoKwai·Rumble logoRumble·Spotify logoSpotify·Apple Music logoApple Music·TikTok Shop logoTikTok Shop·Amazon Shop logoAmazon Shop·Google Shopping logoGoogle Shopping·Trustpilot logoTrustpilot·TripAdvisor logoTripAdvisor·Yelp logoYelp·Linktree logoLinktree·Komi logoKomi·Pillar logoPillar·lnk.bio logolnk.bio·Facebook Ads logoFacebook Ads·Google Ads logoGoogle Ads·LinkedIn Ads logoLinkedIn Ads·Google Search logoGoogle Search·Google News logoGoogle News·Finance logoFinance·Polymarket logoPolymarket·Tavily logoTavily·Hacker News logoHacker News·GitHub logoGitHub·Perplexity logoPerplexity·Naver logoNaver·Utility logoUtility·Universal Search logoUniversal Search
·TikTok logoTikTok·Instagram logoInstagram·YouTube logoYouTube·Facebook logoFacebook·X logoX·LinkedIn logoLinkedIn·Reddit logoReddit·Threads logoThreads·Pinterest logoPinterest·Twitch logoTwitch·Truth Social logoTruth Social·Snapchat logoSnapchat·Kick logoKick·Bluesky logoBluesky·Kwai logoKwai·Rumble logoRumble·Spotify logoSpotify·Apple Music logoApple Music·TikTok Shop logoTikTok Shop·Amazon Shop logoAmazon Shop·Google Shopping logoGoogle Shopping·Trustpilot logoTrustpilot·TripAdvisor logoTripAdvisor·Yelp logoYelp·Linktree logoLinktree·Komi logoKomi·Pillar logoPillar·lnk.bio logolnk.bio·Facebook Ads logoFacebook Ads·Google Ads logoGoogle Ads·LinkedIn Ads logoLinkedIn Ads·Google Search logoGoogle Search·Google News logoGoogle News·Finance logoFinance·Polymarket logoPolymarket·Tavily logoTavily·Hacker News logoHacker News·GitHub logoGitHub·Perplexity logoPerplexity·Naver logoNaver·Utility logoUtility·Universal Search logoUniversal Search
·TikTok logoTikTok·Instagram logoInstagram·YouTube logoYouTube·Facebook logoFacebook·X logoX·LinkedIn logoLinkedIn·Reddit logoReddit·Threads logoThreads·Pinterest logoPinterest·Twitch logoTwitch·Truth Social logoTruth Social·Snapchat logoSnapchat·Kick logoKick·Bluesky logoBluesky·Kwai logoKwai·Rumble logoRumble·Spotify logoSpotify·Apple Music logoApple Music·TikTok Shop logoTikTok Shop·Amazon Shop logoAmazon Shop·Google Shopping logoGoogle Shopping·Trustpilot logoTrustpilot·TripAdvisor logoTripAdvisor·Yelp logoYelp·Linktree logoLinktree·Komi logoKomi·Pillar logoPillar·lnk.bio logolnk.bio·Facebook Ads logoFacebook Ads·Google Ads logoGoogle Ads·LinkedIn Ads logoLinkedIn Ads·Google Search logoGoogle Search·Google News logoGoogle News·Finance logoFinance·Polymarket logoPolymarket·Tavily logoTavily·Hacker News logoHacker News·GitHub logoGitHub·Perplexity logoPerplexity·Naver logoNaver·Utility logoUtility·Universal Search logoUniversal Search
·TikTok logoTikTok·Instagram logoInstagram·YouTube logoYouTube·Facebook logoFacebook·X logoX·LinkedIn logoLinkedIn·Reddit logoReddit·Threads logoThreads·Pinterest logoPinterest·Twitch logoTwitch·Truth Social logoTruth Social·Snapchat logoSnapchat·Kick logoKick·Bluesky logoBluesky·Kwai logoKwai·Rumble logoRumble·Spotify logoSpotify·Apple Music logoApple Music·TikTok Shop logoTikTok Shop·Amazon Shop logoAmazon Shop·Google Shopping logoGoogle Shopping·Trustpilot logoTrustpilot·TripAdvisor logoTripAdvisor·Yelp logoYelp·Linktree logoLinktree·Komi logoKomi·Pillar logoPillar·lnk.bio logolnk.bio·Facebook Ads logoFacebook Ads·Google Ads logoGoogle Ads·LinkedIn Ads logoLinkedIn Ads·Google Search logoGoogle Search·Google News logoGoogle News·Finance logoFinance·Polymarket logoPolymarket·Tavily logoTavily·Hacker News logoHacker News·GitHub logoGitHub·Perplexity logoPerplexity·Naver logoNaver·Utility logoUtility·Universal Search logoUniversal Search
Google Trends API

What can you do with the Explore API?

The Explore endpoint gives you structured Google Trends data with computed fields in a single request. No scraping infrastructure to build or maintain.

Example Request

# GET /v1/google_trends/explore: 5 credits per call. Cache hits are free and failed calls are refunded.
# Check the price first for 0 credits: add dry_run=1 to the query. Nothing is fetched or charged.
# --max-time 55: this endpoint's measured p99 latency x 1.5.
# --retry 3: retries timeouts, 429 and 5xx, honoring Retry-After.
# -o response.json keeps only the final attempt's body.
# One Idempotency-Key per request, reused on every retry, so a retried call is never charged twice.
IDEMPOTENCY_KEY=$(od -An -N16 -tx1 /dev/urandom | tr -d ' \n')
curl -sS --max-time 55 --retry 3 -o response.json \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Idempotency-Key: $IDEMPOTENCY_KEY" \
  "https://www.socialcrawl.dev/v1/google_trends/explore?keywords=uv+index&timeframe=past_90_days" && cat response.json
# GET /v1/google_trends/explore: 5 credits per call. Cache hits are free and failed calls are refunded.
# Check the price first for 0 credits: add dry_run=1 to the query. Nothing is fetched or charged.
import os
import random
import time
import uuid

import requests

API_KEY = os.environ.get("SOCIALCRAWL_API_KEY", "YOUR_API_KEY")
TIMEOUT_S = 55  # this endpoint's measured p99 latency x 1.5.
MAX_RETRIES = 3
URL = "https://www.socialcrawl.dev/v1/google_trends/explore"


def backoff(attempt):
    # Exponential backoff with jitter: about 1 s, 2 s, then 4 s.
    return 2 ** attempt * (0.5 + random.random() / 2)


def socialcrawl(params):
    # One Idempotency-Key per request, reused on every retry, so a retried call is never charged twice.
    idempotency_key = str(uuid.uuid4())
    for attempt in range(MAX_RETRIES + 1):
        try:
            res = requests.get(
                URL,
                params=params,
                headers={"x-api-key": API_KEY, "Idempotency-Key": idempotency_key},
                timeout=TIMEOUT_S,
            )
            body = res.json()
        except (requests.RequestException, ValueError):
            # A timeout, a dropped connection or a non-JSON gateway page: retry with the same key.
            if attempt == MAX_RETRIES:
                raise
            time.sleep(backoff(attempt))
            continue
        if body["success"]:
            return body
        error = body["error"]
        # Branch on error["type"], never on the message text.
        if error["type"] == "RESOURCE_NOT_FOUND":
            return None  # refunded: nothing to read
        retry_after = res.headers.get("Retry-After")
        # SERVICE_UNAVAILABLE without Retry-After is a withdrawn endpoint: permanent.
        permanent = error["type"] == "SERVICE_UNAVAILABLE" and retry_after is None
        if not error.get("retryable") or permanent or attempt == MAX_RETRIES:
            raise RuntimeError(f"{error['type']}: {error['message']} (request_id {body['request_id']})")
        # Retry-After (seconds) wins; otherwise back off.
        time.sleep(float(retry_after) if retry_after else backoff(attempt))


params = {
    "keywords": "uv index",
    "timeframe": "past_90_days",
}
body = socialcrawl(params)
if body is not None:
    print(body["data"])
// GET /v1/google_trends/explore: 5 credits per call. Cache hits are free and failed calls are refunded.
// Check the price first for 0 credits: add dry_run=1 to the query. Nothing is fetched or charged.
const API_KEY = process.env.SOCIALCRAWL_API_KEY ?? "YOUR_API_KEY";
const TIMEOUT_MS = 55_000; // this endpoint's measured p99 latency x 1.5.
const MAX_RETRIES = 3;

type Page = { next_cursor: string | null; has_more: boolean };
type SocialCrawlResponse =
  | { success: true; data: any; pagination?: Page; credits_used: number; request_id: string }
  | { success: false; error: { type: string; message: string; retryable: boolean }; request_id: string };

const sleep = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms));
// Exponential backoff with jitter: about 1 s, 2 s, then 4 s.
const backoffMs = (attempt: number) => 2 ** attempt * 1000 * (0.5 + Math.random() / 2);

async function socialcrawl(url: URL) {
  // One Idempotency-Key per request, reused on every retry, so a retried call is never charged twice.
  const idempotencyKey = crypto.randomUUID();
  for (let attempt = 0; ; attempt++) {
    let res: Response;
    let body: SocialCrawlResponse;
    try {
      res = await fetch(url, {
        headers: {
          "x-api-key": API_KEY,
          "Idempotency-Key": idempotencyKey,
        },
        signal: AbortSignal.timeout(TIMEOUT_MS),
      });
      body = (await res.json()) as SocialCrawlResponse;
    } catch (error) {
      // A timeout, a dropped connection or a non-JSON gateway page: retry with the same key.
      if (attempt >= MAX_RETRIES) throw error;
      await sleep(backoffMs(attempt));
      continue;
    }
    if (body.success) return body;
    // Branch on error.type, never on the message text.
    if (body.error.type === "RESOURCE_NOT_FOUND") return null; // refunded: nothing to read
    const retryAfter = res.headers.get("Retry-After");
    // SERVICE_UNAVAILABLE without Retry-After is a withdrawn endpoint: permanent.
    const permanent = body.error.type === "SERVICE_UNAVAILABLE" && retryAfter === null;
    if (!body.error.retryable || permanent || attempt >= MAX_RETRIES) {
      throw new Error(`${body.error.type}: ${body.error.message} (request_id ${body.request_id})`);
    }
    // Retry-After (seconds) wins; otherwise back off.
    await sleep(retryAfter ? Number(retryAfter) * 1000 : backoffMs(attempt));
  }
}

const url = new URL("https://www.socialcrawl.dev/v1/google_trends/explore");
url.searchParams.set("keywords", "uv index");
url.searchParams.set("timeframe", "past_90_days");

const body = await socialcrawl(url);
if (body) console.log(body.data);

Parameters

ParameterRequiredDescription
keywordsYes1-5 comma-separated keywords (e.g. 'reverse audio,voice changer'). With multiple keywords the 0-100 values are normalised across the set for direct comparison. Each keyword must be 2 to 100 characters. More than 5 keywords, a 1-character keyword, or a keyword made only of punctuation is rejected with a free 400 before the request is billed.
locationNoLocation as an ISO country code ('US', 'KR'), a full country name as Google Trends spells it ('United States', 'South Korea'), or a numeric location code ('2840'). Common spellings and ISO codes are normalised, so 'KR', 'Korea' and 'South Korea' all reach the same place. Google Trends does not publish every country, and a location it has no data for is rejected with a free 400 naming the accepted forms; a 404 means the keyword had no data there, not that the location is unsupported. Defaults to worldwide-leaning US.
timeframeNoPreset time window: past_hour, past_4_hours, past_day, past_7_days, past_30_days, past_90_days, past_12_months, or past_5_years. Defaults to past_12_months. (past_hour | past_4_hours | past_day | past_7_days | past_30_days | past_90_days | past_12_months | past_5_years)
categoryNoNumeric Google Trends category code to scope the query (default 0 = all categories). A non-numeric value is rejected with a free 400 rather than silently returning an all-categories series.
Example Response

What does the Google Trends Explore API return?

Every response follows one unified schema. Here is a real, unmodified response body, so you can see the exact fields you get back before spending a credit.

Example response
{
  "success": true,
  "platform": "google_trends",
  "endpoint": "/v1/google_trends/explore",
  "data": {
    "series": [
      {
        "keyword": "uv index",
        "points": [
          {
            "date": "2026-07-02",
            "datetime": "2026-07-02T00:00:00.000Z",
            "value": 83,
            "partial": false
          },
          {
            "date": "2026-07-03",
            "datetime": "2026-07-03T00:00:00.000Z",
            "value": 90,
            "partial": false
          }
        ]
      }
    ],
    "averages": [
      {
        "keyword": "uv index",
        "value": 35
      }
    ]
  },
  "credits_used": 5,
  "request_id": "req_example000000",
  "cached": false,
  "credits_remaining": 9999,
  "source": "captured",
  "captured_at": "2026-10-02T12:52:49.554Z",
  "redacted": true
}

Live sample illustrating the unified response shape. Field values reflect the record you query.

API Details

How does the Google Trends Explore API work?

Send a GET request with your API key and get back clean, structured JSON in our unified schema. Supported computed fields are populated when the source provides the required inputs.

Method

GET

Response

JSON

Why SocialCrawl

Why use SocialCrawl for Google Trends Explore data?

We handle the complexity of Google Trends data extraction so you can focus on building. Unified schema, AI enrichment, and zero platform logic in your code.

Developer First

How do you scrape social media data in seconds?

The fastest social media scraping API for developers. Scrape profiles, posts, comments, and analytics from 69 platforms covering 10B+ monthly active users.

One schema, every platform

Query 69 platforms with identical response structures. Write your integration once.

Computed fields, not just scraped

When an endpoint supports these metrics and the source provides the required inputs, the normalized record includes engagement_rate, estimated_reach, content_category, and language. Ready to use.

See your data before you code

Visual Data Explorer. Paste any URL, get rich result cards, sortable tables, CSV export.

import requests

response = requests.get(
    'https://www.socialcrawl.dev/v1/tiktok/profile',
    params={'handle': 'charlidamelio'},
    headers={'x-api-key': 'sc_YOUR_API_KEY'}
)
data = response.json()
[ .JSON ]
{
  "success": true,
  "platform": "tiktok",
  "data": {
    "author": {
      "username": "charlidamelio",
      "followers": 152400000
    },
    "engagement": {
      "likes": 12400000000,
      "engagement_rate": 0.087
    },
    "metadata": {
      "language": "en",
      "content_category": "lifestyle"
    }
  }
}
+ 69 platforms
FAQ

Have a question? We got answers

Find answers to frequently asked questions about SocialCrawl's API, pricing, and capabilities.

Contact us
How do I get Google Trends data through an API?
Send a GET request to /v1/google_trends/explore with 1 to 5 comma-separated keywords and an x-api-key header. The response is { series, averages }: each series has dated points with Google's 0 to 100 relative-popularity value, and averages holds the mean per keyword over the window.
Can I compare several keywords in one call?
Yes, up to 5. With more than one keyword the 0 to 100 values are normalised across the set, so the terms compare head to head. More than 5 keywords, a 1-character keyword, or a keyword made only of punctuation is rejected with a free 400.
Which timeframes, countries and categories can I use?
timeframe takes past_hour, past_4_hours, past_day, past_7_days, past_30_days, past_90_days, past_12_months (the default) or past_5_years. location takes a country code such as US or KR, or a country name. category takes a numeric Google Trends category code, and 0 means all.
What does partial mean on a data point?
partial is true on a bucket Google is still accumulating, normally the last point. Treat it as an incomplete count rather than a fall in interest, and drop it before charting a trend.
What happens when a keyword has no search interest?
A keyword set with no measurable search interest returns 404 and costs 0 credits, so a term nobody searches is never billed. A 404 means the keyword had no data in that place, not that the location is unsupported.
How much does the Google Trends data API cost, and how fast is it?
Each call costs 5 credits on the advanced tier. A billed refresh typically takes 5 to 9 seconds and the slow tail reaches about 30, so set a client timeout of at least 60 seconds. Exact repeats within 2 minutes can come from cache at 0 credits.

Ask AI about SocialCrawl

Ready to scrape Google Trends Explore data?

Get your API key and start pulling Google Trends data in under 60 seconds.

Start for free

🤖 AI agent or LLM? Read this page as markdown