NotFairNotFair
Start now

Codex · Google Analytics

Manage Google Analytics from Codex CLI with the same hosted MCP Claude uses

NotFair is a hosted Google Analytics MCP for OpenAI's Codex CLI. One terminal command registers the server. Codex then reads live GA4 data and stages writes for approval. 12 Google Analytics tools.

12 Google Analytics tools

Reporting is read-only. createKeyEvent and deleteKeyEvent are inverses. archiveCustomDimension is irreversible and cannot reuse parameterName. Writes wait for approval. runScript never wraps mutations.

Turn Codex Into Your Marketing Engine

Bring ads, search, analytics, CRM, and WordPress into your AI client. Explore each integration to see its supported actions.

Choose a platform

Choose your AI client

1

Install the MCP

Run this in your terminal:
codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair
2

Sign in and start asking

After running the command, Codex auto-opens a sign-in link in your browser. Sign in with NotFair and you are all set. Try: Audit my Google Analytics account and rank fixes by impact.

How it works

From install to an approved GA4 change

01

Connect GA4

NotFair hosts Google OAuth for GA4. You authorize properties without creating a Cloud project for the MCP client.

02

Add Codex

From any shell where Codex CLI is installed: `codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair`. Codex walks through OAuth and registers the MCP.

03

Ask, then approve writes

Codex can inspect Properties, Data API reports, realtime, metadata, custom dimensions, and key events. Writes wait for your confirmation. Google requires both analytics.readonly and analytics.edit for this combined surface. NotFair does not claim Google Ads impact review on GA4.

What the client can do

Reports first. Config writes with honest limits.

Google's experimental GA4 MCP is local and read-only. NotFair adds hosted OAuth plus gated custom-dimension and key-event writes, and it does not claim Google Ads impact review on Analytics.

Data API reports

runReport with sampling and (other)-row caveats. runScript can fan out up to five reports and never wraps mutations.

Realtime and metadata

runRealtimeReport and getMetadata so the client can inspect active users and available dimensions before proposing a config change.

Key events are inverses

createKeyEvent and deleteKeyEvent reverse each other after approval.

Archive is irreversible

archiveCustomDimension cannot be undone, and parameterName cannot be reused. The client must surface that limit.

GA4 tools

12 Google Analytics tools the client can call

The advertised count is measured from registerGoogleAnalyticsTools() and guarded by a drift test. The table below is a representative subset.

ToolType
listPropertiesread
runReportread
runRealtimeReportread
getMetadataread
createKeyEventwrite
archiveCustomDimensionwrite

Full tool surface: /google-analytics-mcp.

Google Analytics + Codex FAQ

Direct answers for operators connecting Google Analytics to OpenAI Codex CLI through NotFair.

Connect Google Analytics at notfair.co, run `codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair`, then ask Codex to inspect live data. Writes stay staged until you approve them.

Same hosted MCP endpoint, different client. Codex CLI calls NotFair using OpenAI's MCP support. Claude's connector and Claude Code call the same server from Anthropic's clients.

Only with explicit approval. Reporting is read-only. createKeyEvent and deleteKeyEvent are inverses. archiveCustomDimension is irreversible and cannot reuse parameterName. Writes wait for approval. runScript never wraps mutations. Google requires both analytics.readonly and analytics.edit for this combined surface. NotFair does not claim Google Ads impact review on GA4.

Google publishes googleanalytics/google-analytics-mcp as an experimental local, read-only server.

Connect Google Analytics to Codex

Reporting is read-only. createKeyEvent and deleteKeyEvent are inverses. archiveCustomDimension is irreversible and cannot reuse parameterName. Writes wait for approval. runScript never wraps mutations.

Reporting is read-only. createKeyEvent and deleteKeyEvent are inverses. archiveCustomDimension is irreversible and cannot reuse parameterName. Writes wait for approval. runScript never wraps mutations.