Each AI client keeps its MCP server list in its own file. This page lists the file for seven clients, the top-level key inside it, and where the file sits. Each row comes from that client’s own documentation, read on 2026-11-25. Where a client’s docs give no path for an OS, the table says so.
Where each client keeps its MCP servers
| Client | File | Top-level key | Path |
|---|---|---|---|
| Claude Code | .mcp.json (project, shared) and ~/.claude.json (user and local) | mcpServers | .mcp.json at the project root. ~/.claude.json in your home folder. The docs give no separate Windows path. |
| Claude Desktop | claude_desktop_config.json | mcpServers | macOS: ~/Library/Application Support/Claude/claude_desktop_config.json. Windows: %APPDATA%\Claude\claude_desktop_config.json. Linux: ~/.config/Claude/claude_desktop_config.json. |
| Codex | config.toml | [mcp_servers.<name>] tables | ~/.codex/config.toml. Per project: .codex/config.toml, trusted projects only. The docs give no Windows path. |
| Cursor | mcp.json | mcpServers | Global: ~/.cursor/mcp.json. Per project: .cursor/mcp.json in the project folder. |
| VS Code | .vscode/mcp.json (workspace) | servers | The workspace file is .vscode/mcp.json in the project folder. VS Code’s docs say new Copilot setups use other files: ~/.copilot/mcp-config.json (top key mcpServers) or a workspace-root .mcp.json. |
| Hermes Agent | config.yaml | mcp_servers | ~/.hermes/config.yaml. The docs give no Windows path. |
| OpenClaw | openclaw.json | mcp.servers | ~/.openclaw/openclaw.json. The openclaw mcp commands read and write this section. |
Sources: Claude Code MCP docs (scopes: local, project, user); Claude Desktop local MCP servers, Model Context Protocol docs (the three OS paths; the VS Code configuration reference repeats them); Codex MCP docs; Cursor MCP docs (mcp.json, STDIO fields) and the VS Code configuration reference, which lists the Cursor global and workspace paths; VS Code MCP servers and VS Code MCP configuration reference; Hermes MCP docs; OpenClaw MCP registry docs. The OpenClaw file name comes from OpenClaw’s configuration docs.
Minimal examples
The same server, a local filesystem server, written for each client. Replace the path with your own.
Claude Desktop (claude_desktop_config.json):
1{
2 "mcpServers": {
3 "filesystem": {
4 "command": "npx",
5 "args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/you/Desktop"]
6 }
7 }
8}
Claude Code (.mcp.json at the project root, or the same entry added with claude mcp add):
1{
2 "mcpServers": {
3 "filesystem": {
4 "type": "stdio",
5 "command": "npx",
6 "args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/project"]
7 }
8 }
9}
Codex (~/.codex/config.toml):
1[mcp_servers.filesystem]
2command = "npx"
3args = ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/project"]
Cursor (~/.cursor/mcp.json or .cursor/mcp.json):
1{
2 "mcpServers": {
3 "filesystem": {
4 "command": "npx",
5 "args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/project"]
6 }
7 }
8}
Hermes Agent (~/.hermes/config.yaml):
1mcp_servers:
2 filesystem:
3 command: "npx"
4 args: ["-y", "@modelcontextprotocol/server-filesystem", "/home/user/projects"]
VS Code’s workspace file uses the key servers, not mcpServers. OpenClaw’s section is mcp.servers, and the docs show its entries through the openclaw mcp commands, so this page gives no hand-written example for it.
Things that catch people out
- Wrong key. Claude, Cursor and VS Code use different top-level keys (
mcpServersorservers). Codex and Hermes use their own format. Check the key against the table above before you edit a file. - Project files need approval. Claude Code asks before it uses a server from
.mcp.json. Codex reads a project.codex/config.tomlonly in a trusted project. - Hosted clouds read other files. Cursor’s docs say Cursor’s hosted Cloud Agents do not read
~/.cursor/mcp.json. They use servers set on the Cursor website. - Plugins are separate. Installing a VS Code agent plugin can bring its own servers. Those do not appear in your own file.
Where memory fits
An MCP server is a way to give an agent memory tools. Hindsight has an MCP endpoint: the Grok Bot integration README lists https://api.hindsight.vectorize.io/mcp (OAuth, no API key) as its server. For Hermes Agent and OpenClaw, the Hindsight plugin is the usual route and does not need an MCP entry; see the Hermes Agent config reference and the OpenClaw config reference. Limit: if you run your own Hindsight server and want an MCP client to reach it, the MCP endpoint must be public HTTPS with OAuth 2.1, according to Hindsight’s integration notes.
Scope
This page lists the main file per client. Clients can read more than one file (for example Claude Code’s user and local scopes both live in ~/.claude.json). The docs for each client are the authority if a path changes.