Where the config lives
- Project:
.cursor/mcp.json - Global:
~/.cursor/mcp.json
Servers go under the mcpServers key.
What Cursor can run
- Local servers (stdio)
- Remote servers (HTTP)
- Remote servers (SSE)
504 of the 508 servers in the catalog run natively in Cursor.
Step by step
- Create `.cursor/mcp.json` in your project (or `~/.cursor/mcp.json` for every project).
- Add each server under `mcpServers`: `command`/`args` for local servers, `url` for remote ones.
- Open Cursor Settings → MCP and toggle the server on.
Reloading: Cursor detects changes to mcp.json; toggle the server off and on in Settings → MCP if it doesn't.
Example: the Filesystem server in Cursor
The official reference server for file access. Replace the directory with the folder you want the assistant to see.
Create / edit .cursor/mcp.json in your project
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/path/to/allowed/directory"
]
}
}
}Troubleshooting
- `npx` is not found, or the server exits immediately on Windows
- Windows launches `npx` through cmd. Use `"command": "cmd"` with `"args": ["/c", "npx", "-y", "<package>"]`, and make sure Node.js 18+ is on the PATH of the user the client runs as.
- `SyntaxError` or `Unsupported engine` when the server starts
- Most MCP servers need Node.js 18 or newer (`node -v`). If you use nvm, the client may not see your shell's Node: point `command` at the absolute path of `npx`.
- The server shows a red dot in Settings → MCP
- Click it to see the error output. Most often the package name is wrong or a required argument (such as an allowed directory) is missing.
- The server starts but every tool call fails with 401 or 403
- Its API key is missing or wrong. Put it in the server's `env` block (or the header for remote servers) — never in a file you commit.
Official documentation: Cursor MCP docs
Setting up several servers at once?
Tick them in the catalog and the setup builder merges them into one Cursor config.
Open the setup builder for Cursor