Google has released an open-source Model Context Protocol (MCP) server that lets you analyze Google Analytics data using large language models like Gemini.
Announced by Matt Landers, Head of Developer Relations for Google Analytics, the tool serves as a bridge between LLMs and analytics data.
Instead of navigating traditional report interfaces, you can ask questions in plain English and receive responses instantly.
The MCP server offers an alternative to digging through menus or configuring reports manually. You can type queries like “How many users did I have yesterday?” and get the answer you need.

In a demo, Landers used the Gemini CLI to retrieve analytics data. The CLI, or Command Line Interface, is a simple text-based tool you run in a terminal window.
Instead of clicking through menus or dashboards, you type out questions or commands, and the system responds in plain language. It’s like chatting with Gemini, but from your desktop or laptop terminal.
When asked about user counts from the previous day, the system returned the correct total. It also handled follow-up questions, showing how it can refine queries based on context without requiring additional technical setup.
You can watch the full demo in the video below:
The server uses the Google Analytics Admin API and Data API to support a range of capabilities.
According to the project documentation, you can:
To set it up, you’ll need Python, access to a Google Cloud project with specific APIs enabled, and Application Default Credentials that include read-only access to your Google Analytics account.
The server is especially helpful in more advanced scenarios.
In the demo, Landers asked for a report on top-selling products over the past month. The system returned results sorted by item revenue, then re-sorted them by units sold after a follow-up prompt.

Later, he entered a hypothetical scenario: a $5,000 monthly marketing budget and a goal to increase revenue.
The system generated multiple reports, which revealed that direct and organic search had driven over $419,000 in revenue. It then suggested a plan with specific budget allocations across Google Ads, paid social, and email marketing, each backed by performance data.

You can install the server from GitHub using a tool called pipx, which lets you run Python-based applications in isolated environments. Once installed, you’ll connect it to Gemini CLI by adding the server to your Gemini settings file.
Setup steps include:
The server works with any MCP-compatible client, but Google highlights full support for Gemini CLI.
To help you get started, the documentation includes sample prompts for tasks like checking property stats, exploring user behavior, or analyzing performance trends.
Google says it’s continuing to develop the project and is encouraging feedback through GitHub and Discord.
While it’s still experimental, the MCP server gives you a hands-on way to explore what natural language analytics might look like in the future.
If you’re on a marketing team, this could help you get answers faster, without requiring dashboards or custom reports. And if you’re a developer, you might find ways to build tools that automate parts of your workflow or make analytics more accessible to others.
The full setup guide, source code, and updates are available on the Google Analytics MCP GitHub repository.
Featured Image: Mijansk786/Shutterstock
Related Terms & Common Misspellings: