[BUG] Multiple custom MCP connectors stopped working simultaneously with "Couldn't reach the MCP server" error

Resolved 💬 5 comments Opened Apr 23, 2026 by konenknife Closed May 20, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Multiple custom MCP connectors stopped working simultaneously with
"Couldn't reach the MCP server" error.

Reference IDs:

  • ofid_74a318c6cc709003
  • ofid_f99211da79df5a2e

Affected servers (both independently reachable and functional when tested directly):

Server-side diagnostics:

  • kb-mcp DB shows 6 successful hourly token refreshes yesterday, then stopped cold.

Refresh tokens still valid for 30 days.

  • Both endpoints return proper 401 when tested via curl; servers are healthy.

Pattern suggests client-side OAuth refresh/re-auth is not firing.

Claude Code version: [run claude --version]
Platform: macOS [version]

What Should Happen?

Multiple custom MCP connectors stopped working simultaneously with
"Couldn't reach the MCP server" error.

Reference IDs:

  • ofid_74a318c6cc709003
  • ofid_f99211da79df5a2e

Affected servers (both independently reachable and functional when tested directly):

Server-side diagnostics:

  • kb-mcp DB shows 6 successful hourly token refreshes yesterday, then stopped cold.

Refresh tokens still valid for 30 days.

  • Both endpoints return proper 401 when tested via curl; servers are healthy.

Pattern suggests client-side OAuth refresh/re-auth is not firing.

Claude Code version: [run claude --version]
Platform: macOS [version]

Error Messages/Logs

Multiple custom MCP connectors stopped working simultaneously with 
"Couldn't reach the MCP server" error.

Reference IDs:
- ofid_74a318c6cc709003
- ofid_f99211da79df5a2e

Affected servers (both independently reachable and functional when tested directly):
- https://kb-mcp.koknife.com/mcp — OAuth2 PKCE, supports refresh_token grant
- https://portfolio.koknife.com/mcp — OAuth2 PKCE, authorization_code only

Server-side diagnostics:
- kb-mcp DB shows 6 successful hourly token refreshes yesterday, then stopped cold. 
  Refresh tokens still valid for 30 days.
- Both endpoints return proper 401 when tested via curl; servers are healthy.

Pattern suggests client-side OAuth refresh/re-auth is not firing.

Claude Code version: [run `claude --version`]
Platform: macOS [version]

Steps to Reproduce

  1. Set up a self-hosted MCP server with OAuth2 PKCE authorization (e.g.,

FastMCP or @modelcontextprotocol/sdk with OAuth middleware) behind HTTPS.

  1. Add it as a custom connector in Claude Code via Settings → Integrations,

complete the OAuth authorize flow, and confirm tools appear and work.

  1. Leave the connector idle for longer than the server's access-token TTL

(e.g., >1 hour if TTL is 3600s). Do not interact with Claude Code during
this window.

  1. Return to Claude Code and attempt to use a tool from that connector.

Expected: Claude Code either silently refreshes the access token using
the stored refresh token, or (if the server doesn't support refresh_token)
prompts the user to re-authorize.

Actual: Request fails with toast "Couldn't reach the MCP server. You can
check the server URL and verify the server is running. If this persists,
share this reference with support: 'ofid_...'". No retry, no refresh
attempt observed server-side, no re-auth prompt. Connector appears
permanently stuck until manually removed and re-added.

Reproduces across two independently-implemented servers (different
languages, different transports, different DBs) — one supporting
refresh_token grant, one not — which rules out a single server-side bug.

Server-side verification: curl against the /mcp endpoint with a valid
bearer token succeeds. The servers themselves are reachable and healthy.

Claude Model

Not sure / Multiple models

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

Claude Code 2.1.118

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