Google Trends MCP

Google Trends MCP

Enables querying Google Trends data directly from conversational MCP clients, including search interest over time, related queries and topics, regional breakdowns, and trending searches, for market research without leaving the chat.

Category
访问服务器

README

Google Trends MCP

A local MCP server that lets Claude (or any MCP client) query Google Trends directly — search interest over time, related queries and topics, regional breakdowns, and real-time trending searches — so you can do market research inside a conversation instead of tab-switching to trends.google.com and pasting screenshots back in.

Built for personal/self-use market research. No API key required — Google Trends has no official public API, so this wraps pytrends, the standard unofficial Python client, in an MCP server.

Tools

All tools default geo="IN" (India) unless noted — pass geo="" for worldwide, or any ISO country code ("US", "GB", etc.). timeframe accepts pytrends' format, e.g. "today 12-m", "today 5-y", "now 7-d", or an explicit range "2024-01-01 2024-06-01".

interest_over_time(keywords, timeframe="today 12-m", geo="IN")

Relative search interest (0–100) over time for up to 5 keywords, compared side by side. Keywords beyond the first 5 are silently dropped. Each record includes isPartial — true on the most recent data point means that period isn't finished yet and its value is provisional; don't read a dip on that point as a real trend change.

related_queries(keyword, timeframe="today 12-m", geo="IN")

Top and rising related search queries for a single keyword. Returns {"top": [...], "rising": [...]}, each a list of {"query": ..., "value": ...} records. top values are 0–100 relative interest. rising values are percent increase — except a value of 5000%, which is Google's "Breakout" marker for explosive growth from a near-zero baseline, not a literal percentage.

related_topics(keyword, timeframe="today 12-m", geo="IN")

Same as related_queries, but topic clusters (Google's own topic groupings) instead of raw query strings — records have topic_title and topic_type alongside value. Same Breakout convention applies to rising.

interest_by_region(keyword, timeframe="today 12-m", geo="IN")

Search interest for a keyword broken down by state/region within the given geo. Returns a list of {"geoName": ..., "<keyword>": 0-100} records, one per region.

trending_now(geo="india")

Today's top trending searches for a country. Note the geo format is different here — it's a full lowercase country name ("india", "united_states"), not an ISO code like the other four tools. This is a real inconsistency in Google's own endpoints, not a bug.

Known limitation: as of this writing, trending_now fails with an HTTP 404. Google appears to have retired the legacy endpoint (hottrends/dailytrends/realtimetrends) that pytrends' trending-search methods depend on — confirmed by testing all three variants pytrends offers. This is an upstream issue, not fixable in this codebase; it fails cleanly with a readable error string rather than crashing. The other 4 tools use a different, still-functional endpoint family and are unaffected. If Google restores the endpoint or pytrends patches around it, this will start working again with no changes needed here.

All tools catch failures (rate limits, network errors, the above) and return a plain error string instead of crashing — Google Trends is a scraped endpoint, not a stable API, so this is expected behavior, not exceptional.

Setup

Requires Python 3.10+ and uv.

git clone https://github.com/jain-eshan/google-trends-mcp.git
cd google-trends-mcp
uv sync

Register with Claude Code

claude mcp add google-trends -- uv run --directory /absolute/path/to/google-trends-mcp server.py

Verify it connected:

claude mcp list

You should see google-trends listed as ✔ Connected. Start a new Claude Code conversation after registering — sessions already running won't pick up a newly added server.

Usage

Once registered, just ask Claude to use it — e.g.:

"Use the google-trends MCP to compare interest in 'lab grown diamonds' vs 'diamond jewellery' in India over the last 12 months, and show me related queries."

Optional: /trends skill

This repo includes a Claude Code skill at .claude/skills/trends/SKILL.md that wraps the raw tools into a research-and-synthesize workflow — it decides which tools are relevant to your topic and writes up a plain-language summary instead of dumping raw JSON. If you're using Claude Code, this skill is picked up automatically from this repo; just run:

/trends <your topic>

Design notes

  • Data only, no synthesis in the server. Every tool returns raw, structured data — the interpretation (is this trend real, what does a Breakout marker mean here, what's worth flagging) happens in the calling conversation, not baked into the server. This keeps the server simple and lets whatever's calling it (Claude, another MCP client) apply its own judgment.
  • No dependencies beyond mcp[cli] and pytrends. No database, no config file, no API key.
  • No formal test suite. This wraps a scraped third-party endpoint; a test suite would mostly be testing pytrends and Google's current response shape, not this code. Each tool was verified against live Google Trends data during development instead.

License

MIT — see LICENSE.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选