Analytics
November 25, 2026

How to connect Claude to Google Analytics (GA4): step by step with use cases

Fran Sánchez
Head of Marketing at Reporting Ninja
How to connect Claude to Google Analytics (GA4): step by step with use cases

Key takeaways

  • You connect Claude to Google Analytics 4 (GA4) through MCP (Model Context Protocol), which lets Claude read your GA4 data and answer questions in chat.
  • There are four main methods: Google’s official Google Analytics MCP server, a no-code MCP connector like Reporting Ninja, a custom build with the API and Claude Code, and manual exports.
  • Google’s server is free to install but needs Python, a Google Cloud project, and credentials, so it suits technical users. A no-code connector takes minutes to add and suits marketers who want GA4 next to their other marketing data.
  • Once connected, you can ask about traffic, channels, landing pages, and key events, compare periods, and draft monthly report summaries.
  • Every connection method needs a Google account with at least Viewer access to the GA4 property.

Most marketers who use Claude still export GA4 reports and paste them into the chat. Each new question means another export, and the pasted numbers are out of date by the next day.

To connect Claude to Google Analytics, you can use MCP (Model Context Protocol). MCP is an open standard that gives an AI assistant controlled access to a data source, so Claude can read your GA4 data and answer questions in chat.

This guide covers the connection methods, a setup walkthrough, example prompts, and fixes for common problems.

What you can do once Claude is connected to GA4

Once Claude can read your GA4 property, you can ask questions in plain language and get answers from current data. The Google Analytics MCP server page gives sample questions such as how many users visited yesterday and which products sold best.

A connected Claude handles four marketing jobs well:

  • Plain-language questions: Ask which channels brought the most engaged sessions last month, or which landing pages lost traffic. Claude picks the metrics and dimensions and runs the report.
  • Summaries and unusual changes: Ask Claude to summarize the week and point out spikes or drops. Reporting Ninja’s connector also has a guided anomaly sweep that separates real changes from missing data.
  • Monthly report drafts: Ask for a five-bullet summary of the month, then edit it into a client or management report.
  • Period comparisons: Compare this month with last month, or this year with last year, without building an exploration in GA4.

The connection handles the data collection, but you still decide what the numbers mean. That judgment is the core of marketing intelligence, and it is where your time goes once the exports stop.

Did you know? In DemandScience’s 2026 survey of 750 senior marketing leaders, 78% said they spend 21% or more of their time on manual work such as data cleanup and system reconciliation. A direct GA4 connection with Claude removes one part of that work, which is exporting and pasting reports.

What you need before you connect Claude to GA4

Before you start, check your GA4 access, your Claude plan, and, for technical methods, your Google Cloud setup. Every method reads only the Google Analytics 4 properties your Google account can access.

Requirement Why it matters Needed for
GA4 access with at least the Viewer role Claude can only read properties your Google account can see All methods
A Claude plan with connectors Connectors are included on every Claude plan, Free included Methods 1, 2, and 3
Claude Desktop or Claude Code Google’s server runs on your own computer Method 1
A Google Cloud project with the Google Analytics Admin API and Data API turned on Google’s server and custom builds call these APIs Methods 1 and 3
Python 3.10 or higher, plus pipx or uv Google’s server is a Python package Method 1
A Reporting Ninja owner or admin login Only account owners and admins can connect an AI assistant Method 2
Note: As of November 2026, Claude Code is included on paid Claude plans only. The Free plan includes connectors, so it works with hosted connectors such as the no-code MCP connector.

How to connect Claude to Google Analytics

There are four ways to connect Claude to GA4. They each have different setup effort, cost, and Claude visibility into GA4 and other marketing channels.

# Method Best for No-code? GA4 only or cross-channel Cost Setup effort
1 Official Google Analytics MCP server Analysts and developers who use Google Cloud No GA4 only Free to install from GitHub High
2 No-code MCP connector (Reporting Ninja) Marketers and agencies Yes Cross-channel Included in plans from $20 a month, billed annually Low
3 API or Claude Code Teams with a developer No Whatever you build Developer time, plus a paid Claude plan for Claude Code High
4 Export to Sheets or Looker Studio, then upload One-off questions Yes Whatever you export Free Low each time, repeated for every question
Red flag: Any connection to GA4 gives a tool access to your data. Grant the lowest access level that works, such as Viewer, and connect only tools whose makers explain how they handle your data.

Method 1: Official Google Analytics MCP server

Google publishes its own Google Analytics MCP server, with the code on GitHub. It is read-only, so it can’t create, change, or delete anything in your GA4 configuration, according to Google.

The server can list your accounts and properties, read custom dimensions and metrics, and run standard, realtime, funnel, and conversions reports. That range covers most GA4 questions a marketer asks.

