Skip to main content

Connect Claude, Cursor, and Codex via MCP

MCP (Model Context Protocol) lets AI tools like Claude, Cursor, and Codex securely read your Nexly analytics — traffic, reports, funnels, and property details — directly inside the chat or editor.

Nexly exposes a hosted MCP server. There is nothing to install and no tokens to copy: you connect with OAuth and authorize access with your Nexly account, the same way you would sign in with Google. Access is read-only — connected tools can query analytics but can never change anything in your account.

https://api.nexly.to/mcp
note

The MCP server accepts OAuth connections only. Personal API tokens (nxp_…) are for the read API and do not work with MCP.

Connect Nexly to Claude

You'll need the Claude Desktop app (or claude.ai) and a Nexly account. The setup takes about two minutes.

Step 1: Open Claude settings

Open Claude, go to SettingsConnectors, and pick AddAdd custom connector.

Connectors settings in Claude with the Add custom connector menu

Step 2: Add a custom connector

Fill in two fields:

  • Name: Nexly
  • URL: https://api.nexly.to/mcp

Leave the OAuth client fields under Advanced settings empty. Click Add.

Add custom connector dialog with the Nexly server URL

Step 3: Connect your account

Nexly now appears in your connectors list. Open it and click Connect. Claude opens the Nexly authorization page in your browser; sign in to Nexly first if you are not signed in already.

Nexly connector page in Claude with the Connect button

Step 4: Authorize Claude in Nexly

The authorization page shows exactly what Claude will be able to do: read Analytics, Reports, Funnels, and Properties. Review the permissions and click Authorize.

Nexly authorization page showing read-only permissions for Claude

Once authorized, you return to Claude and the connection is active — the connector page lists the available Nexly tools and lets you tune per-tool approval. The same connector works in Claude Desktop, on claude.ai, and in the Claude mobile apps.

Connected Nexly connector in Claude with tool permissions

Connect Nexly to Cursor

Cursor connects to remote MCP servers with OAuth as well.

Step 1: Add the server

Open CustomizeMCPs and click New MCP Server (or New).

MCPs tab in Cursor with the New MCP Server option

Cursor opens ~/.cursor/mcp.json; add the Nexly server there:

{
"mcpServers": {
"nexly": {
"url": "https://api.nexly.to/mcp"
}
}
}

mcp.json in Cursor with the Nexly server entry

Step 2: Authenticate

Back in the MCPs list, Nexly shows up as Needs authentication. Click Authenticate.

Nexly server waiting for authentication in the Cursor MCP list

Cursor opens the Nexly authorization page in your browser. Review the read-only permissions and click Authorize.

Nexly authorization page showing read-only permissions for Cursor

Once connected, the server appears in the list with its tools enabled; open its settings to toggle individual tools.

Connected Nexly server in Cursor with the tool list

Connect Nexly to Codex

Codex connects to remote MCP servers over Streamable HTTP with OAuth. The desktop app, CLI, and IDE extension share one MCP configuration, so adding Nexly once makes it available everywhere.

Step 1: Open MCP settings

In the Codex app, open SettingsPlugins and switch to the MCPs tab. Click Add server.

Codex MCP servers list in Settings → Plugins

Step 2: Add the Nexly server

On the Connect to a custom MCP screen, fill in:

  • Name: Nexly
  • Type: Streamable HTTP
  • URL: https://api.nexly.to/mcp

Leave the bearer token and header fields empty — Nexly uses OAuth, not tokens. Click Save.

Connect to a custom MCP form with the Nexly server URL

Step 3: Authorize Codex in Nexly

When Codex first connects to the server, it opens the Nexly authorization page in your browser. Sign in if needed, review the read-only permissions, and click Authorize.

Prefer the terminal? The same server can be added to ~/.codex/config.toml as a [mcp_servers.nexly] table with url = "https://api.nexly.to/mcp", then authorized with codex mcp login nexly — the app and CLI read the same configuration.

Other OAuth-capable MCP clients (for example Grok) connect the same way: give them the server URL and approve access on the Nexly authorization page.

What you can ask

Once connected, the AI tool can call read-only analytics tools: overview and time-series stats, top pages, sources, countries, devices and browsers, custom events, funnels, reports, anomalies, and AI-traffic breakdowns.

Good examples:

  • "How did traffic change on my site over the last 28 days?"
  • "Which pages drive the most signups this month?"
  • "Summarize the latest weekly report."
  • "What is the conversion of the onboarding funnel?"

Manage connected apps

Every connection you authorize appears in the Nexly dashboard under SettingsConnected apps, with the app name and its last activity.

Connected apps settings with authorized MCP clients

To revoke access, click Disconnect next to the app and confirm. The app loses access immediately; you can always reconnect later by authorizing again.

Security

  • Authorization uses OAuth 2.1 with PKCE; credentials are never shared with the connected app.
  • Access is limited to read-only analytics data available to your account.
  • Tokens are short-lived and refreshed automatically; disconnecting an app revokes all of its tokens at once.