Skip to main content
guidesSource-backedReview first Safety Privacy

Fix Claude MCP Error -32000

Resolve Claude Desktop MCP server connection errors fast. Step-by-step fixes for error -32000, disconnections, and configuration issues with proven solutions.

by JSONbored·added 2025-10-27·
HarnessClaude Code
Review first review before installing

Open the source and read safety notes before installing.

Citation facts

Source-backed facts for citing this resource, derived directly from the registry — also available as plain text for AI assistants.

Source URLs
https://code.claude.com/docs/en/mcp, https://github.com/JSONbored/awesome-claude/blob/main/content/guides/fix-mcp-connection-errors.mdx
Safety notes
Troubleshooting steps run MCP servers as local subprocesses or connect to remote servers, which can execute tools and reach external systems; review what each server is allowed to do before connecting it.
Privacy notes
MCP authentication uses OAuth tokens and API keys, and connected servers can receive project data; keep secrets in .mcp.json env or --env (not committed), and review each server's data access.
Author
JSONbored
Claim status
unclaimed
Last verified
2025-10-27

Decision playbook

Review trust signals before you adopt

Signals are present but mixed. Use the checklist below to confirm the source and operational safety for your environment.

Compare context
Selected

0

Current score

78

Baseline

Delta

No baseline selected

No major trust-signal divergence detected in the current selection.

Source and provenance checks

Complete

Confirm ownership and provenance before trusting install instructions.

  • Source link availableRequired

    Open the canonical repository and verify ownership.

    Done
  • Source provenance statusRequired

    Marked as source-backed.

    Done
  • Metadata reviewed

    Registry metadata indicates a reviewed listing.

    Done

Safety and privacy checks

Complete

Validate risk disclosures before installation or API wiring.

  • Safety notes presentRequired

    Review the listed safety guidance before running commands.

    Done
  • Privacy notes presentRequired

    Review data handling notes before connecting accounts or secrets.

    Done
  • Trust level risk gateRequired

    Trust level does not block evaluation.

    Done

Package and install checks

Needs review

Check package metadata and artifact integrity signals.

  • Install payload available

    Install or copy payload is available for review.

    Done
  • Package verification flag

    No package verification flag provided.

    Pending
  • Checksum metadata

    No checksum provided for downloaded artifact.

    Pending

Compare-driven decision checks

Needs review

Use compare context to validate trade-offs before adoption.

  • Compare tray has multiple entries

    Add at least one more entry to compare trust differences.

    Pending
  • Baseline comparison available

    No baseline peer selected yet.

    Pending
  • Diverging trust signals identified

    No major trust-signal divergence found.

    Pending

Setup at a glance

Copy & paste

Copy-ready — paste the snippet to get started.

Install command

Not provided

Config snippet

Not provided

Copy snippet

Provided

Prerequisites

None

Platforms

1 listed

Difficulty

12/100

Adoption plan

Balanced adoption plan

Current risk score 16/100. Use staged verification before broader rollout.

Risk 16

Pre-adoption checks

Validate source and review signals before any execution.

  • Confirm source provenanceRequired

    Source URL/provenance metadata is present.

    Done
  • Confirm metadata review state

    Listing has review metadata.

    Done
  • Verify install payload

    Install/config payload exists and can be inspected.

    Done

Security checks

Confirm safety, privacy, and package integrity signals.

  • Review safety notesRequired

    Safety notes are present.

    Done
  • Review privacy notesRequired

    Privacy notes are present.

    Done
  • Verify package integrity metadata

    No package verification/checksum metadata.

    Pending

Rollout

Adopt in controlled steps based on the selected plan.

  • Run in isolated sandbox firstRequired

    Use a constrained sandbox and observe behavior across multiple tasks.

    Pending
  • Roll out graduallyRequired

    Roll out to a small cohort before wider usage.

    Pending
  • Set monitoring and fallback

    Define rollback path and monitor errors after adoption.

    Pending

Evidence readiness

Evidence readiness matrix · balanced

Required evidence gates are covered (5/6 signals complete).

Risk 15

Source provenance

Present

Source repository/provenance is listed.

Required in this preset

Metadata review

Present

Review metadata is present.

Required in this preset

Safety notes

Present

Safety notes are present.

Required in this preset

Privacy notes

Present

Privacy notes are present.

Optional in this preset

Package integrity

Missing

Package integrity metadata is missing.

Optional in this preset

Install payload

Present

Install payload is available.

Required in this preset