To set it up, install Python 3.10 or higher, then turn on the Admin API and Data API in a Google Cloud project. After that, you sign in with the read-only Analytics scope through the gcloud tool, and you add the server to Claude Desktop’s config file or register it in Claude Code.

Strengths: It comes from Google, costs nothing to install, and supports funnel and realtime reports.

Limitations: It covers GA4 only, runs on your own computer, and needs technical setup and credential upkeep.

Choose this if you are comfortable with the command line and only need GA4 data in Claude.

Method 2: A no-code MCP connector (e.g., Reporting Ninja)

A no-code connector is a hosted service that handles the GA4 connection for you. Reporting Ninja is a marketing reporting platform with an AI connector (MCP), with no affiliation to Google or Anthropic.

To set it up for free, you can sign up for a free 15-day trial of Reporting Ninja (no credit card required).

After you’ve signed up, connect GA4 once in Reporting Ninja, then add the connector to Claude and sign in. Claude can then read GA4 alongside your other Reporting Ninja integrations, such as Google Ads, Meta Ads, and Search Console, and more, in one chat.

The same connector works with ChatGPT and other MCP clients.

Add custom connector dialog in Claude with the Reporting Ninja MCP URL

Strengths: It needs no code, works on every Claude plan including Free, covers many channels, and is read-only by default.

Limitations: It needs a Reporting Ninja subscription after the 15-day free trial, and each plan sets a limit on how many accounts you connect per data source.

Choose this if you are a marketer or agency that wants GA4 next to your ad and social data without technical setup.

Method 3: API or Claude Code (for developers)

Developers can write their own code against the Google Analytics Data API, or ask Claude Code to write and run the scripts. Claude Code can also register MCP servers, including Google’s, with one terminal command.

A reporting platform’s API is another route. Reporting Ninja’s REST API returns data from GA4 and your other connected sources with one key, so a script doesn’t need a separate login for each platform.

Reporting Ninja REST API request creating a cross-platform report

Strengths: You control every query and can build custom workflows.

Limitations: It takes developer time, and you have to manage API quotas and keep the code working as the APIs change.

Choose this if you have a developer and need automation that goes beyond questions in chat.

Method 4: Export to Sheets or Looker Studio, then upload to Claude

The manual route is to export a GA4 report as a CSV file, or pull it into Google Sheets or Looker Studio, and then upload the file to Claude. Google offers a Report Builder add-on for Sheets, and our Data Studio connectors also pull GA4 numbers into Looker Studio.

Reporting Ninja Google Sheets add-on pulling Google Ads, Meta Ads, and Microsoft Advertising data

Strengths: It doesn’t need any setup and costs nothing.

Limitations: You repeat the export for every new question, and Claude only sees the snapshot you uploaded.

Choose this if you have one question and don’t plan to ask another one soon.

Steps to connect Claude to GA4 with an MCP connector

These steps use Reporting Ninja’s connector as the example, but other no-code connectors follow a similar process.

Note: Our Claude connection guide shows the current screens, which can change over time.

Step 1: Connect and authorize your GA4 property

Sign in to Reporting Ninja and add Google Analytics 4 as a data source. When asked, sign in with the Google account that can see your property.

You only connect GA4 once, and afterwards, every report, dashboard, and assistant uses that connection. If you want Claude to compare site results with ad spend, connect your ad accounts at the same time.

Quick tip: Connect with a Google account that has at least Viewer access to the property. If that account can’t see the property, Claude has no data to read.

Step 2: Check who can connect and what Claude can do

Only an account owner or admin can connect an AI assistant to Reporting Ninja. The connector is included in every plan and starts read-only, so Claude can query and analyze your data but can’t edit anything.

To let Claude build reports too, the account owner turns on write access in the AI connector (MCP) tab. Claude then creates ordinary reports in our report builder, which turns a chat request into automated marketing reports.

AI connector (MCP) settings in Reporting Ninja with the write access option

Claude asks for your confirmation before anything is deleted, scheduled, or shared with a client. The write access never extends to GA4 itself, so your Google Analytics settings stay untouched.

Step 3: Add the connector in Claude

In Claude, open Reporting Ninja in the connector directory and click Connect. Sign in with your Reporting Ninja email and password as the account owner or an admin.

You can also add a custom connector with the URL https://mcp.reportingninja.com/mcp. On Claude Team and Enterprise plans, an organization owner enables the connector for everyone first.

In Claude Code, run claude mcp add --transport http reporting-ninja https://mcp.reportingninja.com/mcp, then type /mcp to sign in.

Terminal adding the Reporting Ninja MCP server to Claude Code
Note: Agencies can connect many GA4 properties in one Reporting Ninja account and ask about each client by name in the same chat. Each of our pricing plans sets the number of accounts per data source, from 10 on Starter to 150 on Large.

Step 4: Ask Claude your first GA4 question

