Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.gumloop.com/llms.txt

Use this file to discover all available pages before exploring further.

Google Analytics 4 is Google’s web and app analytics platform. The Google Analytics MCP server lets you run reports, manage accounts and properties, configure custom dimensions, metrics, and conversions, and send server-side events using natural language.

What Can It Do?

  • Run reports for users, sessions, pageviews, and other metrics, including real-time data
  • Check report compatibility to see which dimensions and metrics can be combined
  • Manage accounts and properties including create, update, delete, and data retention settings
  • Configure data streams for web, iOS, and Android
  • Manage custom dimensions, metrics, and conversion (key) events
  • Link Google Ads and Firebase projects to your GA4 properties
  • Export and download audiences for downstream activation
  • Send server-side events via the Measurement Protocol with auto-fetched API secrets

Where to Use It

Add Google Analytics as a tool to any agent. The agent can then explore your analytics data and configuration conversationally, choosing the right actions based on context. To add an MCP tool to your agent:
  1. Open your agent’s configuration
  2. Click Add toolsConnect an app with MCP
  3. Search for the integration and select it
  4. Authenticate with your Google account
You can control which tools your agent has access to. After adding an integration, click on it to enable or disable specific tools based on what your agent needs.

In Workflows (Via Agent Node)

For automated pipelines, use an Agent Node with Google Analytics tools. This gives you the flexibility of an agent within a deterministic workflow.

As a Custom MCP Node

You can also create a standalone MCP node for a specific action. This generates a reusable node that performs one task, useful when you need the same operation repeatedly in workflows.
To create a custom MCP node:
  1. Go to your node library and search for the integration
  2. Click Create a node with AI
  3. Describe the specific action you want (e.g., “Run a 30-day report of users by country”)
  4. Test the node and save it for reuse
Custom MCP nodes are single-purpose by design. For tasks that require multiple steps or dynamic decision-making, use an agent instead.

Available Tools

Reporting

ToolDescription
Run ReportRun 1-5 GA4 reports and get back users, sessions, pageviews, and other metrics
Run Realtime ReportGet real-time GA4 data for events in the last 30 minutes
Check CompatibilityCheck which dimensions and metrics can be combined in a report
Get MetadataList all dimensions and metrics available for reports on a property
Run Access ReportSee who accessed a GA4 account or property’s data and when

Audiences

ToolDescription
Create Audience ExportStart an export of users in a GA4 audience
List Audience ExportsList audience exports for a GA4 property
Get Audience ExportCheck the status of a GA4 audience export
Query Audience ExportDownload the users from a completed GA4 audience export

Accounts

ToolDescription
List Account SummariesList your GA4 accounts along with the websites and apps tracked in each
List AccountsList your GA4 accounts
Get AccountGet details of a GA4 account
Update AccountRename a GA4 account or change its region
Delete AccountMove a GA4 account to the trash
Get Account Data Sharing SettingsSee how a GA4 account shares data with Google products and support
Search Account Change History EventsSee recent changes made in a GA4 account (who edited what)

Properties

ToolDescription
List PropertiesList the websites and apps (properties) tracked in a GA4 account
Get PropertyGet details of a GA4 property
Create PropertyCreate a new GA4 property to track a website or app
Update PropertyUpdate a GA4 property’s name, timezone, currency, or industry
Delete PropertyMove a GA4 property to the trash
Acknowledge User Data CollectionConfirm Google’s user-data-collection terms for a GA4 property
Get Data Retention SettingsSee how long a GA4 property keeps user and event data
Update Data Retention SettingsChange how long a GA4 property keeps user and event data

Data Streams

ToolDescription
List Data StreamsList the web, iOS, and Android data streams for a GA4 property
Get Data StreamGet details of a GA4 data stream
Create Data StreamAdd a new website, iOS app, or Android app data stream to a property
Update Data StreamUpdate a GA4 data stream’s name or settings
Delete Data StreamDelete a GA4 data stream

Custom Dimensions & Metrics

ToolDescription
List Custom DimensionsList the custom dimensions defined on a GA4 property
Get Custom DimensionGet details of a GA4 custom dimension
Create Custom DimensionCreate a custom dimension that captures an event parameter or user property
Update Custom DimensionUpdate or archive a GA4 custom dimension
List Custom MetricsList the custom metrics defined on a GA4 property
Get Custom MetricGet details of a GA4 custom metric
Create Custom MetricCreate a custom metric from a numeric event parameter (currency, duration, etc.)
Update Custom MetricUpdate or archive a GA4 custom metric

Conversions (Key Events)

ToolDescription
List Key EventsList the conversion events set up on a GA4 property
Get Key EventGet details of a GA4 conversion event
Create Key EventMark an event as a conversion in GA4
Update Key EventUpdate how a GA4 conversion is counted or its default value
Delete Key EventRemove a conversion from GA4
ToolDescription
List Google Ads LinksList the Google Ads accounts linked to a GA4 property
Create Google Ads LinkLink a Google Ads account to a GA4 property
Update Google Ads LinkChange the ads-personalization setting on a Google Ads link
Delete Google Ads LinkUnlink a Google Ads account from a GA4 property
List Firebase LinksList the Firebase projects linked to a GA4 property
Create Firebase LinkLink a Firebase project to a GA4 property
Delete Firebase LinkUnlink a Firebase project from a GA4 property

Measurement Protocol

ToolDescription
Measurement Protocol EventSend, validate, or send-and-validate a server-side event to GA4 via Measurement Protocol. Auto-fetches the API secret (creates one if none exist) and stream identifiers using OAuth

Example Prompts

Use these with your agent or in the Agent Node: Run a report:
Show me total users and sessions for example.com over the last 30 days, broken down by country
Real-time monitoring:
How many active users are on my site right now and what pages are they viewing?
Check compatibility:
Can I combine the "sessionDefaultChannelGroup" dimension with the "totalRevenue" metric in a report?
Inspect a property:
List all properties in my Marketing GA4 account and show me each property's data retention settings
Manage custom dimensions:
Create a custom dimension on the example.com property that captures the "plan_tier" user property
Manage conversions:
List all conversion events on the example.com property and mark "signup_completed" as a conversion
Audience export:
Start an audience export for the "Engaged Users" audience on example.com, then download the users once it's ready
Send a server-side event:
Send a "purchase" event with value=49.99 and currency=USD to GA4 for client_id 12345 via Measurement Protocol

Troubleshooting

IssueSolution
Authentication failedVerify your Google account has access to the GA4 property you’re querying
Property not foundUse the property’s numeric ID (e.g., properties/123456789) when prompting
Real-time report emptyReal-time data only covers the last 30 minutes. Try Run Report for historical data
Measurement Protocol event not appearingUse the validate mode first to confirm the event payload is well-formed before sending
Permission denied on update or deleteThese tools require analytics edit access; confirm your Google account has the right role on the property
Tool not availableVerify the tool is enabled in your agent’s MCP configuration
Unexpected resultsThe agent may chain multiple tools (e.g., listing accounts first, then properties, then running a report). Review the agent’s reasoning to understand its approach.
Agents are smart enough to chain multiple API calls together. For example, asking “What were my top 10 pages last week on example.com?” will look up the property ID first, then run the report. If results seem off, check the agent’s step-by-step reasoning.

Need Help?


Use this integration directly in Claude or Cursor. Connect remotely via the Google Analytics MCP server using your Gumloop credentials.