Required evidence gates are covered for this preset.

Decision timeline

Decision timeline · balanced

5/6 steps complete with no blocking gaps for this preset.

Risk 14

triage

Confirm source provenanceRequired

Source/provenance metadata is available.

Done

triage

Check metadata review statusRequired

Review metadata is available.

Done

verify

Review safety notesRequired

Safety notes are available.

Done

verify

Review privacy notes

Privacy notes are available.

Done

verify

Validate package integrity metadata

Package integrity metadata is missing.

Pending

rollout

Verify install payload and commandsRequired

Install payload is available.

Done

No required blockers for this timeline preset.

Safety & privacy surface

Safety & privacy surface

1 safety and 1 privacy notes across 2 risk areas. Review closely: credentials & tokens, network access.

2 areas
  • SafetyNetwork accessTroubleshooting steps run MCP servers as local subprocesses or connect to remote servers, which can execute tools and reach external systems; review what each server is allowed to do before connecting it.
  • PrivacyCredentials & tokensMCP authentication uses OAuth tokens and API keys, and connected servers can receive project data; keep secrets in .mcp.json env or --env (not committed), and review each server's data access.

Safety notes

  • Troubleshooting steps run MCP servers as local subprocesses or connect to remote servers, which can execute tools and reach external systems; review what each server is allowed to do before connecting it.

Privacy notes

  • MCP authentication uses OAuth tokens and API keys, and connected servers can receive project data; keep secrets in .mcp.json env or --env (not committed), and review each server's data access.

Schema details

Install type
copy
Reading time
2 min
Difficulty score
12
Troubleshooting
Yes
Breaking changes
No
Skill and platform metadata
Retrieval sources
https://code.claude.com/docs/en/mcphttps://code.claude.com/docs/en/troubleshooting
Full copyable content
## Overview

An MCP server that won't connect shows up the same way most of the time: you run `/mcp` inside Claude Code and the server is listed as **failed**, **pending**, or **connected with zero tools**. The underlying cause is almost always one of a handful of things: a relative path that resolves against the wrong directory, missing or wrong authentication, environment variables that never reach the server process, or a project-scoped server that was never approved.

This guide walks through diagnosing and fixing those failures using the built-in commands Claude Code ships with: `/mcp`, `claude mcp list`, `claude mcp get`, and `claude --debug mcp`.

> **Problem Summary**
>
> **Symptoms:** Server shows as failed or pending in `/mcp`, connects but lists zero tools, or returns 401/403 auth errors
> **First command to run:** `/mcp` inside Claude Code, then `claude --debug mcp` from your shell
> **Estimated fix time:** 5-10 minutes for most cases

## First: see what actually loaded

Before changing any config, find out what state the server is in. Run these in order.

```bash
# Inside a Claude Code session: status of every server, tool counts, approval state
/mcp

# From your shell: list all configured servers
claude mcp list

# From your shell: full details for one server (transport, URL, command/args, OAuth state)
claude mcp get my-server
```

What the `/mcp` panel tells you:

- A **failed** server started and exited, or never connected. Usually a bad command/path, a missing dependency, or an auth rejection.
- A **pending** server is mid-connection. For HTTP/SSE servers, Claude Code retries the initial connection with exponential backoff (up to three attempts on transient errors like 5xx, connection refused, or timeout) before marking it failed. Auth and not-found errors are **not** retried.
- A **`Pending approval`** server is a project-scoped server from `.mcp.json` waiting for your one-time approval.
- A **connected** server with **zero tools** started fine but isn't returning a tool list.

For the real error text, run Claude Code with MCP debug logging, which surfaces the server's stderr:

```bash
claude --debug mcp
```

## Troubleshooting table

| Symptom | Likely cause | Fix |
| --- | --- | --- |
| Server **fails to start** only from certain directories | `command`/`args` uses a **relative** path, which resolves against your launch directory, not `.mcp.json` | Use **absolute paths** for local scripts. `PATH` executables like `npx`/`uvx` work as-is. |
| Project server **doesn't appear** at all | The one-time approval prompt was dismissed | Run `/mcp` to approve, or `claude mcp reset-project-choices` to reset choices. |
| Server **starts without its API key / env vars** | Variables were put in `settings.json` `env`, which does **not** propagate to MCP child processes | Set per-server `env` inside `.mcp.json`, or pass `--env KEY=value` to `claude mcp add`. |
| Servers in `.mcp.json` **never load** | File is inside `.claude/` or uses Claude Desktop's format | Project MCP config lives at the **repository root** as `.mcp.json`. |
| Remote server flagged as **needing authentication** | Server responded with `401`/`403` | Run `/mcp` and complete the OAuth 2.0 browser login flow. |
| Remote server **connection failed** even with a token | You set `headers.Authorization` and the server rejected it | Verify the token, or remove the header to fall back to OAuth. |
| `Incompatible auth server: does not support dynamic client registration` | Server needs pre-configured OAuth credentials | Add the server with `--client-id` and `--client-secret`. |
| Connected but **zero tools** | Server started but isn't returning a tool list | Select **Reconnect** from `/mcp`; if still zero, run `claude --debug mcp`. |
| Server times out before it finishes starting | Startup is slower than the default timeout | Increase it: `MCP_TIMEOUT=10000 claude`. |

