AgentFixFind a fix
Claude CodePartial workaroundUpdated Aug 20, 2026

Claude Desktop cancels MCP initialize after 60 seconds

Diagnose Claude Desktop MCP initialize cancellations when an npx, uvx, or pipx package runner spends more than 60 seconds resolving dependencies.

Exact error

Match the message before using the fix

Message from client: method="notifications/cancelled"Client transport closedMCP initialize cancelled after 60 seconds

Quick answer

Start here

Compare the MCP log timestamps first. If `initialize` is cancelled almost exactly 60 seconds after it starts while the package runner is still downloading dependencies, run the same package command once outside Claude Desktop to warm its cache, then restart Desktop. Pinning the server and dependency versions can reduce repeated cold resolution. The upstream issue remains open and does not confirm a client-side timeout setting.

Diagnosis

Why it happens

  • The reported Claude Desktop build cancelled the initialize request at a fixed 60-second boundary.
  • For package-runner commands, the server process may not exist yet because uvx, npx, or pipx is still resolving and downloading packages.
  • A warm cache can start in seconds while a cold dependency refresh takes longer than the client deadline; ordinary network and server crashes can produce similar UI symptoms without the exact timing.

Safest first

Fixes, in order

01

Confirm the exact 60-second initialize boundary

Applies when: When an stdio MCP server disappears from Claude Desktop after a slow launch

The source report distinguishes this problem by log timing, not by a generic failed-to-connect badge.

  1. Open the MCP server log for the affected configuration.
  2. Find the timestamp for the client `initialize` message and the later `notifications/cancelled` or `Client transport closed` message.
  3. Check whether the interval is almost exactly 60 seconds and whether package downloads are still in progress.
  4. If the interval or stage differs, diagnose that error instead of applying this workaround.

Expected: The log shows a cold package install crossing the 60-second initialize boundary.

02

Pre-warm the package runner cache

Applies when: uvx, npx, or pipx-run configurations that succeed when warm

The reporter measured a cold start around 110 seconds and warm starts of 7–26 seconds.

  1. Close Claude Desktop so it does not launch competing package downloads.
  2. Run the exact configured package-runner command manually in a terminal and allow dependency installation to finish.
  3. Stop the manually started MCP server after it reaches its ready state.
  4. Restart Claude Desktop and inspect the next initialize timing.

Expected: The warmed server answers initialize before the 60-second cancellation and its tools appear in Desktop.

03

Pin the server package and volatile dependencies

Applies when: Configurations that repeatedly invalidate their environment after upstream releases

A bounded version reduces surprise resolution work, but the exact pin syntax belongs to the package runner and server you use.

  1. Record the package versions from a known working warm launch.
  2. Use the package runner's documented exact-version syntax in the MCP command.
  3. Test the pinned command manually before changing the Desktop configuration.
  4. Review the pin intentionally when applying security or compatibility updates.

Expected: Routine Desktop restarts reuse a stable environment instead of resolving a new dependency tree.

Verification

Prove the fix worked

  1. Restart Claude Desktop with a cold app session but a warmed package cache.
  2. Confirm the MCP log records an initialize response before 60 seconds.
  3. Call one harmless tool from the server and confirm it returns normally.

Escalation

If it still fails

  • Do not assume `MCP_TIMEOUT` or a `timeout` field changes this initialize deadline; the source did not confirm such an override.
  • Capture the package runner, server package, cold and warm timing, and the exact cancellation log.
  • If the process fails before `initialize`, investigate spawn, PATH, or package-runner errors instead.

Scope

Environment and version notes

  • The detailed reproduction used Claude Desktop 1.25927.0 on macOS with uvx; it does not prove identical Windows behavior.
  • The issue remained open on August 20, 2026. Claude Code CLI 2.1.237 was current in npm, but CLI and Desktop version lines are different products.
  • 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.