ECONNRESET: socket hang up — page 3
The peer tore the TCP connection down mid-request.
251 issues · 46 open · 205 resolved (82%) · first seen May 14, 2025
First response · network
What to do now
Most likely: A DNS, proxy, TLS or socket layer interrupted the connection.
- Check whether the same request works without the current VPN or corporate proxy.
- Verify DNS and certificate trust without disabling TLS verification.
- Capture the hostname and exact socket code before escalating.
These are conservative triage steps, not an official Anthropic fix. Use the issue and workaround evidence below before making a destructive configuration change.
Is this getting better or worse?
This class of problem is still growing. 93 new reports in the last 90 days vs 63 in the 90 before — +48%. The open backlog peaked at 70 in 2026-08 and sits at 46 today.
Derived by counting each matching issue from its creation date until it closed. First-party
computation over the anthropics/claude-code tracker — the trend is not published
anywhere upstream.
Which builds report this
175 of these reports name the Claude Code build they were running, spanning 108 releases. Heaviest reporters:
- Claude Code v2.1.220
- Claude Code v2.1.222
- Claude Code v2.1.226
- Claude Code v2.1.234
- Claude Code v2.1.227
- Claude Code v2.1.177
- Claude Code v2.1.39
- Claude Code v2.1.251
Report volume, not a defect count: an issue can mention a build without that build having caused the failure. Versions come from the version string in the bug-report template, matched against real published tags.
Do these get fixed?
Median time to close is 30 days across 205 closures. Of the 205 closures with a recorded reason, 16% were closed as completed and 172 as not-planned or duplicate. The most recent completed fix landed in 2026-10.
Workarounds reported by the community
58 of these issues post a workaround someone says worked. The highest-engagement ones:
- Persistent ECONNRESET Errors on macOS Network Connections
- …n Bun. That's the same reason it "just works" through Warp. Workaround (Linux/macOS) Add to or : For a more reliable OS-level fix, build an LD PRELOAD shim that forces on every TCP socket: Also lower the TCP keepalive pr…
Found in the thread of #5674 · still open - [BUG] Intermittent ECONNRESET on both desktop app and standalone CLI, no VPN/proxy
- …ards kept working, so Private Relay was the sole cause. Two workarounds — either one is enough 1. Global: System Settings → Apple ID → iCloud → iCloud+ Features → Private Relay → off. 2. Per network (preferred): leave Pr…
Found in the thread of #87424 · still open - [BUG] Connection-level errors (ECONNRESET, EPIPE, ETIMEDOUT) are never retried — immediate failure with zero recovery
- …+ partial retry reimplementation is the core issue. Partial workaround: PostToolUseFailure hook to auto-retry You can't retry API calls from a hook, but you can detect connection-related failures and alert: Better workar…
Found in the thread of #37077 · resolved - [BUG] Bedrock Bearer Token (ABSK) authentication broken in v2.1.94
- …inary with identical environment variables works correctly. Workaround Pin to v2.1.92: shell AWS BEARER TOKEN BEDROCK CLAUDE CODE USE BEDROCK=1 AWS REGION claude /home/.../.local/share/claude/versions/2.1.92 -p "hello"`…
Found in the description of #44929 · resolved - [Bug] Anthropic API Error: ECONNRESET with exhausted retries in Claude desktop app
- …ries in the same file quote their paths and are unaffected. Workaround: quote the path in the hook command, or use forward slashes. Windows hook paths arguably should be quoted by the client.</p <h2 dir="ltr" class="mt-3…
Found in the description of #83994 · still open
Excerpts are quoted from the linked issue so you can judge relevance before opening it. Threads that only ask for a workaround, or report that there is none, are excluded. These are community suggestions, not official guidance from Anthropic — read the full thread before applying one.
Matching issues 201–251
Ranked by community engagement (reactions weighted over comments).
- [Bug Report] Claude Code failing to complete tasks correctly
- [Regression] Cowork OAuth fails with ERR_CONNECTION_RESET on macOS 26.2 after update to v1.2.234
- [FEATURE] VS Code Extension: Local API proxy for Remote-SSH like Copilot
- [FEATURE] Re-read CLAUDE_CODE_CLIENT_CERT in expiration
- [BUG] Claude Code cannot connect - Cloudflare TLS fingerprint rejection (ECONNRESET/ETIMEDOUT)
- [Bug] Unexpected Korean text insertion in Chinese context
- [BUG] Cowork "sdk-daemon not connected" — persists through reinstalls on Windows (v1.1.5749)
- [Bug] Auto-Compress causes team member state hallucination and incorrect termination status
- [Bug] Messages not delivered to team lead after agent spawned in auto-compressed session
- [Bug] Cloudflare deployment documentation outdated for current model
- [Bug] ECONNRESET bursts from Cloudflare ZAG edge during streaming responses
- [BUG] Desktop app: long streaming responses drop with ECONNRESET since v1.24012.11 auto-update
- [BUG] **Title**: Claude Code 2.1.233 intermittently stalls ~3 minutes before responding on Windows (client-side, zero network connections during stall)
- Frequent ECONNRESET disconnects on Windows 11
- [Bug] Subagents abort on connection errors instead of retrying (ECONNRESET)
- [BUG] Claude Code SSE stream repeatedly resets (ECONNRESET) on sustained connections only — local network/security software exhaustively ruled out
- Remote SSH: desktop app parks on "Reconnecting" for hours after a successful reconnect, and never retries
- [BUG] SSE stream to /v1/code/sessions/.../worker/events/stream closes immediately after connect — ECONNRESET banner, 2 machines / 2 networks
- Telegram channel plugin: poller gives up on 409 after ~28 s and never recovers, while /mcp still reports "connected"
- [BUG] Persistent "Unable to connect to API (ECONNRESET)" — survives network change, reinstall, and reboot (macOS, v2.1.212, Claude Pro)
- Resume fails with ECONNRESET when transcript is bloated by Chrome screenshots (each image stored twice in session .jsonl)
- [Bug] API Connection Error: ECONNRESET During Request Retries
- No in-product recovery when a session grows too large to send (/compact requires the failing round-trip)
- Failed requests fork a new conversation branch per retry, leaving dead tips in the transcript
- Nested background subagent: unresumed completion + stale idle_notifications + confident-wrong state claims turn a routine one-command deploy into a ~30-min ordeal (compounds #78782/#73647/#68922)
- Interactive-only 401 "OAuth access token has expired" with valid setup-token on Team org with channelsEnabled — print mode works; DISABLE_NONESSENTIAL_TRAFFIC fixes it
- [BUG] 返答スピードが遅い
- [BUG] Desktop SSH remote: client never sends publickey signature after "Postponed publickey" (regression in 1.21459.3; system OpenSSH with identical key/host works)
- [BUG] ECONNRESET — fresh sessions drop after a few turns; --resume fails to connect at all — v2.1.201, macOS
- [BUG] This task didn't load properly
- Bug Report
- Invalid API Request: Empty Message Content Violation
- Desktop app (Windows): repeated 'API Error: Connection dropped (ECONNRESET)' across multiple sessions, incl. short ones
- Session gets stuck in a retry loop on a very slow upload connection (Claude Desktop, Windows)
- [Bug] ECONNRESET on Wi-Fi at MTU 1500; connections succeed at MTU ≤1492 (path MTU/ICMP suspected)
- ECONNRESET persistente (attempt 10/10) — RST originado por la IP de la API, no por la red local
- [BUG] macOS sandbox proxy truncates response bodies and resets the connection when the server closes it (`Connection: close`)
- [BUG] SSH remote connection fails during Claude Code setup step (ECONNRESET) when connecting to Odoo.sh container
- HTTP hooks: no retry when the OS resets a local connection (read ECONNRESET / ECONNREFUSED), hook output silently dropped
- [BUG] ECONNRESET "Connection dropped" with claude-fable-5-1 at normal effort; works at MAX
- [BUG] Frequent ECONNRESET Disconnections While Other Network Applications Work Normally
- [Bug] Anthropic API Error: ECONNRESET - Connection dropped in every session
- [BUG] Windows: ECONNRESET on first Claude Code prompt despite working HTTPS
- [BUG] Cloud egress gateway resets any TLS ClientHello carrying the ECH extension, so Chromium/Playwright can never connect while curl can
- [BUG] ECONNRESET, four times in ~20 minutes
- API edge RSTs /v1/messages when time-to-first-header exceeds ~15s — large cold prompts (>~90K tokens) fail deterministically through all retries
- [Bug] ECONNRESET on streaming requests with bundled Node v26.3.0
- [BUG] After a Wi-Fi drop, ECONNRESET persists even once the network is back — only a full reboot recovers
- [BUG] Stream reset (ECONNRESET) 2-8ms after first chunk on every /v1/messages streaming request, while non-streaming and third-party SSE are healthy (Windows, v2.1.241)
- [BUG] Persistent ECONNRESET on home network (VDSL), works fine on mobile hotspot — macOS
- [Bug] Desktop app stalls indefinitely on large payloads while CLI completes same tasks normally