Codex · Google Analytics
Use Google Analytics in Codex with the NotFair Ads plugin
Install NotFair Ads from the shared ChatGPT and Codex plugin directory, then connect Google Analytics in your NotFair workspace. Codex can read live data and prepare supported changes for your review. 12 Google Analytics tools. Prefer the terminal? Connect the same hosted MCP with Codex CLI.
12 Google Analytics tools
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
Install NotFair Ads
Use Codex CLI instead
codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair
codex mcp login NotFair-GoogleAnalyticsConnect your workspace and verify
Audit my Google Analytics account and rank fixes by impact.How it works
From plugin install to an approved GA4 change
Install NotFair Ads
Open Plugins in Codex, find NotFair Ads, and install it. Follow the connection prompts to sign in to your NotFair workspace.
Connect GA4
NotFair hosts Google OAuth for GA4. You authorize properties without creating a Cloud project for the MCP client. For manual Codex CLI setup, run `codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair`, then `codex mcp login NotFair-GoogleAnalytics` to complete OAuth.
Verify, then review changes
Start a new Codex chat and ask NotFair Ads to list your connected platforms and accounts. Inspect GA4 data, then review the target and proposed edit before approving a supported write. 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.
| Tool | Type | Description |
|---|---|---|
listProperties | read | Discover accessible GA4 properties grouped by account. |
runReport | read | Run a Data API report with freshness and sampling metadata. |
runRealtimeReport | read | Active users and realtime dimensions for the selected property. |
getMetadata | read | Available dimensions and metrics, including custom definitions. |
createKeyEvent | write | Approval-gated. Inverse of deleteKeyEvent. |
archiveCustomDimension | write | Approval-gated and irreversible. parameterName cannot be reused. |
Full tool surface: /google-analytics-mcp.
Example prompts
Prompts that lead to real account work
Channel report
“Run a last-28-days report of sessions and conversions by sessionDefaultChannelGroup.”
A Data API report with sampling caveats.
Realtime check
“Show realtime active users for the selected property.”
runRealtimeReport output for the targeted propertyId.
Key-event preview
“Preview creating a key event. Do not execute until I approve. Explain whether archiveCustomDimension can be undone.”
A staged Admin API write. Archive is labeled irreversible.
Google Analytics + Codex FAQ
Using the NotFair Ads plugin or hosted MCP with Google Analytics in Codex.
Install NotFair Ads from Plugins in Codex, sign in to NotFair, and connect Google Analytics. Start a new chat and verify your connected accounts. For manual CLI setup, run `codex mcp add NotFair-GoogleAnalytics --url https://notfair.co/api/mcp/notfair`, then `codex mcp login NotFair-GoogleAnalytics`.
ChatGPT and Codex share a plugin directory. NotFair Ads connects to the same NotFair workspace and supported tools. Complete the connection prompts in the client you use, then verify the selected accounts in a new chat.
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. Review the exact change before approving a supported action.
Google publishes googleanalytics/google-analytics-mcp as an experimental local, read-only server.
Related pages
Keep evaluating the same connection.
Google Analytics MCP
Tool surface, endpoint, and 12 Google Analytics tools.
Google Analytics Codex setup guide
Plugin installation and manual Codex CLI setup.
Google Analytics for Claude
Same hosted MCP endpoint on Claude's first-class landing.
Google Analytics for ChatGPT
Install the NotFair Ads plugin and use live platform data in ChatGPT.
Google Analytics for Grok Bot
Marketplace install for the same hosted MCP tools.
Compare Google Analytics MCP servers
Sourced benchmark with public verification prompts.
Google Analytics write safety
Reporting is read-only. createKeyEvent and deleteKeyEvent are inverses. archiveCustomDimension is irreversible and cannot reuse parameterName. Writes wait for approval. runScript never wraps mutations.
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.