On macOS use ~/Library/Application Support/Claude/claude_desktop_config.json; on Windows use %AppData%/Claude/claude_desktop_config.json.
If you work with Claude for Desktop and want local tools, you will eventually need the configuration file that controls Model Context Protocol servers. This guide gives you fast, reliable paths for both macOS and Windows, plus quick open commands, safe editing tips, and fixes when things do not load. For deeper setup and diagnostics, see the MCP quickstart and Anthropic’s Desktop Extensions overview so you can go deeper when needed.
What The File Does
The file named claude_desktop_config.json tells Claude which MCP servers it may start, which command each server uses, and any arguments or environment variables they need. When the app launches, it reads this JSON and spins up those servers so the hammer icon shows in the compose bar. If the JSON is missing or broken, the servers do not load and the icon stays hidden.
Find The Claude Desktop Config File Paths (Windows & Mac)
Here are the default locations. Replace username with your account name on each system.
macOS Default Path
/Users/username/Library/Application Support/Claude/claude_desktop_config.json
You can jump straight there with Finder: press Shift + Command + G, paste ~/Library/Application Support/Claude/, and hit Enter. Some guides also show this path inside Claude’s own menu under Settings → Developer → Update Config, which opens the same file directly.
Windows Default Path
C:\Users\username\AppData\Roaming\Claude\claude_desktop_config.json
Open the folder fast with Win + R, type %AppData%\Claude, and press Enter. Any edits take effect on the next launch of Claude for Desktop.
Quick Ways To Open Or Create The File
Claude reads the file at launch. If it is missing, you can create it in the same folder shown above. Keep the name exact. Here are shortcuts that save time:
macOS
- Quit Claude for Desktop.
- Open Finder → Go to Folder… and paste
~/Library/Application Support/Claude/. - If
claude_desktop_config.jsondoes not exist, create a new file with that name. - Paste a minimal JSON block:
{ "mcpServers": {} } - Save, then reopen Claude.
Windows
- Exit Claude from the tray.
- Press Win + R, enter
%AppData%\Claude, and hit Enter. - Create or edit
claude_desktop_config.jsonwith Notepad. - Use the same minimal JSON shown above and save as UTF-8.
- Start Claude again.
Safe Editing Tips
Use a text editor that shows JSON errors. Keep paths absolute, not relative. Store long secrets in your shell or system keychain when a server supports it. Before risky edits, make a backup copy in the same folder, such as claude_desktop_config.backup.json. If the app refuses to load a server after an edit, restore the backup and retry with smaller changes.
VS Code users can set the file to JSON language mode and turn on format on save. Editor auto-indents and flags trailing commas, a common cause of silent load failures.
If you prefer a point-and-click path, Anthropic now supports Desktop Extensions, which install local MCP servers from a single file with no manual JSON. You can mix both styles: keep JSON for custom tools and use extensions for common ones.
Sample Entries You Can Copy
These snippets add a filesystem server with two directories. Adapt paths to your machine.
macOS Sample
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/username/Desktop", "/Users/username/Downloads"]
}
}
}
Windows Sample
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "C:\\Users\\username\\Desktop", "C:\\Users\\username\\Downloads"]
}
}
}
If a server needs environment variables, most wrappers let you add an env object under the server entry. Only include what you must and keep secrets out of version control.
Troubleshooting When The Hammer Icon Is Missing
Close the app and reopen. If the servers still do not appear, check these spots:
- Logs: macOS writes to
~/Library/Logs/Claude; Windows writes to%AppData%\Claude\logs. Openmcp.logfor clues. The user quickstart lists these paths and offers a simple manual start test. - Syntax: Run your JSON through a linter or paste into an editor that highlights errors.
- Absolute paths: Every path in
argsshould be a full path. - Node present: Many servers need Node.js. Confirm with
node --version. - Manual start: Try running the server command in Terminal or PowerShell to confirm it starts cleanly.
If logs say the command cannot be found, replace npx with the full Node path and a script path. If the server starts by hand but not in Claude, the path used inside JSON is the likely mismatch.
Common Path Pitfalls And Fixes
Spaces In Paths
On Windows, paths with spaces need quoting in the command shell. In JSON, keep the string quoted and avoid extra escapes beyond the backslashes shown in the sample. On macOS, spaces work as plain characters inside the JSON string.
Wrong Home Folder
On macOS, the tilde notation (~/) expands to the user folder. Inside JSON, prefer the full path (/Users/username) to avoid confusion when another user or process launches Claude.
“npx” Fails To Launch
Some users report npx failing due to path or permission issues. Switch to the full Node path plus a script, or install the server globally and call its entry point directly. If you get an error about permission on PowerShell, launch the terminal as Administrator once to test.
File Missing After Update
App updates do not overwrite the folder shown above. If your file seems gone, check you are on the right account and profile. Then search your drive for claude_desktop_config.json.
Wrong JSON Encoding
Save as UTF-8 without a BOM. Editors such as VS Code show the encoding in the status bar and let you switch with one click.
Mixed Slashes On Windows
Use double backslashes inside JSON for Windows paths, shown in the sample. A single backslash escapes characters and breaks the path.
Quick Checklist
- File lives in the user profile: Application Support on macOS, Roaming on Windows.
- Name stays exact:
claude_desktop_config.json. - JSON is valid and uses absolute paths.
- Logs confirm a clean start or show the failing command.
- Restart Claude after any edit.
Handy Table Of Paths And Open Shortcuts
| OS | Default Path | Fast Open |
|---|---|---|
| macOS | /Users/username/Library/Application Support/Claude/claude_desktop_config.json | Finder → Go to Folder → ~/Library/Application Support/Claude/ |
| Windows | C:\Users\username\AppData\Roaming\Claude\claude_desktop_config.json | Win + R → %AppData%\Claude |
Privacy And Backups
The config can hold local paths, API keys, and tokens. Keep it in your user profile and avoid syncing it to shared repos. When you back it up, store copies in a private location. If you rotate keys, scrub old values from the file or move them to environment variables when the server supports that pattern.
When Things Still Refuse To Load
Strip the file back to a single server entry and confirm it runs. Then add servers one by one. Watch for port conflicts and stale global installs. If your goal is a popular server, check for a desktop extension release; one click can replace the manual setup. Anthropic’s note on Desktop Extensions explains the flow in clear steps.
Recap
On macOS, the path sits under Library in your user folder. On Windows, the file lives under Roaming in your AppData tree. Open the folder with the shortcuts above, keep JSON tidy, and restart the app to load servers each time. If you need deeper guidance or test commands, the MCP quickstart shows the expected behavior and log locations.