## Fix 1: Use absolute paths for local (stdio) servers

The single most common stdio failure is a relative path in `command` or `args`. It works from the project root and breaks everywhere else. Use an absolute path, or rely on a `PATH` executable like `npx`:

```bash
# Good: PATH executable, no path issues
claude mcp add --transport stdio airtable \
  --env AIRTABLE_API_KEY=YOUR_KEY \
  -- npx -y airtable-mcp-server
```

Note the `--` before the command: it separates Claude's own flags (`--transport`, `--env`, `--scope`) from the command that runs the server. Everything after `--` is passed to the server untouched.

## Fix 2: Put environment variables where the server can see them

Secrets in `settings.json` `env` do **not** reach MCP child processes. Pass them at add time with `--env`, or set per-server `env` directly in `.mcp.json`. Claude Code expands `${VAR}` and `${VAR:-default}` in `command`, `args`, `env`, `url`, and `headers`:

```json
{
  "mcpServers": {
    "api-server": {
      "type": "http",
      "url": "${API_BASE_URL:-https://api.example.com}/mcp",
      "headers": {
        "Authorization": "Bearer ${API_KEY}"
      }
    }
  }
}
```

## Fix 3: Authenticate remote servers over OAuth

Claude Code marks a remote server as needing authentication when it responds with `401` or `403`, then flags it in `/mcp` so you can finish the OAuth 2.0 flow:

```bash
# Add a remote HTTP server that requires auth, then run /mcp to log in
claude mcp add --transport http sentry https://mcp.sentry.dev/mcp
```

- Tokens are stored securely and refreshed automatically. Use **Clear authentication** in the `/mcp` menu to re-auth from scratch.
- If the browser doesn't open, copy the printed URL and open it manually.
- For servers without Dynamic Client Registration (`Incompatible auth server...`), register an OAuth app and pass `--client-id` / `--client-secret`.

## Fix 4: Connected but zero tools

A server that shows connected with no tools started successfully but isn't returning its tool list. Select **Reconnect** from the `/mcp` panel. If the count stays at zero, read the server's stderr:

```bash
claude --debug mcp
```

## When to isolate the problem

If a server still won't behave, launch a session with all customizations disabled to confirm whether the server (or something else in your config) is the cause:

```bash
# Disables CLAUDE.md, skills, plugins, hooks, MCP servers, and custom commands/agents
claude --safe-mode
```

If the problem disappears in safe mode, one of those surfaces is responsible. You can also run `/doctor` for an automated check of your installation, settings, and MCP configuration.

## Prevention

- **Use absolute paths** for local script servers, or stick to `PATH` executables like `npx` and `uvx`.
- **Keep secrets out of `settings.json`** for MCP. Use `--env` or per-server `env` in `.mcp.json`.
- **Commit `.mcp.json` at the repo root** for project-scoped servers; remember they require a one-time `/mcp` approval.
- **Verify after adding** with `claude mcp get <name>` to confirm transport, URL/command, and OAuth credentials.

## Related resources