Open a new chat in Claude, click + > Connectors, and turn on Reporting Ninja. Start with a question you can verify the answer to, such as “List my connected Google Analytics 4 properties” or “How many sessions did [property] get last month?”

Compare the answer with the same report in GA4. If the numbers match, you can trust Claude’s answers and move on to comparisons and summaries, such as GA4 key events next to Google Ads and Meta Ads spend. Our cross-platform reporting widgets also show you this side-by-side view.

Turning on the Reporting Ninja connector in a Claude chat

Try it on one client first. Connect their GA4 property, add the connector to Claude, and ask your first question. Start your free 15-day trial.

Example prompts to ask Claude about your GA4 data

Paste these prompts into Claude once it is connected to GA4. Replace the text in square brackets with your property, dates, and goals.

Traffic

Summarize last month's GA4 traffic compared with the month before, and flag anything unusual. Name the metrics and date ranges you used.
Which 10 landing pages lost the most sessions this month compared with last month? Show the change for each page as a number and a percentage.

Key events (conversions)

Which channels drove the most key events last quarter, and what was the key event rate for each channel?
Show the funnel from [step 1] to [step 2] to [purchase] for the last 30 days, and tell me where most users drop off.

Content

Which blog posts had the highest average engagement time last month, among pages with at least [100] sessions?
Which pages brought the most new users from organic search this quarter?

Acquisition

Compare sessions and key events by default channel group for this year against the same period last year.
Which source and medium combinations brought the most engaged sessions this month, and which ones fell compared with last month?

Monthly report drafting

Draft a five-bullet executive summary of this month's website performance for [audience]. End with one recommended next step, and name the metric behind each bullet.
Write two sentences that explain the biggest traffic change this month to a client who isn't technical.

Best practices and common issues (troubleshooting)

Most connection problems come from issues around access, credentials, or the way GA4 processes data, and each one has a direct fix. The fixes for Method 1 come from Google’s troubleshooting list.

Issue Why it happens Fix
Claude sees no properties The connected Google account has no access to the property Give the account at least the Viewer role, then reconnect
403 PERMISSION_DENIED or ACCESS_NOT_CONFIGURED (Method 1) The APIs are off, or there is no quota project Turn on the Admin API and Data API, and set your Google Cloud project ID
The server doesn’t appear in Claude Desktop (Method 1) The app can’t find pipx or uvx, or it wasn’t fully restarted Use the full path to pipx or uvx, then quit and reopen the app
401 or expired credentials Your sign-in has expired Sign in again with gcloud, or reconnect the connector
Numbers don’t match the GA4 interface Sampling, thresholding, or a different date range, dimension, or filter Use the same date range, dimensions, and filters as the GA4 report
429 errors The Data API quota for the property has run out Use shorter date ranges and fewer dimensions, then wait for the quota to reset
Answers that look right but aren’t Claude misreads a field or a date range Check key figures in GA4 before you use them

Small differences from the GA4 interface are normal. Google’s reporting data expectations page explains that the Data API can return sampled data and may hide rows with very few users. Very recent data can also change while GA4 finishes processing it.

Local servers bring their own setup problems. Currently, MCP servers only load on cold start,  so you have to quit Claude Desktop fully after you change its config.

You can avoid this step with hosted connectors, since Claude reaches them over the web. Automated reporting software removes the overhead of maintaining connections and also eliminates the manual marketing data integration work of merging GA4 with your other sources.

{{cta-block-v1}}

Connect Claude to all your marketing data with Reporting Ninja

GA4 shows what visitors do on your site. The spend and campaigns that brought them are recorded in your ad and email platforms, so most performance questions need data from both.

To access that, all you need to do is to connect GA4 and your other channels once in Reporting Ninja, add our MCP connector to Claude, and ask about performance across every channel. Every figure comes from each platform’s API, and all our pricing plans include the connector, from $20 a month, billed annually.

Connect your first GA4 property this week and ask Claude what changed last month. Try Reporting Ninja for free.

FAQs

What is a Google Analytics MCP server?

A Google Analytics MCP server is a program that lets an AI assistant run GA4 reports through MCP. Google publishes an official read-only server, and reporting platforms offer hosted connectors that cover GA4 and other channels.

Is it free to connect Claude to GA4?

Sometimes. Google’s official server is free to install and runs with Claude Desktop, which is available on Claude’s Free plan. Reporting Ninja’s connector is included in plans from $20 a month, billed annually, with a 15-day free trial.

Do you need coding skills to connect Claude to Google Analytics?

No, not with a no-code connector. Google’s official server is different, because it needs the command line, a Google Cloud project, and a config file.

Is it safe to connect Claude to your Google Analytics data?

Yes, with the right setup. Give the connected account the Viewer role, use read-only connections, connect trusted tools only, and keep personal data out of your chats.

Elevate your marketing reports to the next level

Sign up for a 15 days free trial. No credit card required.

Instagram custom report
Fran Sánchez