Cursor 0.40.x – 0.42.xMCP / Plugins

Cursor "MCP server failed to start — spawn npx ENOENT"

Error: MCP server failed to start (code -32000): spawn npx ENOENT
Affected versions
0.40.x – 0.42.x
Fixed in
Last verified
Cursor 0.42.3

Root cause

Cursor launches MCP stdio servers with the command from mcp.json, but `npx` is not on the PATH that the editor process inherits (common on macOS GUI launches and Windows where Node is installed per-user).

How to reproduce

Add an MCP server using `npx -y some-mcp` in mcp.json, reload, server shows red 'failed to start'.

Solutions (3)

Ordered by community votes. Always check the verified version before applying.

84
#1Applies to 0.42.x

Use the absolute path to `npx` instead of bare `npx`. Find it with `which npx` (macOS/Linux) or `where npx` (Windows), then set `"command": "/full/path/to/npx"` in mcp.json.

Last verified: Cursor 0.42.3 · community

41
#2Applies to 0.42.x

On Windows, set `"command": "cmd"` and `"args": ["/c", "npx", "-y", "some-mcp"]` so the shell resolves npx.

Last verified: Cursor 0.42.1 · community

23
#3Applies to 0.41.x – 0.42.x

Launch Cursor from a terminal (`open -a Cursor` / `cursor .`) so it inherits your shell PATH including nvm.

Last verified: Cursor 0.42.0 · community

Related errors