Google Analytics 4 MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| GA_CREDENTIALS | No | Service Account JSON key content (copy-paste the entire JSON) | |
| GA_CREDENTIALS_PATH | No | Alternative: path to the JSON key file | ~/.google-analytics-4-mcp/credentials.json |
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 |
|---|---|
| check_auth_statusA | Check if the Google Analytics service account is configured and valid. |
| list_accountsA | List all Google Analytics accounts accessible by the authenticated user. |
| list_propertiesC | List all GA4 properties for an account. |
| create_propertyC | Create a new GA4 property. |
| get_propertyC | Get details of a GA4 property. |
| delete_propertyA | Soft-delete a GA4 property (can be restored within 35 days). |
| list_data_streamsB | List all data streams for a GA4 property. |
| create_web_data_streamC | Create a web data stream and get the Measurement ID (G-XXXXX). |
| delete_data_streamC | Delete a data stream. |
| get_tracking_snippetB | Generate the gtag.js HTML tracking snippet ready to paste into your website. |
| list_key_eventsC | List key events (conversions) configured for a property. |
| create_key_eventC | Mark an event as a key event (conversion). |
| delete_key_eventC | Remove an event from key events (conversions). |
| list_custom_dimensionsC | List custom dimensions for a property. |
| create_custom_dimensionC | Create a custom dimension. |
| list_custom_metricsC | List custom metrics for a property. |
| create_custom_metricC | Create a custom metric. |
| list_google_ads_linksC | List Google Ads links for a property. |
| create_google_ads_linkC | Link a Google Ads account to a GA4 property. |
| get_measurement_protocol_secretC | Get or create a Measurement Protocol API secret for server-side event tracking. |
| run_reportC | Run a GA4 report with dimensions, metrics, date range, and optional filters. |
| run_realtime_reportC | Run a real-time report showing active users and live events. |
| get_metadataA | List all available dimensions and metrics for a GA4 property. Useful to discover which dimension/metric names you can use in run_report. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 23 tools
Each tool targets a distinct resource or action: accounts, properties, data streams, custom dimensions/metrics, key events, Google Ads links, reports, metadata, auth, snippet. No two tools have overlapping purposes; even similar pairs like create/delete are clearly differentiated.
All tools use a consistent verb_noun pattern with underscores, e.g., 'create_custom_dimension', 'run_realtime_report', 'list_properties'. No mixing of styles or unclear verb choices.
23 tools cover a wide range of GA4 management tasks. While slightly on the higher side, each tool serves a specific need without redundancy, making the count reasonable for comprehensive server scope.
Covers core CRUD and reporting but lacks update operations for custom dimensions/metrics, properties, and key events. Missing some advanced features (e.g., user management, filters), limiting full lifecycle coverage.