Set up MCP servers for Claude (Desktop and Claude Code)
Connect Claude to your files, Notion, GitHub and other tools with the Model Context Protocol. Exact config paths and commands from the official MCP and Claude Code docs.
Who it's for: Anyone who keeps copy-pasting data into Claude. Part A (Claude Desktop) needs no coding; Part B (Claude Code) is for developers comfortable in a terminal.
Time: 20 to 40 minutes · Cost: Free (MCP is open source); requires a Claude plan or API access you already have
Tools: Model Context Protocol, Claude, Claude Code, Cursor, Cline
Prerequisites:
- Claude Desktop (macOS, Windows or Linux) and/or Claude Code installed
- Node.js LTS (check with node --version)
- Accounts for any service you want to connect, such as Notion
The Model Context Protocol (MCP) is the closest thing AI has to a USB port: one standard way to plug tools and data into an assistant. Instead of pasting a spreadsheet into Claude, you connect a server once and Claude can read (and, with permission, act on) the real thing. This playbook covers both the no-code path in Claude Desktop and the developer path in Claude Code, using the official MCP user quickstart and the Claude Code MCP reference.
Step 1: Decide what Claude should reach
Start from a pain, not a server list. The Claude Code docs put it well: connect a server when you find yourself copying data into chat from another tool. Good first candidates:
- A folder of documents (contracts, notes, exports) → Filesystem server.
- Your wiki or task tracker (Notion, Asana, Linear) → the vendor’s remote MCP server.
- Your codebase’s surrounding systems (GitHub issues, Sentry, a Postgres database) → for developers in Claude Code.
Write down the one task you want to stop doing manually, e.g. “summarize every PDF in my Contracts folder into a table.” You’ll test against that.
Step 2: Install Node.js
Many MCP servers, including the Filesystem server, run through Node’s npx. In a terminal:
node --version
If that errors, install the LTS version from nodejs.org, then reopen the terminal and check again.
Step 3: Open the Claude Desktop config
In Claude Desktop, open the Claude menu in your system menu bar (not the settings inside the chat window) → Settings… → Developer tab → Edit Config. This creates the file if needed. It lives at:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Step 4: Add the Filesystem server
Replace the file’s contents with this, swapping username for your real username and listing only folders you’re comfortable with Claude reading and modifying:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/Users/username/Desktop",
"/Users/username/Downloads"
]
}
}
}
On Windows, use paths like "C:\\Users\\username\\Desktop" (double backslashes inside JSON). The -y flag lets npx install the package without prompting; everything after the package name is the list of allowed directories. Paths must be absolute.
Security note from the official guide: the server runs with your account’s permissions, so it can do anything you can do in those folders. Point it at a dedicated working folder rather than your whole home directory.
Step 5: Restart and verify the connector
Fully quit Claude Desktop (not just close the window) and reopen it. Then click the “Add files, connectors, and more /” indicator at the bottom-left of the message box, hover Connectors, click Manage connectors, and select filesystem to see its tools.
Now test with your Step 1 task, for example: “List the PDFs in my Downloads folder and make a table of file name, date and a one-line summary.” Claude will ask for approval before each file operation. Read those prompts; that approval is your safety net.
Step 6: Add a remote server in Claude Code
Developers can connect servers from the terminal. Remote HTTP servers are the recommended transport:
# Basic syntax
claude mcp add --transport http <name> <url>
# Real example from the docs: Notion
claude mcp add --transport http notion https://mcp.notion.com/mcp
# With a bearer token
claude mcp add --transport http secure-api https://api.example.com/mcp \
--header "Authorization: Bearer your-token"
The SSE transport is deprecated; use it only for services that still expose nothing else. Browse reviewed connectors in the Anthropic Directory (claude.ai/directory); remote servers listed there can be added the same way.
Then ask Claude Code something that needs the server: “Read the spec page for the onboarding redesign in Notion and list the open questions.”
Step 7: Share project servers with your team
Claude Code reads server definitions from JSON as well as the CLI, including a project-level .mcp.json. Committing that file lets teammates get the same servers when they open the repo. Two gotchas from the docs:
- An entry with a
urlbut notypeis treated as a stdio server and skipped with an error. Always set"type": "http"(streamable-httpis accepted as an alias). - Never commit tokens. Keep secrets in environment variables or each person’s local config.
Step 8: Troubleshoot with logs
If a server doesn’t appear:
- Quit and restart Claude Desktop completely.
- Validate the JSON (a single missing comma breaks it).
- Confirm every path is absolute and exists.
- Run the server by hand to see errors:
npx -y @modelcontextprotocol/server-filesystem /Users/username/Desktop. - Read the logs: macOS
~/Library/Logs/Claude, Windows%APPDATA%\Claude\logs.mcp.logcovers connections;mcp-server-SERVERNAME.logholds each server’s stderr.
On Windows, if logs mention ${APPDATA}, add the expanded APPDATA path to the server’s env block, and make sure npm is installed globally (npm install -g npm).
Pitfalls
- Granting your whole drive. Scope folders tightly; you can always add more.
- Editing the in-app settings instead of the menu-bar Settings. The developer config lives under the system menu bar’s Claude → Settings.
- Not fully quitting. Config is only read at launch.
- Trusting every server. Third-party servers can be malicious or vulnerable to prompt injection, especially ones that fetch web pages or email. Prefer official vendor servers and directory-reviewed connectors.
- Rubber-stamping approvals. The per-action approval only protects you if you read it.
Where to go next
The same servers work in other MCP clients such as Cursor and Cline. Builders can expose their own product as an MCP server so agents can use it; pair that with our OpenAI Agents SDK playbook to see the agent side.
Worked example: a contracts folder assistant
Here’s how a small agency used this setup in under half an hour. They created a dedicated folder, ~/AI-Workspace/Contracts, copied 30 client agreements into it as PDFs, and pointed the Filesystem server at that folder only. Their first prompt was:
For every PDF in AI-Workspace/Contracts, extract client name, start date, renewal date, notice period and monthly fee. Put the results in a table, then save it as renewals.csv in the same folder. Flag any contract where the notice period ends in the next 60 days.
Claude asked for approval to list the folder, read each file and write the CSV. The team checked five rows against the originals (all correct; one fee was ambiguous because the contract had two rates, which Claude flagged). The result replaced a quarterly half-day spreadsheet chore.
Their next step was a remote server: they connected their task tracker so Claude could create a “renewal review” task for each flagged contract, still with approval on every action.
Checklist before you add more servers
- Is this server from the vendor itself or a reviewed directory? If not, read its source or skip it.
- Does it need write access, or would read-only do?
- Where are its credentials stored, and who can see that config file?
- Have you tested the one task you added it for?
- Do teammates know which servers are connected, and what they can touch?
Treat each new server like installing a browser extension with access to your work: useful, but only when you trust it and know what it does.
FAQ
What is an MCP server?
A program that exposes tools and data to an AI application through the open Model Context Protocol. Claude, and many other clients, can then call those tools, with your approval, instead of you pasting data into the chat.
Where is the Claude Desktop MCP config file?
On macOS it is ~/Library/Application Support/Claude/claude_desktop_config.json and on Windows %APPDATA%\Claude\claude_desktop_config.json. Open it from Claude's Settings, Developer tab, Edit Config.
How do I add a remote MCP server to Claude Code?
Run claude mcp add --transport http <name> <url>, for example claude mcp add --transport http notion https://mcp.notion.com/mcp. HTTP is the recommended transport; SSE is deprecated.
Is MCP safe?
Servers run with your permissions and Claude asks before each action, but you should only install servers you trust. Servers that fetch external content can expose you to prompt injection, so review approvals carefully.
Do MCP servers work outside Claude?
Yes. MCP is an open standard supported by many clients, including Cursor, Cline and several agent frameworks.
Last checked against official docs: October 2026 (modelcontextprotocol.io user quickstart; Claude Code MCP reference). Prices and UI labels change; confirm on each vendor's site.