How to Add an MCP Server to Claude Code Globally

Adding an MCP server to Claude Code globally means one command with a scope flag, not editing config files by hand in every project folder you ever plan to open.

I keep a lean, deliberate set of servers running across all my projects, covered in more depth in my lean MCP server set and my full server list.

This piece is about the mechanism behind that setup, how scope actually works, not which specific servers to run.

The three scopes, and what each one actually means

Illustration of a single global config unlocking access across all projects

Local scope is the default. A server added with no flag is available only to you, only in the current project, invisible everywhere else.

Project scope stores shared configuration in .mcp.json. Review it before adding it to version control, keep secrets out, and expect each user’s approval or authentication requirements to apply.

User scope is the global option, available to you across every project on the machine regardless of which folder you happen to be working in. This is what most people actually mean when they ask how to add an MCP server globally.

The actual command

Use --scope user as an option to claude mcp add. For a local stdio server, keep it before the -- separator. Everything after that separator belongs to the server command. See the official MCP reference.

For an HTTP server, the command shape is shown below. Replace the example URL with the verified endpoint from your provider. The example address is a placeholder, not a service to install.

claude mcp add --scope user --transport http my-server https://mcp.example.com/mcp

For a local server, put the reviewed executable and its arguments after --. Do not paste an unknown package command just to test the scope flag.

claude mcp add --scope user my-server -- /absolute/path/to/reviewed-server

These are configuration examples, not commands run for this article. A saved configuration is not proof that the server is connected or authenticated.

Where the config actually lives

User-scoped servers are stored in ~/.claude.json. That makes the configuration available to your user account across projects on that machine. It does not automatically copy it to another computer.

You generally never need to hand-edit this file directly. The CLI command handles it, and hand-editing config that a working CLI already manages is a good way to introduce a typo that quietly breaks a server you rely on daily.

Checking what is actually configured

Use claude mcp list to see configured servers and health status. A status such as “Needs authentication” is different from a missing configuration.

Use claude mcp get my-server to inspect one entry, then open /mcp inside Claude Code for available authentication or connection controls. Avoid sharing output that contains private endpoint or account details.

When user scope makes sense

User scope is useful for a personal tool you deliberately want available across projects. Keep a tool local when its access should be limited to one project. “Personal” does not automatically mean “available everywhere.”

Project scope stays reserved for servers the actual team needs shared and versioned in the repo. Mixing the two up means either re-adding personal tools constantly, or accidentally sharing a personal server’s config with people it was never meant for.

A common mistake worth avoiding

A local definition can override a same-named user definition. Claude Code uses local, then project, then user scope precedence for those entries; it does not merge their fields.

Check which definition is active before changing anything. Keep a record of the intended configuration, and remove a duplicate only after confirming it is unnecessary and choosing the exact scope.

Verify the current session

After a CLI configuration change, check /mcp in the session you intend to use. If it still shows the old configuration, start a new session and check again. Do not treat a successful add message alone as a working connection.

Removing a global server

To remove the example’s user-scoped entry deliberately, use the explicit scope shown below. Check claude mcp remove --help against your installed version first.

claude mcp remove --scope user my-server

Do not start troubleshooting by deleting and re-adding a server. Check its status, endpoint, authentication and permissions first. Removing a remote server can also remove stored OAuth credentials and require another sign-in.

Claude Code MCP globally, quick answers

How do I add a server across projects? Use --scope user on claude mcp add. Keep Claude’s options before -- when the command launches a local server.

How do project and user scope differ? Project scope uses a shared .mcp.json. User scope is private to your account on that machine. Both still have applicable permissions and authentication.

How do I inspect the result? Run claude mcp list and claude mcp get my-server. Then check the intended session with /mcp.

Must I restart every time? Verify the session first. If it has not picked up the configuration, start a fresh session and check again rather than assuming the change is active.

Where this fits

I write about the tools I actually run building software as a one-person business. If a connected system for managing that whole workload interests you, join the Tandri waitlist.

SoftDeveloper23
SoftDeveloper23

I’m the maker behind softDev23, building apps and exploring how AI and automation can make everyday work easier. I share practical guides and lessons from building in public: what worked, what broke, and what I’d do differently.

Follow along as I turn ideas into useful products, one experiment at a time.

Articles: 139

Leave a Reply

Your email address will not be published. Required fields are marked *