Google Analytics MCP Server

Access Google Analytics 4 data with natural language queries and real-time reporting

⚡ Quick Install with Claude Code MCP Guide

Connect Claude Code to any remote MCP server with one simple command. Choose between direct HTTP connections or a universal bridge - all configured automatically with our setup wizard.

Get the Claude Code MCP Setup Guide →

🔌 Test MCP Server Connection

Test your connection to the MCP wrapper server using your x-api-key. This validates that your MCP server credentials are configured correctly.

🚀 Test Full Google Analytics Connection

Test both your MCP server connection AND your Google Analytics platform credentials. This ensures your complete setup is working correctly.

📡 API Endpoint & Required Headers

POST https://googleanalytics.mcp.majewscy.tech

Required HTTP Headers:

Content-Type: application/json
x-api-key: Your MCP server API key
x-google-credentials: Your Google Analytics credentials

🛠️ Available Tools

run_report
Execute a custom analytics report
get_realtime
Get real-time user activity data
list_properties
List accessible GA4 properties
get_metrics
Retrieve specific metrics for a date range
get_dimensions
Get dimension breakdowns for analysis
export_data
Export analytics data in various formats

⚠️ Common Errors & Solutions

401 Unauthorized
Invalid service account credentials
Solution: Check your base64 encoded service account JSON
403 Forbidden
No access to property
Solution: Grant service account access in GA4 property settings
400 Bad Request
Invalid report configuration
Solution: Verify metric and dimension names are valid
429 Rate Limited
API quota exceeded
Solution: Reduce request frequency or wait for quota reset

🏥 Service Health Check

Checking...
Response Time
-
Server Status
-
Protocol Version
2024-11-05
Last Checked
-

Configuration

// Claude Desktop: ~/Library/Application Support/Claude/claude_desktop_config.json (macOS)
// Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "googleanalytics": {
      "command": "npx",
      "args": [
        "-y",
        "@googleanalytics/mcp-server@latest"
      ],
      "env": {
        "GOOGLE_CREDENTIALS": "YOUR_GOOGLE ANALYTICS_TOKEN"
      }
    }
  }
}

Features

Enterprise-grade Google Analytics integration for AI assistants

📊

Real-time Analytics

Access live data streams showing current user activity.

🎯

Custom Reports

Build complex multi-dimensional reports with natural language.

🔐

Secure Auth

Service account authentication with encrypted credentials.

High Performance

Persistent sessions with connection pooling and caching.

🔄

MCP Protocol v2024-11-05

Full compatibility with latest MCP specification.

🌐

Multi-Property

Manage multiple GA4 properties from a single connection.

📋 MCP Server Updates Changelog

Loading... Checking for updates...
  • Fetching latest changes...