← All resources Product

Connect Gemini CLI to Measurebase

Measurebase speaks MCP - the open protocol AI assistants use to reach external tools - and Google's Gemini CLI speaks it too. Register Measurebase once and your tracking answers arrive in the terminal, in the middle of whatever you were doing.

What you can ask

Gemini answers with your live data: statistics, request types, browser and bot breakdowns, Consent Mode v2 signals, request logs, alerts, plan usage, and the ad-block detection status - across every account you're a member of.

Connect in two minutes

  1. In a terminal, run gemini mcp add --transport http measurebase https://mcp.measurebase.com/mcp - or add the server to ~/.gemini/settings.json by hand (.gemini/settings.json inside a project keeps it project-scoped):
{
  "mcpServers": {
    "measurebase": {
      "httpUrl": "https://mcp.measurebase.com/mcp",
      "oauth": { "enabled": true }
    }
  }
}
  1. Start gemini and run /mcp auth measurebase. Gemini CLI opens your browser for the Measurebase login and shows the consent screen that spells out what it gets.
  2. Click Allow. /mcp lists the Measurebase tools; ask your question at the prompt.

The OAuth flow needs a local browser and a localhost redirect. On a headless machine or inside a container, use a token instead.

🔒 Read-only by design

New connections are read-only unless you explicitly tick read & write on the consent screen - and read-only means exactly that: it can never change anything, not your domains, not your settings, not your tokens. With write access the assistant can also toggle power-ups, verify DNS, generate tracking scripts, and set up new accounts and domains (returning the exact DNS record to add) - never more than your own role on each account allows, and Auto Grant Consent is excluded permanently.

Prefer a token?

You can skip the OAuth flow with a static header. Create a personal API token in the dashboard under Settings → API tokens (read-only by default, valid until you revoke it) and add it to the server entry instead of the oauth block:

"headers": { "Authorization": "Bearer YOUR_TOKEN" }

Keep it in your user settings, not in a project file that ends up in version control.

How access and privacy work

🤝 For agencies

Your connection follows your agency access too: clients who approved your link are queryable in the same conversation. "Which of my clients had alerts this week?" is one question instead of ten dashboard visits.

Continue reading

Ready to move your tagging to Europe?

Start free, no credit card required. Live in about 15 minutes.

Start free