GA4 MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| GA4_PROPERTY_ID | No | Default GA4 property ID (optional, can also pass per-tool) | |
| GA4_CREDENTIALS_PATH | Yes | Path to service account JSON key file |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| ga4_list_propertiesA | List all GA4 properties accessible by the service account. Returns property IDs and display names. |
| ga4_get_reportA | Run a custom GA4 report with any combination of dimensions and metrics. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. dimensions: Comma-separated dimension names (e.g., "date", "sessionSource,sessionMedium", "pagePath", "country", "deviceCategory"). Default: "date". metrics: Comma-separated metric names (e.g., "sessions,totalUsers,screenPageViews", "bounceRate,averageSessionDuration,conversions"). Default: "sessions,totalUsers,screenPageViews". days: Lookback period in days (default: 28). row_limit: Max rows to return (default: 20, max: 100). |
| ga4_get_top_pagesA | Get top pages by sessions. Shows page path, sessions, users, pageviews, bounce rate, and average session duration. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. days: Lookback period in days (default: 28). row_limit: Max rows to return (default: 20). |
| ga4_get_traffic_sourcesA | Get traffic sources breakdown by source/medium. Shows sessions, users, bounce rate, and conversions per traffic source. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. days: Lookback period in days (default: 28). row_limit: Max rows to return (default: 20). |
| ga4_get_conversionsA | Get conversion events and their counts. Shows which events are firing and how often, broken down by event name. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. days: Lookback period in days (default: 28). row_limit: Max rows to return (default: 20). |
| ga4_get_realtimeA | Get realtime active users and current events on the site. Shows what's happening RIGHT NOW — active users, top pages, traffic sources. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. |
| ga4_compare_periodsA | Compare current period vs previous period for key metrics. Shows absolute values and percentage change for each metric. Args: property_id: GA4 property ID (numeric). Leave empty to use GA4_PROPERTY_ID env var. metrics: Comma-separated metrics to compare (default: sessions, users, pageviews, bounce rate, avg session duration, conversions). days: Period length in days (default: 28). Compares last N days vs the N days before that. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/luminarylane/ga4-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server