Skip to content
Get started

Product Metrics in ChatGPT and Codex

Add the Product Metrics MCP server to ChatGPT as a developer-mode app or to the Codex CLI, sign in through your browser, and ask about your store and Google Ads.

Give ChatGPT or Codex your stores, products and Google Ads account, and let it run Product Metrics setup for you. Set up the app you use; you don’t need both.

SettingValue
Server nameProduct Metrics in ChatGPT, product-metrics in Codex
Server URLhttps://www.productmetrics.io/mcp
Sign-inBrowser sign-in to Product Metrics (OAuth), then Connect. No API key.

https://www.productmetrics.io/mcp is a client setting, not a page to open in a browser.

ChatGPT

1. Turn on developer mode

In ChatGPT, open Settings → Apps, then Advanced settings, and turn on Developer mode.

2. Create the app

Click Create app and fill in:

FieldValue
NameProduct Metrics
MCP server URLhttps://www.productmetrics.io/mcp
AuthenticationOAuth

Click Create. productmetrics mcp-config --client chatgpt prints the same steps.

3. Sign in and approve

ChatGPT opens a Product Metrics page that names ChatGPT and lists what it Can read and Can change. Signed out, click Continue with Google (it creates an account if you have none) or Sign in under the card. Then click Connect ChatGPT.

4. Use it in a chat

In a new chat, add Product Metrics from the tools menu, then try:

Where is my Product Metrics setup, and what is the next step?

Codex

1. Add the server

Run this in your terminal:

codex mcp add product-metrics --url https://www.productmetrics.io/mcp

2. Sign in and verify

codex mcp login product-metrics

Your browser opens the Product Metrics consent page: click Connect Codex. Restart Codex, then try:

Which Product Metrics stores can I open, and what is left to set up?

3. Optional: skills and the CLI

Skills give Codex the exact steps for tasks such as setting up tracking. The productmetrics CLI gives it the same API as commands with JSON output.

npx skills add https://www.productmetrics.io/docs --skill '*' --agent codex -y
npm install -g @productmetrics/cli

Run productmetrics login in your own terminal, not through Codex, and set PM_AGENT=1 so productmetrics never prompts. Details: For agents and CLI for agents.

What you can ask

"Where is my Product Metrics setup, and what is the next step?"
→ execute (GET /setup/status)

"Connect my WooCommerce store to Product Metrics."
→ execute (POST /companies/:companyId/stores); the setup token shows in
  the Product Metrics app, not in the chat

"Create the Product Metrics conversion actions in Google Ads."
→ execute (POST /properties/:propertyId/google-ads/conversion-actions)

"Which products spend without returning anything?"
→ list_properties, then get_google_ads_report (level: product,
  only_without_conversions: true)

"Why did my Google Ads conversion value drop since Monday?"
→ list_properties, then explain_google_ads_change

Analysis tools only read: they never change Google Ads or your store. Operations that delete something run only after you confirm, and steps that need you in a browser (Google consent, a store install) come back as a link. Every tool: MCP tools.

To give ChatGPT or Codex one store only, use https://www.productmetrics.io/mcp?selectedAccountPropertyId=<propertyId> as the URL.

Troubleshooting

ProblemFix
Create app is missing in ChatGPTTurn on Developer mode first.
Codex says the server needs sign-inRun codex mcp login product-metrics and finish the sign-in in the browser.
“This connection expired or was removed; connect Product Metrics again.”Sign in again: from the app’s settings in ChatGPT, or codex mcp login product-metrics. If that fails, remove the app or server and add it again.
“This connection only has MCP access, so it cannot call the Product Metrics API.”Remove the app or server, add it again and allow everything the consent page shows.
“The MCP server is not enabled for this account yet.”Ask Product Metrics support to turn it on for your account.
“This property needs a Product Metrics Pro subscription for the MCP server.”Upgrade that store to Pro, or ask about another store.
productmetrics can’t reach the API from CodexCodex’s sandbox may block network access for commands. Allow it for this session, or run productmetrics outside the sandbox.

More

  • Get started with Product Metrics MCP in other clients.
  • For humans: the consent page and browser sign-in in detail.
  • MCP tools: what each tool does, with its arguments.