GA4 MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| GA4_CLIENT_ID | No | OAuth client ID from the Google Cloud Console. | |
| GA4_ACCESS_TOKEN | No | OAuth access token for Google Analytics 4 API authentication. | |
| GA4_CLIENT_SECRET | No | OAuth client secret from the Google Cloud Console. | |
| GA4_REFRESH_TOKEN | No | OAuth refresh token for Google Analytics 4 API authentication. | |
| GA4_SERVICE_ACCOUNT_JSON | No | Google Analytics 4 Service Account credentials provided as a raw JSON string. | |
| GOOGLE_APPLICATION_CREDENTIALS | No | Path to the Google Analytics 4 Service Account JSON credentials 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 | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| ga4_account_summariesA | Retrieves information about the user's Google Analytics accounts and properties. Returns a list of all GA4 accounts and their associated properties that the authenticated user has access to. |
| ga4_property_detailsB | Returns details about a specific GA4 property including its name, display name, time zone, currency, industry category, and other settings. |
| ga4_google_ads_linksA | Returns a list of links to Google Ads accounts for a GA4 property. Shows which Google Ads accounts are connected to the property for data sharing. |
| ga4_property_annotationsB | Returns annotations for a GA4 property. Annotations are notes that mark specific dates or periods, typically used to record events like releases, campaigns, or traffic changes. |
| ga4_run_reportA | Runs a Google Analytics Data API report. Returns analytics data based on the specified dimensions, metrics, and date ranges. Hints for argumentsHints for dimensionsThe dimensions list must consist solely of either:
Hints for metricsThe metrics list must consist solely of either:
Hints for dateRangesExamples:
Hints for dimensionFilterExample: {"filter": {"fieldName": "eventName", "stringFilter": {"matchType": "BEGINS_WITH", "value": "page"}}} Hints for orderBysExample: [{"dimension": {"dimensionName": "eventName"}, "desc": false}] or [{"metric": {"metricName": "eventCount"}, "desc": true}] |
| ga4_run_realtime_reportA | Runs a Google Analytics Data API realtime report. Returns real-time analytics data for the last 30 minutes. Hints for argumentsHints for dimensionsUse realtime dimensions from https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions Or user-scoped custom dimensions (apiName starting with "customUser:") Hints for metricsUse realtime metrics from https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics Note: Realtime reports cannot use custom metrics. |
| ga4_custom_dimensions_metricsA | Retrieves the custom dimensions and metrics defined for a GA4 property. Use this to discover what custom definitions are available before running reports. |
| ga4_validate_gtm_paramsA | GTM에서 보내는 이벤트 파라미터가 GA4에 제대로 수집되는지 검증합니다. 사용 방법방법 1: GTM 이벤트 목록 직접 전달gtmEvents 배열로 이벤트별 파라미터를 전달합니다. 방법 2: GTM Container Export JSON 전달GTM에서 컨테이너를 Export한 JSON 파일 내용을 gtmExportJson으로 전달하면 자동으로 파싱합니다. 검증 항목
API 호출 효율성
|
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/wonyoungseong/ga4-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server