SerpBase
Back to Blog

YouTube Trends API: YouTube Search Interest over Time as JSON

Add gprop youtube to a Google Trends request to get weekly YouTube search interest for a term, and compare it with web search interest. Minecraft as the example.

November 30, 2026
By SerpBase Team2 min read

Short answer: add "gprop":"youtube" to a POST /google/trends request. Google Trends then measures how often people searched the term on YouTube instead of on Google web search, as a weekly 0–100 series over the past 12 months. The two curves can peak at different times, which matters if you plan video content.

The request

curl -X POST 'https://api.serpbase.dev/google/trends' \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: YOUR_API_KEY' \
  -d '{"q":"minecraft","gprop":"youtube"}'

Leave gprop out to get the normal web search interest. Each Trends request costs 2 credits.

What came back

On 30 November 2026 the answer held one series of 53 weekly points from 30 November 2025 to 29 November 2026 (shortened):

{
  "status": 0,
  "credits_charged": 2,
  "trends": {
    "query": "minecraft",
    "time_range": "today 12-m",
    "series": [{
      "term": "minecraft",
      "points": [
        {"timestamp": "2025-11-30T00:00:00Z", "value": 81},
        {"timestamp": "2025-12-07T00:00:00Z", "value": 89},
        {"timestamp": "2025-12-14T00:00:00Z", "value": 89},
        {"timestamp": "2026-11-29T00:00:00Z", "value": 79, "partial": true}
      ]
    }]
  }
}

The last point carries "partial": true because that week was not over yet.

YouTube interest vs web interest

We sent the same term with and without gprop a minute apart:

YouTube searchWeb search
Peak week (100)5 July 202628 December 2025
Lowest week22 Nov 2026: 7322 Nov 2026: 60
First week (30 Nov 2025)8181

On the web, interest in Minecraft peaked over the winter holidays; on YouTube it peaked in early July, during the summer break. Both curves were scaled to their own peak, so compare their shapes and timing, not the raw numbers across the two.

Find the best month to publish

import requests
from collections import defaultdict

def series(term, gprop=None):
    body = {"q": term}
    if gprop:
        body["gprop"] = gprop
    data = requests.post("https://api.serpbase.dev/google/trends",
                         headers={"X-API-Key": "YOUR_API_KEY"},
                         json=body, timeout=60).json()
    if data["status"] != 0:
        raise RuntimeError(data.get("error"))
    return [p for p in data["trends"]["series"][0]["points"] if not p.get("partial")]

by_month = defaultdict(list)
for p in series("minecraft", "youtube"):
    by_month[p["timestamp"][:7]].append(p["value"])
best = max(by_month, key=lambda m: sum(by_month[m]) / len(by_month[m]))
print("highest average YouTube interest:", best)

Things that trip people up

  • Values are relative. 100 is the busiest week for that term on that property in the window, not a search count.
  • Drop the partial week before you compare the latest value with older ones.
  • Several terms in one request are scaled together; see the compare guide below. A single term is scaled on its own.

Related

The basics of the endpoint: Google Trends API: interest over time. Up to five terms at once: Google Trends compare API. Searching YouTube itself: YouTube search API.

Cost and docs

Trends requests are 2 credits. Credits cost $0.25–$0.50 per 1,000 depending on the plan; new accounts get 500 free credits.