- [MCP in Claude Code](https://code.claude.com/docs/en/mcp)
- [Troubleshooting](https://code.claude.com/docs/en/troubleshooting)

About this resource

Overview

An MCP server that won't connect shows up the same way most of the time: you run /mcp inside Claude Code and the server is listed as failed, pending, or connected with zero tools. The underlying cause is almost always one of a handful of things: a relative path that resolves against the wrong directory, missing or wrong authentication, environment variables that never reach the server process, or a project-scoped server that was never approved.

This guide walks through diagnosing and fixing those failures using the built-in commands Claude Code ships with: /mcp, claude mcp list, claude mcp get, and claude --debug mcp.

Problem Summary

Symptoms: Server shows as failed or pending in /mcp, connects but lists zero tools, or returns 401/403 auth errors First command to run: /mcp inside Claude Code, then claude --debug mcp from your shell Estimated fix time: 5-10 minutes for most cases

First: see what actually loaded

Before changing any config, find out what state the server is in. Run these in order.

# Inside a Claude Code session: status of every server, tool counts, approval state
/mcp

# From your shell: list all configured servers
claude mcp list

# From your shell: full details for one server (transport, URL, command/args, OAuth state)
claude mcp get my-server

What the /mcp panel tells you:

  • A failed server started and exited, or never connected. Usually a bad command/path, a missing dependency, or an auth rejection.
  • A pending server is mid-connection. For HTTP/SSE servers, Claude Code retries the initial connection with exponential backoff (up to three attempts on transient errors like 5xx, connection refused, or timeout) before marking it failed. Auth and not-found errors are not retried.
  • A Pending approval server is a project-scoped server from .mcp.json waiting for your one-time approval.
  • A connected server with zero tools started fine but isn't returning a tool list.

For the real error text, run Claude Code with MCP debug logging, which surfaces the server's stderr:

claude --debug mcp

Troubleshooting table

Symptom Likely cause Fix
Server fails to start only from certain directories command/args uses a relative path, which resolves against your launch directory, not .mcp.json Use absolute paths for local scripts. PATH executables like npx/uvx work as-is.
Project server doesn't appear at all The one-time approval prompt was dismissed Run /mcp to approve, or claude mcp reset-project-choices to reset choices.
Server starts without its API key / env vars Variables were put in settings.json env, which does not propagate to MCP child processes Set per-server env inside .mcp.json, or pass --env KEY=value to claude mcp add.
Servers in .mcp.json never load File is inside .claude/ or uses Claude Desktop's format Project MCP config lives at the repository root as .mcp.json.
Remote server flagged as needing authentication Server responded with 401/403 Run /mcp and complete the OAuth 2.0 browser login flow.
Remote server connection failed even with a token You set headers.Authorization and the server rejected it Verify the token, or remove the header to fall back to OAuth.
Incompatible auth server: does not support dynamic client registration Server needs pre-configured OAuth credentials Add the server with --client-id and --client-secret.
Connected but zero tools Server started but isn't returning a tool list Select Reconnect from /mcp; if still zero, run claude --debug mcp.
Server times out before it finishes starting Startup is slower than the default timeout Increase it: MCP_TIMEOUT=10000 claude.

Fix 1: Use absolute paths for local (stdio) servers

The single most common stdio failure is a relative path in command or args. It works from the project root and breaks everywhere else. Use an absolute path, or rely on a PATH executable like npx:

# Good: PATH executable, no path issues
claude mcp add --transport stdio airtable \
  --env AIRTABLE_API_KEY=YOUR_KEY \
  -- npx -y airtable-mcp-server

Note the -- before the command: it separates Claude's own flags (--transport, --env, --scope) from the command that runs the server. Everything after -- is passed to the server untouched.

Fix 2: Put environment variables where the server can see them

Secrets in settings.json env do not reach MCP child processes. Pass them at add time with --env, or set per-server env directly in .mcp.json. Claude Code expands ${VAR} and ${VAR:-default} in command, args, env, url, and headers:

{
  "mcpServers": {
    "api-server": {
      "type": "http",
      "url": "${API_BASE_URL:-https://api.example.com}/mcp",
      "headers": {
        "Authorization": "Bearer ${API_KEY}"
      }
    }
  }
}

Fix 3: Authenticate remote servers over OAuth

Claude Code marks a remote server as needing authentication when it responds with 401 or 403, then flags it in /mcp so you can finish the OAuth 2.0 flow:

# Add a remote HTTP server that requires auth, then run /mcp to log in
claude mcp add --transport http sentry https://mcp.sentry.dev/mcp
  • Tokens are stored securely and refreshed automatically. Use Clear authentication in the /mcp menu to re-auth from scratch.
  • If the browser doesn't open, copy the printed URL and open it manually.
  • For servers without Dynamic Client Registration (Incompatible auth server...), register an OAuth app and pass --client-id / --client-secret.

Fix 4: Connected but zero tools

A server that shows connected with no tools started successfully but isn't returning its tool list. Select Reconnect from the /mcp panel. If the count stays at zero, read the server's stderr:

claude --debug mcp

When to isolate the problem

If a server still won't behave, launch a session with all customizations disabled to confirm whether the server (or something else in your config) is the cause:

# Disables CLAUDE.md, skills, plugins, hooks, MCP servers, and custom commands/agents
claude --safe-mode

If the problem disappears in safe mode, one of those surfaces is responsible. You can also run /doctor for an automated check of your installation, settings, and MCP configuration.

Prevention

  • Use absolute paths for local script servers, or stick to PATH executables like npx and uvx.
  • Keep secrets out of settings.json for MCP. Use --env or per-server env in .mcp.json.
  • Commit .mcp.json at the repo root for project-scoped servers; remember they require a one-time /mcp approval.
  • Verify after adding with claude mcp get <name> to confirm transport, URL/command, and OAuth credentials.

Related resources

Source citations

Add this badge to your README

Show that Fix Claude MCP Error -32000 is listed on HeyClaude. Paste this Markdown into your README — it renders the badge and links back to this page.

Listed on HeyClaude
[![Listed on HeyClaude](https://heyclau.de/badge/guides/fix-mcp-connection-errors.svg)](https://heyclau.de/entry/guides/fix-mcp-connection-errors)

How it compares

Fix Claude MCP Error -32000 side by side with 3 alternatives on trust, install, platform support, and disclosed safety notes — all from reviewed registry metadata.

Field

Resolve Claude Desktop MCP server connection errors fast. Step-by-step fixes for error -32000, disconnections, and configuration issues with proven solutions.

Open dossier

Diagnose and fix Claude Code 429 errors, session and weekly usage limits, and high token consumption using built-in commands and documented settings.

Open dossier

Fix Claude Code high CPU and memory usage, hangs, slow responses, and auto-compact thrashing using /context, /compact, /clear, /doctor, and documented context-management techniques.

Open dossier

Connect existing MCP servers to Claude Code with claude mcp add: stdio, HTTP, and SSE transports, local/project/user scopes, .mcp.json, and /mcp OAuth.

Open dossier
Next steps
Trust
Review statusReviewedMaintainer reviewedReviewedMaintainer reviewedReviewedMaintainer reviewedReviewedMaintainer reviewed
Package trustPackage not verifiedPackage not verifiedPackage not verifiedPackage not verified
Source provenanceSource-backedSource-backedSource-backedSource-backed
Submitter
Install riskReview firstReview firstReview firstReview first
Notes Safety Privacy Safety Privacy Safety Privacy Safety Privacy
Brand
Categoryguidesguidesguidesguides
Sourcesource-backedsource-backedsource-backedsource-backed
AuthorJSONboredJSONboredJSONboredJSONbored
Added2025-10-272025-10-272025-10-272025-10-27
Platforms
Claude Code
Claude Code
Claude Code
Claude Code
Source repo
Safety notesTroubleshooting steps run MCP servers as local subprocesses or connect to remote servers, which can execute tools and reach external systems; review what each server is allowed to do before connecting it.Changing retry, timeout, and concurrency environment variables or spend limits alters how Claude Code calls the API; review these before applying them in shared or CI environments./heapdump writes a JavaScript heap snapshot (which can contain session content) to your Desktop or home directory; do not attach heap snapshots to public issues, and share only redacted diagnostics through a private support channel when requested.Local stdio servers run their command with your user privileges, and remote servers expose model-controlled tools, so connect only servers you trust and review the command, URL, and headers first.
Privacy notesMCP authentication uses OAuth tokens and API keys, and connected servers can receive project data; keep secrets in .mcp.json env or --env (not committed), and review each server's data access./usage and cost figures are computed locally from this machine's session history and reflect only this device; the commands send no data beyond normal model requests./usage cost figures and /context breakdowns are computed locally from this machine's session history and do not include usage from other devices or claude.ai.Server URLs, command paths, header names, and tool results can expose internal hosts and private data; keep API keys and tokens out of shared `.mcp.json` and use environment-variable expansion or `/mcp` OAuth instead.
Prerequisites— none listed— none listed— none listed
  • Claude Code installed and signed in, with the `claude` CLI on your PATH.
  • The connection details for the server you are connecting: its transport (stdio command, HTTP/SSE URL), any required header or environment variable, and its trust/source information.
Install
Config
Citations
ClaimUnclaimedUnclaimedUnclaimedUnclaimed
Open 4 picks in the interactive comparison tool

Related guides

Signals

Loading live community signals…

More like this, weekly

A short, calm digest of reviewed Claude resources. Unsubscribe any time.