Build an MCP Server for Google Analytics (No Code Needed)
“The best dashboards are the ones that answer before you ask.” — Smart Marketer Using MCP
Last week you learned how to get answers pushed to you with Claude and Slack.
This week?
You’ll learn how to ask anything about your traffic — in plain English — and get live GA4 insights back. No code needed. Just one simple MCP server.
The Setup: GA4 + MCP = Your Marketing Brain
Here’s how it works:
GA4 — your existing analytics
Cursor IDE — no-code tool to build your server
Claude — your AI analyst
MCP SDK — connects Claude to GA4 with tools like:
queryAnalytics
getRealTimeUsers
sessionsByCountry
Use Case: Kill the Dashboard. Start a Chat.
You ask:
“What are my top traffic sources this month?”
Claude says:
“Organic search is up 14%. LinkedIn dropped 21%. Want content ideas to fix it?”
No logins. No dashboard. Just questions and answers.
Your Stack
GA4 + Google Cloud + Cursor + Claude + MCP SDK
Prompt to drop into Cursor:
“Create an MCP server that connects to my GA4 data. I want to ask questions and get traffic insights in plain language. Include tools like queryAnalytics, getRealTimeUsers, trafficSources, sessionsByCountry.”
.env setup:
GA_PROPERTY_ID = your GA4 ID
GA_CLIENT_EMAIL + GA_PRIVATE_KEY = from your service account
Cursor walks you through the setup.
Action Step
Want my 1-page guide?
Reply “GA MCP” and I’ll send the step-by-step (zero dev skills needed).
One smart move. Done in under 2 minutes.
-Fatmir
PS: GA4 gives you the data.
MCP gives you decisions.
That’s the move.