Kipt

Claude Code MCP: add, manage and secure MCP servers

Claude Code MCP guide: the claude mcp add command, local, project and user scopes, HTTP and stdio transports, useful servers, security, and MCP vs skills.

By the Kipt team · Updated 23 October 2026

What MCP gives Claude Code

MCP, the Model Context Protocol, is an open standard for connecting AI tools to outside systems. An MCP server exposes tools, and once you connect one, Claude Code can call them: read issues from your tracker, query a database, drive a browser, check error reports.

To add one, run claude mcp add in your terminal with a name and either a URL (remote server) or a launch command (local server). A good time to connect a server is when you notice yourself copying data from another tool into the chat. Once it is connected, Claude reads that system directly.

How do you add an MCP server?

You add an MCP server with claude mcp add, in one of two common shapes depending on where the server runs.

Remote server over HTTP

HTTP is the recommended transport for remote servers.

# Basic syntax
claude mcp add --transport http <name> <url>

# Example: Notion
claude mcp add --transport http notion https://mcp.notion.com/mcp

# Example with a bearer token
claude mcp add --transport http secure-api https://api.example.com/mcp \
  --header "Authorization: Bearer your-token"

Local server over stdio

A stdio server runs as a process on your machine. Everything after -- is the command that starts the server; everything before it is for Claude Code.

# Basic syntax
claude mcp add [options] <name> -- <command> [args...]

# Example: a server that needs an API key
claude mcp add --env AIRTABLE_API_KEY=YOUR_KEY --transport stdio airtable \
  -- npx -y airtable-mcp-server

The -- matters. Without it, Claude Code tries to read the server's own flags, like -y or --port, as its own options.

Transports at a glance

Transport Use it for How to add
http Remote servers. Supports OAuth sign-in claude mcp add --transport http
stdio Local processes started with npx, uvx or a binary claude mcp add <name> -- <command>
sse Older remote servers. Deprecated Use --transport http; recent versions fall back to SSE automatically, or pass --transport sse
ws Remote servers that push events claude mcp add-json or .mcp.json only

Add from a JSON block

Many servers publish setup instructions for other clients as an mcpServers JSON block. Pass the object inside it, not the wrapper, to claude mcp add-json:

claude mcp add-json example '{"command":"npx","args":["-y","@example/mcp-server"]}'

If the entry has a url but no type, add "type": "http" first. Claude Code reads an entry without a type as a local stdio server.

What are MCP server scopes?

Every server is saved at one of three scopes: local, project or user. Pass --scope to choose; the default is local.

Scope Loads in Shared with team Stored in
local (default) Current project only No ~/.claude.json
project Current project only Yes, via git .mcp.json in the repo root
user All your projects No ~/.claude.json
# Share with your team: writes .mcp.json
claude mcp add --transport http shared-server --scope project https://example.com/mcp

# Available in every project for you
claude mcp add --transport http hubspot --scope user https://mcp.hubspot.com/anthropic

A project-scoped .mcp.json looks like this:

{
  "mcpServers": {
    "shared-server": {
      "type": "http",
      "url": "https://example.com/mcp"
    }
  }
}

Keep secrets out of committed files with environment variable expansion. .mcp.json supports ${VAR} and ${VAR:-default} in command, args, env, url and headers:

{
  "mcpServers": {
    "api-server": {
      "type": "http",
      "url": "${API_BASE_URL:-https://api.example.com}/mcp",
      "headers": {
        "Authorization": "Bearer ${API_KEY}"
      }
    }
  }
}

If the same server name exists at several scopes, local wins over project, and project over user. The whole entry from the winning scope is used; fields are not merged.

Manage your servers

# List servers with a health status for each
claude mcp list

# Details for one server
claude mcp get notion

# Remove a server (also deletes its stored OAuth tokens)
claude mcp remove notion

# Sign in to a server from your shell
claude mcp login sentry

Inside a session, /mcp opens the server list. From there you can see each server's status, sign in through the browser for servers that use OAuth, clear authentication, and toggle a server off without deleting its config. claude mcp list shows statuses such as ✔ Connected, ! Needs authentication and ✘ Failed to connect.

For a remote server that needs sign-in, add it and then authenticate:

  1. Run claude mcp add --transport http sentry https://mcp.sentry.dev/mcp.
  2. Start Claude Code and type /mcp.
  3. Pick the server and follow the browser sign-in. Tokens are stored and refreshed for you.

Useful servers you can add today

These commands come from the Claude Code docs or the server's own README. Check each project's page for current options before you connect.

