The short answer
Google's official Google Analytics MCP server is free, read-only and works well in apps that run on your computer, such as Claude Desktop, Claude Code and Cursor. Plan on about five steps first: Python, a Google Cloud project with two APIs turned on, the Google Cloud command line tool, a sign-in with the right scopes, and a config file with absolute paths.
It does not work in claude.ai or ChatGPT on the web unless you host it yourself. And its 10 tools add about 57.9 KB of instructions to every conversation, roughly 14,000 tokens, before your first question.
See the numbers
| Tool | Bytes |
|---|---|
run_realtime_report | 15,769 |
run_conversions_report | 14,884 |
run_report | 14,764 |
run_funnel_report | 8,817 |
list_property_annotations | 835 |
list_key_events | 775 |
get_custom_dimensions_and_metrics | 598 |
list_google_ads_links | 583 |
get_property_details | 550 |
get_account_summaries | 273 |
| All 10 tools | 57,868 |
Data: Harvv test, Nov 11, 2026
The four report tools make up 94% of that, because each one carries Google's full guide to dimensions, metrics and filters. That is what lets the AI write a correct report. Some apps load tool definitions only when they need them, so the cost depends on the app you use.
How do you set up the Google Analytics MCP?
These are Google's steps from its developer guide and the GitHub README, in the order you'll need them.
- Install Python 3.10 or newer, and pipx. The server is a Python package called
analytics-mcp. In our test it installed in about 17 seconds and started in about 2. - Turn on two APIs in a Google Cloud project. The Google Analytics Admin API and the Google Analytics Data API. If you've never used Google Cloud, this is where you create a project.
gcloud services enable analyticsadmin.googleapis.com analyticsdata.googleapis.com --project=YOUR_PROJECT_ID - Sign in with the read-only scope. This needs the Google Cloud command line tool (
gcloud). The README also passes your own OAuth client file, which you create in the same Cloud project.gcloud auth application-default login --scopes https://www.googleapis.com/auth/analytics.readonly,https://www.googleapis.com/auth/cloud-platform --client-id-file=YOUR_CLIENT_JSON_FILECopy the credentials path it prints. - Check your GA4 access. The Google account you signed in with needs at least Viewer on the property.
- Add it to your AI app. For Claude Code:
claude mcp add analytics-mcp --scope user -e GOOGLE_APPLICATION_CREDENTIALS=PATH_TO_CREDENTIALS_JSON -e GOOGLE_CLOUD_PROJECT=YOUR_PROJECT_ID -- pipx run analytics-mcpIn desktop apps, write full paths. Many apps don't expand~or$HOMEin their config files.
What went wrong in our test
We started the server on a computer with no Google sign-in. It started normally, listed all 10 tools, and looked connected. The failure came only when the AI asked its first question: "Your default credentials were not found."
So "connected" in your AI app doesn't mean it works. Ask one simple question, like "list my Google Analytics properties", right after setup. If you get a 403 error instead, Google's checklist names three usual causes: an API not turned on, a missing scope at sign-in, or no Viewer role on the property.
What are its limits?
- It runs on your computer. claude.ai and ChatGPT on the web can't reach it. The code has an HTTP mode with sign-in that you can host, for example on Google Cloud Run, but then you run a server.
- Google's quotas still apply. A standard GA4 property gets 200,000 quota tokens a day and 40,000 an hour, and one Cloud project can use 14,000 an hour on a property (Google's quota page). These are Google's tokens, not AI tokens. A busy afternoon of questions can run into the hourly one.
- It knows what GA4 knows. Sessions, events, key events, sources and pages. It can't see where people clicked, what they couldn't find, or whether a visit was a bot GA4 counted as a person.
- It's read-only by default. Good for safety. To add annotations or key events you start it with
--allow-writeand sign in again with theanalytics.editscope.
When a hosted connector is easier
Google's server is the right pick if you want any GA4 report, you use Claude Desktop, Claude Code or Cursor, and you're comfortable in Google Cloud.
Harvv's connector at harvv.com/mcp is the other path. You connect GA4 once with a Google sign-in (read-only), and it works in claude.ai, ChatGPT and the desktop apps. Harvv copies a fixed set of GA4 reports each day (events and key events, sessions and revenue by source and campaign, landing pages) and puts them next to what its own script saw on the page, so the AI can answer "why did this page stop converting", not only "how many". It does not run any report you can think of; for that, use Google's.
The same choice comes up for Search Console, Google Ads and Meta Ads. Our guide to SEO and marketing MCP servers lists the official server for each and how hard each one is to set up.
How we tested this
- November 11, 2026, on a Mac with Python 3.14. We installed
analytics-mcp1.1.0 from PyPI into a fresh virtual environment and talked to it over MCP directly: start, list tools, call one tool. - Sizes are the JSON of each tool definition as the server sent it. Tokens are estimated at about 4 characters each and rounded down.
- We ran it with no Google credentials on purpose, to see how a missing sign-in shows up. We did not finish a Google sign-in in this test. Setup steps and quotas are quoted from Google's pages, read the same day.