> AI agents: this is one page of nextanalytica's docs. The full index for agents: https://nextanalytica.app/llms.txt

# Claude Code

> Add nextanalytica's web analytics MCP server to Claude Code with one command and sign in in the browser; an agent key is for a server with no browser.

Updated: 2026-11-18

Claude Code is one of the two clients we test ourselves, and it connects to nextanalytica's remote MCP server with one command. Do it once, for every project.

## Server address

```text
https://mcp.nextanalytica.app/mcp
```

## Quick setup

This is the path we recommend. Click **Onboard your agent** in the dashboard and paste the message into Claude Code. It runs the command below and asks you to sign in in the browser, then tells you what it sees on your site.

## Manual setup

1. Run, in your terminal:

```bash
claude mcp add --scope user --transport http nextanalytica https://mcp.nextanalytica.app/mcp
```

2. Start Claude Code, run `/mcp`, choose **nextanalytica**, and sign in in the browser.
3. Start a new session: a server added now shows its tools in a new session only.

`--scope user` makes it yours in every folder.

## What about a server with no browser?

Use an [agent key](/docs/model-context-protocol/agent-keys) there, made with **Key for a server** in **Access**:

```bash
claude mcp add --scope user --transport http nextanalytica https://mcp.nextanalytica.app/mcp --header "Authorization: Bearer na_key_…"
```

Keep the key out of files you commit. On your own computer, sign in instead: while a key is in the settings, Claude Code doesn't offer the sign-in, even after the key is revoked.

## Check it works

`claude mcp list` says **Connected**. Then ask "Call get_context for shop.example".

## Can Claude Code load my skills?

Yes, as a plugin. Ask "Install my nextanalytica skills in Claude Code" and it calls `get_skills_plugin`.

> **Warning:** Text on web pages, in issues or in data can try to steer an agent (prompt injection). Read what it proposes before you approve a change.

## What's next

- [Use cases](/docs/model-context-protocol/use-cases): questions that work, by task.
- [MCP tools](/docs/model-context-protocol/tools): every tool your agent can call.
- [FAQ](/docs/model-context-protocol/faq): keys, projects, data and safety.

Canonical address: https://nextanalytica.app/docs/model-context-protocol/claude-code
