Adding an MCP server in Claude Code
Claude Code adds remote MCP servers through a CLI command. The general form is claude mcp add <name> --transport http <server-url> — here it is with a real, working server rather than a placeholder:
- claude mcp add --transport http mcp-ads https://mcp-ads.com/mcp-slim
- For a local/stdio server instead of a remote one: claude mcp add <name> -- <command> <args>
- Claude Code stores the configuration in ~/.claude.json at the user level, not per-project
- Restart any open Claude Code sessions after adding a server for the tools to appear — an existing session does not pick up new servers automatically
Adding an MCP server in Claude Desktop
Claude Desktop reads MCP server configuration from a JSON config file for local/stdio servers, but for a remote server — one reachable over a URL, like most SaaS-hosted MCP servers — the faster path is the in-app connector flow: Settings → Connectors → Add custom connector, then paste the server URL directly. No config file editing needed for this case.
The URL you paste is the same one used everywhere else: https://mcp-ads.com/mcp-slim for MCP Ads, or the equivalent hosted endpoint for any other remote MCP server.
Adding a remote MCP server in Claude.ai
In Claude.ai, go to Settings → Connectors → Add custom connector, paste the MCP server URL, and approve the connection. For servers that require account authorization on top of the server connection itself (ad platforms, CRMs, anything with its own login), you will be prompted to connect each underlying account through browser-based OAuth after the server itself is added — that is a separate step from adding the server.
"A server with this url already exists" — what it means and how to fix it
This error fires when Claude Code already has an entry pointing at that URL (or that name) under a different local label, and a second claude mcp add tries to register it again. It is not a sign anything is broken — Claude Code is refusing a duplicate, not failing to connect.
Run claude mcp list first to see what is already registered and under what name. If the existing entry is the one you want, there is nothing to fix — connect a new conversation and the tools will already be there. If it is stale (an old URL, a renamed server, a test entry), remove it with claude mcp remove <name> and re-add it with the name and URL you actually want.
- claude mcp list — see every server currently registered and its URL
- claude mcp remove <name> — clear a stale or duplicate entry before re-adding
- The name in claude mcp add <name> is just a local label; the URL is what Claude actually matches on, so renaming does not dodge the conflict — the URL has to be free too
Verifying the connection actually worked
Adding a server and having it work are two different checkpoints. Start a brand-new conversation (not one already open before you added the server) and ask something the server can only answer with real access — for MCP Ads, a prompt like "list my connected ad accounts" only succeeds if the server is registered and any required account authorization is complete.
A generic response, a refusal, or the assistant saying it does not have that capability usually means one of the two steps above — server registration or account OAuth — did not finish, not that the product itself does not support the request.
If the MCP server tools do not show up
Beyond the duplicate-URL error above, a few other checks resolve most remaining cases.
- Restart the Claude session completely — a simple reload sometimes is not enough
- Check that the server URL or command has no typos and that any required environment variables are set
- For remote servers, confirm the OAuth/account-connection step was completed, not just the server-add step
- Run claude mcp list (Claude Code) to confirm the server is registered before troubleshooting further