Server What Claude can do Command
GitHub Review PRs, create issues, search repos claude mcp add --transport http github https://api.githubcopilot.com/mcp/ --header "Authorization: Bearer YOUR_GITHUB_PAT"
Notion Read and update pages and databases claude mcp add --transport http notion https://mcp.notion.com/mcp
Sentry Look up errors and issues claude mcp add --transport http sentry https://mcp.sentry.dev/mcp
Stripe Work with your Stripe account claude mcp add --transport http stripe https://mcp.stripe.com
Playwright Drive a real browser to test pages claude mcp add playwright -- npx @playwright/mcp@latest
DBHub Query Postgres and other SQL databases claude mcp add --transport stdio db -- npx -y @bytebase/dbhub --dsn "postgresql://readonly:pass@host:5432/db"

For GitHub, create a fine-grained personal access token limited to the repos Claude should touch. For databases, put a read-only user in the connection string so Claude's queries cannot change data. You can browse more reviewed servers in the Anthropic Directory; any remote server listed there can be added with claude mcp add.

Also consider whether you need a server at all. If a service has a good CLI, such as gh for GitHub, Claude can often use it directly with less setup and less context.

MCP prompts become commands

Servers can also expose prompts. They show up in the / menu as /servername:promptname (MCP), and you can run them as /mcp__servername__promptname with arguments after a space, such as /mcp__github__pr_review 456. See the slash commands guide for how they sit alongside built-in and custom commands.

Do MCP servers use up context?

Adding MCP servers is much cheaper than it was, but not free. Every connected server used to add all of its tool definitions to your context. Claude Code now uses tool search by default: only tool names and server instructions load at session start, and full definitions load when Claude needs a tool. Run /context all to see how many tokens each loaded MCP tool uses, and disconnect servers you are not using.

Security

MCP servers can read and change real systems, so treat each one like a dependency with access to your accounts.

  1. Only connect servers you trust. A server that fetches outside content, such as web pages or tickets written by strangers, can carry prompt injection that tries to steer Claude.
  2. Use least privilege. Scope tokens to the repos or projects needed, and use read-only database users.
  3. Keep credentials local. Use local or user scope for servers with personal tokens. In committed .mcp.json files, reference secrets with ${VAR} instead of writing them in.
  4. Review project servers. In interactive sessions, Claude Code asks before using servers from a repo's .mcp.json. In claude -p and SDK runs it cannot ask, so it loads them. Read .mcp.json before scripting Claude over a repo you did not write. claude mcp reset-project-choices clears your past approvals.
  5. Control tools with permissions. Permission rules name MCP tools as mcp__<server>__<tool>. Allow mcp__github__get_* for read tools only, or deny mcp__* to block every MCP tool. Subagents can also be limited to specific servers with their tools and mcpServers fields.

Teams that need central control can manage the allowed server list through managed settings, covered in the docs on managed MCP configuration.

MCP vs skills

MCP servers and skills solve different problems, and the best setups use both.

MCP server Skill
What it is A connection to an outside system Instructions and reference material
Provides Tools and data access Knowledge and repeatable workflows
Examples Database queries, issue tracker, browser control Review checklist, deploy steps, API style guide
Context at startup Tool names Short description
Set up with claude mcp add A SKILL.md file in .claude/skills/

MCP gives Claude the ability to reach a system. A skill tells Claude how your team wants that system used: your schema and query patterns, your ticket format, your release steps. The skills vs MCP guide goes deeper on the trade-offs. If you want to ship servers, skills and hooks together, plugins bundle them into one install.

Kipt stores the skill side of that pairing. Keep the prompts and skills that explain how to use your tools in a private GitHub repo you own, turn a good prompt into a SKILL.md with Promote to skill, and install the lot on any machine with npx skills add https://github.com/<you>/<repo>.git.

Sources: Connect Claude Code to tools via MCP, Extend Claude Code, and the Playwright MCP README.

Questions

How do I add an MCP server to Claude Code?

Run claude mcp add in your terminal. For a remote server use claude mcp add --transport http <name> <url>. For a local one use claude mcp add <name> -- <command>, with the server's launch command after the double dash.

Where does Claude Code store MCP servers?

Local and user scoped servers are stored in ~/.claude.json. Project scoped servers go in a .mcp.json file at the root of your repo, which you can commit so your team gets the same servers.

How do I check if an MCP server is connected?

Run claude mcp list in your shell, which shows a status like Connected or Failed to connect next to each server, or type /mcp inside Claude Code to see status and sign in to servers that need it.

Do MCP servers use a lot of context?

Less than they used to. Tool search is on by default, so only tool names load at session start and full tool definitions load when Claude needs them. Run /context all to see what each loaded tool costs.

Should I use an MCP server or a skill?

Use MCP when Claude needs to reach an outside system like a database, issue tracker or browser. Use a skill when Claude needs instructions or knowledge. They work well together: MCP provides the connection and a skill explains how to use it.

More in Claude Code

All guides

Keep your prompts and skills in one place, in your own GitHub. Install every skill with one command.

Get started

Kipt is an independent product, not affiliated with or endorsed by Anthropic, OpenAI, Cursor or GitHub. Claude, ChatGPT, Codex, Cursor and GitHub are trademarks of their owners.