Google Analytics MCP
Google Analytics MCP is an MCP server that adds data and analytics tools to AI assistants such as Claude Desktop, Claude Code and Cursor. GA4 MCP server for AI agents: schema discovery, server-side aggregation, analysis-ready defaults. It has 242 GitHub stars, is released under the MIT license and runs locally with uvx google-analytics-mcp.
github.com/surendranb/google-analytics-mcp (opens in a new tab)
- Needs API key
- Data & analytics
- MIT
- Actively maintained
Install Google Analytics MCP
Generated from the server's MCP registry entry. Replace your-value with your own values.
Claude Desktop
{
"mcpServers": {
"google-analytics-mcp": {
"command": "uvx",
"args": [
"google-analytics-mcp"
],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "your-value",
"GA4_PROPERTY_ID": "your-value"
}
}
}
}Settings > Developer > Edit Config. macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\. Restart Claude Desktop afterwards.
Claude Code
claude mcp add --env GOOGLE_APPLICATION_CREDENTIALS=your-value --env GA4_PROPERTY_ID=your-value --transport stdio google-analytics-mcp -- uvx google-analytics-mcpCursor
{
"mcpServers": {
"google-analytics-mcp": {
"type": "stdio",
"command": "uvx",
"args": [
"google-analytics-mcp"
],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "your-value",
"GA4_PROPERTY_ID": "your-value"
}
}
}
}Project file; use ~/.cursor/mcp.json to enable it in every project.
VS Code
{
"inputs": [
{
"type": "promptString",
"id": "google_application_credentials",
"description": "GOOGLE_APPLICATION_CREDENTIALS",
"password": true
}
],
"servers": {
"google-analytics-mcp": {
"type": "stdio",
"command": "uvx",
"args": [
"google-analytics-mcp"
],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "${input:google_application_credentials}",
"GA4_PROPERTY_ID": "your-value"
}
}
}
}Config formats checked against the official docs on Oct 7, 2026: modelcontextprotocol.io (opens in a new tab), code.claude.com (opens in a new tab), cursor.com (opens in a new tab), code.visualstudio.com (opens in a new tab).
Environment variables
Variables the server reads at startup.
| Name | Required | Description |
|---|---|---|
GOOGLE_APPLICATION_CREDENTIALSsecret | Yes | Absolute path to your Google Cloud service account JSON key with GA4 property access. |
GA4_PROPERTY_ID | Yes | Numeric GA4 Property ID to query, for example 123456789. |
About Google Analytics MCP
Model Context Protocol (MCP) server for Google Analytics 4: real-time query exploration, schema discovery, metric aggregation, and audience insights for AI agents.
- ai-agent
- analytics
- claude-mcp
- ga4
- gemini-extension
- google-analytics
- mcp-server
- model-context-protocol
- ai-agents
- claude
Similar MCP servers
More data & analytics MCP servers
Ida Pro MCP
mrexodia/ida-pro-mcp
AI-powered reverse engineering assistant that bridges IDA Pro with language models through MCP.
Data & analyticsPythonAsk Jev
pollinations/pollinations
Evaluate state with typed choice, score, and probability questions.
Data & analyticsTypeScriptJitsu
jitsucom/jitsu
Manage Jitsu data pipelines: destinations, streams, connections, functions, live events.
OfficialData & analyticsTypeScriptGoogle Ads + Meta Ads + SEO/GEO MCP
irinabuht12-oss/google-ads-meta-ads-mcp
Google Ads, Meta Ads, SEO, GEO & GA4 MCP by Ryze AI - audits, reports, keywords, Search Console.
Data & analyticsBlitz
blitzdotdev/blitz-mac
Give AI agents full control over iOS/macOS development via a native macOS app with 30+ MCP tools.
Data & analyticsSwiftChunkhound
chunkhound/chunkhound
Your entire engineering context, deeply understood.
OfficialData & analyticsPython
What is Google Analytics MCP?
Google Analytics MCP is an MCP server that adds data and analytics tools to AI assistants such as Claude Desktop, Claude Code and Cursor. GA4 MCP server for AI agents: schema discovery, server-side aggregation, analysis-ready defaults. It has 242 GitHub stars, is released under the MIT license and runs locally with uvx google-analytics-mcp. The source code is at github.com/surendranb/google-analytics-mcp.
How do I install the Google Analytics MCP MCP server?
Add the command uvx google-analytics-mcp to your MCP client: put it in claude_desktop_config.json for Claude Desktop, run claude mcp add for Claude Code, or add it to .cursor/mcp.json (Cursor) or .vscode/mcp.json (VS Code). The snippets on this page are ready to paste.
Is Google Analytics MCP free?
The server is open source under the MIT license, so running it is free. It needs credentials (GOOGLE_APPLICATION_CREDENTIALS) for the service it connects to, which may require a paid account.
Is Google Analytics MCP actively maintained?
The most recent commit was on Oct 3, 2026. The latest release is v2.11.3, published Aug 18, 2026. appsgit only lists MCP servers with a commit in the last six months and re-checks every server daily.