Skip to content

How to Set Up MCP Servers in Claude Desktop (Step-by-Step)

The complete guide to adding MCP servers to Claude Desktop. Find your config file, add servers, troubleshoot common issues, and test your setup.

March 24, 2026
5 min read

Claude Desktop supports MCP servers natively. You add a few lines to a JSON config file, restart, and your AI can search the web, query databases, manage repos, and more.

Here is the exact process, including the parts that trip people up.

Step 1: Find Your Config File

Claude Desktop reads its MCP configuration from claude_desktop_config.json. The location depends on your OS:

macOS:

~/Library/Application Support/Claude/claude_desktop_config.json

Windows:

%APPDATA%\Claude\claude_desktop_config.json

Linux:

~/.config/Claude/claude_desktop_config.json

If the file does not exist, create it. Start with an empty JSON object:

{}

Shortcut on macOS: Open Claude Desktop, go to Settings > Developer > Edit Config. This opens the file in your default editor and creates it if it does not exist.

Built-in Connectors UI: Claude Desktop also has a Connectors panel and an Extensions marketplace for installing MCP servers without editing JSON. Open the "+" menu at the bottom of a chat and select "Connectors" to browse available servers. The JSON method below gives you full control and works for any MCP server, including custom and private ones.

Step 2: Add Your First MCP Server

Each server gets an entry under the mcpServers key. Here is a minimal example using the Toolradar MCP server — a safe starting point because it is read-only (no filesystem access, no write operations):

{
  "mcpServers": {
    "toolradar": {
      "command": "npx",
      "args": ["-y", "toolradar-mcp"],
      "env": {
        "TOOLRADAR_API_KEY": "tr_live_your_key_here"
      }
    }
  }
}

Get your free API key (100 calls/day) at toolradar.com/dashboard/api-keys.

Config anatomy

Every MCP server entry has three parts:

FieldRequiredPurpose
commandYesThe executable to run (npx, node, python, docker, uvx)
argsYesArguments passed to the command (package name, flags, script path)
envNoEnvironment variables visible only to this server (API keys, tokens)

The command + args pattern means Claude Desktop launches the MCP server as a subprocess. It communicates over stdio — the server reads JSON-RPC from stdin and writes responses to stdout.

Step 3: Restart Claude Desktop

Close Claude Desktop completely (not minimize — quit). On macOS: Cmd+Q. On Windows: right-click the system tray icon and select Quit. Then reopen it.

The MCP server starts as a subprocess in the background. You will not see a confirmation message. The way to verify: look at the bottom of a new chat window. You should see a hammer icon with a number indicating how many tools are available. Click it to see the list.

Alternatively, ask Claude something that requires the MCP server:

Try: "How much does Figma cost?"

If Claude calls the get_pricing tool and returns actual tier data (Starter: Free, Professional: $16/seat/month...), your setup works.

Step 4: Add More Servers

You can add as many servers as you want. Each gets its own key:

{
  "mcpServers": {
    "toolradar": {
      "command": "npx",
      "args": ["-y", "toolradar-mcp"],
      "env": {
        "TOOLRADAR_API_KEY": "tr_live_your_key"
      }
    },
    "brave-search": {
      "command": "npx",
      "args": ["-y", "@anthropic-ai/brave-search-mcp"],
      "env": {
        "BRAVE_API_KEY": "your_brave_key"
      }
    },
    "github": {
      "command": "docker",
      "args": [
        "run", "-i", "--rm",
        "-e", "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_your_token"
      }
    }
  }
}

Restart Claude Desktop after each change to the config file.

Performance note: Each MCP server is a separate subprocess. Adding 3-5 servers is fine. Adding 20+ may slow down Claude Desktop's startup and increase memory usage. Install only what you actively use. For a curated list, see our 25 best MCP servers for 2026.

Desktop Extensions (.mcpb files)

As of early 2026, Claude Desktop supports Desktop Extensions — packaged MCP servers distributed as .mcpb files. These are pre-configured bundles that install with a double-click, no JSON editing required.

How they differ from manual JSON config:

Manual JSONDesktop Extension (.mcpb)
InstallEdit config file, add server entryDouble-click the .mcpb file
UpdatesManual (re-pull package)Automatic via Claude Desktop
DiscoveryFind on npm, GitHub, or docsBrowse the Extensions marketplace
ConfigFull control over args and envGuided setup wizard for API keys
Custom serversYesOnly published extensions

Desktop Extensions are ideal for non-technical users or for servers you want to "set and forget." The JSON config remains the right choice for custom servers, private servers, or when you need full control over arguments and environment variables.

To browse available extensions: open a new chat, click the "+" button at the bottom, and select "Extensions."

Troubleshooting

"Claude doesn't seem to use my MCP server"

