Fixes › Claude Desktop, Cursor

MCP server crashes because the client uses an old Node version

Claude DesktopCursor

The error

SyntaxError: Unexpected token '?' • ReferenceError: fetch is not defined • ERR_REQUIRE_ESM

Why it happens

With nvm installed, a GUI app may pick up an old system Node (e.g. v16) instead of your nvm default. Modern MCP servers need Node 18+ and often 20+ (Playwright MCP requires Node 20 or newer since version 0.0.86, released November 18, 2026). The official reference servers (Filesystem, Memory, Sequential Thinking and Everything) need Node 24 or newer since version 2.0.0, released October 19, 2026, and their maintainers now ask for Node 24.22.1 or 26.12.1 or later because of the October 2026 Node security releases.

How to fix it

  1. Check which Node the client sees
    Temporarily set command to node with args ["-v"] and read the log, or compare /usr/local/bin/node -v with node -v.
  2. Point at a modern Node directly
    Use the absolute npx path from your nvm version and put its bin folder first in PATH.
    {
      "command": "/Users/you/.nvm/versions/node/v24.22.1/bin/npx",
      "args": ["-y", "@upstash/context7-mcp"],
      "env": { "PATH": "/Users/you/.nvm/versions/node/v24.22.1/bin:/usr/bin:/bin" }
    }
  3. Or upgrade the system Node
    Install a current LTS from nodejs.org so every app gets it. For the official reference servers, that means Node 24.22.1 or 26.12.1 or later. npm will not warn you about an older Node 24, so check with node --version.

Related servers

Sources