GuidesDATA APIS
Google Trends API from JavaScript
Google has no public Trends API: the official one, announced on 24 July 2025, is still an alpha for selected testers, and pytrends was archived on 17 April 2025. What still answers is the trending searches RSS feed, 10 searches per country with traffic buckets and news links. It sends no CORS header, but through the free https://proxy.cors.dev/ tier (no signup, GET and HEAD, about 600 requests a minute per IP) it returned 200 for all 10 countries we tried on 28 October 2026.
Is there an official Google Trends API?
Google announced the Google Trends API (alpha) on 24 July 2025, saying it "will be available only to a very limited number of testers". On 28 October 2026 developers.google.com/search/apis/trends still read "Get early access to the Google Trends API alpha" and "We're now accepting applications for alpha testers." There is no public sign-up, price or release date.
For accepted testers, Google describes consistently scaled search interest (not absolute search volumes) that can be compared across requests, a rolling window of 1,800 days (about 5 years) up to 2 days ago, daily, weekly, monthly and yearly aggregation, and region and sub-region breakdowns using ISO 3166-2 codes.
Which Google Trends endpoints still answer
Everything else is undocumented: the endpoints behind the Trends website. We called each one on 28 October 2026 with an Origin header of https://example.com, directly and through https://proxy.cors.dev/. None of them sends a CORS header, so a page on your site cannot read them directly.
| Endpoint | What it returns | Direct from a web page | Through cors.dev |
|---|---|---|---|
| trending/rss?geo=US | 10 trending searches with traffic and news links | Blocked, no CORS header | 200, about 21 KB of XML |
| trending/rss, 9 more countries | Same feed for GB, DE, IN, NL, FR, JP, BR, CA, AU | Blocked, no CORS header | 200, 17 to 22 KB each |
| trending/rss?geo=XX | Unknown country code | 400 HTML page | 400, passed through |
| trends/api/autocomplete | Topic suggestions as JSON | Blocked, no CORS header | 200, 416 bytes |
| trends/api/explore | Tokens for interest over time | 429, no CORS header | 429, 3 of 3 attempts |
| trends/api/widgetdata/multiline | Interest over time, needs an explore token | 400 without a token | 400, passed through |
| trends/api/dailytrends | Old daily trends JSON | 404, retired | 404, passed through |
| trends/api/realtimetrends | Old realtime trends JSON | 404, retired | 404, passed through |
| trends/trendingsearches/daily/rss | Old daily RSS feed | 404, retired | 404, passed through |
| Official Google Trends API | Alpha, selected testers only | Not public | No public endpoint |
The endpoints older tutorials use for daily and realtime trends are retired. trends/api/autocomplete/bitcoin still works: it returned topics with mid, title and type, behind a )]}' line you strip before JSON.parse.
Daily trending searches through cors.dev
https://trends.google.com/trending/rss?geo=US lists the 10 searches trending now in one country. At 22:40 UTC on 28 October 2026 the top US item was "wizards vs cavaliers" at 5000+, and the GB feed led with "fourfourtwo" at 100+. Each item has:
title: the searchht:approx_traffic: a bucket such as200+,500+or5000+pubDate: when the trend started, such asWed, 28 Oct 2026 15:00:00 -0700ht:pictureandht:picture_source: a thumbnail and its sourceht:news_item: related articles, each withht:news_item_title,ht:news_item_snippet,ht:news_item_url,ht:news_item_pictureandht:news_item_source
Parse the text with DOMParser and 'text/xml'; getElementsByTagName('ht:approx_traffic') matches the prefixed tags directly. Through the shared proxy Google sometimes answers 429, so this function waits and retries twice:
// Runs in a module script or the DevTools console
const proxy = 'https://proxy.cors.dev/';
async function trendingSearches(geo = 'US', attempts = 3) {
for (let attempt = 1; ; attempt++) {
const response = await fetch(proxy + 'https://trends.google.com/trending/rss?geo=' + geo);
if (response.ok) {
const xml = new DOMParser().parseFromString(await response.text(), 'text/xml');
const text = (node, tag) => node.getElementsByTagName(tag)[0]?.textContent ?? '';
return [...xml.getElementsByTagName('item')].map((item) => ({
query: text(item, 'title'),
traffic: text(item, 'ht:approx_traffic'),
started: new Date(text(item, 'pubDate')),
news: [...item.getElementsByTagName('ht:news_item')].map((news) => ({
title: text(news, 'ht:news_item_title'),
source: text(news, 'ht:news_item_source'),
url: text(news, 'ht:news_item_url'),
})),
}));
}
// Google sometimes answers 429 to the shared proxy: wait, then retry
if (response.status !== 429 || attempt === attempts) throw new Error(`Trends RSS failed: ${response.headers.get('X-Cors-Error') ?? response.status}`);
await new Promise((resolve) => setTimeout(resolve, 2000 * attempt));
}
}
console.table(await trendingSearches('US'));Interest over time and pytrends
Most tutorials for search interest use pytrends, the unofficial Python library. Its owner archived the GitHub repository on 17 April 2025, and the last PyPI release, 4.9.2, dates from 13 April 2023.
pytrends calls the same internal endpoints as the Trends website: trends/api/explore for widget tokens, then trends/api/widgetdata/multiline and similar paths for the data, plus the now retired dailytrends and realtimetrends. On 28 October 2026 explore answered 429 with an HTML error page to 3 of 3 attempts, direct and through cors.dev, and multiline without a token answered 400. There is no keyless way to get interest over time from JavaScript today. Your options:
- Apply for the official alpha.
- Export CSV by hand from the Trends website.
- Use a commercial scraping API.
Limits and which cors.dev tier fits
We sent 30 requests through the proxy (10 countries, 3 rounds, 5 seconds apart): Google answered 429 to 5 of them, and an identical second run got none. A short pause and a retry fixed every one.
- cors.dev free: prefix the URL with
https://proxy.cors.dev/. No signup, no key, GET and HEAD only, about 600 requests a minute per IP, no daily quota, responses up to 6 MiB, no caching. Enough for a dashboard or a prototype. - cors.dev Pro: $5 a month for 500,000 requests, with a 7-day trial of 1,000 requests and no card. 3,000 requests a minute per account and 100 in flight, plus an optional GET cache with
X-Cors-Cache: 60(1 to 300 seconds; cache hits still count as requests) for responses that allow it. The trending RSS does not: Google sends it withno-storeand a cookie, so it is never cached; keep the parsed feed in memory instead. Start the trial.
Good questions.
Does Google Trends have a public API?
No. The official Google Trends API, announced on 24 July 2025, is an alpha for a limited number of testers who apply through developers.google.com. On 28 October 2026 it was still accepting alpha applications, with no public sign-up or price.
Is pytrends still maintained?
No. The GitHub repository was archived by its owner on 17 April 2025 and is read-only, and the last PyPI release, 4.9.2, is from 13 April 2023. The first endpoint it calls, trends/api/explore, answered 429 to every request in our tests.
Why does the Google Trends daily trends endpoint return 404?
Google retired trends/api/dailytrends, trends/api/realtimetrends and the old trends/trendingsearches/daily/rss; all three returned 404 on 28 October 2026. Use https://trends.google.com/trending/rss?geo=US, which returned 10 trending searches.
Can I get Google Trends interest over time in JavaScript?
Not without the official alpha. The website's trends/api/explore endpoint answered 429 to every attempt, direct and through cors.dev, and trends/api/widgetdata/multiline needs a token from it. You can still export CSV by hand from the Trends website.
How do I get trending searches for another country?
Change geo to a two-letter country code, such as geo=GB or geo=IN. All 10 countries we tried returned 17 to 22 KB through cors.dev, and an unknown code such as geo=XX returned 400.
Why do I get 429 errors from Google Trends through a proxy?
Google sometimes answers 429 to requests that arrive through a shared proxy. In our test 5 of 30 requests got 429 and an identical second run got none, so wait a few seconds and retry, and reuse the parsed feed instead of fetching it on every page view.