# Google Analytics — MCP server on mcp.ai > Connect your Google Analytics account and use 4 tools for analytics straight from your AI agent. Connect in one click, no API key needed. Google Analytics tracks and reports website traffic, user behavior, and conversion data, enabling marketers to optimize online performance and customer journeys. By: mcp.ai · official Page: https://new.mcp.ai/google_analytics ## Connect (MCP protocol) Remote MCP endpoint (HTTP, streamable): https://api.mcp.ai/p_google_analytics?ms=1796396520000 Add it as a custom/remote MCP connector, then authenticate when prompted. ## Install in your AI client (step by step) Link to paste in any client: https://api.mcp.ai/p_google_analytics ### Claude 1. Copy the Google Analytics link above (Copy button). 2. In Claude, Plugins → Add → Add custom connector: name Google Analytics, paste the link and click Continue. Under Authentication, choose Sign in now and click Add. 3. The first time, Claude opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. Open: https://claude.ai/plugins ### ChatGPT 1. Copy the Google Analytics link above (Copy button). 2. In ChatGPT (web), Plugins → Add → Add custom MCP server: name Google Analytics, paste the link, under Authentication choose OAuth or no authentication, check I understand, click Create as a plugin, then Sign in with Google Analytics. 3. The first time, ChatGPT opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. Open: https://chatgpt.com/plugins ### Cursor 1. Copy the Google Analytics link above (Copy button). 2. In Cursor, Settings → MCP → "Add new MCP server", paste the link and save. 3. The first time, Cursor opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. ### Claude Desktop 1. Copy the Google Analytics link above (Copy button). 2. Added it in Claude? The connector lives in your account and shows up on Desktop. If not, Plugins → Add → Add custom connector, paste the link and choose Sign in now. 3. The first time, Claude opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. ### Manus 1. Copy the Google Analytics link above (Copy button). 2. Paste the link into a Manus chat and ask it to connect the MCP server. 3. The first time, Manus opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. ### Agents 1. Copy the Google Analytics link above (Copy button). 2. Paste the link into your MCP-compatible agent (remote HTTP server). 3. The first time, agent opens the mcp.ai sign-in: sign in with Google or email and click Allow. 4. When Google Analytics needs your account, the AI sends you a link: click Connect Google Analytics and authorize. 5. Done: just ask in the chat. ## REST API (no MCP client required) Every tool is also a REST endpoint, authed with a workspace API key. Discover: GET https://api.mcp.ai/api/google_analytics/_endpoints # public; lists every endpoint Call: POST https://api.mcp.ai/api/google_analytics/ Authorization: Bearer sk_live_… # create one at https://new.mcp.ai/settings/api-keys Content-Type: application/json Body: { …args } → { "ok": true, "tool": "", "result": { … } } ## Developer docs Install guide (prompt + clients + REST), markdown: https://new.mcp.ai/google_analytics/index.md How to use (MCP or REST), markdown: https://new.mcp.ai/google_analytics/skill.md Postman collection (v2.1): https://new.mcp.ai/google_analytics/postman.json ## Tools - google_analytics_check_compatibility(property_id: string, dimensions?: object[], metrics?: object[], dimensionFilter?: object, metricFilter?: object, compatibilityFilter?: string) — Check whether a set of dimensions and metrics can be combined in the same report before running it. Not every pair is valid in GA4. - google_analytics_create_expanded_data_set(parent: string, expandedDataSet: object) — Tool to create an expanded data set for a property. use when you need to combine specific dimensions and metrics into a custom dataset after property creation. - google_analytics_get_account(name: string) — Tool to retrieve a single account by its resource name. use when you need detailed account info after confirming the account resource name (e.g., accounts/100). - google_analytics_get_metadata(property_id: string) — List every dimension and metric this property accepts, including the custom ones. Call this when unsure which names a report can use. - google_analytics_list_accounts(pageSize?: integer, pageToken?: string, showDeleted?: boolean) — Tool to list all accounts accessible by the caller. use when you need to enumerate all google analytics accounts your credentials can access. - google_analytics_list_audiences(parent: string, pageSize?: integer, pageToken?: string) — Tool to list all audiences on a property. use when you need to fetch all audiences for a ga4 property after confirming its existence. - google_analytics_list_key_events(property_id: string, pageSize?: integer, pageToken?: string) — List the property's key events (what GA4 counts as a conversion). Use to learn which event names are worth reporting on. - google_analytics_list_properties(pageSize?: integer, pageToken?: string) — List every Google Analytics account the connected user can see, each with its GA4 properties (id + display name). Start here: every other tool needs a property_id. - google_analytics_run_funnel_report(property_id: string, dateRanges: object[], funnel: object, funnelBreakdown?: object, funnelNextAction?: object, limit?: integer) — Funnel report: how many people advance through each step and where they drop off. Use for 'where are people abandoning the checkout'. - google_analytics_run_pivot_report(property_id: string, dateRanges: object[], dimensions?: object[], metrics: object[], pivots: object[], dimensionFilter?: object) — Cross two or more dimensions in a pivot table (e.g. channel by month). Use when a flat report would need one row per combination. - google_analytics_run_realtime_report(property_id: string, dimensions?: object[], metrics: object[], dimensionFilter?: object, limit?: integer) — Who is on the site right now: realtime report for the last 30 minutes. Use for 'how many people are online', not for historical periods. - google_analytics_run_report(property_id: string, dateRanges: object[], dimensions?: object[], metrics: object[], dimensionFilter?: object, metricFilter?: object, orderBys?: object[], limit?: integer, offset?: integer, keepEmptyRows?: boolean) — Run a Google Analytics report: users, sessions, pageviews, conversions and revenue, broken down by any dimension (date, channel, source, page, country, device). This is the main tool for questions abo ## Example prompts - "What can I do in Google Analytics?" - "Show me a summary of my Google Analytics account" ## Links Docs: https://mcp.ai/docs/mcps/google_analytics Website: https://mcp.ai/mcps/google_analytics