Exact error
Match the message before using the fix
Failed to reconnect to plugin:playwright:playwrightMCP error -32000: Connection closedClaude Code rewrites /c to C:/ in the MCP commandQuick answer
Start here
Bypass the affected plugin command on native Windows and register Playwright MCP through its JavaScript entry point with `node`. The reporter confirmed that a direct `node .../@playwright/mcp/cli.js` configuration connected, while the plugin and `cmd /c` form failed after `/c` became `C:/`. Back up Claude configuration first because package paths vary by installation.
Diagnosis
Why it happens
- The failing report shows the Windows command-switch `/c` serialized as the path-like value `C:/`.
- The Playwright plugin then cannot start or reconnect, surfacing a generic `-32000` connection-closed error.
- Error `-32000` is generic; only use this page when the logs also show the Playwright plugin or `/c` rewrite signature.
Safest first
Fixes, in order
Run the Playwright MCP JavaScript entry point with Node
Applies when: Best match when logs show `/c` changed to `C:/`
The upstream reporter installed the Playwright MCP package and configured Claude to launch its CLI file directly with Node, avoiding the broken command-switch serialization.
- Back up your Claude configuration.
- Install the official Playwright MCP package in a stable directory.
- Locate `@playwright/mcp/cli.js` in that installation.
- Configure the MCP command as `node` and pass the full CLI path plus any Playwright arguments.
- Restart Claude Code and check the MCP connection.
node D:/path/to/node_modules/@playwright/mcp/cli.js --cdp-endpoint http://127.0.0.1:9222Expected: Claude reports the Playwright MCP as connected and no longer rewrites a `/c` argument.
Remove the broken plugin entry before adding the direct command
Applies when: Use when Claude repeatedly reconnects the old plugin definition
Two definitions can make it unclear which server is failing. Keep a backup and remove only the affected Playwright entry.
- Export or copy the current Claude configuration.
- Disable or remove the failing Playwright plugin entry.
- Add the direct Node-based server with a distinct name.
- Restart Claude Code and inspect that server alone.
Expected: Only one Playwright server definition starts, using Node directly.
Check the browser endpoint separately
Applies when: Use when the direct server starts but Playwright still cannot attach
A valid MCP process can still fail if the CDP endpoint is not listening. This is a separate failure from the `/c` rewrite.
- Start the browser with remote debugging enabled if your setup requires it.
- Open the configured CDP endpoint locally.
- Start the direct Node MCP command manually and confirm it remains running.
- Reconnect from Claude Code.
Expected: The MCP process stays running and the configured endpoint responds.
Verification
Prove the fix worked
- Inspect the effective MCP command and confirm no argument became `C:/`.
- Run the exact Node command manually; it should remain active rather than exit immediately.
- Reconnect in Claude Code and run a harmless browser inspection action.
Escalation
If it still fails
- If there is no `/c` rewrite in the logs, diagnose `-32000` as a separate transport or server-exit problem.
- Record Claude Code, Node, Playwright MCP, and Windows versions plus the sanitized effective configuration.
- Do not paste secrets, tokens, or browser profile credentials into an issue.
Scope
Environment and version notes
- The confirmed report used native Windows 11 and Playwright MCP 0.0.68.
- The issue was closed as stale/not planned; that is not evidence of a shipped fix.
- Sources rechecked August 20, 2026.
Evidence
Sources
Source labels describe the evidence available on the checked date. A closed issue is not automatically a shipped fix.