Check the config path. The most common issue. The file must be at the exact path listed in Step 1, not in your home directory or Desktop. On macOS, ~/Library is a hidden folder — use Finder's Go > Go to Folder (Cmd+Shift+G) to navigate there.

Check the JSON syntax. Missing comma, extra comma, mismatched brackets — any syntax error silently disables all servers. Validate with:

cat ~/Library/Application\ Support/Claude/claude_desktop_config.json | python3 -m json.tool

Check that npx works. Open a terminal and run npx -y toolradar-mcp. If it errors (missing Node.js, npm not found), fix that first. Claude Desktop uses the same Node.js as your terminal.

Check that you fully quit Claude Desktop. On macOS, closing the window does not stop the app. Use Cmd+Q or right-click the dock icon and select Quit. Then reopen.

"Permission denied" or "command not found"

Node.js is not in Claude Desktop's PATH. This happens frequently on macOS when Node was installed via nvm, Homebrew, or fnm. Fix by using the full path to npx:

{
  "command": "/usr/local/bin/npx",
  "args": ["-y", "toolradar-mcp"]
}

Find your npx path: which npx (macOS/Linux) or where npx (Windows).

For nvm users, the path is typically:

~/.nvm/versions/node/v22.x.x/bin/npx

"The server connects but Claude never calls the tools"

Claude decides whether to call a tool based on relevance. If you ask "write me a poem," it will not call Toolradar — there is no need. Ask something that requires the tool: "Compare Notion and Clickup" or "What project management tools are free?"

If Claude still does not call tools, try being explicit: "Use the Toolradar MCP server to look up Figma's pricing."

"Error: TOOLRADAR_API_KEY is not set"

The env block in your config is not reaching the server. Double-check:

  • The env key is inside the specific server's object, not at the top level
  • Key names are case-sensitive (TOOLRADAR_API_KEY, not toolradar_api_key)
  • The value is a string in double quotes
  • No trailing commas after the last key-value pair

"ENOENT: no such file or directory"

The npx command could not download or find the package. Common causes:

  • No internet connection (npx needs to download the package on first run)
  • Corporate proxy blocking npm registry access
  • Disk full

Fix: run npx -y toolradar-mcp in your terminal first to verify the package downloads correctly.

Server works once, then stops

Some MCP servers crash after a period of inactivity. Claude Desktop will restart them automatically on the next tool call, but there can be a delay. If a server is consistently unstable, check for updates: npx -y toolradar-mcp@latest.

Security Notes

  • MCP servers run locally as subprocesses with your user permissions
  • Each server only sees the environment variables you pass in its env block — not your full shell environment
  • API keys in the config file are stored in plain text — keep the file readable only by your user
  • Servers that use Docker ("command": "docker") run in container isolation
  • Start with read-only servers (Toolradar, Brave Search) before adding servers with write access (GitHub, Filesystem)
  • Review what permissions each server requests — the MCP security guide covers this in depth

What to Do After Setup

Once your first MCP server is working, here is how to get the most out of it.

Combine multiple servers. The real power of MCP is chaining tools. With Toolradar + Brave Search + GitHub installed, you can ask Claude: "Find the best open-source alternatives to Datadog, check their GitHub stars, and create an issue in my repo summarizing the options." Claude orchestrates calls across all three servers automatically.

Use it in real workflows. Some practical patterns:

  • Stack decisions: "Compare Supabase vs PlanetScale vs Neon for a Next.js app" → Toolradar handles the comparison
  • Vendor evaluation: "Find CRM tools under $20/user with API access and SOC 2 compliance" → filtered search with pricing
  • Fact-checking: "Does Vercel still have a free tier? What are the limits?" → verified data, not training data guesses
  • Code context: Have Claude Code use Toolradar to look up API pricing before you commit to a dependency

Explore more servers. Our curated lists by use case:

Understand the protocol. If you want to know what is happening under the hood:

If you are new to MCP, install these three:

ServerWhat it addsRisk level
Toolradar MCPSoftware tool search, comparison, pricingRead-only, safe
Brave SearchLive web searchRead-only, safe
GitHubRepository managementRead/write, scope via token

This gives Claude the ability to search for tools, browse the web, and manage your code — covering most developer workflows.

Also: Claude Code (CLI)

If you use Claude Code (the CLI), MCP setup is simpler:

claude mcp add toolradar -- npx -y toolradar-mcp

No config file editing needed. The server is added to your Claude Code configuration automatically. See our full Claude Code MCP setup guide for more servers optimized for the terminal.

Looking for servers to install? 25 best MCP servers for 2026 →

New to MCP? What is an MCP server? →

Concerned about security? MCP security best practices →

mcpclaude-desktopsetuptutorialhow-toconfiguration
Share this article