Error reference
Show diff (156 lines)
--- a/errors.md
+++ b/errors.md
@@ -136,6 +136,7 @@
`Couldn't read the stored credentials for MCP server "<name>", so the request didn't run`| Authentication
`A request to MCP server "<name>" was sent without your stored credentials`| Authentication
`This server's URL is missing or not a valid URL, so sign-in can't start`| Authentication
+`This service doesn't accept sign-ins from Claude Code` / `Incompatible auth server: does not support dynamic client registration`| [Use pre-configured OAuth credentials](</docs/en/mcp#use-pre-configured-oauth-credentials>)
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
`Stopped an OAuth request`| Authentication
`Refusing to send credentials to non-https token endpoint` / `<short-name> from the MCP SDK for <server-url>`| Authentication
@@ -229,6 +230,7 @@
`API Error: 400 orphaned tool_result in conversation history`| Request errors
`API Error: 400 duplicate tool_use ID in conversation history`| Request errors
`Invalid data in redacted_thinking block`| Request errors
+`If other sessions work and this one keeps failing, start a new session`| [Retry unchanged, then without earlier thinking](</docs/en/llm-gateway-protocol#retry-unchanged-then-without-earlier-thinking>), on the LLM gateway protocol page
`[Unsupported tool content removed]`| Request errors
`role 'system' must precede an 'assistant' message`| Request errors
`Invalid encrypted_content in search_result block` / `Invalid encrypted_index in text block` / `Failed to decrypt web search result content`| Request errors
@@ -449,7 +451,9 @@
`The sandbox could not create <dir>, a folder it must protect from the command, because the temp disk is full`| Free space on the temp disk or repair it, then have Claude run the command again.
`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)` / `The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
-`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
+`File is not valid UTF-8`| Tool errors
+`File has NUL bytes in its first 8 KB` / `File is UTF-16 big-endian (it starts FE FF), which these tools cannot write`| Ask Claude to make the change with a shell command that keeps the file’s encoding.
+`File starts with the UTF-16LE byte-order mark (FF FE) but has an odd number of bytes`| Ask Claude to fix the file’s length with a shell command.
`git is not installed on this Mac. To install it, run xcode-select --install, then try again.`| Tool errors
`Refusing to apply edits to <path>: a hook is configured for file edits in this session`| Tool errors
`no longer leads where it did` / `Could not confirm that working directory "<cwd>" is the directory that this command was permission-checked in`| Ask Claude to try again.
@@ -547,6 +551,7 @@
`Your Claude session has expired. Sign in again to continue (claude auth login).`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
`Your organization's managed settings need your approval, which couldn't be asked for here.`| Configuration warnings
+`Your organization may apply global configuration to Claude Code`| [Security approval dialogs](</docs/en/server-managed-settings#security-approval-dialogs>)
`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
`Your organization's managed settings allow Claude Code to use: <providers>`| Configuration warnings
`Your organization's managed settings allow Claude Code to use no API provider at all`| Configuration warnings
@@ -610,7 +615,7 @@
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
* A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code doesn’t re-run the request, because that could execute the same tool calls twice. It keeps what Claude completed, runs any tool calls Claude finished, and continues the turn from their results. For what you see in an interactive session and in a non-interactive one, read The response above may be incomplete. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
- * A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
+ * A server error, dropped connection, or stalled stream after Claude has finished the response. Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
* A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
@@ -762,8 +767,8 @@
In four cases, Claude Code handles the failure without showing this notice right away:
* Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
- * When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
- * In a [non-interactive session](</docs/en/headless>), such as a `-p` run, an [Agent SDK](</docs/en/agent-sdk/overview>) run, or a [cloud session](</docs/en/claude-code-on-the-web>), you don’t have to send `continue` yourself when the cut-off response is in the main conversation and contains text but no tool calls: Claude Code keeps the partial output and prompts Claude to continue from where it stopped, up to three times in a row. You see this notice for such a response only once Claude Code has used up those continuations. Before v2.1.246, Claude Code ended a non-interactive turn with this notice on the first cut-off.
+ * When a server error, dropped connection, or stall happens after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error.
+ * In a [non-interactive session](</docs/en/headless>), when a cut-off response in the main conversation contains text but no tool calls, the turn continues from the partial output. You see this notice for such a response only once Claude Code has used up those continuations. Non-interactive sessions include `-p` runs, [Agent SDK](</docs/en/agent-sdk/overview>) runs, and [cloud sessions](</docs/en/claude-code-on-the-web>). Before v2.1.246, Claude Code ended a non-interactive turn with this notice on the first cut-off.
* In a [subagent](</docs/en/sub-agents#api-errors-in-subagents>), whether the session is interactive or not: when its cut-off response contains text but no tool calls, Claude Code prompts the subagent to continue. The notice becomes the subagent’s last message only once those continuations are used up. Before v2.1.257, a subagent showed this notice on the first cut-off.
**What to do:**
@@ -941,14 +946,12 @@
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered · nothing was sent · answer it where this session is running, or /model to change
Claude stopped here because Fable 5.1 now requires usage credits.
-The messages name the session’s Fable model, so on Fable 5.2 you see text such as `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. With [Remote Control](</docs/en/remote-control>) connected, the first two messages can instead end with `Claude stopped here · send a message to be asked again, or switch models`. Before v2.1.257, the first message began `Fable 5 limit reached`. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
+The messages name the session’s Fable model, so on Fable 5.2 you see text such as `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. With [Remote Control](</docs/en/remote-control>) connected, the first two messages can instead end with `Claude stopped here · send a message to be asked again, or switch models`. Before v2.1.257, the first message began `Fable 5 limit reached`. **What to do:**
* Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first.
* With Remote Control connected to a terminal session, you can also reply from your device and answer the prompt if it appears there
* Run `/model` to switch to a model that doesn’t bill usage credits
* To give yourself more time, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
-
-Before v2.1.236, these messages didn’t appear. While a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
### Server is temporarily limiting requests
@@ -2802,9 +2805,9 @@
**What to do:**
* For `could not be created` followed by `is full (ENOSPC)`, free disk space on the volume the message names. When it says `your disk quota on the volume holding /tmp is used up (EDQUOT)` instead, delete your own files on that volume that you no longer need
- * For the `Refusing to use it` forms, remove the named entry itself, not what a link points to, and start Claude Code again; for the `owned by uid` form, only an administrator or that user can remove it
+ * For `is not a directory`, remove the symlink that the error names, not its target, and start Claude Code again
* For `is not readable`, run `chmod 0700` on the named directory, or remove it and start again
- * In any of these cases, set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory you control and start Claude Code again, leaving the refused path alone
+ * For `owned by uid`, or in any of these cases, set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory you control and start Claude Code again, leaving the refused path alone
Before v2.1.309, Claude Code printed only the operating system’s error text when the volume was full or your quota was used up. An example is `ENOSPC: no space left on device, mkdir '/tmp/claude-501'`, and the same steps apply.
@@ -2893,7 +2896,6 @@
Claude Code doesn’t refuse global flags that are harmless to drop, such as `--verbose`, `--model`, or a wrapper-injected `--session-id` or `--plugin-dir`: it ignores them and Remote Control starts. Claude Code also refuses to start for a global flag it doesn’t yet recognize as harmless, so a flag added in a newer release can appear in this message until a later release marks it harmless. **What to do:**
* Remove the flag from before the verb and pass [Remote Control’s own options](</docs/en/remote-control#start-a-remote-control-session>) after it; `claude remote-control --help` lists them
- * When the refused flag is `--permission-mode`, run `claude remote-control --permission-mode <mode>` to set the permission mode for the sessions Remote Control starts
Before v2.1.248, `claude remote-control` didn’t accept its own flags when a global flag came first, and the command failed with an `unknown option` error.
@@ -4238,16 +4240,16 @@
### File is not valid UTF-8
-Claude used the Edit or NotebookEdit tool on a file whose bytes don’t decode as UTF-8, and Claude Code refused the change. Nothing was written, so the file is as it was. Those tools save the whole file back as UTF-8, which would have turned every byte they couldn’t decode into the replacement character `U+FFFD`. The message appears in the tool result:
-
- File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary. This tool saves the whole file as UTF-8, which would replace every byte it cannot decode with U+FFFD. Nothing was written. Make the change with a shell command that reads and writes the file in its own encoding, or ask the user whether to convert the file to UTF-8 first.
+Claude used the Edit, Write, or NotebookEdit tool on a file whose bytes don’t decode as UTF-8. Claude Code refused the change. Nothing was written, so the file is as it was. The message appears in the tool result:
+
+ File is not valid UTF-8: it uses a legacy encoding such as Windows-1252, Shift-JIS or GBK, or it is binary. These tools write UTF-8 (or UTF-16LE behind its byte-order mark) and never convert a file's encoding on their own, so nothing was written. If the file is text, make the change with a shell command that reads and writes it in its own encoding (iconv, or PowerShell Get-Content/Set-Content -Encoding), or ask the user whether to convert it to UTF-8 first. To replace the whole file with new UTF-8 text anyway, delete it first, then Write it.
A file that is meant to be UTF-8 gets this message too when it contains even one invalid byte sequence, because the check covers the file’s bytes as a whole. **What to do:**
* To keep the file in its current encoding, let Claude make the change with a shell command that reads and writes the file in that encoding, as the message tells it to
* To keep editing the file with the Edit tool, convert it to UTF-8, or fix the invalid bytes in a file that is meant to be UTF-8, then ask Claude to make the edit again
-Before v2.1.296, Edit and NotebookEdit applied such an edit and saved every byte they couldn’t decode as `U+FFFD`. On those versions, update Claude Code.
+Before v2.1.299, Write could replace such a file and save it as UTF-8. Before v2.1.296, Edit and NotebookEdit applied such an edit and saved every byte they couldn’t decode as the replacement character `U+FFFD`. On those versions, update Claude Code.
### Refusing to apply edits: a hook is configured for file edits in this session
@@ -4649,7 +4651,7 @@
This error means a Claude Code process that the [VS Code extension](</docs/en/vs-code>) or an Agent SDK application launched didn’t report in time that it was ready. The extension or application then stopped it. In a VS Code conversation the error starts with `Claude Code did not finish starting`, for example:
- Claude Code did not finish starting: it did not answer in time. The output logs ("View output logs") show how far it got. Slow plugins, MCP servers, hooks, disks or network can each cause this.
+ Claude Code did not finish starting: it did not answer in time. The output logs ("Show logs") show how far it got. Slow plugins, MCP servers, hooks, disks or network can each cause this.
In the extension’s output logs, on its sign-in screen, and in an Agent SDK application, the error reads differently. It starts with `Subprocess initialization did not complete within` and the time limit, then gives what Claude Code reported, for example:
@@ -4658,12 +4660,12 @@
**What to do:**
* To try again in VS Code, send a message. If the error appeared while you were signing in, select the sign-in method again instead.
- * To see how far Claude Code got, click **View output logs** under a conversation’s error, or run **Claude Code: Show Logs** from the Command Palette. Include the entries around the `Subprocess initialization` line when [reporting the problem](<https://github.com/anthropics/claude-code/issues>).
+ * To see how far Claude Code got, click **Show logs** under a conversation’s error, or run **Claude Code: Show Logs** from the Command Palette. Include the entries around the `Subprocess initialization` line when [reporting the problem](<https://github.com/anthropics/claude-code/issues>).
* To check your network, see [Network configuration](</docs/en/network-config>). If the message tells you to check your sign-in or authentication, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>).
* If the message says that [SessionStart](</docs/en/hooks#sessionstart>) or [Setup](</docs/en/hooks#setup>) hooks hadn’t finished, [check how long yours run](</docs/en/hooks#debug-hooks>). In VS Code, the first 10 minutes in which Claude Code reports these hooks running don’t count toward the 60-second limit. Make a slow hook finish sooner, lower a non-async hook’s [`timeout`](</docs/en/hooks#common-fields>), or [remove the hook](</docs/en/hooks#disable-or-remove-hooks>).
* If your Agent SDK application calls [`startup()`](</docs/en/agent-sdk/typescript#startup>), set `initializeTimeoutMs` long enough for the whole start, or leave it unset so up to 10 minutes of reported hook time doesn’t count.
-Before VS Code extension v2.1.304 and TypeScript Agent SDK v0.3.304, all hook time counted toward the limit. With the default limit, the message contained `Subprocess initialization did not complete within 60000ms — check authentication and network connectivity`. If you see that wording, update the extension or the SDK.
+Before VS Code extension v2.1.334, click **View output logs** under a conversation’s error to open the logs. Before VS Code extension v2.1.304 and TypeScript Agent SDK v0.3.304, all hook time counted toward the limit. With the default limit, the message contained `Subprocess initialization did not complete within 60000ms — check authentication and network connectivity`. If you see that wording, update the extension or the SDK.
### Claude Code process exited with code N
@@ -4673,7 +4675,7 @@
On Windows, the native build can exit with code `4294967295` right after a turn completes. When that exit lands at a turn boundary, with no message waiting and no background task running, the [VS Code extension](</docs/en/vs-code>) closes the session quietly instead of showing this error. Your next message resumes the conversation. Before v2.1.273, the extension showed the error for that exit at every turn boundary, even though nothing was lost. **What to do:**
- * In VS Code, follow the **View output logs** link shown with the error to see the underlying failure
+ * In VS Code, follow the **Show logs** link shown with the error to see the underlying failure. Before VS Code extension v2.1.334, the link was labeled **View output logs**.
* In an Agent SDK application, catch the error around your message loop. The entries under [CLI process exit](</docs/en/agent-sdk/troubleshooting#cli-process-exit>) cover what your code receives in each SDK language.
* Run `claude` in a terminal in the same project. The failure usually reproduces there with its real error message, which you can then look up on this page.
* Run `claude doctor` in a terminal to check the installation and configuration
@@ -4992,7 +4994,7 @@
**What to do:**
- * Run `claude` in a terminal and approve the settings when the dialog appears, then run the same `claude plugin` command again. Claude Code keeps the approval and the approved settings in your [configuration directory](</docs/en/server-managed-settings#approval-memory>). If the command that stopped ran as another user or with `CLAUDE_CONFIG_DIR` set, run `claude` the same way so that both use the same directory.
+ * Run `claude` in a terminal and approve the settings if the dialog appears, then run the same `claude plugin` command again. Claude Code keeps the approval and the approved settings in your [configuration directory](</docs/en/server-managed-settings#approval-memory>). If the command that stopped ran as another user or with `CLAUDE_CONFIG_DIR` set, run `claude` the same way so that both use the same directory.
### Managed settings block the default model
--- a/errors.md
+++ b/errors.md
@@ -507,6 +507,13 @@
`A message is still queued` / `A /clear is still queued`, when you rewind code in VS Code| Stop Claude, then follow the rest of the message.
`Couldn’t load the diff view or code colors`, in VS Code| Click a diff to try again, or reload the window.
`Settings file is empty, and another program may still be writing it: <path>`, in VS Code| Try again in a minute. If the message repeats, put `{}` in the file.
+`Session was interrupted`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`Claude Code on <host> stopped when its sign-in expired`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`Folder not found on <host>`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`<host> doesn’t have this conversation` / `<host> doesn’t have this conversation right now`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`Claude no longer has the earlier messages`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`Couldn’t create a worktree on <host>`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
+`Couldn’t start Claude Code on the remote host` / `Claude Code is missing on the remote host`, in an SSH session in the Desktop app| [SSH session stops or fails to start](</docs/en/desktop#ssh-session-stops-or-fails-to-start>)
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Claude Code could not be started from <command>: it is the <system> build, and this computer needs the <build> build`| If you set [`claudeCode.claudeProcessWrapper`](</docs/en/vs-code#extension-settings>), point it at a program built for `<build>`. Otherwise, install the VS Code extension package for `<build>`.
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
@@ -3077,7 +3084,7 @@
The list after `Available MCP tools:` names the MCP tools that were connected. **What to do:**
- * Check that the server starts and stays connected: run `claude mcp list` in the same directory and confirm the server is listed as connected
+ * Check that Claude Code connects to the server: rerun your `claude -p` command with `--output-format stream-json --verbose`. In the [line with `"subtype":"init"`](</docs/en/headless#read-session-metadata>), confirm that the `mcp_servers` field lists the server as `connected`. If it doesn’t, see [the possible statuses and what to check](</docs/en/agent-sdk/mcp#error-handling>).
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
* If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
Show diff (124 lines)
--- a/errors.md
+++ b/errors.md
@@ -29,6 +29,7 @@
`Auto mode classifier transcript exceeded context window`| Server errors
`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
`The server-side auto mode classifier gave no verdict`| Server errors
+`Auto mode fell back to billed classifier requests`| [What else `denyInsteadOfPrompting` stops](</docs/en/settings-reference#what-else-denyinsteadofprompting-stops>)
`<tool> was not reviewed and did not run: the conversation is too long for auto mode's classifier`| Server errors
`Auto mode is unavailable — the server returned no safety verdict for the last 10 responses`| Server errors
`Agent terminated early due to an API error`| Server errors
@@ -37,6 +38,7 @@
`Usage credits ran out before the response was finished.`| [Add usage credits](</docs/en/costs#add-usage-credits-to-your-subscription>)
`the prompt to confirm went unanswered · nothing was sent`, from v2.1.324| Usage limits
`Claude stopped here · send a message to be asked again`| Usage limits
+`Claude stopped here because <model> now requires usage credits`| Usage limits
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
@@ -147,6 +149,7 @@
`Microsoft Foundry authentication failed`| Authentication
`Gateway refused the request`| Authentication
`Could not load AWS credentials` / `Could not load Google Cloud credentials`| Authentication
+`Could not load Azure credentials`| [Foundry credentials not loading](</docs/en/troubleshoot-install#bedrock-agent-platform-or-foundry-credentials-not-loading>)
`AWS default-chain credential resolve timed out`| Authentication
`Timed out after 60s waiting for AWS`| Authentication
`A request to AWS timed out. Check your network and proxy settings, then try again.`| Authentication
@@ -255,6 +258,7 @@
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
`Cloud sessions aren't available:` followed by why your organization’s policy couldn’t be loaded| Command-line errors
`Branch '<branch>' was not checked out`| [Teleport requirements](</docs/en/claude-code-on-the-web#teleport-requirements>)
+`Loaded from the session's last compaction, so the messages it summarized aren't here.`| [Continue a cloud session in your terminal](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>)
`Cloud sessions aren't available with this Console sign-in. They need a claude.ai sign-in.`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Cloud sessions need a claude.ai sign-in`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Nothing was stashed: "<path>" is now a folder in place of a tracked file or link` / `are now folders in place of tracked files or links`| Command-line errors
@@ -390,6 +394,8 @@
`installed mods are off for now`| [Check whether mods can load](</docs/en/plugins/mods/troubleshoot#check-whether-mods-can-load>)
`the hooks worker was lost with <mod>'s <event> hook in flight`| Fix the named mod. For one cause, see [`it crashed the hooks worker`](</docs/en/plugins/mods/troubleshoot#it-crashed-the-hooks-worker>).
`dispatches in a row for fills by <mods>`| Change the named mods so they fill the prompt box at most eight times in a row.
+`changed a slash command's typed line`| [Change command arguments](</docs/en/plugins/mods/events#change-command-arguments>)
+`no prompt.submit in flight carries an attachment under that id`| Call `$.prompt.media` inside the `prompt.submit` hook whose `e.attachments` lists the `id` you pass. Look up `$.prompt.media` in [the types for your build](</docs/en/plugins/mods/create#get-the-types-for-your-build>).
`Error: No such tool available: <tool name>`| Tool errors
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
`MCP server "<name>" is disabled — re-enable it via /mcp to use its tools`| Tool errors
@@ -446,7 +452,9 @@
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`git is not installed on this Mac. To install it, run xcode-select --install, then try again.`| Tool errors
`Refusing to apply edits to <path>: a hook is configured for file edits in this session`| Tool errors
+`no longer leads where it did` / `Could not confirm that working directory "<cwd>" is the directory that this command was permission-checked in`| Ask Claude to try again.
`blocking because onFailure is "block"`| [Block the action when a hook fails](</docs/en/hooks#block-the-action-when-a-hook-fails>)
+`in one call, so a Write could lose`| Ask Claude to read the whole file in one Read call, or to use Edit.
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
@@ -538,6 +546,7 @@
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`"<name>" is a reserved MCP server name and was not loaded`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
+`Your organization's policy could not be read, so this session cannot run a turn.`| Send the error to your administrator.
`Managed settings drop-in directory could not be read`| Configuration warnings
`Unable to read managed policy settings`| Configuration warnings
`Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:`| Configuration warnings
@@ -919,18 +928,20 @@
### The prompt to confirm went unanswered
-When the [Fable usage-credits consent prompt](</docs/en/model-config#fable-and-usage-credits>) closes with nobody answering it, Claude Code ends the turn with one of these messages:
+When you dismiss the mid-session [Fable usage-credits consent prompt](</docs/en/model-config#fable-and-usage-credits>) or it closes unanswered, Claude Code can end the turn with one of these messages:
Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered · nothing was sent · answer it where this session is running, or /model to change
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered · nothing was sent · answer it where this session is running, or /model to change
-
-The messages name the session’s Fable model, so on Fable 5.2 they read `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. With [Remote Control](</docs/en/remote-control>) connected, each message can instead end `Claude stopped here · send a message to be asked again, or switch models`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
-
- * Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. If the message says `Claude stopped here`, you can also reply from your connected device and answer the consent prompt there.
+ Claude stopped here because Fable 5.1 now requires usage credits.
+
+The messages name the session’s Fable model, so on Fable 5.2 you see text such as `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. With [Remote Control](</docs/en/remote-control>) connected, the first two messages can instead end with `Claude stopped here · send a message to be asked again, or switch models`. Before v2.1.257, the first message began `Fable 5 limit reached`. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
+
+ * Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first.
+ * With Remote Control connected to a terminal session, you can also reply from your device and answer the prompt if it appears there
* Run `/model` to switch to a model that doesn’t bill usage credits
* To give yourself more time, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
-Before v2.1.236, this message didn’t appear: while a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
+Before v2.1.236, these messages didn’t appear. While a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
### Server is temporarily limiting requests
@@ -2246,7 +2257,7 @@
* **Interactive CLI** : run `/model` to pick from models available to your account.
* **Non-interactive mode (`-p`)**: pass `--model` with a valid alias or ID, or set [`ANTHROPIC_MODEL`](</docs/en/env-vars>). The error text shows `Run --model` on this surface.
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
- * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
+ * On the Anthropic API, use an alias such as `sonnet` or `opus` instead of a full versioned ID. An alias resolves to a default model that can change over time. On a third-party provider, [pin a current model version](</docs/en/model-config#pin-models-for-third-party-deployments>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
* Before v2.1.206, an expired claude.ai login that could no longer be refreshed failed every model with this error. Run `/login` on those versions.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
@@ -2273,7 +2284,7 @@
On providers with provider-specific model IDs, the message may add a `Try '...' instead` suggestion that names your provider’s ID for a fallback model. **What to do:**
- * Run `/model` with no argument and pick from the models available to your account, or use a [model alias](</docs/en/model-config#model-aliases>) such as `sonnet`, which resolves to a maintained default
+ * Run `/model` with no argument and pick from the models available to your account, or on the Anthropic API use a [model alias](</docs/en/model-config#model-aliases>) such as `sonnet`
* If you typed a full ID, check it against your provider’s model catalog. A newly launched model can be available on the Anthropic API before your provider or region offers it.
* In the Agent SDK, `setModel()` fails with this message and the session keeps running on its previous model. In the TypeScript SDK, call [`supportedModels()`](</docs/en/agent-sdk/typescript#query-object>) to list the models you can switch to.
* Before v2.1.265, `/model` also rejected the `opusplan[1m]` alias spelling with this error. On those versions, update Claude Code, or set the model in [settings](</docs/en/model-config#setting-your-model>) or with `--model` instead.
@@ -3996,7 +4007,7 @@
### pkill pattern matches the Claude Code process
-A `pkill` command in a Bash tool call used a pattern, typically with `-f`, that matches the Claude Code process itself, so Claude Code refuses the command instead of letting it end the session. Claude Code tests the pattern with `pgrep` before running `pkill` and refuses when its own process ID is in the result. The check runs on Linux only; on macOS, `pkill` runs unmodified. Before v2.1.214, the command ran, and a matching pattern killed the Claude Code session mid-turn.
+Claude Code refused a `pkill` or `pkill -f` command in a Bash tool call because its pattern matches the Claude Code process itself. Claude Code refuses on Linux only, after testing the pattern with `pgrep` and finding its own process ID in the result. Before v2.1.214, the command ran on Linux, and a matching pattern killed the Claude Code session mid-turn.
pkill: refusing to run — this pattern matches the Claude CLI process (PID 12345). Narrow the pattern, or target your own children with `pkill -P $$ ...`.
@@ -4499,7 +4510,7 @@
This session was running agent 'code-reviewer', which is no longer available (no agent by that name in /home/you/project). Continuing with the default tools and system prompt — the agent's tool restrictions no longer apply. To restore it, re-create the agent, or resume with an explicit --agent <name>.
-The warning names only the directories Claude Code searched, and it appears in the resumed conversation whether you wake a [background session](</docs/en/agent-view>), run `/resume` or `claude --resume`, or resume in [non-interactive mode](</docs/en/headless>), where it also goes to stderr. Sessions using `--input-format stream-json` don’t show it, because the Agent SDK supplies agents after startup. Claude Code doesn’t save the fallback to the session, so the warning repeats on each resume until you act. The built-in `claude` agent doesn’t trigger the warning, since falling back to the default toolset changes nothing for it. Before v2.1.216, Claude Code silently continued as the default agent, and the lookup covered only the directory you resumed from, so a project-scoped agent was lost on any resume from another directory. **What to do:**
+The warning names only the directories Claude Code searched. Sessions using `--input-format stream-json` don’t show it, because the Agent SDK supplies agents after startup. Claude Code doesn’t save the fallback to the session, so the warning repeats on each resume until you act. The built-in `claude` agent doesn’t trigger the warning, since falling back to the default toolset changes nothing for it. Before v2.1.216, Claude Code silently continued as the default agent, and the lookup covered only the directory you resumed from, so a project-scoped agent was lost on any resume from another directory. **What to do:**
* Re-create the agent file at `.claude/agents/<name>.md` in the session’s project, or at `~/.claude/agents/<name>.md` for a personal agent, then resume again
* Or resume with `--agent <name>` naming an agent that does exist, to run the session as that agent instead
Show diff (148 lines)
--- a/errors.md
+++ b/errors.md
@@ -48,6 +48,8 @@
`Sign in again to take your previous account or API key off the config file.`| Authentication
`Your account or API key may still be in the config file. Run claude auth logout.`| Authentication
`Authentication required · Sign in again to continue`| Authentication
+`Sign in again to continue` followed by `For security, Claude Code needs a recent sign-in.`| Wrapper and IDE errors
+`Claude Code needs a recent sign-in. Signing in won’t stop sessions.`| Wrapper and IDE errors
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`Your apiKeyHelper script is failing`| Authentication
@@ -87,19 +89,22 @@
`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`Authentication error · This may be a temporary network issue` in a cloud session| Send your message again.
+`login required — run /login` in agent view| If a message listed in this table follows it, use that row. Otherwise run `/login`.
`Warning: this sign-in`| [Check when a stored login ends](</docs/en/authentication#check-when-a-stored-login-ends>)
`The browser can't return the sign-in to Claude Code automatically`| Authentication
`Couldn't start the local listener that receives the browser sign-in. Try again.`| Authentication
`Failed to start OAuth callback server`| Authentication
`Claude login not accepted · Run /login, then try again`| Authentication
`Artifacts need a claude.ai login`| Authentication
+`Your authentication token belongs to organization`| [Restrict login to your organization](</docs/en/authentication#restrict-login-to-your-organization>)
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Managed settings on this machine configure a Cloud gateway sign-in; run interactive /login to authenticate.`| [`claude auth login`](</docs/en/cli-reference#cli-commands>)
`You chose an organization that is managed in Anthropic's Enterprise Admin Console`| [Turn on sign-in from Claude Code](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#turn-on-sign-in-from-claude-code>)
`The organization's settings won't apply on this computer`| [Which settings take priority](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#which-settings-take-priority>)
`no usable organization sign-in` / `no readable organization sign-in`| [When a sign-in ends](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#when-a-sign-in-ends>)
-`the session no longer runs under that sign-in` / `This Claude Code process ran under your organization` / `After a sign-in to your organization, only a new session sends requests`| [Log in to Claude Code](</docs/en/authentication#log-in-to-claude-code>)
+`the session no longer runs under that sign-in` / `This Claude Code process ran under your organization` / `After a sign-in to your organization, only a new session sends requests` / `Claude Code needs to restart to use it`| [Log in to Claude Code](</docs/en/authentication#log-in-to-claude-code>)
`This conversation ran under organization` / `This conversation ran under more than one organization`| [Log in to Claude Code](</docs/en/authentication#log-in-to-claude-code>)
`Claude Code could not read the managed settings that apply to this computer, which may require a sign-in to Anthropic`| [`enforceAnthropicSignIn`](</docs/en/settings-reference#enforceanthropicsignin>)
`This computer's managed settings require a sign-in to Anthropic` / `This computer's settings require a sign-in to Anthropic that this app cannot use`| [Require the sign-in](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#require-the-sign-in-with-managed-settings>)
@@ -292,6 +297,7 @@
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Couldn't run `<command>` for <name>. A file named HEAD or .git in this folder or one above it may not be yours`, from a skill that injects dynamic context| [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>)
+`Not run in /<name>` / `Ran anyway in /<name>` / `[not run: blocked by hook`, from `/security-review` or a skill that injects dynamic context| [PreSkillShellCommand decision control](</docs/en/hooks#preskillshellcommand-decision-control>)
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`No shell command in <name> was run, because the <tool> tool does not accept one of them`| Command-line errors
`This skill, command or hook and the arguments filled into it add up to more than 4,000,000 characters`| Command-line errors
@@ -337,6 +343,7 @@
`/feedback is disabled by your organization's policy`, or the same for `/bug` or `/share`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`credential store on this machine holds a symbolic link inside it`| [Grant tools](</docs/en/plugin-evals#grant-tools>)
+`cannot be disallowed`, from `claude plugin eval`| Use a built-in tool’s [exact name](</docs/en/plugin-evals#disallow-tools>), and [put the target before `--disallow-tools`](</docs/en/plugin-evals#choose-what-to-evaluate>)
`cannot be evaluated where sessions load it`| [Test plugins with evals](</docs/en/plugin-evals#cannot-be-evaluated-where-sessions-load-it>)
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Claude Code refuses the marketplace name "<name>"`| Plugin errors
@@ -363,6 +370,8 @@
`commands path not found: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#commands-path-not-found>)
`Plugin not loaded: its manifest <path> was not read`| Plugin errors
`path couldn't be checked` / `path could not be checked`| Plugin errors
+`Couldn't load hooks from <path>` / `Failed to load hooks from <path>` / `Hook load failed`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#failed-to-load-hooks-from-and-hooks-that-dont-fire>)
+`hooks.json declares PreToolUse/PermissionRequest`| Put the events under a `hooks` key, as in the [plugin hooks example](</docs/en/plugins/components#hooks>).
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
`Plugin source path refused`| Plugin errors
`Failed to load marketplace configuration`| Plugin errors
@@ -376,10 +385,16 @@
`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
`is not added on this machine, so your organization's marketplace policy keeps its plugins off`| [Add a marketplace](</docs/en/plugins/install#add-a-marketplace>)
`A mod's http.fetch hook stopped this request`| [Turn mods on or off](</docs/en/plugins/mods/overview#turn-mods-on-or-off>)
+`hook was skipped. "<mod>" runs first and sent the event on past it.`| If you listed the quoted mod in [`prependPlugins`](</docs/en/settings-reference#prependplugins>) in your user settings, change that mod. Otherwise, ask your administrator.
+`<file>: changed while it was read`| If `claude plugin validate` printed this, rerun it. Otherwise, restart the session.
+`installed mods are off for now`| [Check whether mods can load](</docs/en/plugins/mods/troubleshoot#check-whether-mods-can-load>)
+`the hooks worker was lost with <mod>'s <event> hook in flight`| Fix the named mod. For one cause, see [`it crashed the hooks worker`](</docs/en/plugins/mods/troubleshoot#it-crashed-the-hooks-worker>).
+`dispatches in a row for fills by <mods>`| Change the named mods so they fill the prompt box at most eight times in a row.
`Error: No such tool available: <tool name>`| Tool errors
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
`MCP server "<name>" is disabled — re-enable it via /mcp to use its tools`| Tool errors
`MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit.`| Tool errors
+`The server's response is not a valid MCP response, so it was not read`| Before retrying, check whether the request ran. Report the error to the MCP server’s author.
`Permission prompt tool returned an invalid result`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
@@ -425,6 +440,7 @@
`Disk full: this computer's volume holding <dir> (Claude Code's temporary directory) has <n> MB free` / `Nearly out of inodes: this computer's volume holding <dir>`| Tool errors
`Disk full: a test write beside this command's output file` / `Disk quota used up: a test write beside this command's output file`| Tool errors
`The command was not started: this computer's disk is full (ENOSPC)` / `the user's disk quota is used up (EDQUOT)`| Tool errors
+`The sandbox could not create <dir>, a folder it must protect from the command, because the temp disk is full`| Free space on the temp disk or repair it, then have Claude run the command again.
`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)` / `The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
@@ -477,12 +493,19 @@
`Subprocess initialization did not complete within 60000ms`| Wrapper and IDE errors
`Claude Code did not finish starting`| Wrapper and IDE errors
`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
+`Dictation error: The speech service refused the connection` / `Dictation error: The connection to the speech service was lost` / `Dictation error: Couldn’t connect to the speech service`, in VS Code| Run **Claude Code: Show Logs** from the Command Palette and search for `Speech-to-text`.
+`The last request was refused`, on the VS Code sign-in screen| Select **Cancel** , then look up the conversation’s error in this table.
+`Plan not copied: The new session starts without a plan file.`, in VS Code| If you need the plan, ask Claude to write it again in the new session.
+`A message is still queued` / `A /clear is still queued`, when you rewind code in VS Code| Stop Claude, then follow the rest of the message.
+`Couldn’t load the diff view or code colors`, in VS Code| Click a diff to try again, or reload the window.
+`Settings file is empty, and another program may still be writing it: <path>`, in VS Code| Try again in a minute. If the message repeats, put `{}` in the file.
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Claude Code could not be started from <command>: it is the <system> build, and this computer needs the <build> build`| If you set [`claudeCode.claudeProcessWrapper`](</docs/en/vs-code#extension-settings>), point it at a program built for `<build>`. Otherwise, install the VS Code extension package for `<build>`.
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
`Couldn't restore N files: the backup is missing or the file can't be written`| Make the files that failed writable, then restore them from version control.
+`Kept N files created since then, because a restore failed`| If you don’t want the files Claude created after the checkpoint, delete them.
`The file backups are still being copied. Nothing was changed. Try again in a moment.`| Select the same point in [`/rewind`](</docs/en/checkpointing>) again. When you restore code soon after [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code can still be copying the file backups to the new session.
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
@@ -527,6 +550,7 @@
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
`matches no tool · check for typos` / `matches no known tool — check for typos`| Configuration warnings
+`lets <tool> run without asking only in the working directories` / `adds nothing to <tool>'s default`| [Allow a file tool outside the working directories](</docs/en/permissions#allow-a-file-tool-outside-the-working-directories>)
`... is not matched by file permission checks`| Configuration warnings
`Write(<path>) never matches · use Edit(<path>)` / `Glob(<path>) never matches · use Read(<path>)`| Configuration warnings
`... has a wildcard before the rest of the command`| Configuration warnings
@@ -4673,6 +4697,25 @@
* Send the message again. The next message starts a fresh `claude` process that resumes the conversation.
* If it repeats, run `claude` in a terminal in the same project. A failure that keeps ending the process usually reproduces there with its real error message.
+### Claude Code needs a recent sign-in
+
+When a local, WSL, or SSH session in the Code tab needs a new saved sign-in and you haven’t signed in recently, the [Claude Desktop app](</docs/en/desktop>) shows this message:
+
+ For security, Claude Code needs a recent sign-in.
+
+For these sessions, being asked up to about once a month for each account and organization on each computer is routine, with or without single sign-on (SSO). **What to do:**
+
+ * Click **Sign in again** on the card, then sign in
+ * If a banner at the top of the Code tab says `Claude Code needs a recent sign-in. Signing in won’t stop sessions.`, click **Sign in again** on the banner
+ * If you’re asked again within three weeks for these sessions, with the same account and organization on the same computer, [check your version](</docs/en/desktop#check-your-version>) of Claude Desktop. If it’s older than v5.11492.0, update it:
+ * **macOS** : select **Claude > Check for Updates…**
+ * **Windows** : select **Help > Check for Updates…**, or update through the Microsoft Store if you installed the app from there
+ * **Linux** : [update through apt](</docs/en/desktop-linux#update>)
+ * **Managed updates** : if your organization [turns off auto-updates](</docs/en/desktop#device-management-policies>), ask your administrator for v5.11492.0 or later
+ * If that continues on v5.11492.0 or later, [contact support](</docs/en/desktop#still-stuck>)
+
+If you see the card in a Remote Control session, see [Trusted Devices](</docs/en/remote-control#trusted-devices>), which can ask for a more recent sign-in. Before Claude Desktop v5.11492.0, the Code tab could lose its saved sign-in when a company proxy or gateway answered its background renewal with a JSON error.
+
## Rewind warnings and errors
These messages come from a [`/rewind`](</docs/en/checkpointing>) code restore. `Restored the code, but skipped N files` is a warning that Claude Code skipped some paths. `No files were restored` is an error that means it restored nothing.
@@ -4697,7 +4740,7 @@
### No files were restored
-Claude Code shows this message when you restore code with [`/rewind`](</docs/en/checkpointing>) and it can’t restore any of the files in that checkpoint. For each file, either the backup Claude Code saved before editing it is missing, or Claude Code couldn’t write to or delete the file.
+You see this message when a [`/rewind`](</docs/en/checkpointing>) code restore fails on at least one file and restores no files.
Failed to restore the code:
No files were restored: 1 file failed (backup missing, or the file could not be updated)
--- a/errors.md
+++ b/errors.md
@@ -318,6 +318,9 @@
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
`Windows reported an error (EBADF) when Claude Code read this session's transcript file`| Command-line errors
+`Failed to resolve base branch "HEAD"` / `Failed to resolve HEAD in <folder>`| [Run parallel sessions with worktrees](</docs/en/common-workflows#run-parallel-sessions-with-worktrees>)
+`points to a bare repository`| [Manage worktrees manually](</docs/en/worktrees#manage-worktrees-manually>)
+`Cannot use PR/MR #<number>`| Follow the fix in the message.
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
`Can't restart while work is running in the background`| Command-line errors
@@ -338,6 +341,7 @@
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Claude Code refuses the marketplace name "<name>"`| Plugin errors
`Marketplace name impersonates an official Anthropic/Claude marketplace`| Plugin errors
+`Can't use the marketplace name "<name>"`| [Reserved names](</docs/en/plugins/marketplace-reference#reserved-names>)
`Marketplace "<name>" is already added from a different source`| Plugin errors
`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
`Cannot add marketplace "<name>": Claude Code cannot install plugins from a marketplace with this name`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#cannot-install-plugins-from-a-marketplace-with-this-name>)
@@ -355,6 +359,8 @@
`does not load (...), so Claude Code ignores the whole file`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#does-not-load-so-claude-code-ignores-the-whole-file>)
`path escapes plugin directory`| Plugin errors
`path not read: <path> is absolute or has a ".." part`| Plugin errors
+`Plugin path not found: <path>`| Fix the plugin path you started the session with. For a plugin synced from claude.ai, restart Claude Code.
+`commands path not found: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#commands-path-not-found>)
`Plugin not loaded: its manifest <path> was not read`| Plugin errors
`path couldn't be checked` / `path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
@@ -395,6 +401,7 @@
`Sandbox is required (sandbox.failIfUnavailable) and stopped being available in this session: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
`pkill: refusing to run`| Tool errors
`Sandbox settings can't be changed here` / `Sandbox settings are overridden by a higher-priority configuration`| [Sandboxing troubleshooting](</docs/en/sandboxing#sandbox-settings-overridden>)
+`GH_HOST names a host other than github.com` / `GH_REPO names a host other than github.com`| Ask Claude to pass `--hostname <host>` on the `gh api` command, as in `gh api --hostname ghe.example.com repos/my-org/my-repo/pulls`. For `GH_REPO`, also have Claude replace the command’s `{owner}` and `{repo}` with real names.
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
@@ -511,6 +518,7 @@
`Managed settings drop-in directory could not be read`| Configuration warnings
`Unable to read managed policy settings`| Configuration warnings
`Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:`| Configuration warnings
+`did not load, so nothing in them is in effect` / `These settings entries were skipped` in a `-p` run| [Broken settings in a `-p` run](</docs/en/settings#broken-settings-in-a-p-run>)
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`apply_flag_settings: nothing in this request was applied and earlier settings stay in force. Fix or remove these invalid settings and send it again`| [`applyFlagSettings()`](</docs/en/agent-sdk/typescript#applyflagsettings>)
`Invalid JSON provided to --settings` / `Invalid JSON provided to the settings option`| [`--settings` flag](</docs/en/cli-reference#cli-flags>) or [`settings` option](</docs/en/agent-sdk/typescript#options>)
@@ -597,8 +605,8 @@
Variable| Default| Effect
---|---|---
-[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
-[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
+[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts, capped at 15. Lower it to surface failures faster in scripts. With `CLAUDE_CODE_RETRY_WATCHDOG` set on v2.1.199 or later, the cap doesn’t apply, and the default for transient errors other than capacity errors is 300.
+[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to keep retrying `429` and `529` capacity errors past `CLAUDE_CODE_MAX_RETRIES`. For exceptions, see When the retry watchdog stops retrying. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>).
[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
`CLAUDE_CODE_RETRY_WATCHDOG_MAX_USAGE_LIMIT_WAIT_MS`| no cap| With `CLAUDE_CODE_RETRY_WATCHDOG` set, the longest time in milliseconds one request waits for your plan’s usage limit, such as the session or weekly limit, to reset. When the reset is further away than this cap, the request fails at once, unless usage credits have room or the API couldn’t check them. In those cases it’s retried, and fails if the cap passes before it succeeds. Requires Claude Code v2.1.301 or later.
[`CLAUDE_CODE_RETRY_WATCHDOG_USAGE_LIMIT_RECHECK_MS`](</docs/en/env-vars>)| unset| Minimum interval in milliseconds between checks of whether a usage limit was already lifted, while a request waits for that limit to reset with `CLAUDE_CODE_RETRY_WATCHDOG` set. When a check finds the limit lifted, the request goes out at once. Give plain digits from `60000` to `10800000`. When unset or outside that range, no checks are made. For when Claude Code skips these checks, see the [environment variables reference](</docs/en/env-vars>). Requires Claude Code v2.1.305 or later.
@@ -607,6 +615,16 @@
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Time in milliseconds that each request attempt has to receive its response headers. It doesn’t limit how long a streaming response runs after that. Raise it for slow networks or proxies. For how it caps the first-byte deadline, see No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. For each attempt’s timeout, see How long a non-streaming attempt waits. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
+
+#### When the retry watchdog stops retrying
+
+With `CLAUDE_CODE_RETRY_WATCHDOG` set, Claude Code stops retrying a request outside fast mode on responses such as these:
+
+ * **Spend limit** : a `429` for a usage-credit spend limit, or for a gateway spend cap that resets on a schedule.
+ * **Exhausted[usage credits](</docs/en/costs#add-usage-credits-to-your-subscription>)**: an out-of-credits `429` with no `anthropic-ratelimit-unified-overage-status` or `anthropic-ratelimit-unified-representative-claim` header.
+ * **Marked not retryable** : a `429` or `529` with the [`x-should-retry: false`](</docs/en/llm-gateway-protocol#response-headers>) header. Claude Code still retries the request when the API couldn’t check your usage credits.
+
+The spend limit and usage credit cases require Claude Code v2.1.239 or later. The `x-should-retry` case requires v2.1.311 or later.
#### How long a non-streaming attempt waits
@@ -3095,7 +3113,7 @@
### Skill, command, or hook over the 4,000,000-character limit
-A message with `more than 4,000,000 characters` means a skill, a command, or a [prompt or agent hook](</docs/en/hooks#prompt-and-agent-hook-fields>) didn’t run. If you pasted long text as arguments, save it to a file, run `/clear`, since the text stays in the conversation, then pass its path. If your `PreToolUse` prompt or agent hook is over the limit, a tool call that Claude makes directly isn’t blocked. Use a [command hook](</docs/en/hooks#command-hook-fields>), which has no such limit. For a call from code in Code Mode, see [Tool call refused by a hook](</docs/en/code-mode#tool-call-refused-by-a-hook>).
+A message with `more than 4,000,000 characters` means a skill, a command, or a [prompt or agent hook](</docs/en/hooks#prompt-and-agent-hook-fields>) didn’t run. If you pasted long text as arguments, save it to a file, run `/clear`, since the text stays in the conversation, then pass its path. If your `PreToolUse` prompt or agent hook is over the limit, a tool call that Claude makes directly isn’t blocked. Use a [command hook](</docs/en/hooks#command-hook-fields>), which has no such limit. For a call from code in Code Mode, see [Tool call ran after a hook failed](</docs/en/code-mode#tool-call-ran-after-a-hook-failed>).
### Input must be provided when using `--print`
@@ -3641,7 +3659,7 @@
* One of a plugin’s [default component locations](</docs/en/plugins/manifest-reference#standard-layout>), such as the `skills/` folder, the `monitors/monitors.json` file, or a [`SKILL.md` at the plugin root](</docs/en/plugins/components#skills>): the plugin’s other components still load
* The plugin’s own directory: nothing from that plugin loads
-You don’t see this error for a path that doesn’t exist at all. In `/plugin`, the error appears under the plugin and names the path and the code the operating system returned:
+In `/plugin`, the error names the path and the code the operating system returned:
skills path couldn't be checked: /home/user/my-plugin/skills (ELOOP)
--- a/errors.md
+++ b/errors.md
@@ -1001,11 +1001,11 @@
### Could not resolve authentication method
-The session reached the API client without any credential. [Background sessions](</docs/en/agent-view>) and cloud sessions show this message when the worker starts without a credential. Interactive, `-p`, and Agent SDK runs report the same condition as Not logged in and write this string only to their debug log, so if you found it there, follow that entry instead.
+The session reached the API client without any credential. If an interactive, `-p`, or Agent SDK run showed Not logged in and this string is in its debug log, follow that entry.
Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
-On current versions the error means no credential was available to the worker process. Before v2.1.174, a background session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Before v2.1.176, a cloud session that sat idle before being claimed could too. Upgrade to recover. **What to do:**
+Before v2.1.174, a background session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Before v2.1.176, a cloud session that sat idle before being claimed could too. Upgrade to recover. **What to do:**
* Upgrade to v2.1.176 or later if this appears in a background or cloud session and your credentials are already configured
* Confirm `ANTHROPIC_API_KEY`, `CLAUDE_CODE_OAUTH_TOKEN`, or your cloud provider credentials are set in the environment that launches the worker, not only in your interactive shell
@@ -4687,7 +4687,7 @@
Claude Code deletes a session’s backups in the [retention sweep](</docs/en/claude-directory#cleaned-up-automatically>), by default about 30 days after the session last saved one. If you resume a session after that, `/rewind` still lists its checkpoints, but rewinding to one of them can fail with this error. If the message also says `N paths were skipped for link safety`, see Restored the code, but skipped files for those paths. When you fork a session, for example with [`--fork-session`](</docs/en/cli-reference#cli-flags>) or [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code copies the original session’s backups into the fork. When Claude Code can’t copy a backup, for example because the disk is full, that backup is missing in the fork. Rewinding to a checkpoint that needs it can fail with this error. **What to do:**
* Undo the changes another way: ask Claude to reverse its edits, or restore the files from version control. When the backups are gone, running `/rewind` again fails the same way.
- * If Claude Code couldn’t write or delete a file, fix what blocks the write, such as file permissions, then run `/rewind` again.
+ * If Claude Code couldn’t write or delete a file after you chose **Restore code** , fix what blocks the write, such as file permissions. Then run `/rewind` again.
* To keep backups longer in future sessions, raise [`cleanupPeriodDays`](</docs/en/settings-reference#cleanupperioddays>).
Before v2.1.260, Claude Code silently skipped files whose backups were missing, and the rewind appeared to succeed.
@@ -4710,7 +4710,7 @@
Before v2.1.217, Claude Code dropped the failing writes without a warning, and a later `--resume` missing recent messages was the first sign. **What to do:**
* Fix the condition the error code names: free disk space for `ENOSPC`; raise or clear the quota for `EDQUOT`; restore write access to the transcript location for `EACCES`, `EPERM`, or `EROFS`
- * The warning clears on its own at the next successful write; no restart is needed
+ * The warning clears on its own at the next successful write
* Messages sent while the warning was showing may still be missing when you resume the session later
### Transcript saving is off because CLAUDE_CODE_SKIP_PROMPT_HISTORY is set
Show diff (116 lines)
--- a/errors.md
+++ b/errors.md
@@ -96,6 +96,14 @@
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Managed settings on this machine configure a Cloud gateway sign-in; run interactive /login to authenticate.`| [`claude auth login`](</docs/en/cli-reference#cli-commands>)
+`You chose an organization that is managed in Anthropic's Enterprise Admin Console`| [Turn on sign-in from Claude Code](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#turn-on-sign-in-from-claude-code>)
+`The organization's settings won't apply on this computer`| [Which settings take priority](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#which-settings-take-priority>)
+`no usable organization sign-in` / `no readable organization sign-in`| [When a sign-in ends](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#when-a-sign-in-ends>)
+`the session no longer runs under that sign-in` / `This Claude Code process ran under your organization` / `After a sign-in to your organization, only a new session sends requests`| [Log in to Claude Code](</docs/en/authentication#log-in-to-claude-code>)
+`This conversation ran under organization` / `This conversation ran under more than one organization`| [Log in to Claude Code](</docs/en/authentication#log-in-to-claude-code>)
+`Claude Code could not read the managed settings that apply to this computer, which may require a sign-in to Anthropic`| [`enforceAnthropicSignIn`](</docs/en/settings-reference#enforceanthropicsignin>)
+`This computer's managed settings require a sign-in to Anthropic` / `This computer's settings require a sign-in to Anthropic that this app cannot use`| [Require the sign-in](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code#require-the-sign-in-with-managed-settings>)
+`This computer's managed settings set the Microsoft Foundry key or token in use` / `This computer's managed settings could not be read, so the Microsoft Foundry key or token in use may be theirs`| [Managed settings that conflict with the console](<https://claude.com/docs/third-party/claude-desktop/admin-console-claude-code-reference#managed-settings-that-conflict-with-the-console>)
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`Login reached its time limit · Please run /login` / `Failed to authenticate: this login reached its time limit`| Authentication
`Failed to authenticate: your claude.ai login expired`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
@@ -106,6 +114,7 @@
`Could not refresh your login: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
`Failed to refresh OAuth token: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
+`This account is on hold and can't sign in` / `This Claude Design account is on hold` / `The account signed in to Claude Design is on hold`| Open the link in the message to view details or appeal.
`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
`Login expired · Run /login to sign in again, or re-authenticate your Anthropic profile`| Authentication
@@ -235,10 +244,12 @@
`Error: bypassPermissions not supported in restricted mode`| [Restricted mode](</docs/en/permission-modes#restricted-mode-refuses-bypasspermissions>)
`Session was started with bypass permissions, so plan mode won't ask before most edits or commands`| [Plan mode](</docs/en/permission-modes#analyze-before-you-edit-with-plan-mode>)
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
+`--fork-session can't fork a cloud session, so nothing was opened or sent`| [Errors when sending to a cloud session](</docs/en/claude-code-on-the-web#errors-when-sending-to-a-cloud-session>)
`Cloud sessions are disabled by your organization's policy`| Command-line errors
`Cloud sessions use your claude.ai login`, at the end of a policy denial that names a credential| Command-line errors
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
`Cloud sessions aren't available:` followed by why your organization’s policy couldn’t be loaded| Command-line errors
+`Branch '<branch>' was not checked out`| [Teleport requirements](</docs/en/claude-code-on-the-web#teleport-requirements>)
`Cloud sessions aren't available with this Console sign-in. They need a claude.ai sign-in.`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Cloud sessions need a claude.ai sign-in`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Nothing was stashed: "<path>" is now a folder in place of a tracked file or link` / `are now folders in place of tracked files or links`| Command-line errors
@@ -272,6 +283,7 @@
`Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes`| Command-line errors
`MCP server "<name>" was not saved to` / `was not removed from`| Command-line errors
`MCP server "<name>" may not have been saved` / `may not have been removed`| Command-line errors
+`Names that start with "claude.ai " are claude.ai connectors, which Claude Code can't remove` / `is a claude.ai connector, Claude Code can't remove it`| [Disable claude.ai connectors](</docs/en/mcp#disable-claude-ai-connectors>)
`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
`This server (Java MCP SDK 0.17.0 or older) rejected Claude Code's elicitation capability`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
@@ -292,6 +304,7 @@
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
`Your checkout has no branches (detached HEAD only)`| Command-line errors
+`but its shell has moved to`, from `/code-review ultra` or `/ultrareview`| Start a new session in the repository you want reviewed.
`Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected`| Command-line errors
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
@@ -378,6 +391,7 @@
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`Sandbox is required but failed to initialize: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
+`too long for macOS, which limits their total size` / `one path in the sandbox's rules is longer than macOS accepts`| Follow the fix in the message, such as shortening a path list or removing unused git worktrees.
`Sandbox is required (sandbox.failIfUnavailable) and stopped being available in this session: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
`pkill: refusing to run`| Tool errors
`Sandbox settings can't be changed here` / `Sandbox settings are overridden by a higher-priority configuration`| [Sandboxing troubleshooting](</docs/en/sandboxing#sandbox-settings-overridden>)
@@ -396,6 +410,7 @@
`Refusing to write through symlink: <path>` / `Refusing to write into symlinked directory: <path>`| Tool errors
`Refusing to write <path>: where it leads on disk could not be determined` / `Refusing to read <path>: where it leads on disk could not be determined`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
+`can't be verified and was not run` / `Claude can't use tools in its working folder` / `Claude couldn't use a tool in its working folder`| If it keeps happening, start a new session in the place the message suggests.
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`The search failed, so this is not a "no matches" result: matches may exist`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
@@ -436,6 +451,7 @@
`kept <id> — its worktree is still at <path>`| Background session errors if the message’s next line mentions unpushed commits, otherwise [What deleting a session removes](</docs/en/agent-view#what-deleting-a-session-removes>)
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
+`Worktree kept at` with `another Claude Code session (...) is running in it`| [Clean up worktrees](</docs/en/worktrees#clean-up-worktrees>)
`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
`Session isn't responding` / `Press enter again to restart this session — it isn't responding`| Background session errors
`Session <id> was stopped while the respawn was in flight`| Background session errors
@@ -455,6 +471,7 @@
`Claude Code did not finish starting`| Wrapper and IDE errors
`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
+`Claude Code could not be started from <command>: it is the <system> build, and this computer needs the <build> build`| If you set [`claudeCode.claudeProcessWrapper`](</docs/en/vs-code#extension-settings>), point it at a program built for `<build>`. Otherwise, install the VS Code extension package for `<build>`.
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
@@ -496,6 +513,7 @@
`Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:`| Configuration warnings
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`apply_flag_settings: nothing in this request was applied and earlier settings stay in force. Fix or remove these invalid settings and send it again`| [`applyFlagSettings()`](</docs/en/agent-sdk/typescript#applyflagsettings>)
+`Invalid JSON provided to --settings` / `Invalid JSON provided to the settings option`| [`--settings` flag](</docs/en/cli-reference#cli-flags>) or [`settings` option](</docs/en/agent-sdk/typescript#options>)
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
@@ -2736,9 +2754,9 @@
Error: Claude Code could not save all of this session's transcript under /Users/you/.claude because the disk is full (ENOSPC). If you resume this session, part of the conversation may be missing. Free up space on that disk before the next run.
-With text or `json` output, the run exits with code 1, and the answer has already been printed. With `stream-json` output, the run keeps its usual exit code, and the answer still arrives. **What to do:**
-
- * **`the disk is full (ENOSPC)`** : before your next run, free up space on the disk that holds the path in the message
+The run exits with code 1 when the output format is text or `json`, or when the message names `output sent to a file`. Other `stream-json` runs keep their usual exit code. **What to do:**
+
+ * **`the disk is full (ENOSPC)`** : before your next run, free up space on the disk that holds your output file or the path in the message
* **`your disk quota is used up (EDQUOT)`** : before your next run, free up space or ask for a larger quota
### Directory couldn’t be resolved to a real location
@@ -3077,7 +3095,7 @@
### Skill, command, or hook over the 4,000,000-character limit
-A message with `more than 4,000,000 characters` means a skill, a command, or a [prompt or agent hook](</docs/en/hooks#prompt-and-agent-hook-fields>) didn’t run. If you pasted long text as arguments, save it to a file, run `/clear`, since the text stays in the conversation, then pass its path. Outside [Code Mode](</docs/en/code-mode#tool-call-refused-by-a-hook>), a `PreToolUse` prompt or agent hook over the limit doesn’t block the call. Use a [command hook](</docs/en/hooks#command-hook-fields>), which has no such limit.
+A message with `more than 4,000,000 characters` means a skill, a command, or a [prompt or agent hook](</docs/en/hooks#prompt-and-agent-hook-fields>) didn’t run. If you pasted long text as arguments, save it to a file, run `/clear`, since the text stays in the conversation, then pass its path. If your `PreToolUse` prompt or agent hook is over the limit, a tool call that Claude makes directly isn’t blocked. Use a [command hook](</docs/en/hooks#command-hook-fields>), which has no such limit. For a call from code in Code Mode, see [Tool call refused by a hook](</docs/en/code-mode#tool-call-refused-by-a-hook>).
### Input must be provided when using `--print`
Show diff (251 lines)
--- a/errors.md
+++ b/errors.md
@@ -34,6 +34,7 @@
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit` / `You've hit your Opus limit` / `You've hit your Sonnet limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
+`Usage credits ran out before the response was finished.`| [Add usage credits](</docs/en/costs#add-usage-credits-to-your-subscription>)
`the prompt to confirm went unanswered · nothing was sent`, from v2.1.324| Usage limits
`Claude stopped here · send a message to be asked again`| Usage limits
`Server is temporarily limiting requests`| Usage limits
@@ -78,6 +79,7 @@
`Remote Control was turned off by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-was-turned-off-by-your-organizations-policy>)
`Session failed: working folder not found:`| [Troubleshoot Remote Control](</docs/en/remote-control#working-folder-not-found>)
`The program file this Remote Control started from is gone`| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
+`Session failed: program not found:`| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
`Session failed: spawn error:` followed by an `ENOENT` message| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
`Remote Control disconnected:` followed by a reason that mentions a `share link`| [Remote Control](</docs/en/remote-control#what-connected-devices-see>)
`OAuth token revoked` / `OAuth token has expired`| Authentication
@@ -85,6 +87,7 @@
`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`Warning: this sign-in`| [Check when a stored login ends](</docs/en/authentication#check-when-a-stored-login-ends>)
`The browser can't return the sign-in to Claude Code automatically`| Authentication
`Couldn't start the local listener that receives the browser sign-in. Try again.`| Authentication
`Failed to start OAuth callback server`| Authentication
@@ -97,6 +100,7 @@
`Login reached its time limit · Please run /login` / `Failed to authenticate: this login reached its time limit`| Authentication
`Failed to authenticate: your claude.ai login expired`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
`claude.ai login ended · usage now billed to` / `Warning: the claude.ai login on this machine has ended`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
+`The refresh token in CLAUDE_CODE_OAUTH_REFRESH_TOKEN was used for this attempt`| Fix the refusal printed above it, then set [`CLAUDE_CODE_OAUTH_REFRESH_TOKEN`](</docs/en/env-vars#variables>) to a new token.
`Could not refresh your login because another Claude Code process is refreshing it`| Authentication
`Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh`| Authentication
`Could not refresh your login: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
@@ -149,10 +153,11 @@
`403` with `x-deny-reason: host_not_allowed` in a cloud session or cloud scheduled task| Network
`proxy refused the connection`| Network
`403` with `GitHub GraphQL is not available from Claude Code sessions` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
+`ENOTFOUND` with `In this cloud session a host fails to resolve like this`| Network
`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
`Failed to fetch session from Sessions API: Failed to fetch session logs`| Network
`Couldn't load the history of cloud session`| Network
-`Couldn't reconnect to your Remote Control session`| Network
+`Couldn't reconnect to your Remote Control session`| [Troubleshoot Remote Control](</docs/en/remote-control#couldnt-reconnect-to-your-remote-control-session>)
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
`Couldn't send feedback`| Network
@@ -200,6 +205,7 @@
`thinking.type.enabled is not supported for this model`| Request errors
`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
`effort '<level>' is not supported when thinking is disabled`| Request errors
+`API Error: 400 Invalid effort level` / `Your organization limits effort for <model>, so Claude Code is using '<level>' instead of '<level>'`| [Organization effort limits](</docs/en/model-config#organization-effort-limits>)
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`Claude's response exceeded the ... output token maximum`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
@@ -306,7 +312,7 @@
`Claude Code couldn't restart`| Command-line errors
`Couldn't open Claude Desktop`| Command-line errors
`Failed to open Claude Desktop. Please try opening it manually.`| Command-line errors
-`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
+`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap` / `Your Zed keymap is a symbolic link`| Command-line errors
`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
`Skill usage reports are not available on this connection.`| Command-line errors
`Custom output styles can't be selected over Remote Control or from a relayed message`| Command-line errors
@@ -324,6 +330,8 @@
`Cannot add marketplace "<name>": Claude Code cannot install plugins from a marketplace with this name`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#cannot-install-plugins-from-a-marketplace-with-this-name>)
`Cannot add marketplace "<name>": Claude Code reserves this name and cannot register a marketplace under it`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#claude-code-reserves-this-name>)
`Marketplace "<name>" is added but ignored`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
+`Marketplace "<name>", which managed settings declare, stands from another source and cannot be taken back while its declared source is unreachable`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-cannot-be-taken-back-while-its-declared-source-is-unreachable>)
+`The list of installed plugins (installed_plugins.json) could not be read, so marketplace "<name>", which managed settings declare, cannot be taken back from another source`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-could-not-be-read-so-marketplace-cannot-be-taken-back>)
`Marketplace "<name>" is registered but was refused (see the debug log)`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -344,6 +352,7 @@
`"<plugin>" was not uninstalled: it is still switched on in <file>`| Plugin errors
`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
+`was updated or removed, so this hook did not run`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-directory-does-not-exist>)
`Plugin directory does not exist: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-directory-does-not-exist>)
`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
`is not added on this machine, so your organization's marketplace policy keeps its plugins off`| [Add a marketplace](</docs/en/plugins/install#add-a-marketplace>)
@@ -379,6 +388,7 @@
`cannot be handed to a teammate intact`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
+`Held a message from <sender>` / `Dropped the held message from <sender> without delivering it`| [Control inbound messages](</docs/en/cross-session-messaging#control-inbound-messages>), or [Non-interactive sessions](</docs/en/cross-session-messaging#non-interactive-sessions>) for `claude -p`
`Cross-session message was dropped at the recipient session's inbox`| Tool errors
`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
@@ -398,6 +408,7 @@
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`git is not installed on this Mac. To install it, run xcode-select --install, then try again.`| Tool errors
`Refusing to apply edits to <path>: a hook is configured for file edits in this session`| Tool errors
+`blocking because onFailure is "block"`| [Block the action when a hook fails](</docs/en/hooks#block-the-action-when-a-hook-fails>)
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
@@ -584,7 +595,7 @@
A non-streaming attempt ends at its request timeout or at the body idle timeout, whichever comes first:
* **Request timeout** : `API_TIMEOUT_MS` when you set a positive value, otherwise 300 seconds in a local session.
- * **[Body idle timeout](</docs/en/network-config#streaming-idle-watchdogs>)** : 5 to 6 minutes without a response, however high you set `API_TIMEOUT_MS`, where it runs and you haven’t turned it off.
+ * **[Body idle timeout](</docs/en/network-config#streaming-idle-watchdogs>) where it runs**: by default, 5 to 6 minutes without a response, however high you set `API_TIMEOUT_MS`.
## Server errors
@@ -625,7 +636,8 @@
* If every request fails with this message and you set `API_TIMEOUT_MS` to `0`, check `claude --version`. On a version before v2.1.305, update Claude Code or set a positive value.
* Retry the request
- * If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
+ * If the message continues past `Request timed out` and names an [environment variable](</docs/en/env-vars#set-environment-variables>), do what the message says. `No data arrived` means the [body idle timeout](</docs/en/network-config#streaming-idle-watchdogs>) ended the request.
+ * With a slow network or proxy on a version before v2.1.328, raise `API_TIMEOUT_MS`. If the request still times out, [update to v2.1.328 or later](</docs/en/setup#update-claude-code>) and set any variable the next timeout message names. If you can’t update, set [`API_FORCE_IDLE_TIMEOUT`](</docs/en/env-vars>) to `0`.
* If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
### No response from API
@@ -998,7 +1010,7 @@
### Your apiKeyHelper script is failing
-Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. The `Authentication` panel in the terminal shows which of these happened:
+Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. A panel in the terminal shows which of these happened:
* The command exited with an error or timed out
* The command printed nothing to stdout
@@ -1012,7 +1024,6 @@
* If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
* Fix the command so it prints only the key to stdout, as a single token of printable ASCII up to 16,384 characters, and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
* Run `/status` to see the failure and confirm `apiKeyHelper` is the active credential source. The `apiKeyHelper` row shows `Failing` with the last failure’s detail, such as the exit code and the command’s error output, and disappears after the next successful run. Before v2.1.274, `/status` showed only the credential source, not the failure.
- * Each time the command fails, its exit code and error output also appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
### Claude Code didn’t send your claude.ai login
@@ -1309,7 +1320,7 @@
An API key may still be in `~/.claude.json` too if a Console login created one on Linux or Windows. **What to do:**
- * Run `claude auth logout` in your shell to try the save again. When the save goes through, the command prints `Successfully logged out from your Anthropic account.`
+ * Run `claude auth logout` in your shell to try the save again
### Couldn’t start the local listener that receives the browser sign-in
@@ -1844,7 +1855,7 @@
The cloud environments service returned a response in an unexpected format (HTTP 200 with a non-JSON body). This is usually temporary — try again in a moment.
The cloud environments service returned a response in an unexpected format (HTTP 200 without a usable environments list). This is usually temporary — try again in a moment.
-The server accepted the request but answered with a body that isn’t the environments list: empty, not JSON, or JSON without the list. This usually accompanies a service-side disruption and clears on its own. Depending on the surface that requested the list, Claude Code may add a prefix, such as `couldn't list environments:` in the `/remote-env` dialog. **What to do:**
+**What to do:**
* Retry the action. Claude Code requests the list again each time
* If the message keeps appearing, check [status.claude.com](<https://status.claude.com>) for active incidents
@@ -1875,15 +1886,7 @@
### Couldn’t reconnect to your Remote Control session
- Couldn't reconnect to your Remote Control session. Retry, or start a fresh session without --resume.
-
-Resuming with `claude --resume` or `claude --continue` reconnects to the [Remote Control](</docs/en/remote-control>) session recorded in that conversation. This message means the reconnection failed for a reason that may be temporary, such as a network interruption or a server error, so Claude Code can’t confirm whether the remote session still exists. Your local session keeps running without Remote Control. **What to do:**
-
- * Run `/remote-control` to retry the connection
- * Start a new session with `claude --remote-control` to create a new Remote Control session
- * For other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
-
-If the server reports instead that the previous session is gone, you don’t see this message. Claude Code starts a new session in its place or shows [`Previous session is unavailable — run /remote-control to start a new one`](</docs/en/remote-control#previous-session-is-unavailable>).
+For the cause and the fix, see [this message in Remote Control troubleshooting](</docs/en/remote-control#couldnt-reconnect-to-your-remote-control-session>).
### Sessions ended while this machine was offline
@@ -2135,7 +2138,12 @@
API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid
API Error: 400 ... tools.N.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'
-The first form means the schema isn’t valid JSON Schema draft 2020-12. The second means a top-level property name doesn’t match the pattern the message quotes. Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a [deployment where flag fetching is off](</docs/en/env-vars#features-that-need-feature-flag-fetching>), or on a machine whose flags have never arrived, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`. Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though the top-level property-name check still applies. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
+The first form means the schema isn’t valid JSON Schema draft 2020-12. The second means a top-level property name doesn’t match the pattern the message quotes. Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. The error can still occur, such as when:
+
+ * [Feature flag fetching](</docs/en/env-vars#features-that-need-feature-flag-fetching>) is on but the [flags haven’t arrived](</docs/en/env-vars#first-session-after-an-install-or-upgrade>). Before v2.1.328, the error could also occur with fetching off.
+ * The tool’s schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`.
+
+**What to do:**
* If your Claude Code version is earlier than v2.1.300, run [`claude update`](</docs/en/setup#update-claude-code>) in your shell. Before v2.1.300, Claude Code didn’t [retry the request without the rejected tool’s parameters](</docs/en/mcp#tools-whose-input-schema-the-api-refuses>), so this error repeated on every request that included the tool.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
@@ -3382,7 +3390,7 @@
### /terminal-setup left your Zed keymap unchanged
-You ran [`/terminal-setup`](</docs/en/terminal-config#enter-multiline-prompts>) in Zed, and Claude Code couldn’t complete the update to your Zed `keymap.json`, so it left the file as it was. Each message names the path to your keymap and ends with the keybinding block to add yourself:
+You ran [`/terminal-setup`](</docs/en/terminal-config#enter-multiline-prompts>) in Zed, and Claude Code couldn’t complete the update to your Zed `keymap.json`, so it left the file as it was. Each message names the path to your keymap and includes the keybinding block to add yourself:
Couldn't update your Zed keymap, so it was left unchanged.
To add the binding yourself, add this block to the keymap array in <path to keymap.json>:
@@ -3392,6 +3400,7 @@
* `Couldn't read your Zed keymap, so it was left unchanged.`: Claude Code couldn’t read the file, for example because of file permissions
* `Your Zed keymap isn't a readable list of keybindings, so it was left unchanged.`: the file read fine but doesn’t parse as an array of keybinding blocks, even with `//` comments and trailing commas allowed
+ * `Your Zed keymap is a symbolic link, so it was left unchanged.`: `keymap.json` links to another file
* `Couldn't back up your Zed keymap; not modifying it.`: Claude Code couldn’t copy the file to a `.bak` backup beside it, so it changed nothing
* `Couldn't update your Zed keymap, so it was left unchanged.`: the merged result didn’t verify as a valid keymap carrying the binding, so Claude Code discarded it instead of writing. A keybinding block with a duplicated key can cause this
@@ -3482,15 +3491,7 @@
### Marketplace is registered from an untrusted source
-The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugins/marketplace-reference#marketplace-file>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, an entry registered before its name became reserved kept loading.
-
- Marketplace "claude-community" is registered from an untrusted source: The name 'claude-community' is reserved for official Anthropic marketplaces. Only repositories from 'github.com/anthropics/' can use this name. To fix it, remove the marketplace and re-add it from the official source.
-
-For a marketplace whose source isn’t a GitHub repository or a Git URL, such as a local directory, the middle sentence reads `can only be used with GitHub sources from the 'anthropics' organization` instead. `claude plugin marketplace add` runs the same check, and refuses a reserved name with `Failed to add marketplace:` followed by the same reserved-name sentence. **What to do:**
-
- * If the marketplace is already registered, run `claude plugin marketplace remove <name>`, then add it again from the official `github.com/anthropics` repository
- * If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
- * See the reserved name list under [Marketplace schema](</docs/en/plugins/marketplace-reference#marketplace-file>)
+For the cause and the fix, see [this message in plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-registered-from-an-untrusted-source>).
### Marketplace name is another spelling of a reserved name
@@ -3556,19 +3557,7 @@
### Plugin archive integrity check failed
-The plugin’s marketplace entry uses an [`archive` source](</docs/en/plugins/marketplace-reference#archive-plugin-source>) with a `sha256` pin, and the digest of the downloaded file doesn’t match the pin. Claude Code refuses the install, so nothing changes in the plugin cache. The mismatch has three possible causes:
-
- * The file at the URL changed after the author computed the pin
- * The author entered the wrong digest in the marketplace entry
- * The URL serves a different file than the author pinned
-
- Plugin archive integrity check failed for https://artifacts.example.com/claude-plugins/my-plugin.zip: expected sha256 6bfa50e3d2e00c052b46abe51fff89346ac803e45771f76dcf6df1ab74cca5e1, got ac52220c0914ef8ca6a602e4a7362f88d30fb021110f72a6d15b68c3fe7df2b7. The archive was not installed. Verify the sha256 in the marketplace entry, or that the URL serves the intended file.
-
-**What to do:**
-
- * If you publish the plugin, recompute the digest of the exact file the URL serves, for example with `shasum -a 256 my-plugin.zip`, or `Get-FileHash -Algorithm SHA256 my-plugin.zip` in PowerShell, and update the `sha256` in the marketplace entry
- * If you install the plugin, run `/plugin marketplace update <name>` to refresh the catalog in case the entry was corrected, then retry the install
- * If the digests still disagree after a refresh, ask the marketplace owner which file they pinned before installing
+For the causes and the fix, see [this message in plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-archive-integrity-check-failed>).
### Path escapes plugin directory
@@ -5221,12 +5210,7 @@
### Sandbox mask files left behind at write-deny paths
-This warning in `claude doctor` and `/status` lists mask files: 0-byte read-only placeholder files at paths the [sandbox](</docs/en/sandboxing>) denies writes to. It appears on Linux and WSL2 when sandboxing is enabled with filesystem isolation on. Delete them from your shell once no Claude Code session is open in the project that holds them. The sandbox creates a placeholder while a sandboxed command runs and removes it when the command ends. One stays behind in cases such as these:
-
- * The session is killed before the command ends, for example by SIGKILL
- * You quit the session while a sandboxed command is still running, such as one in the background
-
-In `claude doctor`, the warning reads:
+This warning in `claude doctor` and `/status` lists mask files: 0-byte read-only placeholder files at paths the [sandbox](</docs/en/sandboxing>) denies writes to. It appears on Linux and WSL2 when sandboxing is enabled with filesystem isolation on. Delete them from your shell once no Claude Code session is open in the project that holds them. In `claude doctor`, the warning reads:
- Sandbox mask files left behind at write-deny paths: /home/you/project/.claude/settings.local.json
Fix: A session leaves one where it was killed, or where it exited while a sandboxed command was still running. Remove each with `rm <path>` while no other Claude Code session is running in that project — a 0-byte read-only file where a settings file belongs makes "Yes, and don't ask again" fail to save, and the sandbox binds it read-only again on every start
Show diff (154 lines)
--- a/errors.md
+++ b/errors.md
@@ -40,7 +40,7 @@
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
`You've hit your monthly spend limit` / `You've hit your individual spend limit` / `You've hit your org's monthly spend limit` / `You've hit your channel's monthly spend limit` / `You've hit your team's shared budget` / `You've hit your individual usage limit`| Usage limits
-`Could not update your spend limit`| Usage limits
+`Could not update your spend limit` / `Could not remove your spend limit`| Usage limits
`spend limit reached` / `spend limit unavailable` / `This request exceeds your group's budget`| Usage limits
`Not logged in · Please run /login`| Authentication
`Couldn't save your login`| Authentication
@@ -92,6 +92,7 @@
`Artifacts need a claude.ai login`| Authentication
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
+`Managed settings on this machine configure a Cloud gateway sign-in; run interactive /login to authenticate.`| [`claude auth login`](</docs/en/cli-reference#cli-commands>)
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`Login reached its time limit · Please run /login` / `Failed to authenticate: this login reached its time limit`| Authentication
`Failed to authenticate: your claude.ai login expired`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
@@ -225,6 +226,8 @@
`--bg and --print conflict`| Command-line errors
`Couldn't tell whether --bg is a flag or text here, so nothing was started`| Command-line errors
`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
+`Error: bypassPermissions not supported in restricted mode`| [Restricted mode](</docs/en/permission-modes#restricted-mode-refuses-bypasspermissions>)
+`Session was started with bypass permissions, so plan mode won't ask before most edits or commands`| [Plan mode](</docs/en/permission-modes#analyze-before-you-edit-with-plan-mode>)
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Cloud sessions are disabled by your organization's policy`| Command-line errors
`Cloud sessions use your claude.ai login`, at the end of a policy denial that names a credential| Command-line errors
@@ -259,6 +262,7 @@
`Cannot add MCP server to scope: managed`| Command-line errors
`Cannot add MCP server: your organization's managed settings allow only MCP servers that plugins provide`| Command-line errors
`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
+`Can't add to .mcp.json: it lists servers at the top level`| Move the servers under an `mcpServers` key, as in the [project-scope format](</docs/en/mcp#project-scope>).
`Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes`| Command-line errors
`MCP server "<name>" was not saved to` / `was not removed from`| Command-line errors
`MCP server "<name>" may not have been saved` / `may not have been removed`| Command-line errors
@@ -297,7 +301,7 @@
`Windows reported an error (EBADF) when Claude Code read this session's transcript file`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
-`Can't restart while work is running in the background — wait for it to finish (or stop it via /tasks), then try again.`| Command-line errors
+`Can't restart while work is running in the background`| Command-line errors
`Can't restart while Remote Control is connected. To use the installed version, exit and start Claude Code again, then run /resume.`| Command-line errors
`Claude Code couldn't restart`| Command-line errors
`Couldn't open Claude Desktop`| Command-line errors
@@ -331,7 +335,7 @@
`path escapes plugin directory`| Plugin errors
`path not read: <path> is absolute or has a ".." part`| Plugin errors
`Plugin not loaded: its manifest <path> was not read`| Plugin errors
-`path could not be checked`| Plugin errors
+`path couldn't be checked` / `path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
`Plugin source path refused`| Plugin errors
`Failed to load marketplace configuration`| Plugin errors
@@ -357,6 +361,7 @@
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
`command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run`| Tool errors
+`This command's variables and substitutions expand to more text than the permission check reads, so it was not run`| Ask Claude to use fewer or shorter variables and substitutions.
`This call was not run. Claude Code could not confirm that the shell is back in the directory`, from v2.1.323| Tool errors
`File is too large to read as an image (the limit is 128MB)`| Tool errors
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
@@ -366,11 +371,12 @@
`Sandbox is required but failed to initialize: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
`Sandbox is required (sandbox.failIfUnavailable) and stopped being available in this session: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
`pkill: refusing to run`| Tool errors
+`Sandbox settings can't be changed here` / `Sandbox settings are overridden by a higher-priority configuration`| [Sandboxing troubleshooting](</docs/en/sandboxing#sandbox-settings-overridden>)
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
`Only a teammate can approve a shutdown request`| Tool errors
-`A command-line deny rule cannot be handed to a teammate intact`| Tool errors
+`cannot be handed to a teammate intact`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
`Cross-session message was dropped at the recipient session's inbox`| Tool errors
@@ -441,6 +447,7 @@
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
+`Couldn't restore N files: the backup is missing or the file can't be written`| Make the files that failed writable, then restore them from version control.
`The file backups are still being copied. Nothing was changed. Try again in a moment.`| Select the same point in [`/rewind`](</docs/en/checkpointing>) again. When you restore code soon after [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code can still be copying the file backups to the new session.
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
@@ -455,6 +462,7 @@
`N skill or command names refused: run with --debug to see which ([names]), rename, then restart`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`Two Claude Code config files exist: this run uses <path>, not <path>`| Configuration warnings
+`a settings change wasn't saved`| Make `~/.claude/settings.json` and the project’s `.claude/settings.local.json` writable, then make the change again. If another tool generates the file, see [A change is lost in new sessions](</docs/en/settings#a-change-you-made-in-claude-code-is-lost-in-new-sessions>). If a file isn’t valid, see [Fix a broken settings file](</docs/en/settings#fix-a-broken-settings-file>).
`Make this change again later: <path> could not be updated, so it applies to this session only`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
@@ -935,7 +943,7 @@
Could not update your spend limit: <reason from the server>
-When the server explains the rejection, the message ends with that reason, and retrying the same value fails again. When the failure has no server-provided reason, such as a dropped connection, the message reads `Could not update your spend limit. Press Enter to retry.` and retrying can succeed. Before v2.1.216, Claude Code showed the generic form for every failure. **What to do:**
+When the server explains the rejection, the message ends with that reason, and retrying the same value fails again. When the failure has no server-provided reason, such as a dropped connection, the message reads `Could not update your spend limit. Press Enter to retry.` and retrying can succeed. Before v2.1.216, Claude Code showed the generic form for every failure. If you remove the limit, the generic form starts `Could not remove your spend limit` on v2.1.327 or later. **What to do:**
* If the message includes a reason, choose a limit that satisfies it, such as a lower amount
* If the message shows only the generic form, retry; the failure may be transient
@@ -2752,7 +2760,7 @@
If you answer `n` or press Enter at the [`Trust <directory>?` question](</docs/en/remote-control#requirements>), the command prints a `Remote Control did not start` message that names the directory and exits with code 1. Run `claude rc` again to answer `y`. **What to do:**
- * Trust the directory from a terminal first: run `claude rc` there and answer `y`, or run `claude` there and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
+ * Trust the directory from a terminal first: run `claude` there and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
* In your home directory, change to a project directory and start Remote Control there
Before v2.1.284, the command never asked, even in a terminal.
@@ -2768,7 +2776,7 @@
* In a script or CI job, append `--trust-workspace` to trust the folder for that run: `claude ultrareview --trust-workspace`. Append it only for code you trust, because git and Claude Code can then run programs named in the folder’s git configuration and project settings. For a pull request whose code you don’t trust, [run the review from a branch you trust](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>).
* On your own machine, run `claude` in that folder and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
-Each of these messages from `claude ultrareview` means that no review started and the exit code is 1:
+In a session, `/ultrareview` and `/code-review ultra` can stop with `Ultrareview did not start: "<folder>" is not trusted, and this session started without asking whether you trust it`. Start `claude` in that folder without [`IS_DEMO`](</docs/en/env-vars#variables>) set, accept the workspace trust dialog, and run the command in the new session. Each of these messages from `claude ultrareview` means that no review started and the exit code is 1:
* **`Error: Workspace not trusted. This terminal ...`** : the terminal reported no row and column count, or can’t fit the trust question and its warnings. Enlarge it or use a terminal that reports its size, then run `claude ultrareview` again. Outside your home directory, you can also run `claude` in that folder once and accept the trust dialog, so later runs there don’t ask.
* **`Error: Workspace not trusted.<folder> is your home directory`**: because trust for your home directory is never saved, running `claude` there first can’t help. Run `claude ultrareview` from a project directory instead, after running `claude` there once to accept the trust dialog, or append `--trust-workspace`.
@@ -3628,7 +3636,7 @@
You don’t see this error for a path that doesn’t exist at all. In `/plugin`, the error appears under the plugin and names the path and the code the operating system returned:
- skills path could not be checked: /home/user/my-plugin/skills (ELOOP)
+ skills path couldn't be checked: /home/user/my-plugin/skills (ELOOP)
In `claude plugin list`, the same error reads `Path not found: /home/user/my-plugin/skills (skills, ELOOP)`. Causes that produce this error include:
@@ -3992,11 +4000,11 @@
This message means Claude Code didn’t start a [split-pane](</docs/en/agent-teams#choose-a-display-mode>) teammate in your [agent team](</docs/en/agent-teams>). Claude Code passes the lead’s command-line deny rules to a split-pane teammate on the teammate’s own command line, and stops when the teammate would read one of them differently:
- A command-line deny rule cannot be handed to a teammate intact, so the teammate would not enforce it — spawn aborted
-
-**What to do:**
-
- * Run `/config` in the lead session and set **Teammate mode** to `in-process`, then ask Claude to start the teammate again. You don’t need to find the rule or restart the lead. An in-process teammate [runs under the lead’s live deny rules](</docs/en/agent-teams#permissions>).
+ The deny rule "<rule>" cannot be handed to a teammate intact, so the teammate was not started. Remove that rule or move it to permissions.deny in settings, then try again.
+
+**What to do:**
+
+ * Run `/config` in the lead session and set **Teammate mode** to `in-process`. If the row says `overridden` and already shows `in-process`, cycle through the values back to it. Then ask Claude to start the teammate again. An in-process teammate [runs under the lead’s live deny rules](</docs/en/agent-teams#permissions>).
* Later sessions that take [`teammateMode`](</docs/en/settings-reference#teammatemode>) from your user settings start teammates in-process too, because `/config` saves the choice there. To go back to split panes in a later session, set **Teammate mode** to `auto`, `tmux`, or `iterm2`, whichever you used before.
### Message too large for cross-session delivery
@@ -4036,7 +4044,7 @@
* `its queue of undelivered peer messages was full`: the recipient already held as many undelivered messages from other sessions as its queue allows
* `you sent faster than that session accepts`: the sending session’s messages arrived faster than the recipient accepts from one sender
* `it repeated your previous message`: the message was identical to one the sending session sent this recipient shortly before
- * `a relay loop between sessions was cut`: the message continued a chain of sessions messaging each other, and the chain had passed through the recipient too many times or grown too long
+ * `a relay loop between sessions was cut`: the message continued a long [chain of replies that can be cut off](</docs/en/cross-session-messaging#limitations>), such as one that includes a session beyond this machine
**What to do:**
--- a/errors.md
+++ b/errors.md
@@ -93,6 +93,9 @@
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
+`Login reached its time limit · Please run /login` / `Failed to authenticate: this login reached its time limit`| Authentication
+`Failed to authenticate: your claude.ai login expired`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
+`claude.ai login ended · usage now billed to` / `Warning: the claude.ai login on this machine has ended`| [After the login expires](</docs/en/authentication#after-the-login-expires>)
`Could not refresh your login because another Claude Code process is refreshing it`| Authentication
`Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh`| Authentication
`Could not refresh your login: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
@@ -357,6 +360,7 @@
`This call was not run. Claude Code could not confirm that the shell is back in the directory`, from v2.1.323| Tool errors
`File is too large to read as an image (the limit is 128MB)`| Tool errors
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
+`could not fully check your permission rules`| [Actions no mode auto-approves](</docs/en/permission-modes#actions-no-mode-auto-approves>)
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`Sandbox is required but failed to initialize: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
@@ -676,7 +680,7 @@
### Auto mode cannot determine the safety of an action
-The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on how the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is unavailable:
+The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on how the classifier failed. When the classifier model is unavailable:
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
@@ -917,6 +921,7 @@
Your Console organization has run out of prepaid credits, or Claude Code is sending your requests with a Console API key when you meant to use your subscription.
Credit balance is too low
+ Credit balance too low · Add funds: https://platform.claude.com/settings/billing
**What to do:**
@@ -1185,7 +1190,7 @@
### OAuth token revoked or expired
-Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
+Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
OAuth token revoked · Please run /login
Please run /login · API Error: 401 OAuth token has expired ...
@@ -1219,7 +1224,7 @@
### Login expired
-Claude Code tried to renew your saved claude.ai login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each model request stops locally with this message before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the model request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
+Claude Code tried to renew your saved claude.ai login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. With no [other saved credential](</docs/en/authentication#after-the-login-expires>), model requests then stop with this message:
Login expired · Please run /login
@@ -1227,9 +1232,9 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-For a `Login expired` message that ends with `or re-authenticate your Anthropic profile`, see Anthropic profile login expired. This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
-
- * Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
+If the login reached its time limit, both messages say `reached its time limit` instead on Claude Code v2.1.318 or later. For a `Login expired` message that ends with `or re-authenticate your Anthropic profile`, see Anthropic profile login expired. When the renewal fails because the account itself is suspended, Claude Code shows Your account is on hold instead. **What to do:**
+
+ * Run `/login` to sign in again.
* If you sign in with your claude.ai account in another Claude Code window, see Not logged in for when this session starts using that login on its own.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
@@ -1889,7 +1894,7 @@
Couldn't share the transcript.
-The upload must fit an 8 MiB limit. On a long session, Claude Code progressively drops parts of the share, the last request’s model settings first, then the structured conversation and subagent transcripts, and shows this message when no reduced version can be sent or a network or server error stops the upload. When Claude Code saves a local archive instead, the message means it couldn’t write the archive. **What to do:**
+The upload must fit an 8 MiB limit. On a long session, Claude Code progressively drops parts of the share. You see this message when no reduced version can be sent or a network or server error stops the upload. When Claude Code saves a local archive instead, the message means it couldn’t write the archive. **What to do:**
* Run `/feedback` to send the transcript with a description of what happened. See Report an error if `/feedback` is unavailable in your environment
* If other requests are failing too, check your network connection and see Unable to connect to API
@@ -2167,7 +2172,7 @@
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
- * Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
+ * Before v2.1.206, an expired claude.ai login that could no longer be refreshed failed every model with this error. Run `/login` on those versions.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
--- a/errors.md
+++ b/errors.md
@@ -395,6 +395,7 @@
`Reading a local file from outside this session's connected folders, or through a link, needs the approval card`| Tool errors
`cannot read file_path (...) — the file could not be examined, and no one can answer the approval card`| Tool errors
`WebFetch cannot fetch localhost or other hostnames without a dot`| Tool errors
+`Claude Code is unable to fetch from ...`| Tool errors
`The safety check for domain ... is rate-limited`| Tool errors
`The safety check for domain ... is temporarily rate-limited`| Tool errors
`Unable to verify if domain ... is safe to fetch`| Tool errors
@@ -471,6 +472,7 @@
`Unable to read managed policy settings`| Configuration warnings
`Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:`| Configuration warnings
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
+`apply_flag_settings: nothing in this request was applied and earlier settings stay in force. Fix or remove these invalid settings and send it again`| [`applyFlagSettings()`](</docs/en/agent-sdk/typescript#applyflagsettings>)
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
@@ -4253,6 +4255,14 @@
Before v2.1.268, WebFetch reported these URLs with a generic `Invalid URL` error.
+### Claude Code is unable to fetch from a host
+
+WebFetch sends a URL’s hostname to `api.anthropic.com` before requesting the page, to check it against Anthropic’s domain safety blocklist. This message means the check answered that the hostname can’t be fetched:
+
+ Claude Code is unable to fetch from example.com
+
+Claude Code didn’t contact the host, because the check runs before the request. For what the check sends, see [WebFetch domain safety check](</docs/en/data-usage#webfetch-domain-safety-check>).
+
### WebFetch domain safety check failed
Before fetching a URL, WebFetch sends the URL’s hostname to `api.anthropic.com` to check it against Anthropic’s [domain safety blocklist](</docs/en/data-usage#webfetch-domain-safety-check>). If the check can’t complete, WebFetch can’t confirm that the domain is safe, so it doesn’t fetch the page and the tool result carries one of these messages instead:
Show diff (147 lines)
--- a/errors.md
+++ b/errors.md
@@ -34,7 +34,8 @@
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit` / `You've hit your Opus limit` / `You've hit your Sonnet limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
-`the prompt to confirm went unanswered — nothing was sent`| Usage limits
+`the prompt to confirm went unanswered · nothing was sent`, from v2.1.324| Usage limits
+`Claude stopped here · send a message to be asked again`| Usage limits
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
@@ -72,6 +73,7 @@
`Remote Control stopped — the app running this session is now signed in to a different Claude account`| Authentication
`Remote Control stopped — the app running this session is signed out of Claude`| Authentication
`Couldn't verify your organization's policy for remote control`| [Troubleshoot Remote Control](</docs/en/remote-control#couldnt-verify-your-organizations-policy-for-remote-control>)
+`Remote Control didn't finish connecting`| [Start a Remote Control session](</docs/en/remote-control#start-a-remote-control-session>)
`Remote Control is disabled by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-is-disabled-by-your-organizations-policy>)
`Remote Control was turned off by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-was-turned-off-by-your-organizations-policy>)
`Session failed: working folder not found:`| [Troubleshoot Remote Control](</docs/en/remote-control#working-folder-not-found>)
@@ -130,11 +132,13 @@
`Unable to connect to API`| Network
`Connection refused —` / `Can't reach the API server —` / `No internet route —` / `Couldn't connect through your proxy` / `Connection dropped`, each with an error code in parentheses| Network
`Unable to connect to Anthropic services` during setup| Network
+`Unable to fetch your privacy settings at this time`| [Privacy settings on claude.ai](<https://claude.ai/settings/data-privacy-controls>)
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`API returned an empty or malformed response`| Network
`Streaming response ended before any complete data was received`| Network
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
+`Claude Code used only the certificates that it could read in full from the NODE_EXTRA_CA_CERTS file` / `Claude Code ignored all of the NODE_EXTRA_CA_CERTS file: it holds no certificate that Claude Code can read`| [Custom CA certificates](</docs/en/network-config#custom-ca-certificates>)
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`unable to get local issuer certificate`| Network
@@ -265,6 +269,7 @@
`Couldn't run `<command>` for <name>. A file named HEAD or .git in this folder or one above it may not be yours`, from a skill that injects dynamic context| [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>)
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`No shell command in <name> was run, because the <tool> tool does not accept one of them`| Command-line errors
+`This skill, command or hook and the arguments filled into it add up to more than 4,000,000 characters`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Claude Code can't read the keyboard here: stdin is not a terminal`| Command-line errors
`Error: Input contained only whitespace`| Command-line errors
@@ -278,6 +283,7 @@
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
`Not uploading this working tree` with `the upload cannot follow that setting`| Command-line errors
+`Not uploading this working tree` with another cause / `Git will not work in this checkout because its folder, or the .git in it, belongs to another user`| [Send local repositories without GitHub](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>)
`GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud`| Command-line errors
`Your GitHub organization has an IP allowlist that is blocking Claude`| Command-line errors
`Your GitHub organization requires single sign-on`| Command-line errors
@@ -301,6 +307,7 @@
`/recap only runs when you ask for it yourself in this session`| Command-line errors
`/feedback is disabled by your organization's policy`, or the same for `/bug` or `/share`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
+`credential store on this machine holds a symbolic link inside it`| [Grant tools](</docs/en/plugin-evals#grant-tools>)
`cannot be evaluated where sessions load it`| [Test plugins with evals](</docs/en/plugin-evals#cannot-be-evaluated-where-sessions-load-it>)
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Claude Code refuses the marketplace name "<name>"`| Plugin errors
@@ -347,7 +354,7 @@
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
`command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run`| Tool errors
-`This call was not run. The command was approved before Claude Code restarted`| Tool errors
+`This call was not run. Claude Code could not confirm that the shell is back in the directory`, from v2.1.323| Tool errors
`File is too large to read as an image (the limit is 128MB)`| Tool errors
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
@@ -436,6 +443,7 @@
`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>)
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
+`declares type "claudeai-proxy", which only claude.ai connectors use`| Remove the entry from your MCP config. See [Use MCP servers from claude.ai](</docs/en/mcp#use-mcp-servers-from-claude-ai>).
`hook needs quotes around a path with a space`| Configuration warnings
`Instruction file not loaded`| Configuration warnings
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
@@ -477,8 +485,7 @@
`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" reads as <N> tokens, so Claude Code treats it as the 100k minimum`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" is too large, so Claude Code treats it as the 1M maximum`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" isn't a usable size, so Claude Code ignores it`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
-`Model "<model>" isn't recognized · context assumed to be 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
-`Claude Code doesn't recognize the model "<model>", so it assumes a context window of 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
+`Model "<model>" isn't recognized · context assumed to be <N> tokens` / `Claude Code doesn't recognize the model "<model>", so it assumes a context window of <N> tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`Model "<model>" isn't recognized · did you mean "<suggestion>"?` / `Claude Code doesn't recognize the model "<model>". Did you mean "<suggestion>"?`| [Fix a mistyped model name](</docs/en/model-config#fix-a-mistyped-model-name>)
`[claude-code:unrecognized_model]`| Configuration warnings
`is ignored — managed settings set allowManagedReadPathsOnly` / `is ignored — managed settings set allowManagedDomainsOnly`| Configuration warnings
@@ -828,12 +835,12 @@
When the [Fable usage-credits consent prompt](</docs/en/model-config#fable-and-usage-credits>) closes with nobody answering it, Claude Code ends the turn with one of these messages:
- Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
- Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-
-The messages name the session’s Fable model, so on Fable 5.2 they read `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
-
- * Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
+ Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered · nothing was sent · answer it where this session is running, or /model to change
+ Fable 5.1 now uses usage credits · the prompt to confirm went unanswered · nothing was sent · answer it where this session is running, or /model to change
+
+The messages name the session’s Fable model, so on Fable 5.2 they read `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. With [Remote Control](</docs/en/remote-control>) connected, each message can instead end `Claude stopped here · send a message to be asked again, or switch models`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
+
+ * Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. If the message says `Claude stopped here`, you can also reply from your connected device and answer the consent prompt there.
* Run `/model` to switch to a model that doesn’t bill usage credits
* To give yourself more time, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
@@ -1974,7 +1981,7 @@
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
- * If the error appears near 200K tokens on a model that accepts more, one cause is a model ID that Claude Code doesn’t recognize. Claude Code assumes a 200K window for such an ID, so to keep working past that point, [give it the model’s real context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>).
+ * If Claude Code warned that it doesn’t recognize your model ID, the warning can name the window it assumed. When the model’s real window differs, [give Claude Code the real window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>).
* If you use a custom [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) and the error starts with `Prompt is too long · automatic compaction failed`, [set the model’s context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>) or [update](</docs/en/setup#update-claude-code>) to v2.1.299 or later. Before v2.1.299, Claude Code ended the turn with that message near the assumed 200K window instead of sending the request.
* If the error appeared right after you stopped Claude while it was compacting the conversation, your conversation is unchanged and still large enough to need compacting. Run `/compact` and send your message again. To keep the error from recurring, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.304 or later. Before v2.1.304, stopping at that moment could end the turn with this error.
* On v2.1.305, with many MCP tools and a direct connection to the Anthropic API, this error can hide an unrelated 400 or 422 error from the API. [Update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.306 or later to see the original error.
@@ -3045,6 +3052,10 @@
* Find each `�` in the command quoted at the end of the message. Remove the character it stands for from the [skill or command file](</docs/en/skills#where-skills-live>), or from the arguments or [options](</docs/en/plugins/manifest-reference#user-configuration>) substituted into the file.
+### Skill, command, or hook over the 4,000,000-character limit
+
+A message with `more than 4,000,000 characters` means a skill, a command, or a [prompt or agent hook](</docs/en/hooks#prompt-and-agent-hook-fields>) didn’t run. If you pasted long text as arguments, save it to a file, run `/clear`, since the text stays in the conversation, then pass its path. Outside [Code Mode](</docs/en/code-mode#tool-call-refused-by-a-hook>), a `PreToolUse` prompt or agent hook over the limit doesn’t block the call. Use a [command hook](</docs/en/hooks#command-hook-fields>), which has no such limit.
+
### Input must be provided when using `--print`
Bare `claude` needs stdout to be a terminal to start the interactive UI. When stdout is redirected, or the console isn’t a real terminal, such as PowerShell ISE and some IDE output panes, `claude` runs [non-interactively](</docs/en/headless>) instead. That is the same mode as `claude -p`, which requires a prompt, so the message names `--print` even when you didn’t pass the flag. Passing `-p`/`--print` with no prompt and nothing piped on stdin produces the same error anywhere.
@@ -3866,11 +3877,11 @@
* **For a command Claude wrote** : you have nothing to fix. The message tells Claude how to rewrite the command.
* **For a skill or command file** : the message follows `No shell command in <name> was run`. See where to find the character and remove it.
-### Command approved before Claude Code restarted was not run
+### Approved command was not run after Claude Code restarted
A shell command you approved didn’t run, and Claude receives this message as the command’s result:
- This call was not run. The command was approved before Claude Code restarted, and Claude Code could not confirm that the shell is back in the directory where it was approved. That directory may be gone or replaced, lie outside the directory where the session started, or be one that Claude Code needs approval to enter or is not allowed to examine. The shell's directory is <directory>. If the command still makes sense, cd to the directory it was meant for and make the call again; it may need approval again.
+ This call was not run. Claude Code could not confirm that the shell is back in the directory where it was approved. That directory may be gone or replaced, lie outside the directory where the session started, or be one that Claude Code needs approval to enter or is not allowed to examine. The shell's directory is <directory>. If the command still makes sense, cd to the directory it was meant for and make the call again; it may need approval again.
The message’s third sentence can instead read `It does not keep track of that directory across a restart in a session that has been in a worktree.` **What to do:**
@@ -4823,7 +4834,7 @@
Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them or couldn’t apply what the server returned, so it shows this warning in interactive sessions and in Claude Desktop’s Code tab. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`. The cause `no setting in the server response could be applied as written` means the server answered but none of the settings it returned passed [validation](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>). Before v2.1.282, this cause read `server returned invalid settings`. The rest of the line says which policy the session runs on:
* **Settings cached from an earlier successful fetch** : Claude Code runs the session on that cached policy, except the [withheld environment variables](</docs/en/server-managed-settings#fetch-and-caching-behavior>), and the line reads `using cached policy`.
- * **No cache** : Claude Code runs the session without server-managed settings, and the line reads `no remote policy applied`.
+ * **No cached settings to apply** : Claude Code runs the session without server-managed settings, and the line reads `no remote policy applied`. For example, the machine hasn’t fetched settings yet, or last fetched them more than [24 hours](</docs/en/server-managed-settings#fetch-and-caching-behavior>) ago.
In the Code tab, the warning appears as a line in the conversation when you send a message, and a new line appears when the state of the fetch changes. Three related messages appear the same way:
Show diff (180 lines)
--- a/errors.md
+++ b/errors.md
@@ -77,6 +77,7 @@
`Session failed: working folder not found:`| [Troubleshoot Remote Control](</docs/en/remote-control#working-folder-not-found>)
`The program file this Remote Control started from is gone`| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
`Session failed: spawn error:` followed by an `ENOENT` message| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
+`Remote Control disconnected:` followed by a reason that mentions a `share link`| [Remote Control](</docs/en/remote-control#what-connected-devices-see>)
`OAuth token revoked` / `OAuth token has expired`| Authentication
`Failed to authenticate: OAuth token revoked`| Authentication
`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
@@ -142,6 +143,7 @@
`403` with `GitHub GraphQL is not available from Claude Code sessions` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
`Failed to fetch session from Sessions API: Failed to fetch session logs`| Network
+`Couldn't load the history of cloud session`| Network
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
@@ -169,6 +171,7 @@
`PDF too large` / `PDF is password protected` / `pdftoppm is not installed`| Request errors
`Extra inputs are not permitted`| Request errors
`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid` / `Property keys should match pattern`| Request errors
+`N tools left out` beside a server in `/mcp` / `Claude wasn't given N tools because the Anthropic API would reject their input schemas`| [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>)
`Tool "mcp__<server>__<tool>" is not sent to Claude: its name has <N> characters and the API accepts at most 128`| Request errors
`tools.N.custom.name: String should have at most 128 characters`| Request errors
`tool_use.name: String should have at most 200 characters`| Request errors
@@ -259,6 +262,7 @@
`No available ports for OAuth redirect`| Command-line errors
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
+`Couldn't run `<command>` for <name>. A file named HEAD or .git in this folder or one above it may not be yours`, from a skill that injects dynamic context| [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>)
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`No shell command in <name> was run, because the <tool> tool does not accept one of them`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
@@ -328,6 +332,8 @@
`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
`Plugin directory does not exist: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-directory-does-not-exist>)
`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
+`is not added on this machine, so your organization's marketplace policy keeps its plugins off`| [Add a marketplace](</docs/en/plugins/install#add-a-marketplace>)
+`A mod's http.fetch hook stopped this request`| [Turn mods on or off](</docs/en/plugins/mods/overview#turn-mods-on-or-off>)
`Error: No such tool available: <tool name>`| Tool errors
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
`MCP server "<name>" is disabled — re-enable it via /mcp to use its tools`| Tool errors
@@ -416,6 +422,8 @@
`Workspace not trusted.` when starting or restarting a background session| Background session errors
`Claude Code is being updated by npm on this machine (still not runnable after 2 min, ...)`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
+`Subprocess initialization did not complete within 60000ms`| Wrapper and IDE errors
+`Claude Code did not finish starting`| Wrapper and IDE errors
`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
@@ -545,7 +553,7 @@
`CLAUDE_CODE_RETRY_WATCHDOG_MAX_USAGE_LIMIT_WAIT_MS`| no cap| With `CLAUDE_CODE_RETRY_WATCHDOG` set, the longest time in milliseconds one request waits for your plan’s usage limit, such as the session or weekly limit, to reset. When the reset is further away than this cap, the request fails at once, unless usage credits have room or the API couldn’t check them. In those cases it’s retried, and fails if the cap passes before it succeeds. Requires Claude Code v2.1.301 or later.
[`CLAUDE_CODE_RETRY_WATCHDOG_USAGE_LIMIT_RECHECK_MS`](</docs/en/env-vars>)| unset| Minimum interval in milliseconds between checks of whether a usage limit was already lifted, while a request waits for that limit to reset with `CLAUDE_CODE_RETRY_WATCHDOG` set. When a check finds the limit lifted, the request goes out at once. Give plain digits from `60000` to `10800000`. When unset or outside that range, no checks are made. For when Claude Code skips these checks, see the [environment variables reference](</docs/en/env-vars>). Requires Claude Code v2.1.305 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
-[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 64000, so that later retries keep spreading apart when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.296 or later.
+[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 300000, so that later retries keep spreading apart when the API is at capacity. Values above 64000 require v2.1.323 or later. Has no effect in the same cases as `CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`. Requires Claude Code v2.1.296 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Time in milliseconds that each request attempt has to receive its response headers. It doesn’t limit how long a streaming response runs after that. Raise it for slow networks or proxies. For how it caps the first-byte deadline, see No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. For each attempt’s timeout, see How long a non-streaming attempt waits. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
@@ -857,7 +865,7 @@
### You’ve hit your monthly spend limit
-Your plan’s included usage can’t cover this request, and the [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) that would otherwise pay for it have reached a spend limit. That happens when one of your plan’s usage windows has run out, or when the request is one that only usage credits pay for, such as a request to a model that [bills to usage credits](</docs/en/model-config#fable-and-usage-credits>). The message names whose limit blocked you. The text after the `·` says how to get that limit increased, and varies with your plan and whether you manage billing:
+Your plan’s included usage can’t cover this request, and the [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) that would otherwise pay for it have reached a spend limit. Your plan can’t cover a request when one of its usage windows has run out, or when only usage credits pay for the request. One example is a request to a model that [bills to usage credits](</docs/en/model-config#fable-and-usage-credits>). The words before the `·` name the limit that blocked you, such as your org’s monthly spend limit, and the text after it says how to get that limit increased. In a cloud session or under [Remote Control](</docs/en/remote-control>), that text gives no URL, and a message about your own `monthly spend limit` doesn’t say how to raise it. Other sessions show forms like these:
You've hit your monthly spend limit · raise it at https://claude.ai/settings/usage?from=cc_cli_limit_message
You've hit your individual spend limit · ask your admin for a higher limit
@@ -1538,6 +1546,7 @@
**What to do:**
* If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * If you set `CLAUDE_CODE_USE_ANTHROPIC_GOOGLE_CLOUD`, follow the steps for [Claude Models on Google Cloud (Anthropic managed)](</docs/en/claude-models-on-google-cloud-anthropic-managed#google-cloud-credentials-expired-or-invalid>) instead
* If you authenticate with application default credentials, run the [`gcpAuthRefresh`](</docs/en/google-vertex-ai#advanced-credential-configuration>) command named in the message, or `gcloud auth application-default login`, and complete the sign-in, then retry
* If you route through an [LLM gateway](</docs/en/llm-gateway>) with `CLAUDE_CODE_SKIP_VERTEX_AUTH` set, refresh the gateway token in `ANTHROPIC_AUTH_TOKEN` or `ANTHROPIC_CUSTOM_HEADERS`, then retry
* If you authenticate with a service account key file, confirm `GOOGLE_APPLICATION_CREDENTIALS` points at a valid key. See [Configure GCP credentials](</docs/en/google-vertex-ai#3-configure-gcp-credentials>)
@@ -1554,6 +1563,7 @@
**What to do:**
* If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * If you set `CLAUDE_CODE_USE_ANTHROPIC_GOOGLE_CLOUD`, follow the steps for [Claude Models on Google Cloud (Anthropic managed)](</docs/en/claude-models-on-google-cloud-anthropic-managed#google-cloud-authentication-failed>) instead
* Confirm the roles in [IAM configuration](</docs/en/google-vertex-ai#iam-configuration>) are granted to the identity you authenticate with
* Confirm the model is enabled for your project. See [Request model access](</docs/en/google-vertex-ai#2-request-model-access>)
@@ -1830,6 +1840,16 @@
* Run the same teleport again. If it fails the same way, report the problem
Before v2.1.296, Claude Code didn’t retry a failed read, and after one it could open the session with an empty conversation and report success instead of printing this message.
+
+### Couldn’t load the history of cloud session
+
+This message means Claude Code found the [cloud session you asked to pull into your terminal](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>), but the request for its conversation history came back as not found:
+
+ Couldn't load the history of cloud session session_01HJKLMNOPQRSTUVWXYZ. Check it at https://claude.ai/code/session_01HJKLMNOPQRSTUVWXYZ?from=cli
+
+**What to do:**
+
+ * Open the link in the message to check the session in your browser. If it opens there and the same teleport fails this way again, report the problem.
### Couldn’t reconnect to your Remote Control session
@@ -3000,7 +3020,7 @@
Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>), and a failed injected command aborts that skill’s invocation. Sibling strings fire before the command runs at all:
- * `Shell command permission check failed for pattern "..."`: the command’s permission check didn’t allow it. [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>) covers which results abort in each permission mode and how to pre-approve a command with `allowed-tools`
+ * `Shell command permission check failed for pattern "..."`: the command’s permission check didn’t allow it. See [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>) for which results abort in each permission mode and when `allowed-tools` pre-approves a command
* `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
**What to do:**
@@ -4320,9 +4340,9 @@
You opened a [background session](</docs/en/agent-view>) that ended while the background service was off, and [transcript cleanup](</docs/en/settings-reference#cleanupperioddays>) has since removed its saved conversation, for example after the machine was off for weeks. Opening such a row normally [resumes its saved conversation](</docs/en/agent-view#sessions-show-as-failed-after-shutdown>). With nothing left to resume, Claude Code refuses rather than re-run the session’s original prompt without asking:
- This session's saved conversation is no longer on disk (it ended while the background service was off, and old transcripts are cleaned up), so there is nothing to resume. `claude rm 7c5dcf5d` deletes the row; `claude respawn 7c5dcf5d` runs its original prompt again instead.
-
-`claude attach <id>` prints this text. In agent view, the footer is shorter and ends with `ctrl+x deletes the row`. **What to do:**
+ This session's saved conversation is no longer on disk (it ended while the background service was off, and old transcripts are cleaned up), so there is nothing to resume. `claude rm 7c5dcf5d` removes the row; `claude respawn 7c5dcf5d` runs its original prompt again instead.
+
+`claude attach <id>` prints this text. In agent view, the footer is shorter and ends with `ctrl+x removes the row`. **What to do:**
* Run `claude rm <id>` to delete the row. When one of the [kept cases](</docs/en/agent-view#what-deleting-a-session-removes>) applies, `claude rm` keeps the row and the worktree instead and names the reason
* To run the session’s original prompt again as a fresh conversation, run `claude respawn <id>`
@@ -4331,19 +4351,19 @@
### Worktree has commits that are not pushed anywhere
-You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits unseen. `claude rm` names the branch and the unpushed commits, and says how to proceed:
+You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. `claude rm` says how to proceed:
kept 7c5dcf5d — its worktree is still at “/home/you/project/.claude/worktrees/fix-login”
2 unpushed commits on “claude/fix-login”: a1b2c3d “Fix login flow” and 1 more. They exist on no remote, so deleting the worktree would lose them.
push them and run 'claude rm 7c5dcf5d' again, or discard the worktree and its commits: claude rm 7c5dcf5d --discard-unpushed a1b2c3d000000000000000000000000000000000@0123456789abcdef0123456789abcdef
-When Claude Code can’t summarize the commits, the detail line reads `The worktree has unpushed commits` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
-
- * To keep the commits, push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
- * To discard the commits, run the `claude rm <id> --discard-unpushed` command the message printed, or press `Ctrl+X` twice on the session’s row in agent view again. This removes the session and the worktree along with its branch, the unpushed commits, and any uncommitted changes. If the delete is refused again, follow the new message.
- * When the message says the worktree is also recorded by another finished session, deleting again doesn’t discard it: push the commits, then delete the session again
-
-Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or commits, and there was no discard route. You can still delete the session, losing uncommitted changes but keeping the branch and commits. Run `git worktree remove --force --force <path>` with the path the refusal printed, then `claude rm <id>`. Git needs `--force` twice for a locked worktree. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
+When Claude Code can’t summarize the commits, the detail line reads `The worktree has unpushed commits` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not removed` with the same reason. **What to do:**
+
+ * To keep the commits, push them. Once the push puts them on a remote-tracking branch, such as `origin/claude/fix-login`, try deleting the session again.
+ * If the message offers to discard the commits, first make sure you don’t need the worktree, the commits or any uncommitted changes. Then take the step the message gives: press `Ctrl+X` twice on the session’s row in agent view, or run the `claude rm <id> --discard-unpushed <commit>@<worktree-id>` command that `claude rm` printed. If Claude Code refuses again, follow the new message.
+ * When the message says the worktree is also recorded by another finished session, deleting again doesn’t discard it: push the commits, then try deleting the session again
+
+Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or commits, and there was no discard route. You can still delete the session, losing uncommitted changes but keeping the branch and commits. Run `git worktree remove --force --force <path>` with the path the refusal printed, then `claude rm <id>`. Git needs `--force` twice for a locked worktree.
### Terminal host process died
@@ -4523,6 +4543,26 @@
## Wrapper and IDE errors
These errors come from the program that launched Claude Code for you, such as an IDE extension or an [Agent SDK](</docs/en/agent-sdk/overview>) application, rather than from Claude Code itself.
+
+### Subprocess initialization did not complete within 60000ms
+
+This error means a Claude Code process that the [VS Code extension](</docs/en/vs-code>) or an Agent SDK application launched didn’t report in time that it was ready. The extension or application then stopped it. In a VS Code conversation the error starts with `Claude Code did not finish starting`, for example:
+
+ Claude Code did not finish starting: it did not answer in time. The output logs ("View output logs") show how far it got. Slow plugins, MCP servers, hooks, disks or network can each cause this.
+
+In the extension’s output logs, on its sign-in screen, and in an Agent SDK application, the error reads differently. It starts with `Subprocess initialization did not complete within` and the time limit, then gives what Claude Code reported, for example:
+
+ Subprocess initialization did not complete within 60000ms. Claude Code did not answer the initialize request and reported no SessionStart or Setup hook running. Slow plugins, MCP servers, hooks that Claude Code does not report, disks or network can each cause this.
+
+**What to do:**
+
+ * To try again in VS Code, send a message. If the error appeared while you were signing in, select the sign-in method again instead.
+ * To see how far Claude Code got, click **View output logs** under a conversation’s error, or run **Claude Code: Show Logs** from the Command Palette. Include the entries around the `Subprocess initialization` line when [reporting the problem](<https://github.com/anthropics/claude-code/issues>).
+ * To check your network, see [Network configuration](</docs/en/network-config>). If the message tells you to check your sign-in or authentication, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>).
+ * If the message says that [SessionStart](</docs/en/hooks#sessionstart>) or [Setup](</docs/en/hooks#setup>) hooks hadn’t finished, [check how long yours run](</docs/en/hooks#debug-hooks>). In VS Code, the first 10 minutes in which Claude Code reports these hooks running don’t count toward the 60-second limit. Make a slow hook finish sooner, lower a non-async hook’s [`timeout`](</docs/en/hooks#common-fields>), or [remove the hook](</docs/en/hooks#disable-or-remove-hooks>).
+ * If your Agent SDK application calls [`startup()`](</docs/en/agent-sdk/typescript#startup>), set `initializeTimeoutMs` long enough for the whole start, or leave it unset so up to 10 minutes of reported hook time doesn’t count.
+
+Before VS Code extension v2.1.304 and TypeScript Agent SDK v0.3.304, all hook time counted toward the limit. With the default limit, the message contained `Subprocess initialization did not complete within 60000ms — check authentication and network connectivity`. If you see that wording, update the extension or the SDK.
### Claude Code process exited with code N
Show diff (4259 lines)
--- a/errors.md
+++ b/errors.md
@@ -2,11 +2,7 @@
Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
-##
-
-
-
-Find your error
+## Find your error
Match the message you see to a section below.
@@ -114,6 +110,7 @@
`A request to MCP server "<name>" was sent without your stored credentials`| Authentication
`This server's URL is missing or not a valid URL, so sign-in can't start`| Authentication
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
+`Stopped an OAuth request`| Authentication
`Refusing to send credentials to non-https token endpoint` / `<short-name> from the MCP SDK for <server-url>`| Authentication
`Cloud gateway session expired — run /login to reconnect.`| Authentication
`Cloud gateway <url> no longer accepts this session`| Authentication
@@ -243,6 +240,8 @@
`Ultrareview did not start`| Command-line errors
`Remote Control did not start: "<question>" got no answer`| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
+`Remote Control did not start, because sessions would skip part or all of the --settings file`| Command-line errors
+`The settings file <file> has changed since Remote Control started, so this session did not start`| Command-line errors
`--sandbox is not supported by claude remote-control` / `--no-sandbox is not supported by claude remote-control`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
@@ -481,11 +480,7 @@
`bwrap: setting up uid map: Permission denied` / `bwrap: loopback: Failed RTM_NEWADDR: Operation not permitted`| [Sandboxing troubleshooting](</docs/en/sandboxing#bwrap-uid-map-permission-denied>)
Responses seem lower quality than usual| Response quality
-##
-
-
-
-Automatic retries
+## Automatic retries
Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure. Claude Code retries these failures:
@@ -514,19 +509,11 @@
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
* A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
-###
-
-
-
-What you see while Claude Code retries or waits
+### What you see while Claude Code retries or waits
While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations.
-####
-
-
-
-Waiting for API response
+#### Waiting for API response
The `Waiting for API response · will retry in … · check your network` banner means that Claude Code has waited at least 20 seconds without receiving any data for a request. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. If the abort happens:
@@ -536,11 +523,7 @@
The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. If you connect through a gateway, see The waiting banner comes and goes behind a gateway. Before v2.1.185, the banner appeared after 10 seconds with different wording.
-####
-
-
-
-The waiting banner comes and goes behind a gateway
+#### The waiting banner comes and goes behind a gateway
If the `Waiting for API response` banner comes and goes while Claude thinks and you connect through a gateway, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.309 or later. The banner appears after 45 seconds without data on these connections:
@@ -550,11 +533,7 @@
Before v2.1.309, the banner appeared after 20 seconds on these connections.
-###
-
-
-
-Tune retry behavior
+### Tune retry behavior
You can tune retry behavior with these environment variables:
@@ -571,30 +550,18 @@
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. For each attempt’s timeout, see How long a non-streaming attempt waits. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
-####
-
-
-
-How long a non-streaming attempt waits
+#### How long a non-streaming attempt waits
A non-streaming attempt ends at its request timeout or at the body idle timeout, whichever comes first:
* **Request timeout** : `API_TIMEOUT_MS` when you set a positive value, otherwise 300 seconds in a local session.
* **[Body idle timeout](</docs/en/network-config#streaming-idle-watchdogs>)** : 5 to 6 minutes without a response, however high you set `API_TIMEOUT_MS`, where it runs and you haven’t turned it off.
-##
-
-
-
-Server errors
+## Server errors
Most of these errors come from the inference provider: Anthropic’s service on the Anthropic API, and the service behind that provider’s endpoint on Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway. Auto mode cannot determine the safety of an action and Agent terminated early due to an API error also cover causes on your side, such as an Amazon Bedrock account that can’t invoke the classifier model or a subagent that hit a usage limit.
-###
-
-
-
-API Error: 500 Internal server error
+### API Error: 500 Internal server error
Claude Code shows the status code and the API’s error message for any 5xx response. The example below shows a 500 response on the Anthropic API:
@@ -607,11 +574,7 @@
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every request fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable in your environment.
-###
-
-
-
-API Error: Repeated 529 Overloaded errors
+### API Error: Repeated 529 Overloaded errors
The API is temporarily at capacity across all users. Claude Code has already retried several times before showing this message:
@@ -623,11 +586,7 @@
* Try again in a few minutes
* Run `/model` and switch to a different model to keep working, since capacity is tracked per model. Claude Code prompts you to do this when one model is under particularly high load, for example `Opus is experiencing high load, please use /model to switch to Sonnet`. On Fable models the message names Fable. In a session the Claude Desktop app runs, such as the Code tab or Cowork, the message reads `Opus is experiencing high load. Switch to Sonnet.` and you switch models with the app’s model picker.
-###
-
-
-
-Request timed out
+### Request timed out
The API didn’t respond before the connection deadline.
@@ -640,11 +599,7 @@
* If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
* If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
-###
-
-
-
-No response from API
+### No response from API
Claude Code sent a streaming request, and the API returned no response headers within the deadline for the first byte. Claude Code aborts such a request rather than wait for the full `API_TIMEOUT_MS` request timeout, and sends it again if the retry budget allows. When the deadline passes for the retry too, the turn ends with this message, which shows how long each attempt waited. If you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), Claude Code keeps retrying under the budget described in Tune retry behavior instead of ending the turn.
@@ -664,11 +619,7 @@
Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request. Before v2.1.261, the retry waited the same deadline as the first attempt and the message showed no durations. Before v2.1.307, Claude Code ignored `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` in a Claude apps gateway session.
-###
-
-
-
-The response above may be incomplete
+### The response above may be incomplete
A streaming request failed while the response was still in progress, after Claude had completed a block of text or a tool call, or had started one after finishing its thinking. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
@@ -706,11 +657,7 @@
* With `--output-format json` or `stream-json`, Claude Code reports this message in the `result` field.
* To continue the turn once the connection is stable, resume the session and send `continue` as described in [Continue conversations](</docs/en/headless#continue-conversations>).
-###
-
-
-
-Auto mode cannot determine the safety of an action
+### Auto mode cannot determine the safety of an action
The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on how the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is unavailable:
@@ -763,11 +710,7 @@
* In an interactive session, approve or deny the action in the prompt that appears
* In an interactive session, run `/compact` to reduce the conversation size so subsequent actions fit within the classifier window again
-###
-
-
-
-The server returned no safety verdict
+### The server returned no safety verdict
Under [server-side classifier review](</docs/en/permission-modes#server-side-classifier-review>), auto mode denies an action when the server gives no verdict for it. The denial names a category in parentheses when Claude Code can determine one, such as `(timed out)`:
@@ -794,26 +737,18 @@
Before v2.1.280, Claude Code denied each action from a response without a verdict immediately and never stopped the turn. Before v2.1.302, on a direct connection to the Anthropic API, Claude Code didn’t compact a conversation that had grown too long for the server’s check.
-####
-
-
-
-`a hook changed this call's input after auto mode reviewed it`
+#### `a hook changed this call's input after auto mode reviewed it`
This denial means a hook or mod [changed the call’s input](</docs/en/hooks#pretooluse-updatedinput-in-auto-mode>) after the server reviewed it, so the review doesn’t cover what would run. It isn’t a judgment that the action is unsafe. Later calls in the same Claude response can be denied with this reason:
- another call in this response was changed by a hook after auto mode reviewed it, or could not be confirmed unchanged
+ another call in this response was changed after auto mode reviewed it, or could not be confirmed unchanged
Claude can then issue each denied call again so the server reviews it. If a permission prompt opens, answer it. You don’t need to do anything else unless Claude says in its reply that auto mode couldn’t check the call. Then stop the change or approve the call yourself, and ask Claude to try the call again:
* **Stop the change** : turn off the [hook](</docs/en/hooks#disable-or-remove-hooks>) or [mod](</docs/en/plugins/mods/overview#turn-mods-on-or-off>) that changed the call or an earlier call in the same Claude response, or ask your administrator to turn it off. To look for a hook, run [`/hooks`](</docs/en/hooks#the-%2Fhooks-menu>) at the Claude Code prompt. In a terminal session, run `/plugin` to see the active mods.
* **Approve the call yourself** : [switch to Manual mode](</docs/en/permission-modes#switch-permission-modes>)
-###
-
-
-
-Was not reviewed and did not run
+### Was not reviewed and did not run
A `was not reviewed and did not run` denial means the conversation is too long for the [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) classifier to check the action, so the action didn’t run. Claude Code returns this message to Claude:
@@ -829,11 +764,7 @@
* If the compaction the message announces succeeds, you don’t need to do anything.
* If you see either of those two messages, run `/compact` at the Claude Code prompt to shorten the conversation yourself. If you turned [auto-compact](</docs/en/settings-reference#autocompactenabled>) off, turn it back on so Claude Code compacts on its own next time.
-###
-
-
-
-Agent terminated early due to an API error
+### Agent terminated early due to an API error
A [subagent](</docs/en/sub-agents>)’s API request failed terminally, for example because a usage limit was reached or retries for a server error ran out, so the subagent stopped before finishing its task. This message requires Claude Code v2.1.199 or later; before then the API error text was returned to Claude as if it were the subagent’s result.
@@ -846,19 +777,11 @@
When a rate limit, overload, or server error interrupts a foreground subagent that already produced text output, Claude receives that partial output marked as incomplete instead of this error. A subagent whose only output was tool calls gets this error too; in v2.1.199 that shape returned an empty partial result instead. See [API errors in subagents](</docs/en/sub-agents#api-errors-in-subagents>).
-##
-
-
-
-Usage limits
+## Usage limits
Most errors in this section mean a quota tied to your account or plan has been reached. Three work differently: `Server is temporarily limiting requests` is a server-side throttle unrelated to your plan quota, `Usage credits required for 1M context` is an entitlement check rather than an exhausted quota, and `The prompt to confirm went unanswered` means a usage-credits consent prompt closed unanswered, whether or not a quota was reached.
-###
-
-
-
-You’ve hit your session limit
+### You’ve hit your session limit
Subscription plans include a rolling usage allowance. When it runs out you see one of these messages:
@@ -878,11 +801,7 @@
Before a window runs out, Claude Code can warn you that you’ve used most of it, with a message such as `You've used 85% of your session limit · resets 3:45pm`. To watch your remaining allowance, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>).
-###
-
-
-
-Usage credits required for 1M context
+### Usage credits required for 1M context
The selected model uses the 1M-token extended context window, and your plan only includes it through usage credits.
@@ -897,11 +816,7 @@
Before v2.1.268, the message ended with `run /usage-credits to turn them on, or /model to switch to standard context` and didn’t mention restarting.
-###
-
-
-
-The prompt to confirm went unanswered
+### The prompt to confirm went unanswered
When the [Fable usage-credits consent prompt](</docs/en/model-config#fable-and-usage-credits>) closes with nobody answering it, Claude Code ends the turn with one of these messages:
@@ -916,11 +831,7 @@
Before v2.1.236, this message didn’t appear: while a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
-###
-
-
-
-Server is temporarily limiting requests
+### Server is temporarily limiting requests
The API applied a short-lived throttle that is unrelated to your plan quota.
@@ -931,11 +842,7 @@
* Wait briefly and try again
* Check [status.claude.com](<https://status.claude.com>) if it persists
-###
-
-
-
-Request rejected (429)
+### Request rejected (429)
You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Cloud project.
@@ -948,11 +855,7 @@
* For Anthropic API keys, see the [rate limits reference](<https://platform.claude.com/docs/en/api/rate-limits>) for how tiers work and how to set per-workspace caps
* Reduce concurrency: avoid running many parallel subagents, or switch to a smaller model with `/model` for high-volume scripted runs
-###
-
-
-
-You’ve hit your monthly spend limit
+### You’ve hit your monthly spend limit
Your plan’s included usage can’t cover this request, and the [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) that would otherwise pay for it have reached a spend limit. That happens when one of your plan’s usage windows has run out, or when the request is one that only usage credits pay for, such as a request to a model that [bills to usage credits](</docs/en/model-config#fable-and-usage-credits>). The message names whose limit blocked you. The text after the `·` says how to get that limit increased, and varies with your plan and whether you manage billing:
@@ -970,11 +873,7 @@
* If the message names a reset time for your plan’s window, you can wait for it instead
* Run `/usage` to see your plan’s windows and when each resets
-###
-
-
-
-Spend limit reached
+### Spend limit reached
You connect through a [Claude apps gateway](</docs/en/claude-apps-gateway>) and have reached a [spend cap](</docs/en/claude-apps-gateway-spend-limits>) your gateway operator set. The gateway blocks your requests until the operator raises the cap, or until the cap resets if it’s above $0. It marks each blocked `429` response `x-should-retry: false`, so in the terminal Claude Code shows this message without retrying.
@@ -996,11 +895,7 @@
A related message, `spend limit unavailable`, means the gateway could not read its spend records and blocked the request as a precaution rather than over your cap. It usually clears on its own; if it persists, tell your gateway operator.
-###
-
-
-
-Credit balance is too low
+### Credit balance is too low
Your Console organization has run out of prepaid credits, or Claude Code is sending your requests with a Console API key when you meant to use your subscription.
@@ -1012,11 +907,7 @@
* Add credits at [platform.claude.com/settings/billing](<https://platform.claude.com/settings/billing>), and consider enabling auto-reload there so the balance refills before it hits zero
* Set per-workspace spend caps in the Console to prevent a single project from draining the org balance. See [Manage costs effectively](</docs/en/costs>).
-###
-
-
-
-Could not update your spend limit
+### Could not update your spend limit
The server rejected a spend limit change you made from the prompt that appears when you reach your spend limit.
@@ -1028,19 +919,11 @@
* If the message shows only the generic form, retry; the failure may be transient
* If the change keeps failing, make it from your [claude.ai billing settings](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) in the browser instead
-##
-
-
-
-Authentication errors
+## Authentication errors
These errors mean Claude Code cannot prove who you are to the API. Run `/status` at any time to see which credential is currently active.
-###
-
-
-
-Not logged in
+### Not logged in
No valid credential is available for this session.
@@ -1056,11 +939,7 @@
If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock checks and macOS credential-storage recovery steps.
-###
-
-
-
-Could not resolve authentication method
+### Could not resolve authentication method
The session reached the API client without any credential. [Background sessions](</docs/en/agent-view>) and cloud sessions show this message when the worker starts without a credential. Interactive, `-p`, and Agent SDK runs report the same condition as Not logged in and write this string only to their debug log, so if you found it there, follow that entry instead.
@@ -1073,11 +952,7 @@
* For the Agent SDK, see [authentication setup in the quickstart](</docs/en/agent-sdk/quickstart#setup>)
* Run `/status` in an interactive session in the same environment to confirm which credential source resolves
-###
-
-
-
-Invalid API key
+### Invalid API key
The `ANTHROPIC_API_KEY` environment variable or `apiKeyHelper` script returned a key the API rejected, or Claude Code blocked a key from `ANTHROPIC_API_KEY` before sending it.
@@ -1091,11 +966,7 @@
* If the key comes from an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script, run the script directly to confirm it prints a valid key on stdout
* Run `/status` to confirm which credential source Claude Code is actually using
-###
-
-
-
-Your apiKeyHelper script is failing
+### Your apiKeyHelper script is failing
Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. The `Authentication` panel in the terminal shows which of these happened:
@@ -1113,11 +984,7 @@
* Run `/status` to see the failure and confirm `apiKeyHelper` is the active credential source. The `apiKeyHelper` row shows `Failing` with the last failure’s detail, such as the exit code and the command’s error output, and disappears after the next successful run. Before v2.1.274, `/status` showed only the credential source, not the failure.
* Each time the command fails, its exit code and error output also appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
-###
-
-
-
-Claude Code didn’t send your claude.ai login
+### Claude Code didn’t send your claude.ai login
These messages mean Claude Code refused your request and didn’t send your claude.ai login:
@@ -1135,11 +1002,7 @@
Before v2.1.315, a refused prompt or file upload printed one message that began `Claude Code didn't send your claude.ai login`.
-###
-
-
-
-Invalid request header value
+### Invalid request header value
A value Claude Code was about to send as a request header contains a character that HTTP headers can’t carry: a line break, a NUL byte, or a character above `U+00FF`, such as a curly quote or a zero-width space. Claude Code stops the request before anything is sent and names the variable or setting to fix. The usual cause is a credential pasted from a document or chat that carried an invisible character or a stray line break. Claude Code runs this check when it sends requests to the Claude API directly or through an [LLM gateway](</docs/en/llm-gateway>). On a third-party cloud provider such as [Amazon Bedrock](</docs/en/amazon-bedrock>), Claude Code doesn’t run it before sending.
@@ -1163,11 +1026,7 @@
* For `ANTHROPIC_CUSTOM_HEADERS`, keep one `Name: Value` pair per line and rewrite the pair the message counts
* Run `/status` to confirm which credential source is active
-###
-
-
-
-This organization has been disabled
+### This organization has been disabled
Claude Code is using a stale `ANTHROPIC_API_KEY` from a disabled Console organization. When you have a saved subscription login, the key overrides it.
@@ -1182,11 +1041,7 @@
* Run `/status` afterward to confirm the active credential is your subscription
* If no environment variable is set and the error persists, contact support or sign in with a different account.
-###
-
-
-
-Your organization has disabled API key authentication
+### Your organization has disabled API key authentication
This message requires Claude Code v2.1.169 or later. Your Console organization’s admin has turned off API key authentication, so the API rejects the key Claude Code is sending. The recovery hint after the `·` varies by where the key came from:
@@ -1204,11 +1059,7 @@
* Run `/status` afterward to confirm the active credential is your subscription rather than an API key
* If you need API key authentication for automation, ask your organization admin to re-enable it in the Console
-###
-
-
-
-Your organization has disabled Claude subscription access
+### Your organization has disabled Claude subscription access
Your Claude organization doesn’t allow signing in to Claude Code with a subscription login. Running `/login` again with the same account returns the same error.
@@ -1220,11 +1071,7 @@
* Authenticate with a Console API key instead of your subscription. See [Claude Console authentication](</docs/en/authentication#claude-console-authentication>) for setup.
* If you are the admin and do not see an option to enable access, contact [Anthropic support](<https://support.claude.com>)
-###
-
-
-
-Scheduled tasks are off for your organization
+### Scheduled tasks are off for your organization
[Cloud scheduled tasks](</docs/en/routines>) are off for your organization, so you can’t create or run them. The message from claude.ai calls them scheduled tasks or routines, and a sentence about your admin follows:
@@ -1235,11 +1082,7 @@
* Ask your Team or Enterprise Owner whether they can turn on the toggle labeled **Scheduled tasks (Was Routines)** or **Routines** at [**Organization settings > Capabilities > Remote sessions**](<https://claude.ai/admin-settings/capabilities>)
-###
-
-
-
-Remote Control requires the Anthropic API
+### Remote Control requires the Anthropic API
The session isn’t talking to the Anthropic API directly, which [Remote Control](</docs/en/remote-control>) requires.
@@ -1258,11 +1101,7 @@
* If the variable isn’t set in your shell, check the `env` key in your [settings files](</docs/en/settings#where-settings-live>), which applies environment variables to every session
* For this and the other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
-###
-
-
-
-Remote Control couldn’t refresh your login
+### Remote Control couldn’t refresh your login
Claude Code runs a live [Remote Control](</docs/en/remote-control>) connection on short-lived credentials that it obtains and renews using your saved claude.ai login. When claude.ai stops accepting that login, or Claude Code has no saved login left, Claude Code stops Remote Control and needs you to sign in again. Either failure can happen while Claude Code is still connecting or later, when it renews the credentials. When Claude Code asks the login service to refresh your saved login and gets no answer, it keeps Remote Control running and tries the refresh again while the connection’s current credential is still valid. A refresh gets no answer when Claude Code can’t reach the login service, the request times out, or the service fails without rejecting your login. If the login service still isn’t answering when that credential expires, Claude Code stops Remote Control and reports `OAuth token refresh failed`. When Claude Code stops Remote Control, it shows the reason in a warning and in a transcript line that starts with `Remote Control disconnected`. Your local session keeps running without Remote Control. This section covers these lines:
@@ -1289,11 +1128,7 @@
Before v2.1.224, `OAuth token refresh failed — run /login to re-authenticate` read `OAuth token refresh failed — re-authenticate, then re-enable Remote Control`, and `JWT refresh failed: no OAuth token — run /login` read `no OAuth token available for recovery (code <N>)`. The `Claude.ai login expired`, `Claude.ai login was rejected`, and `OAuth token unavailable` messages were added in v2.1.225. Before v2.1.238, Claude Code reported the cases that now say `Signed out of Claude` as `JWT refresh failed: no OAuth token — run /login`, and stopped Remote Control with `Claude.ai login expired — run /login to restore Remote Control` as soon as one login refresh got no answer.
-###
-
-
-
-Remote Control could not renew this computer’s connection
+### Remote Control could not renew this computer’s connection
This warning appears in the terminal running [`claude remote-control`](</docs/en/remote-control#start-a-remote-control-session>) when the server can’t use your claude.ai login to renew its connection’s credential before it expires. The warning’s last sentence says how long the current credential still works, or that it has already expired:
@@ -1304,11 +1139,7 @@
* If the warning tells you to run `claude /login`, open another terminal on the machine running the server, run `claude /login` there, and sign in with your claude.ai account
* If the server still can’t sign in once the connection’s credential has expired, it prints an error containing `Poll: Authentication failed (401)` and stops. Sign in again as the warning’s second sentence says, then run `claude remote-control` again in the terminal where the server stopped.
-###
-
-
-
-Remote Control stopped because the signed-in account changed
+### Remote Control stopped because the signed-in account changed
Claude Code shows this line during a [Remote Control](</docs/en/remote-control>) session when you sign in to a different claude.ai account or organization on this machine. You made the switch outside the Claude Code session, for example by running `/login` in another terminal. A Remote Control session that you started while signed in through `/login` belongs to the claude.ai account and organization that were signed in at the time.
@@ -1321,11 +1152,7 @@
Before v2.1.234, Claude Code didn’t notice when you switched to a different account or organization outside the Claude Code session. Claude Code kept the Remote Control session connected until a later request to the Remote Control server failed with `Remote Control server rejected the request (HTTP 404)`. That failure could come hours after the switch.
-###
-
-
-
-Remote Control stopped because the app running the session signed out or switched accounts
+### Remote Control stopped because the app running the session signed out or switched accounts
When the Claude desktop app or an IDE hosts your session, Claude Code gets its login token from that app rather than from `/login`. When claude.ai rejects that token, Claude Code asks the app for a new one. If the app answers that it’s signed out, or that it’s now signed in to a different Claude account, Claude Code ends the [Remote Control](</docs/en/remote-control>) session and sends the app one of these lines:
@@ -1339,11 +1166,7 @@
Before v2.1.238, Claude Code sent the app the `run /login` messages listed under Remote Control couldn’t refresh your login in both cases.
-###
-
-
-
-OAuth token revoked or expired
+### OAuth token revoked or expired
Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
@@ -1363,11 +1186,7 @@
* For repeated prompts to log in across launches, see the system clock checks and macOS credential-storage recovery steps in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
-###
-
-
-
-API Error: 401 Invalid authentication credentials
+### API Error: 401 Invalid authentication credentials
The API recognized the format of your credential but rejected the account or organization behind it. Anthropic returns this message when a credential was recently revoked, when an organization was disabled or removed your access, or when the account itself was deactivated, so an expired token isn’t the cause. The credential can be your saved login or an approved `ANTHROPIC_API_KEY`, and the fix differs, so start by running `/status` to see which one is active.
@@ -1381,11 +1200,7 @@
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
* If every request fails with a `401` once your gateway has the credential it expects, check that the gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
-###
-
-
-
-Login expired
+### Login expired
Claude Code tried to renew your saved claude.ai login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each model request stops locally with this message before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the model request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
@@ -1402,11 +1217,7 @@
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
-###
-
-
-
-Could not refresh your login because another Claude Code process is refreshing it
+### Could not refresh your login because another Claude Code process is refreshing it
This message doesn’t mean your login was rejected. Your saved claude.ai login had expired and needed renewing. Another Claude Code process on the same machine held the shared refresh lock, or exited and left it behind, and the refresh made no progress while this session waited. Claude Code stops the request before sending it:
@@ -1422,11 +1233,7 @@
* If the message keeps returning, close other Claude Code windows and processes, then retry.
* If it returns with no other Claude Code process running, run `/login`. Signing in again doesn’t wait on the refresh lock.
-###
-
-
-
-Could not refresh your login: the disk that holds the Claude Code config directory is full
+### Could not refresh your login: the disk that holds the Claude Code config directory is full
Free space on the disk that holds the Claude Code config directory, then send your message again. Signing in wouldn’t help while the disk is full, because a new login couldn’t be saved. The config directory is `~/.claude` in your home directory unless you set [`CLAUDE_CONFIG_DIR`](</docs/en/env-vars>).
@@ -1441,11 +1248,7 @@
* For a script, rerun its `claude -p` command
* If the disk already shows free space, running out of disk quota or of inodes produces the same message. Delete your own files on that disk. If the message returns, delete many small files rather than a few large ones, because each file takes one inode whatever its size.
-###
-
-
-
-Couldn’t save your login
+### Couldn’t save your login
You signed in with claude.ai, but Claude Code couldn’t save the login to its credential store, so the login didn’t complete. On macOS this can happen when the login keychain locks, for example on sleep or idle, after Claude Code has already read or saved credentials in it during the same session.
@@ -1458,11 +1261,7 @@
* On other platforms, run `/login` again
* If the login still doesn’t save, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for the keychain unlock command and other credential-storage recovery steps
-###
-
-
-
-Sign in again to take your previous account or API key off the config file
+### Sign in again to take your previous account or API key off the config file
This warning after you sign in means any account you were signed in with before may still be stored in [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>):
@@ -1472,11 +1271,7 @@
* Run `claude auth login` in your shell to sign in again. Claude Code then retries the save that takes the replaced account or API key off the file.
-###
-
-
-
-Your account or API key may still be in the config file
+### Your account or API key may still be in the config file
You ran `/logout` or `claude auth logout`, and Claude Code signed this process out but couldn’t confirm that [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>) no longer holds your account. Either the save didn’t land, or the file couldn’t be read back to check.
@@ -1486,11 +1281,7 @@
* Run `claude auth logout` in your shell to try the save again. When the save goes through, the command prints `Successfully logged out from your Anthropic account.`
-###
-
-
-
-Couldn’t start the local listener that receives the browser sign-in
+### Couldn’t start the local listener that receives the browser sign-in
Each of these messages from `/login`, `claude auth login`, or `claude setup-token` means Claude Code couldn’t open the port on `127.0.0.1` where your browser returns the sign-in result. With the notice that begins `The browser can't return the sign-in to Claude Code automatically`, the sign-in continues without that port. No browser opens, and the notice appears above a URL where you sign in instead:
@@ -1509,11 +1300,7 @@
Before v2.1.305, the sign-in stopped as soon as the port couldn’t be opened and showed no URL to sign in at. The message read, for example, `Failed to start OAuth callback server: Failed to start server. Is port 0 in use?`. On those versions, update Claude Code and sign in again, or sign in with a token or API key instead of the browser.
-###
-
-
-
-Claude login not accepted
+### Claude login not accepted
You tried to start a [cloud session](</docs/en/claude-code-on-the-web>), and the server refused to create it with a 401: it didn’t accept the Claude login this machine sent, usually because the login expired or was revoked. The first part of the line is the server’s own reason when it gives one. Otherwise the line reads:
@@ -1523,11 +1310,7 @@
* Run `/login`, complete the sign-in, then start the session again
-###
-
-
-
-Artifacts need a claude.ai login
+### Artifacts need a claude.ai login
Claude Code refused an [artifact](</docs/en/artifacts>) publish or read because the session has no claude.ai login it can use for artifacts. Every form of the message starts with the same words, followed by a remedy that depends on how your session authenticates. With no competing credential it reads:
@@ -1541,11 +1324,7 @@
* When the message says the credential is injected by the session’s host environment, you can’t change it in that session; start a session that is signed in to claude.ai
* See [Availability](</docs/en/artifacts#availability>) for the other requirements artifacts have, such as plan, model provider, and organization policy
-###
-
-
-
-Administrator policy requires a Cloud gateway sign-in
+### Administrator policy requires a Cloud gateway sign-in
An administrator’s [managed settings](</docs/en/managed-settings>) on this machine set [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"` or set [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>). Unless you select a cloud provider through a variable such as `CLAUDE_CODE_USE_BEDROCK`, Claude Code then accepts only the [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in. You see one of two messages:
@@ -1565,11 +1344,7 @@
Before v2.1.284, the startup message listed the possible credentials instead of naming the configured one. It began `Administrator policy requires a Cloud gateway sign-in on this machine; the Anthropic-issued credential configured here (ANTHROPIC_API_KEY, ANTHROPIC_AUTH_TOKEN, or apiKeyHelper) is not used.` If you see that wording and can’t tell which credential to remove, update to v2.1.284 or later and start `claude` again. On v2.1.265, a regression also showed the first message in some LLM-gateway and proxy configurations that authenticate with an API key, `apiKeyHelper`, or custom headers, even with no administrator requirement on the machine. Update to v2.1.266 or later. You don’t need to change your configuration. Before v2.1.261, on machines that set `forceLoginMethod` to `"gateway"`, Claude Code used a leftover saved login instead of failing model requests, and reported a configured environment credential with `This machine's managed settings require a first-party login` instead of the startup message.
-###
-
-
-
-Your account is on hold
+### Your account is on hold
The Claude account behind your login has been suspended. Claude Code shows the first message when it tries to renew your saved login and learns of the hold, and the second when a sign-in you complete in the browser reports it:
@@ -1581,11 +1356,7 @@
* Open the link in the message to view the hold’s details or appeal it
* If you have another Claude account or an API key that isn’t affected by the hold, you can keep working while the hold is resolved: run `/login` with that account, or set the key with `ANTHROPIC_API_KEY`
-###
-
-
-
-Anthropic profile login expired
+### Anthropic profile login expired
Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying.
@@ -1608,11 +1379,7 @@
This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message.
-###
-
-
-
-OAuth scope requirement
+### OAuth scope requirement
The stored token predates a permission scope that a newer feature needs:
@@ -1622,11 +1389,7 @@
* Run `/login` to get a new token with the current scopes. You don’t need to log out first.
-###
-
-
-
-claude.ai rejected the session token
+### claude.ai rejected the session token
A [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) request failed because claude.ai rejected the token from your Claude Code login. The rejected token is your login, not the connector’s own authorization in claude.ai, so authorizing the connector again doesn’t resolve it. In `/mcp`, the connector shows as `session token rejected` and its detail view reads:
@@ -1639,11 +1402,7 @@
Before v2.1.222, Claude Code marked the connector as needing authentication instead, which pointed you at the connector’s authorization flow even though completing it didn’t resolve the state.
-###
-
-
-
-MCP server needs you to sign in again
+### MCP server needs you to sign in again
A remote [MCP server](</docs/en/mcp>) rejected the credential on a tool call mid-session, usually because a sign-in or token expired or because the token lacks a permission the tool needs. The tool call fails, and `/mcp` marks the server as [needing authentication](</docs/en/mcp#authenticate-with-remote-mcp-servers>). For a server you sign in to from Claude Code, including a claude.ai connector, the sign-in expired or was revoked:
@@ -1671,11 +1430,7 @@
Run `/mcp`, select the server, and authenticate again from its menu. When the server’s configuration sets neither [`oauth.scopes`](</docs/en/mcp#restrict-oauth-scopes>) nor [`authServerMetadataUrl`](</docs/en/mcp#override-oauth-metadata-discovery>), Claude Code requests the scope the server named. With either setting, Claude Code requests that setting’s scopes instead. If you pinned `oauth.scopes`, add the missing scope to that list before you authenticate again. Before v2.1.274, this case showed the `needs you to sign in again` message, and before v2.1.273 it showed `requires re-authorization (token expired)` like the other cases.
-###
-
-
-
-Couldn’t read the stored credentials for MCP server
+### Couldn’t read the stored credentials for MCP server
Claude Code keeps your sign-ins for OAuth [MCP servers](</docs/en/mcp>) in a credential store. This message means Claude Code couldn’t read that store, so a request to the server didn’t run:
@@ -1702,11 +1457,7 @@
Before v2.1.307, a `claude -p` or Agent SDK run on a Mac with a locked login keychain reported the server as needing authentication instead of showing either message.
-###
-
-
-
-MCP server URL is missing or not a valid URL
+### MCP server URL is missing or not a valid URL
Claude Code refused to start an OAuth sign-in for a remote MCP server because the server’s configured `url` doesn’t parse as a URL. Unless Claude Code has a more specific configuration problem to report for the server, running [`claude mcp login <name>`](</docs/en/mcp#authenticate-from-the-command-line>) in your shell prints the refusal as:
@@ -1716,11 +1467,7 @@
* Set the entry’s `url` to the server’s real endpoint where the server is configured, or set the environment variable that its [`${VAR}` reference](</docs/en/mcp#environment-variable-expansion-in-mcp-json>) names, then run the sign-in again.
-###
-
-
-
-Issuer mismatch in authorization response
+### Issuer mismatch in authorization response
During an [MCP OAuth sign-in](</docs/en/mcp#authenticate-with-remote-mcp-servers>), the authorization server redirected back to Claude Code with an `iss` parameter that doesn’t name the issuer that Claude Code expected from the server’s OAuth metadata. A wrong issuer at this step is how an authorization server mix-up attack looks, so Claude Code fails the sign-in instead of exchanging the authorization code. Claude Code shows the error in the `/mcp` server menu after the browser sign-in:
@@ -1734,11 +1481,18 @@
Before v2.1.232, Claude Code used the v2 runtime only in a gradual rollout or when you set `MCP_SDK_GENERATION=v2`.
-###
-
-
-
-Refusing to send credentials to non-https token endpoint
+### Stopped an OAuth request
+
+This message means that Claude Code stopped an [OAuth request for an MCP server](</docs/en/mcp#authenticate-with-remote-mcp-servers>) because an OAuth endpoint redirected it. In both forms of the message, the first address is the one that sent the redirect:
+
+ Stopped an OAuth request, which can hold secrets: https://auth.example.com redirected it to https://other.example.com. Ask the owner of https://auth.example.com to remove that redirect.
+ Stopped an OAuth request: https://auth.example.com redirected it more than 5 times. Ask the owner of https://auth.example.com to fix those redirects.
+
+**What to do:**
+
+ * Ask whoever runs the first address, such as the MCP server’s operator, to remove or fix the redirect. Then try again from `/mcp`.
+
+### Refusing to send credentials to non-https token endpoint
On the [v2 runtime](</docs/en/mcp#mcp-client-runtimes>), Claude Code sends an [MCP OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>) token request only to a token endpoint served over HTTPS or at `localhost`, `127.0.0.1`, or `::1`. This message means the server’s token endpoint is neither, so Claude Code stopped before sending the request. That happens after the browser sign-in, so the browser step succeeds first, and again whenever Claude Code refreshes the server’s token. In its full form, the message comes from the MCP SDK and quotes the token endpoint it refused. In the debug log, it follows `Error during auth completion:` for a sign-in or `Token refresh failed:` for a refresh. In your shell, `claude mcp login <name>` prints it after `Couldn't complete authentication for "<name>":`, and in a session, `/mcp` shows it under the server’s menu:
@@ -1749,11 +1503,7 @@
* Serve that token endpoint over HTTPS, for example by putting the server behind a reverse proxy or tunnel that terminates TLS and configuring the server to advertise the `https://` address
* To connect without changing the server, start Claude Code with [`MCP_SDK_GENERATION=v1`](</docs/en/env-vars>), whose [runtime](</docs/en/mcp#mcp-client-runtimes>) doesn’t apply this rule and sends the token request over plain HTTP. That choice lasts until you exit and applies to every server. The v1 runtime also skips the issuer check, so prefer serving the endpoint over HTTPS
-###
-
-
-
-AWS credentials expired or invalid
+### AWS credentials expired or invalid
Your AWS session token expired or was rejected. This message appears on a 401 from [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), which is how those providers report an expired security token. The action hint in the middle varies with your setup. The stable part is the leading `AWS credentials expired or invalid`:
@@ -1766,11 +1516,7 @@
* With `awsAuthRefresh` set in an interactive session, you can instead run `/login`, choose **3rd-party platform** , then select **Claude Platform on AWS · refresh credentials** under **Using 3rd-party platforms** to run the same command without restarting Claude Code. See [Configure AWS credentials](</docs/en/claude-platform-on-aws#1-configure-aws-credentials>)
* If the error repeats after the refresh command succeeds, confirm the identity is valid outside Claude Code with `aws sts get-caller-identity` in the same shell and profile
-###
-
-
-
-AWS authentication failed
+### AWS authentication failed
Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission. Claude Code can’t tell those two causes apart. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Amazon Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
@@ -1783,11 +1529,7 @@
* If your credentials are current, confirm the IAM permissions in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>) are attached to the identity you’re using and that the selected model is enabled for your account and region
* Run `aws sts get-caller-identity` to confirm which identity your requests use
-###
-
-
-
-Google Cloud credentials expired or invalid
+### Google Cloud credentials expired or invalid
Your Google Cloud credentials for [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>) expired or were rejected: the request returned a 401, which is how Agent Platform reports credential expiry. The action hint in the middle varies with your setup. The stable part is the leading `Google Cloud credentials expired or invalid`:
@@ -1803,11 +1545,7 @@
Before v2.1.273, a 401 from Agent Platform showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Google Cloud credentials.
-###
-
-
-
-Google Cloud authentication failed
+### Google Cloud authentication failed
[Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>) returned a 403, which it uses for authorization denials rather than expired credentials. Usually the identity you authenticate with is missing an IAM permission, or the model isn’t enabled for your project. The action hint in the middle varies with your setup. The stable part is the leading `Google Cloud authentication failed`:
@@ -1821,11 +1559,7 @@
Before v2.1.273, a 403 from Agent Platform showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Google Cloud credentials.
-###
-
-
-
-Microsoft Foundry authentication failed
+### Microsoft Foundry authentication failed
[Microsoft Foundry](</docs/en/microsoft-foundry>) returned a 401 or 403: the Azure credential on the request was rejected, or the identity behind it doesn’t have access to the Foundry resource. `/login` can’t mint Azure credentials. The action hint in the middle varies with your setup. The stable part is the leading `Microsoft Foundry authentication failed`:
@@ -1839,11 +1573,7 @@
Before v2.1.273, a 401 or 403 from Microsoft Foundry showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Azure credentials.
-###
-
-
-
-Could not load AWS or Google Cloud credentials
+### Could not load AWS or Google Cloud credentials
Claude Code couldn’t obtain usable credentials from the AWS credential provider chain or from your Google application default credentials on the machine it runs on, so no request reached your cloud provider. The detail after the `·` names the specific cause, such as an expired SSO session, missing application default credentials reported as `Could not load the default credentials`, or a revoked sign-in reported as `invalid_grant`:
@@ -1855,11 +1585,7 @@
* Run your provider’s sign-in command, such as `aws sso login --profile myprofile` or `gcloud auth application-default login`, then retry. [Bedrock, Agent Platform, or Foundry credentials not loading](</docs/en/troubleshoot-install#bedrock-agent-platform-or-foundry-credentials-not-loading>) shows how to confirm the credentials outside Claude Code
* If the detail reads `AWS default-chain credential resolve timed out`, the chain hung rather than failed, so follow AWS default-chain credential resolve timed out instead
-###
-
-
-
-AWS default-chain credential resolve timed out
+### AWS default-chain credential resolve timed out
The AWS default credential provider chain didn’t produce credentials within 60 seconds, so Claude Code stopped the resolve and failed the request. This timeout is one cause of Could not load AWS or Google Cloud credentials. The failure is local credential resolution: the request never reached [Amazon Bedrock](</docs/en/amazon-bedrock>), [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>). Claude Code clears its [credential cache](</docs/en/amazon-bedrock#credential-caching-and-resolution-timeout>) and retries before this error surfaces, so by the time you see it the chain has stalled on repeated attempts.
@@ -1871,11 +1597,7 @@
* Complete the sign-in step before starting Claude Code, for example `aws sso login --profile myprofile`
* If your chain runs an interactive sign-in that legitimately needs more than 60 seconds, such as SSO with MFA through a wrapper like `aws-vault`, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
-###
-
-
-
-Bedrock setup verification timed out waiting for AWS
+### Bedrock setup verification timed out waiting for AWS
A call to AWS during the [Bedrock setup wizard](</docs/en/amazon-bedrock#sign-in-with-bedrock>)’s credential verification, such as the credential lookup or the identity check, didn’t finish within the 60-second limit. The wizard stops waiting and fails the verification step:
@@ -1891,11 +1613,7 @@
* Complete any interactive sign-in before opening the wizard, for example `aws sso login --profile myprofile`
* If a credential helper in your AWS profile legitimately needs longer than 60 seconds to prompt you, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
-###
-
-
-
-Cloud gateway session expired
+### Cloud gateway session expired
You signed in through a [Claude apps gateway](</docs/en/claude-apps-gateway>), and the gateway session saved on this machine has expired and couldn’t be renewed, or the gateway no longer accepts it, for example after the gateway’s [JWT secret is replaced](</docs/en/claude-apps-gateway-deploy#jwt-secret-rotation>). If you see this line when you start `claude` interactively, the session has opened signed out of the gateway:
@@ -1910,11 +1628,7 @@
* Run `/login` in the session and complete the browser sign-in
* For a non-interactive launch, start `claude` in the same environment, run `/login`, then rerun your command
-###
-
-
-
-Sign-in timed out while waiting for you to continue
+### Sign-in timed out while waiting for you to continue
During a [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in, the gateway named the account that signed in, and Claude Code asked you to confirm it before saving the credential. You left the confirmation open past the sign-in’s own expiry, and the gateway issued no refresh token that could renew it, so Claude Code stored nothing when you continued:
@@ -1924,11 +1638,7 @@
* Run `/login` again and confirm the account before the sign-in expires
-###
-
-
-
-Gateway refused the request
+### Gateway refused the request
You’re signed in through a [Claude apps gateway](</docs/en/claude-apps-gateway>), and a request returned a 403: the gateway, or the upstream behind it, refused it. Signing in again doesn’t change a refusal, so the message points at your gateway administrator:
@@ -1941,19 +1651,11 @@
Before v2.1.273, a 403 on a gateway session showed the generic `Please run /login` or `Failed to authenticate` message instead, and signing in again didn’t clear the refusal.
-##
-
-
-
-Network and connection errors
+## Network and connection errors
Most of these errors mean a network request from Claude Code failed to reach its destination, or something between Claude Code and the API altered the response on its way back; where an entry also has a local cause, such as a failed archive write, its body says so. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
-###
-
-
-
-Unable to connect to API
+### Unable to connect to API
The TCP connection to the API failed or never completed. For the common connection error codes, the message names the kind of failure and keeps the code in parentheses:
@@ -1981,11 +1683,7 @@
* On macOS, a VPN client that was disconnected or uninstalled can leave a tunnel interface or routing rule behind. Check `ifconfig` for stale `utun` interfaces and remove the VPN’s network extension in System Settings.
* Docker Desktop and similar container runtimes can intercept outbound traffic. Quit them and retry to rule this out.
-###
-
-
-
-Unable to connect to Anthropic services
+### Unable to connect to Anthropic services
During first-run setup, Claude Code checks that it can reach `api.anthropic.com` and `platform.claude.com` before showing the sign-in step. When either check fails, Claude Code prints the reason and exits.
@@ -2000,22 +1698,14 @@
* Work through the checks in Unable to connect to API. The `curl` test and firewall guidance there apply to this check too.
* If your network is open and the failure persists, Claude Code may not be [available in your country](<https://www.anthropic.com/supported-countries>)
-###
-
-
-
-Socket is closed
+### Socket is closed
`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Depending on how far the response had progressed, Claude Code retries the request, keeps what Claude produced, or ends the turn. See Automatic retries. Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
* If you see this error, update to v2.1.214 or later with `claude update`, then send your message again
* If turns keep failing behind the same proxy after updating, work through Unable to connect to API and check the proxy setup in [Network configuration](</docs/en/network-config>)
-###
-
-
-
-API returned an empty or malformed response
+### API returned an empty or malformed response
Claude Code shows this error when its non-streaming retry of a failed streaming request gets an HTTP success status but the body isn’t a Claude API message: commonly an HTML error or sign-in page, an empty body, or JSON in another format. A proxy, gateway, or network sign-in page answering in the API’s place is the usual source. Claude Code doesn’t retry the request, and the turn ends with this error.
@@ -2033,11 +1723,7 @@
* On a network with a sign-in page, such as guest Wi-Fi, complete the sign-in in a browser, then retry
* If only the non-streaming route through your gateway is broken, set [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK=1`](</docs/en/env-vars#variables>) to turn off this fallback, except when the streaming endpoint itself returns `404`, where Claude Code still falls back
-###
-
-
-
-Streaming response ended before any complete data was received
+### Streaming response ended before any complete data was received
A streaming response from your model provider completed without delivering any usable data, so Claude Code re-sent the request without streaming to finish the turn. Claude Code shows the warning once per session, in interactive sessions only. Before v2.1.239, Claude Code silently retried without streaming.
@@ -2048,11 +1734,7 @@
* Configure any proxy or gateway between Claude Code and your model provider to pass streaming response bodies and their headers through unmodified
* On [Amazon Bedrock](</docs/en/amazon-bedrock>), see [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>) for the header and body requirements
-###
-
-
-
-Bedrock streaming response has an unexpected content-type
+### Bedrock streaming response has an unexpected content-type
A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`. Rather than decode a body it can’t read, Claude Code rejects a successful streaming response that reports a different content-type. Claude Code doesn’t retry the request.
@@ -2063,11 +1745,7 @@
* Configure the gateway to pass the `InvokeModelWithResponseStream` response body and its `Content-Type` header through unmodified. An intermediary that re-emits the stream as server-sent events is a common cause.
* Setting [`CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1`](</docs/en/env-vars>) hides this error, but Claude Code doesn’t decode a binary body under a rewritten header, so those requests fall back to a slower non-streaming path. See [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>).
-###
-
-
-
-SSL certificate errors
+### SSL certificate errors
A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Claude Code does not trust it.
@@ -2084,13 +1762,9 @@
* See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
* Don’t set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
-###
-
-
-
-Host not allowed in a cloud session
-
-An outbound HTTP request from a cloud session or cloud scheduled task was blocked by the environment’s network policy.
+### Host not allowed in a cloud session
+
+In a cloud session or cloud scheduled task, a `403` or a DNS error such as `ENOTFOUND` can mean that the requested host isn’t on the [cloud environment’s allowlist](</docs/en/cloud-environments#access-levels>). To confirm, check the host against that list. A `403` with this header confirms the block, but not every blocked request’s `403` has it:
HTTP 403
x-deny-reason: host_not_allowed
@@ -2108,11 +1782,7 @@
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
-###
-
-
-
-The proxy refused the connection
+### The proxy refused the connection
You see this message when Claude reads an [artifact](</docs/en/artifacts>) through the proxy you set in `HTTPS_PROXY` or a related [proxy variable](</docs/en/network-config#environment-variables>). Artifact content comes from `*.frame.claudeusercontent.com`, so Claude Code first sends the proxy a `CONNECT` request asking it to open a tunnel to that host. When the proxy refuses, nothing reaches the host, and the message carries the proxy’s HTTP status:
@@ -2134,11 +1804,7 @@
Before v2.1.238, Claude Code reported a refused tunnel as a generic network error.
-###
-
-
-
-The cloud environments service returned an empty or unexpected response
+### The cloud environments service returned an empty or unexpected response
Claude Code requests your [cloud environments](</docs/en/cloud-environments>) list at several points, such as when you create a cloud session from the CLI or run [`/remote-env`](</docs/en/cloud-environments#select-an-environment-from-the-cli>). When it can’t read the server’s answer, it shows one of these messages:
@@ -2153,11 +1819,7 @@
Before v2.1.236, Claude Code showed a raw JavaScript TypeError instead of these messages.
-###
-
-
-
-Failed to fetch session from Sessions API
+### Failed to fetch session from Sessions API
This message means Claude Code found the [cloud session you asked to pull into your terminal](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>) but couldn’t read its conversation history from Anthropic’s servers, so it didn’t open it:
@@ -2169,11 +1831,7 @@
Before v2.1.296, Claude Code didn’t retry a failed read, and after one it could open the session with an empty conversation and report success instead of printing this message.
-###
-
-
-
-Couldn’t reconnect to your Remote Control session
+### Couldn’t reconnect to your Remote Control session
Couldn't reconnect to your Remote Control session. Retry, or start a fresh session without --resume.
@@ -2185,11 +1843,7 @@
If the server reports instead that the previous session is gone, you don’t see this message. Claude Code starts a new session in its place or shows [`Previous session is unavailable — run /remote-control to start a new one`](</docs/en/remote-control#previous-session-is-unavailable>).
-###
-
-
-
-Sessions ended while this machine was offline
+### Sessions ended while this machine was offline
Claude Code shows this message in the terminal running [`claude remote-control`](</docs/en/remote-control#start-a-remote-control-session>) after your machine was offline long enough that the server cleaned up the Remote Control environment your machine was serving. The sessions in that environment ended, and you can’t resume them. The count is the number of sessions that ended.
@@ -2200,11 +1854,7 @@
* When Claude Code lists kept worktrees under this message, pick up any uncommitted work from them
* Run `claude remote-control` to start a fresh environment
-###
-
-
-
-Couldn’t share the transcript
+### Couldn’t share the transcript
After you agree to share your session transcript from a survey prompt, such as the [session quality survey](</docs/en/data-usage#session-quality-surveys>), Claude Code uploads it to Anthropic, or saves a local archive instead on third-party providers, on [Claude apps gateway](</docs/en/claude-apps-gateway>) sessions, and when no Anthropic credentials are available. This message means the share didn’t complete.
@@ -2215,11 +1865,7 @@
* Run `/feedback` to send the transcript with a description of what happened. See Report an error if `/feedback` is unavailable in your environment
* If other requests are failing too, check your network connection and see Unable to connect to API
-###
-
-
-
-Couldn’t send feedback
+### Couldn’t send feedback
A message starting `Couldn't send feedback` means the feedback service didn’t confirm the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>). Treat it as not received. When a sentence about your organization follows the colon, your organization refuses feedback. The second example is an organization’s refusal:
@@ -2237,11 +1883,7 @@
Issues at github.com/anthropics/claude-code are public, so leave out code, transcripts, and anything else confidential when you open one. Before v2.1.281, every send failed with this message once a Remote Control **Stop** or an urgent cross-session message had arrived while the dialog was open. On those versions, close the dialog, reopen it, and send again.
-###
-
-
-
-Feedback payload too large
+### Feedback payload too large
This message in the [review screen](</docs/en/tools-reference#review-and-edit-a-draft>) for a [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>) means Claude Code has no confirmation that the service accepted the draft. Treat it as not received. The draft stays in your `/feedback` queue, so you can send it again.
@@ -2251,11 +1893,7 @@
* In the review screen, set **Send transcript** to `no`, then send the draft again. Shortening the details removes at most 10 KB of text, which is all a draft’s details can hold.
-###
-
-
-
-MCP server connection timed out during a sleep or clock change
+### MCP server connection timed out during a sleep or clock change
This message means a connection to an [MCP server](</docs/en/mcp>) timed out, and Claude Code found that your system clock jumped forward during the attempt:
@@ -2270,19 +1908,11 @@
Before v2.1.307, Claude Code showed a timeout message such as `MCP server "<name>" connection timed out after <N>ms` instead of this one.
-##
-
-
-
-Request errors
+## Request errors
These errors relate to the content of your request. Most come back from the API after it rejected the request; a few are produced locally by Claude Code before any request is sent.
-###
-
-
-
-Prompt is too long
+### Prompt is too long
The conversation plus attached files exceeds the model’s context window.
@@ -2331,11 +1961,7 @@
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
-###
-
-
-
-Context exceeds the token limit
+### Context exceeds the token limit
`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window:
@@ -2357,11 +1983,7 @@
Before v2.1.216, `/context` showed usage above 100% with no warning line explaining what that meant or how to recover.
-###
-
-
-
-Request too large
+### Request too large
The raw request body exceeded the API’s 32MB limit before tokenization, usually because of large pasted content, tool results, or attachments. This limit is separate from the context window.
@@ -2379,11 +2001,7 @@
* Reference large files by path instead of pasting their contents, so Claude can read them in chunks
* For images, see Image was too large below
-###
-
-
-
-Image was too large
+### Image was too large
A pasted or attached image exceeds the API’s size or dimension limits.
@@ -2406,11 +2024,7 @@
The `dimension limit for many-image requests` message shows the pixel limit named in the API’s error.
-###
-
-
-
-Unable to resize image
+### Unable to resize image
Claude Code couldn’t downscale an attached image before sending it to the API.
@@ -2422,17 +2036,13 @@
Unable to resize image — it is an animated WebP whose first frame Claude Code cannot decode, and at …px it is over the 2000x2000px limit, so it cannot be sent. Save its first frame as a PNG or JPEG and try again.
Unable to resize image — its pixels could not be decoded (the file may be damaged, or use an encoding Claude Code cannot read), and it is over the … API limit (… raw, … base64), so it cannot be sent. Re-save it as a PNG or JPEG and try again.
-Claude Code normally resizes large images automatically. These errors mean the image couldn’t be decoded or resized to fit within the API limits. **What to do:**
+Claude Code normally resizes large images automatically. These errors mean the image couldn’t be decoded or resized to fit within the API limits. The error you see can name a different pixel limit, such as `2576x2576px` where these examples say `2000x2000px`. **What to do:**
* If the message asks you to convert the image, convert it to PNG, JPEG, GIF, or WebP and attach it again. Claude Code can verify dimensions for these formats from the file header, without decoding the image.
* If the message reports a dimension or size limit, resize or recompress the image below that limit before attaching.
* If the message names a cause, such as a CMYK JPEG, an animated WebP, or a possibly damaged file, re-save the image in the format the message suggests and attach it again.
-###
-
-
-
-Request rejected as unprocessable by the model
+### Request rejected as unprocessable by the model
The API refused the request as one the model can’t process. The message is the API’s own.
@@ -2442,11 +2052,7 @@
* If the message keeps appearing in a conversation with images or documents, remove them yourself. Press Esc twice to step back past the turns that added them, or run `/clear` to start fresh.
-###
-
-
-
-PDF errors
+### PDF errors
The PDF you attached couldn’t be processed. The messages are shown here in their non-interactive form; in an interactive session they instead prompt you to double press esc and try again.
@@ -2465,11 +2071,7 @@
Page-range reads render pages with `pdftoppm`. Install poppler-utils with the command the message gives, or on other platforms a poppler build that puts `pdftoppm` on your `PATH`. See [Read tool behavior](</docs/en/tools-reference#read-tool-behavior>) for which PDFs are read by page range.
-###
-
-
-
-Extra inputs are not permitted
+### Extra inputs are not permitted
The endpoint that received the request rejected one of the request’s fields as an input it doesn’t accept, and the endpoint’s message names that field.
@@ -2484,11 +2086,7 @@
Before v2.1.302, this error could also name the field `diagnostics` with no gateway involved. It appeared when a session that had already used the Anthropic API moved to Amazon Bedrock or Google Cloud’s Agent Platform without a restart. For example, a session you left open moves to Bedrock when you run [`/setup-bedrock`](</docs/en/commands>) in another Claude Code window. On those versions, run `/clear` in that session or restart it.
-###
-
-
-
-Tool input schema is invalid
+### Tool input schema is invalid
A tool in the request declared an `input_schema` that fails the API’s JSON Schema validation, so the API rejected the whole request. The number after `tools.` is the failing tool’s position in the request’s tool list, not a name you can look up.
@@ -2501,11 +2099,7 @@
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
* If you maintain the server, fix the tool’s `input_schema`. The schema must be valid JSON Schema, and top-level property names must be 1 to 64 characters long and use only ASCII letters and digits, `_`, `.`, and `-`. See [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>).
-###
-
-
-
-MCP tool name over 128 characters
+### MCP tool name over 128 characters
An MCP server lists a tool whose full name, such as `mcp__<server>__<tool>`, is longer than the 128 characters the API accepts. Claude Code [leaves that tool out of the tools it sends to Claude](</docs/en/mcp#tools-with-names-longer-than-128-characters>), and the server’s other tools keep working. In a session you start with `claude --debug` from your shell, Claude Code writes this message to the debug log at `~/.claude/debug/<session-id>.txt`:
@@ -2519,11 +2113,7 @@
Before v2.1.292, Claude Code sent the tool anyway, and the API rejected every request that included it with `API Error: 400 ... tools.N.custom.name: String should have at most 128 characters`.
-###
-
-
-
-tool_use.name over 200 characters
+### tool_use.name over 200 characters
A tool call in the conversation history carries a name longer than the 200 characters the API accepts in a request:
@@ -2535,11 +2125,7 @@
Before v2.1.281, the overlong name stayed in the history and the API rejected every request that re-sent the conversation, including `/compact` and `--resume`, so this error repeated and the conversation was stuck.
-###
-
-
-
-There’s an issue with the selected model
+### There’s an issue with the selected model
The configured model name was not recognized or your account lacks access to it. As of v2.1.160 the trailing hint, shown here in its interactive form, varies by surface.
@@ -2556,11 +2142,7 @@
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
-###
-
-
-
-Model is not a recognized model id
+### Model is not a recognized model id
The string you passed to a model switch isn’t one Claude Code can use as a model, so it refused the switch without sending a request and the session keeps its current model. You can get this error when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.200, Claude Code saved the string and failed on the next request with There’s an issue with the selected model.
@@ -2573,11 +2155,7 @@
* A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under [Setting your model](</docs/en/model-config#setting-your-model>).
* On any provider other than the Anthropic API, or behind a gateway or custom `ANTHROPIC_BASE_URL`, only an empty string gets this error. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
-###
-
-
-
-Model not found
+### Model not found
You switched to a model by name and Claude Code couldn’t confirm that a model with that name exists. When the name isn’t a [model alias](</docs/en/model-config#model-aliases>) or another spelling Claude Code accepts locally, Claude Code verifies it with a minimal API request, and this error is usually your API endpoint’s answer. With `/model <name>`, a name that can’t be a model ID at all, such as one containing spaces, gets the same message.
@@ -2590,11 +2168,7 @@
* In the Agent SDK, `setModel()` fails with this message and the session keeps running on its previous model. In the TypeScript SDK, call [`supportedModels()`](</docs/en/agent-sdk/typescript#query-object>) to list the models you can switch to.
* Before v2.1.265, `/model` also rejected the `opusplan[1m]` alias spelling with this error. On those versions, update Claude Code, or set the model in [settings](</docs/en/model-config#setting-your-model>) or with `--model` instead.
-###
-
-
-
-Couldn’t confirm model with the API
+### Couldn’t confirm model with the API
You switched models through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), and the request that confirms the model ID with your API endpoint got no answer within 15 seconds. The session keeps its current model.
@@ -2605,11 +2179,7 @@
* Switch to the model again
* If the switch keeps failing, check that Claude Code can reach your API endpoint; see Network and connection errors
-###
-
-
-
-API error when checking the picked model
+### API error when checking the picked model
You picked a model with `/model <name>`, or an app connected to the session requested the switch. The API refused the minimal request Claude Code sends to verify the model, for a reason that has no entry of its own, such as a rate limit or a server error. The session keeps its current model, and the message ends by saying so:
@@ -2620,11 +2190,7 @@
* Act on the server’s explanation; for a rate limit or a 5xx status, wait and pick the model again
* The refusals with their own wording are covered by the surrounding entries, such as Model not found and Model is restricted by your organization’s settings
-###
-
-
-
-Claude Opus is not available with the Claude Pro plan
+### Claude Opus is not available with the Claude Pro plan
Your active subscription plan does not include the model you selected.
@@ -2636,11 +2202,7 @@
* If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on claude.ai does not take effect in an existing session until you re-authenticate.
* See [claude.com/pricing](<https://claude.com/pricing>) for which models each plan includes
-###
-
-
-
-Claude Code does not support this model
+### Claude Code does not support this model
The API refused the request with a 400 because your Claude Code version is below a required minimum. Either the model you selected requires a newer version, which the server checks per model, or your organization’s policy requires one. The 400 carries the error code `claude_code_version_too_old`, and the message says which minimum applies.
@@ -2663,11 +2225,7 @@
* For the per-model wording, you can keep working in the current session by switching to another model: run `/model` in the CLI, call [`setModel()`](</docs/en/agent-sdk/typescript#query-object>) on the TypeScript SDK’s `Query` object in streaming input mode, or call [`set_model()`](</docs/en/agent-sdk/python#claudesdkclient>) on the Python SDK’s `ClaudeSDKClient`
* For the organization-policy wording, update before you continue
-###
-
-
-
-Model is restricted by your organization’s settings
+### Model is restricted by your organization’s settings
Your organization admin has disabled this model in the claude.ai admin console, or managed settings exclude it through an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist or a [`deniedModels`](</docs/en/model-config#block-specific-models-or-versions>) list. The notice appears at startup when `--model`, `ANTHROPIC_MODEL`, or the `model` setting named the restricted model, and it names the model the session uses instead. If managed settings leave no permitted model for the session to use, see Managed settings block the default model. The substitution notice can also appear mid-session after an admin disables the model a session is running on in the claude.ai admin console.
@@ -2679,11 +2237,7 @@
* If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, the `model` field of a settings file, or the `model` frontmatter of a [subagent](</docs/en/sub-agents#choose-a-model>), skill, or command, remove or update that value so the notice doesn’t recur
* If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
-###
-
-
-
-Can’t switch to the default model
+### Can’t switch to the default model
You picked the Default model, for example by selecting the Default row in the `/model` picker or typing `/model default`. Claude Code refused the switch, so the session keeps its current model.
@@ -2703,11 +2257,7 @@
If a session instead fails to start with a `Claude Code can't start` message under these managed settings, see Managed settings block the default model.
-###
-
-
-
-Model switch was blocked by a PreModelSwitch hook
+### Model switch was blocked by a PreModelSwitch hook
A [PreModelSwitch hook](</docs/en/hooks#premodelswitch>) didn’t approve the model switch you or a client requested, so the session keeps its current model. When the switch came from an [Agent SDK](</docs/en/agent-sdk/overview>) host or [Remote Control](</docs/en/remote-control>) rather than a command you typed, the message reads `Model switch blocked by a PreModelSwitch hook` without naming the target model.
@@ -2718,16 +2268,12 @@
* **A reason a hook wrote** : a PreModelSwitch hook supplied that reason when it [denied the switch or asked for confirmation](</docs/en/hooks#premodelswitch-decision-control>). Address what it asks, or pick a model your hooks allow.
* **`PreModelSwitch hook<name> did not respond before its timeout`**: a hook that doesn’t answer before its [timeout](</docs/en/hooks#timeouts>) blocks the switch. Fix the hanging command or raise that hook’s `timeout`, then switch again.
* **`confirmation required, and this session cannot ask`** : a hook answered `ask` without a reason, and a control request has no way to show the confirmation prompt. A `/model` command in a [`-p` run](</docs/en/headless>) reports the same condition with `(run /model interactively to confirm)` after the reason. Make the switch from an interactive session, or change the hook’s decision for this model.
- * **`so organization-managed PreModelSwitch hooks could not be checked`** : Claude Code couldn’t tell which PreModelSwitch hooks your organization’s [managed plugins](</docs/en/settings-reference#enabledplugins>) deliver, for example because a managed plugin failed to load. One of those hooks might block the switch, so Claude Code refuses rather than apply the switch unchecked. The start of the reason names what failed. Claude Code re-checks on every switch attempt, so a failure that has since cleared stops blocking; if it keeps failing, run `claude --debug` and switch again to capture the details, then fix the plugin or ask your admin to fix it.
+ * **`so organization-managed PreModelSwitch hooks could not be checked`** : Claude Code before v2.1.323 refuses when it can’t tell which PreModelSwitch hooks your [managed plugins](</docs/en/settings-reference#enabledplugins>) deliver. The text before this phrase names what failed. To stop the refusal, update Claude Code. To also get a failed plugin’s hooks running, fix the plugin or ask your admin. For details, start `claude --debug` in your shell and switch models, then read the [debug log](</docs/en/hooks#debug-hooks>).
* **`a PreModelSwitch hook failed before answering`** or **`PreModelSwitch hooks were cancelled (the control stream closed) before answering`** : the hook run ended without a verdict, and Claude Code doesn’t treat that as approval. Run `claude --debug` to see what failed, then switch again.
Before v2.1.260, the managed-plugin refusal read `plugin hooks could not be loaded, so PreModelSwitch hooks could not be checked; see the debug log`. Claude Code retried the plugin load once and then refused later switches in the session, even when your organization managed no plugins. Restart the session to run the plugin load again on those versions.
-###
-
-
-
-Couldn’t save it as your default
+### Couldn’t save it as your default
You picked a model to save as your default, for example with `/model <name>` or `Enter` in the `/model` picker, and Claude Code couldn’t write the pick to your user settings file, `~/.claude/settings.json`. The switch itself applied, so the current session runs on the model you picked, but your default is unchanged and the next session starts on the old value.
@@ -2740,11 +2286,7 @@
A notice ending `couldn't confirm it was saved as your default (~/.claude/settings.json is still being written)` means the write hadn’t finished after three seconds. It continues in the background, so the default may still be saved; check which model your next session starts on, or run `/model <name>` again. Before v2.1.265, the notice said the model was `saved as your default for new sessions` even when the write failed.
-###
-
-
-
-Advisor is less capable than the current main model
+### Advisor is less capable than the current main model
Your [advisor model](</docs/en/advisor>) ranks below your session’s main model, so Claude Code keeps the selection but doesn’t attach the advisor to the main model’s requests.
@@ -2763,11 +2305,7 @@
Before v2.1.287, Claude Code ranked several pairings differently. It showed this note for a Sonnet 5.5 advisor with an Opus 4.7 or Opus 4.8 main model, a pairing it now accepts. It also attached some advisors that now produce this note, such as an Opus 4.8 advisor with a Sonnet 5.5 main model.
-###
-
-
-
-thinking.type.enabled is not supported for this model
+### thinking.type.enabled is not supported for this model
Your Claude Code version is older than the minimum for the selected model. The CLI sent a thinking configuration the model no longer accepts.
@@ -2780,11 +2318,7 @@
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
* If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later. Sonnet 5.5 needs TypeScript SDK v0.3.284 or later
-###
-
-
-
-Effort isn’t available with thinking turned off
+### Effort isn’t available with thinking turned off
You turned [extended thinking](</docs/en/model-config#extended-thinking>) off and ran at an [effort level](</docs/en/model-config#adjust-effort-level>) above `high`. The model doesn’t accept that combination, so the API rejected the request.
@@ -2797,11 +2331,7 @@
Before v2.1.242, Claude Code showed the API’s own message: `API Error: 400 output_config.effort 'xhigh' is not supported when thinking is disabled on this model. Use effort 'high' or below, or enable thinking.` Before v2.1.251, Claude Code sent the request at the effort level you set, so Opus 5 rejected every request above `high` with thinking turned off. Claude Code now sends effort `high` instead to models it knows reject the combination, such as Opus 5.
-###
-
-
-
-Thinking budget exceeds output limit
+### Thinking budget exceeds output limit
The configured extended thinking budget exceeds the maximum response length, so there is no room left for the actual answer.
@@ -2812,11 +2342,7 @@
* Raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
* See [Extended thinking](</docs/en/model-config#extended-thinking>) for how the budget interacts with output length
-###
-
-
-
-Response exceeded the output token maximum
+### Response exceeded the output token maximum
Claude’s reply reached the largest number of output tokens the request allowed and was cut off there:
@@ -2829,11 +2355,7 @@
* If the message says to set `CLAUDE_CODE_MAX_OUTPUT_TOKENS`, see [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) for how the value is capped and [Set environment variables](</docs/en/env-vars#set-environment-variables>) for where to set it
* To keep each reply under the limit, ask Claude for the output in smaller pieces, such as one file or one section per reply
-###
-
-
-
-Tool use or thinking block mismatch
+### Tool use or thinking block mismatch
The conversation history reached the API in an inconsistent state.
@@ -2848,11 +2370,7 @@
* If you are using Opus 4.7 or Opus 4.8, run `claude update` first. Versions before v2.1.156 can trigger this error during normal tool use, and `/rewind` doesn’t clear it.
* Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
-###
-
-
-
-Invalid data in redacted_thinking block
+### Invalid data in redacted_thinking block
The API refused the request with a 400 because it couldn’t accept a `redacted_thinking` block that an earlier turn in the conversation history carries.
@@ -2863,11 +2381,7 @@
* If you’re on v2.1.281 or earlier and every turn fails with this error, run `claude update` and resume the session
* If the error persists, run `/clear` to start a conversation that doesn’t carry the block
-###
-
-
-
-Unsupported tool content removed
+### Unsupported tool content removed
When Claude Code connects directly to the Anthropic API and loads or previews a saved session, it removes tool content the Anthropic API doesn’t accept and leaves this line where removed content sat between two thinking blocks:
@@ -2878,11 +2392,7 @@
* None needed when you see the placeholder line. The session continues without the removed content.
* If every turn of a resumed session fails with the 400 error instead, run `claude update` and resume the session again. Versions before v2.1.246 don’t remove the content.
-###
-
-
-
-role ‘system’ must precede an ‘assistant’ message
+### role ‘system’ must precede an ‘assistant’ message
The API refused the request with a 400 because a system message sits at a position in the conversation it doesn’t accept:
@@ -2895,11 +2405,7 @@
Before v2.1.280, Claude Code didn’t recognize this wording, so the error also appeared when the refused system message was one Claude Code itself sent, and every later turn of the conversation failed the same way.
-###
-
-
-
-Invalid encrypted_content in search_result block
+### Invalid encrypted_content in search_result block
The API refused the request with a 400 because the conversation history holds hosted web-search content it can’t decrypt. The wording names the field it can’t read:
@@ -2914,11 +2420,7 @@
* If the error persists, or the message names `encrypted_stdout`, run `/rewind` to step back to a checkpoint before the turn that added the content, or run `/clear` to start a conversation that doesn’t carry it
* If you run Claude Code behind a proxy or gateway, report the error to whoever operates it
-###
-
-
-
-Usage Policy refusal
+### Usage Policy refusal
The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. The message includes a Request ID and a Message ID you can quote to support if you believe the refusal is incorrect.
@@ -2932,11 +2434,7 @@
* If you can’t identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
* In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt in a new session without `--continue`. Policy checks vary by model, so switching to a different model with `--model` may also resolve the refusal in some cases.
-###
-
-
-
-Safety measures flagged a cybersecurity topic
+### Safety measures flagged a cybersecurity topic
The model’s safety measures flagged content in the conversation as a cybersecurity topic. The message names the model that flagged the request:
@@ -2954,11 +2452,7 @@
* From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link. In interactive sessions, it continued with `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.`
* Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link
-###
-
-
-
-Safeguards flagged a request for Claude’s reasoning
+### Safeguards flagged a request for Claude’s reasoning
The API declined the request because safeguards flagged it as asking the model to reproduce its internal reasoning in the response. The API names this [refusal category](<https://platform.claude.com/docs/en/build-with-claude/refusals-and-fallback#refusal-response>) `reasoning_extraction`, and the refusal message includes this line:
@@ -2973,11 +2467,7 @@
* You can still ask Claude to explain its answer. Ask for a short explanation, the evidence behind a result, or a summary of the actions it took. To read summaries of Claude’s thinking, see [`showThinkingSummaries`](</docs/en/settings-reference#showthinkingsummaries>).
* For more examples, and what to do if a reworded request is still declined, see [Keep reasoning in thinking blocks](<https://platform.claude.com/docs/en/build-with-claude/refusals-and-fallback#keep-reasoning-in-thinking-blocks>)
-###
-
-
-
-Output blocked by content filtering policy
+### Output blocked by content filtering policy
The API’s output content filter stopped the response Claude was generating. The message text comes from the API:
@@ -2988,19 +2478,11 @@
* Rephrase your last message or take a different approach
* To step back to a checkpoint before the turn that triggered the block, press Esc twice or run `/rewind`. See [Checkpointing](</docs/en/checkpointing>)
-##
-
-
-
-Command-line errors
+## Command-line errors
These errors come from the `claude` command line and its subcommands, from a command name you submit at the prompt, and from commands such as `/security-review` that gather context by running shell commands before their prompt runs. They also come from `/tui`, which relaunches the CLI.
-###
-
-
-
-Conflict between `--bg` and `--print`
+### Conflict between `--bg` and `--print`
This message requires Claude Code v2.1.198 or later. You combined `--bg` with `-p` or `--print` in the same `claude` invocation. `--bg` starts a [background session](</docs/en/agent-view#from-your-shell>) that you later attach to with `claude agents`, while `--print` runs [non-interactively](</docs/en/headless>) and never starts the interactive session that `claude agents` attaches to. Before v2.1.198 this combination silently created a background job that could never be attached to.
@@ -3011,11 +2493,7 @@
* Drop `-p` or `--print`. `--bg` takes the prompt as its positional argument, so `claude --bg "<task>"` is the complete command. See [Dispatch new agents from your shell](</docs/en/agent-view#from-your-shell>).
* To run the prompt non-interactively and print the result instead of creating a background session, drop `--bg` and run `claude -p "<task>"`
-###
-
-
-
-Couldn’t tell whether `--bg` is a flag or text
+### Couldn’t tell whether `--bg` is a flag or text
You ran `claude` with `--bg` or `--background` at a position where Claude Code couldn’t tell whether you meant it as the background flag or as text. The command started nothing, printed this line, and exited with code 1:
@@ -3025,11 +2503,7 @@
* To start a [background session](</docs/en/agent-view#from-your-shell>), run the command again in your shell with the flag first: `claude --bg --name nightly-audit "<task>"`
-###
-
-
-
-Conflict between a system prompt flag and its file form
+### Conflict between a system prompt flag and its file form
You passed [`--append-subagent-system-prompt`](</docs/en/cli-reference#cli-flags>) together with `--append-subagent-system-prompt-file` in one `claude` invocation, so `claude` exits with code 1 instead of starting the session:
@@ -3039,11 +2513,7 @@
* Keep one form of the flag and drop the other. To combine a fixed prompt file with per-run text, merge the text into the file before launching instead of passing both flags
-###
-
-
-
-Invalid `--agents` configuration
+### Invalid `--agents` configuration
The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway.
@@ -3065,11 +2535,7 @@
* Fix each problem the message lists, then run the command again. See [the fields a CLI-defined subagent takes](</docs/en/sub-agents#choose-the-subagent-scope>).
-###
-
-
-
-Cloud sessions cannot be created from a `--restricted` session
+### Cloud sessions cannot be created from a `--restricted` session
When you start a session with [`--restricted`](</docs/en/cli-reference#cli-flags>), Claude Code refuses to create [cloud sessions](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) from it, because the new session would run outside the restricted process and wouldn’t enforce restricted mode. Claude Code refuses on the client, before contacting the server, so no cloud session is created:
@@ -3082,11 +2548,7 @@
Before v2.1.248, Claude Code had no `--restricted` flag; earlier versions reject the flag itself with an unknown-option error.
-###
-
-
-
-Cloud sessions are disabled by your organization’s policy
+### Cloud sessions are disabled by your organization’s policy
Your organization’s `allow_remote_sessions` policy is off, so [cloud sessions](</docs/en/claude-code-on-the-web>) and the commands that use them aren’t available:
@@ -3096,11 +2558,7 @@
* Ask an [Owner](</docs/en/server-managed-settings#access-control>) in your organization to enable cloud sessions in the Claude Code admin settings at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
-###
-
-
-
-Cloud sessions use your claude.ai login
+### Cloud sessions use your claude.ai login
When the policy denial names a credential this session is using and ends with this sentence, Claude Code checked the cloud-session policy of the organization that issued that credential. That organization can differ from the one your claude.ai login belongs to:
@@ -3108,11 +2566,7 @@
The last sentence means that cloud sessions run on your claude.ai login rather than on that credential. This form appears when you start, resume, or message a cloud session from your shell, such as with `--cloud` or `--teleport`. Before v2.1.296, Claude Code printed the form that tells you to contact your organization admin in this case too.
-###
-
-
-
-Couldn’t verify your organization’s policy for cloud sessions
+### Couldn’t verify your organization’s policy for cloud sessions
These messages mean Claude Code couldn’t load your organization’s policy, which it checks before it creates, resumes, or messages a [cloud session](</docs/en/claude-code-on-the-web>). While the policy request hasn’t finished, the message is:
@@ -3131,11 +2585,7 @@
* For the `Couldn't verify` message, check your network connection and try again. Inside a session, restart Claude Code first
* For a `Cloud sessions aren't available:` message, do what its cause calls for, such as checking your proxy or unsetting the credential it names, then run the command again
-###
-
-
-
-Nothing was stashed because a folder replaced a tracked file
+### Nothing was stashed because a folder replaced a tracked file
This message means a folder in your checkout now sits where a git-tracked file or link used to be. It appears after you choose the stash option while pulling a [cloud session](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>) into your terminal, for example with `claude --teleport` or `/teleport`. Stashing that state could delete the files inside the folder, so Claude Code refuses the stash and leaves your checkout and index unchanged:
@@ -3145,11 +2595,7 @@
* Commit the change or move the folder somewhere else, as the message says, then run the teleport again
-###
-
-
-
-The `--json-schema` value is not a valid JSON Schema
+### The `--json-schema` value is not a valid JSON Schema
The schema you passed to [`--json-schema`](</docs/en/cli-reference#cli-flags>) in [non-interactive mode](</docs/en/headless#get-structured-output>) failed JSON Schema compilation, so `claude` exits with code 1 instead of running the prompt. Before v2.1.205, an invalid schema produced unstructured output with no error, and any schema that used the `format` keyword was treated as invalid.
@@ -3160,11 +2606,7 @@
* Fix the part of the schema the diagnostic names, then rerun the command
* See [Get structured output](</docs/en/headless#get-structured-output>) for a working schema and command
-###
-
-
-
-Settings file exceeds the 2MiB limit
+### Settings file exceeds the 2MiB limit
The file you passed to [`--settings`](</docs/en/cli-reference#cli-flags>) is larger than 2 MiB, so `claude` exits with code 1 at startup instead of loading it. Before v2.1.214, Claude Code read the file with no size check, and a multi-gigabyte file or a device file such as `/dev/zero` grew memory without bound.
@@ -3174,11 +2616,7 @@
* Point `--settings` at a regular JSON settings file under 2 MiB. See [Settings](</docs/en/settings>) for the format.
-###
-
-
-
-Configuration error in ~/.claude.json
+### Configuration error in ~/.claude.json
Claude Code couldn’t parse `~/.claude.json`, the file that holds your account details, MCP servers, and per-project state. A [non-interactive](</docs/en/headless>) start such as `claude -p` exits with code 1. When Claude Code finds a [backup](</docs/en/claude-directory#cleaned-up-automatically>), the output names it and prints a `cp` line that copies it back:
@@ -3195,11 +2633,7 @@
* **The output has no`cp` line, or the error returns after you run it**: if `~/.claude.json` still has your configuration, fix its JSON. If you can’t, copy another `.claude.json.backup.<timestamp>` file from [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) over it if there is one, or rename it. With no file at `~/.claude.json`, Claude Code starts with default settings and none of what the file held.
* **`~/.claude.json` no longer has your configuration**: find a `.claude.json.corrupted.<timestamp>` file that still has it, in [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) or your home directory. Fix its JSON, then copy it over `~/.claude.json`. If you can’t find or fix one, try the same steps with a `.claude.json.backup.<timestamp>` file that has your configuration. If none does, rename `~/.claude.json` and add your MCP servers again with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>).
-###
-
-
-
-Claude configuration file was empty and no backup holds anything
+### Claude configuration file was empty and no backup holds anything
This message at startup means the file it names was blank and none of the file’s [`.backup` copies](</docs/en/claude-directory#cleaned-up-automatically>) holds anything. Claude Code started with defaults for what that file holds. Your `settings.json` files and `.mcp.json` are separate files.
@@ -3212,11 +2646,7 @@
Before v2.1.318, Claude Code reported a blank file with no backup as corrupted.
-###
-
-
-
-The current directory no longer exists
+### The current directory no longer exists
You started `claude` from a directory that was deleted or moved after your shell entered it, for example a worktree or temp directory another shell removed. Claude Code can’t read its working directory, so it exits with code 1 before starting the session, in interactive and [non-interactive](</docs/en/headless>) mode alike. Before v2.1.239, Claude Code crashed with minified bundle source and a raw `ENOENT ... uv_cwd` stack on stderr instead of this message.
@@ -3229,11 +2659,7 @@
* If the directory was recreated at the same path, your shell still holds the deleted one. Run `cd "$PWD"` or leave and re-enter the directory, then run `claude` again
* For `EPERM` on macOS, quit your terminal app with Cmd+Q, open it again, return to that folder, and run `claude`. If `ls` in that folder still fails, open **System Settings > Privacy & Security > Files and Folders**, turn on the folder for your terminal app, then reopen the terminal
-###
-
-
-
-Temp directory refused or cannot be created
+### Temp directory refused or cannot be created
On macOS and Linux, Claude Code creates a private temp directory at startup, `claude-<uid>` under the system temp directory or the [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) override. When the directory can’t be created, or an entry already at that path fails the safety checks, Claude Code prints the failure to stderr and exits with code 1 rather than start the session:
@@ -3254,11 +2680,7 @@
Before v2.1.309, Claude Code printed only the operating system’s error text when the volume was full or your quota was used up. An example is `ENOSPC: no space left on device, mkdir '/tmp/claude-501'`, and the same steps apply.
-###
-
-
-
-Claude Code could not save because the disk is full
+### Claude Code could not save because the disk is full
This line on stderr after a [`claude -p`](</docs/en/headless>) run means the disk is full or your disk quota is used up, so Claude Code couldn’t save everything from the run:
@@ -3269,11 +2691,7 @@
* **`the disk is full (ENOSPC)`** : before your next run, free up space on the disk that holds the path in the message
* **`your disk quota is used up (EDQUOT)`** : before your next run, free up space or ask for a larger quota
-###
-
-
-
-Directory couldn’t be resolved to a real location
+### Directory couldn’t be resolved to a real location
You ran `/add-dir` for a subdirectory of your working directory, and Claude Code couldn’t resolve the directory to its real location. You already have file access to a subdirectory of the working directory, so `/add-dir` only loads its skills, commands, and agents. Before loading them, Claude Code checks that the directory’s real location, with any symlinks resolved, is inside the working directory. When Claude Code can’t resolve that location, it loads nothing and shows this message:
@@ -3286,11 +2704,7 @@
Before v2.1.261, this message also appeared for every `/add-dir <subdirectory>` when the working directory was on a `/net/<host>` automount, where Claude Code declines to resolve paths by design; the directory was fine and retrying couldn’t help.
-###
-
-
-
-Workspace not trusted when starting Remote Control
+### Workspace not trusted when starting Remote Control
If `claude ultrareview` printed `Error: Workspace not trusted`, see Workspace not trusted when running claude ultrareview instead.
@@ -3309,11 +2723,7 @@
Before v2.1.284, the command never asked, even in a terminal.
-###
-
-
-
-Workspace not trusted when running claude ultrareview
+### Workspace not trusted when running claude ultrareview
In a folder you haven’t trusted, when [`claude ultrareview`](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>) can’t ask whether you trust it, the run exits with code 1 before the review starts:
@@ -3334,11 +2744,7 @@
Before v2.1.309, `claude ultrareview` didn’t accept `--trust-workspace`.
-###
-
-
-
-Remote Control did not start because a question got no answer
+### Remote Control did not start because a question got no answer
This message means [`claude remote-control`](</docs/en/remote-control>) asked the first-run question quoted in the message and got no answer:
@@ -3350,15 +2756,11 @@
* **`Enable Remote Control?`** : in a script or a service, standard input ends before anyone can answer. Run `claude remote-control` once in a terminal, as the user your script or service runs as, and answer `y`.
* **`Choose [1/2] (default: 1):`** : run `claude remote-control` again and [choose a spawn mode](</docs/en/remote-control#set-the-default-spawn-mode-for-a-project>), or pass [`--spawn=same-dir` or `--spawn=worktree`](</docs/en/remote-control#start-a-remote-control-session>) to skip the question
-###
-
-
-
-Not carried over to the sessions Remote Control starts
+### Not carried over to the sessions Remote Control starts
You started [Remote Control](</docs/en/remote-control>) with a global `claude` flag before the `remote-control` verb, one that would restrict or configure the sessions Remote Control starts, such as `--settings`, `--setting-sources`, `--permission-mode`, `--disallowed-tools`, or `--mcp-config`. A flag placed before the verb never reaches those sessions. Claude Code refuses to start instead, naming the flag:
- Error: `--settings` before `remote-control` is not carried over to the sessions Remote Control starts, so Remote Control refuses to start rather than drop it — remove it, and give Remote Control's own options after the verb (see `claude remote-control --help`).
+ Error: `--settings` before `remote-control` is not carried over to the sessions Remote Control starts, so Remote Control refuses to start rather than drop it — remove it, and give Remote Control's own options after the verb (see `claude remote-control --help`). Pass settings with `claude remote-control --settings <file>`.
Claude Code doesn’t refuse global flags that are harmless to drop, such as `--verbose`, `--model`, or a wrapper-injected `--session-id` or `--plugin-dir`: it ignores them and Remote Control starts. Claude Code also refuses to start for a global flag it doesn’t yet recognize as harmless, so a flag added in a newer release can appear in this message until a later release marks it harmless. **What to do:**
@@ -3367,11 +2769,28 @@
Before v2.1.248, `claude remote-control` didn’t accept its own flags when a global flag came first, and the command failed with an `unknown option` error.
-###
-
-
-
-`--sandbox` or `--no-sandbox` is not supported by claude remote-control
+### Remote Control did not start because of the `--settings` file
+
+The file you passed to [`claude remote-control --settings`](</docs/en/remote-control#start-a-remote-control-session>) has a problem:
+
+ Error: Remote Control did not start, because sessions would skip part or all of the --settings file ./rc-settings.json: Invalid or malformed JSON
+
+**What to do:**
+
+ * Fix the problem the message names, then run your `claude remote-control` command again
+
+### The settings file has changed since Remote Control started
+
+This message in the terminal running `claude remote-control` means that sessions won’t start from the file you passed to [`--settings`](</docs/en/remote-control#start-a-remote-control-session>) as it is now:
+
+ Session failed: Error: The settings file /path/to/settings.json has changed since Remote Control started, so this session did not start. Restart `claude remote-control` to use it as it is now.
+
+**What to do:**
+
+ * To use the file as it is now, stop `claude remote-control` and run the same command again. To bring back the sessions it was serving, see [Resume sessions after stopping the server](</docs/en/remote-control#resume-sessions-after-stopping-the-server>).
+ * To keep the settings Remote Control started with, put the file’s contents back as they were, then run the command again if `claude remote-control` has exited
+
+### `--sandbox` or `--no-sandbox` is not supported by claude remote-control
This error means the command that starts your [Remote Control](</docs/en/remote-control>) server passes `--sandbox` or `--no-sandbox` after `remote-control`, and `claude remote-control` accepts neither flag. The server exits with code 1 instead of starting:
@@ -3385,11 +2804,7 @@
Both flags were removed from `claude remote-control` in v2.1.300, so a command written for an earlier version can still carry one.
-###
-
-
-
-claude import is not yet available in this build
+### claude import is not yet available in this build
You ran [`claude import`](</docs/en/cli-reference#cli-commands>), and Claude Code found the import flow turned off, so the command exits with code 1 instead of starting the import. Before v2.1.222, a build with the import flow off treated `import` as a prompt and started an interactive session instead of printing this message.
@@ -3406,11 +2821,7 @@
* On a fresh installation, start `claude`, wait for the session to load, exit, and run `claude import` again
* Where feature-flag fetching stays off, set the configuration up yourself: add MCP servers with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>), and create the [`CLAUDE.md` files](</docs/en/memory#how-claude-md-files-load>), [skills and commands](</docs/en/skills#where-skills-live>), and [subagents](</docs/en/sub-agents#choose-the-subagent-scope>) you want to carry over. The message also names `~/.claude/settings.json`. Of the configuration `claude import` carries, that file holds only the [permission mode](</docs/en/settings-reference#permission-settings>); Claude Code doesn’t read MCP servers from it.
-###
-
-
-
-Could not read Claude Code config
+### Could not read Claude Code config
You ran [`claude import`](</docs/en/cli-reference#cli-commands>) while Claude Code couldn’t parse `~/.claude.json`, the file where it stores your account details and per-project state. The subcommand reads that file to check availability but doesn’t show the recovery dialog the interactive session shows, so it exits with code 1. Before v2.1.222, `claude import` with an unreadable config file started an interactive session, whose recovery dialog handled the file.
@@ -3421,11 +2832,7 @@
* Run `claude` with no arguments. Claude Code detects the invalid file and offers to reset it. Then run `claude import` again.
* To keep manual edits you’ve made, fix the JSON syntax in `~/.claude.json` in an editor instead, then rerun `claude import`
-###
-
-
-
-Could not import a server from Claude Desktop
+### Could not import a server from Claude Desktop
Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import.
@@ -3436,11 +2843,7 @@
* Rename the server in `claude_desktop_config.json` to use only letters, numbers, hyphens, and underscores, then run `claude mcp add-from-claude-desktop` again
* Add that server directly with `claude mcp add` or `claude mcp add-json` under a valid name. See [Import MCP servers from Claude Desktop](</docs/en/mcp#import-mcp-servers-from-claude-desktop>).
-###
-
-
-
-Cannot add MCP server to the managed scope
+### Cannot add MCP server to the managed scope
You ran `claude mcp add` or `claude mcp add-json` with `--scope managed`. That scope holds the servers your organization provides through the [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) managed setting. Claude Code reads them from managed settings only, so the command can’t write a server to that scope.
@@ -3451,11 +2854,7 @@
* Add the server to a scope you can write: `local`, `user`, or `project`. Without `--scope`, the command uses `local`. See [MCP installation scopes](</docs/en/mcp#mcp-installation-scopes>)
* To provide the server to every user in your organization, add it to [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) in the managed settings you deploy
-###
-
-
-
-Cannot add MCP server when managed settings allow only plugin servers
+### Cannot add MCP server when managed settings allow only plugin servers
You ran `claude mcp add` or `claude mcp add-json` while your organization’s managed settings set [`strictPluginOnlyCustomization`](</docs/en/settings-reference#strictpluginonlycustomization>) to `true` or to a list that includes `mcp`. With that setting, Claude Code doesn’t load MCP servers from `~/.claude.json` or `.mcp.json`, so the command exits with code 1 instead of saving a server that would never load:
@@ -3466,11 +2865,7 @@
* Install a [plugin](</docs/en/plugins/install>) that provides the server
* Ask your administrator to distribute the server in a [plugin](</docs/en/plugins/org>), or to provide it through [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) if it’s a remote HTTP or SSE server
-###
-
-
-
-Can’t read .mcp.json
+### Can’t read .mcp.json
A command that reads the project’s [`.mcp.json`](</docs/en/mcp#project-scope>), such as `claude mcp add` or `claude mcp add-json` with `--scope project`, or `claude mcp remove`, found that the file in your current directory isn’t a regular file or is larger than 2 MiB, so it exits with this error instead of reading the file.
@@ -3480,11 +2875,7 @@
* Check what sits at `.mcp.json` in your current directory. Replace it with an ordinary JSON file in the [project-scope format](</docs/en/mcp#project-scope>), or delete it, then run the command again.
-###
-
-
-
-MCP server was not saved or removed
+### MCP server was not saved or removed
This error means a command such as `claude mcp add` or `claude mcp remove` didn’t get your change into `~/.claude.json`. Other Claude Code processes may have kept the file locked, or the file may be read-only or protected by a sandbox.
@@ -3497,11 +2888,7 @@
Before v2.1.283, `claude mcp add`, `claude mcp add-json`, and `claude mcp remove` reported success even when the change didn’t reach the file. Before v2.1.318, the message didn’t mention the lock, and Claude Code didn’t read [`CLAUDE_CODE_CONFIG_LOCK_WAIT_MS`](</docs/en/env-vars#variables>).
-###
-
-
-
-MCP server may not have been saved or removed
+### MCP server may not have been saved or removed
You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>), and Claude Code couldn’t read `~/.claude.json` back to confirm the change. The change may or may not be on disk. The parentheses after `to confirm the change` give the reason.
@@ -3512,11 +2899,7 @@
* Run `claude mcp get <name>` to check whether the change is on disk. For a `local`-scope server, run it from the project directory the server belongs to, since local scope is per project.
* If the server is missing after an add, or still listed after a remove, run the same add or remove command again.
-###
-
-
-
-Server is Anthropic-hosted and doesn’t support local OAuth
+### Server is Anthropic-hosted and doesn’t support local OAuth
You started a sign-in for an MCP server whose URL points at an Anthropic-hosted connector host that authenticates through a third-party identity provider. These hosts include `microsoft365.mcp.claude.com`, `gmail.mcp.claude.com`, and `gcal.mcp.claude.com`. Claude Code refuses to start its local OAuth flow for these hosts from both the `/mcp` panel and `claude mcp login`, because [their sign-in works only through claude.ai](</docs/en/mcp#use-mcp-servers-from-claude-ai>).
@@ -3527,11 +2910,7 @@
* Remove your entry with `claude mcp remove <name>`, so it can’t hide the claude.ai connector at the same URL
* After removing it, connect the service at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>), while signed in to the account you use in Claude Code. Once connected, [the connector appears in Claude Code automatically](</docs/en/mcp#use-mcp-servers-from-claude-ai>) if your active authentication method is a claude.ai subscription login
-###
-
-
-
-Server rejected the Authorization header minted by the configured headersHelper
+### Server rejected the Authorization header minted by the configured headersHelper
An MCP server whose [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) supplies the `Authorization` header answered the connection with HTTP 401 or 403, so Claude Code reports the connection as failed. Because the helper supplies the `Authorization` header, Claude Code [doesn’t fall back to OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>) for the server:
@@ -3544,11 +2923,7 @@
Before v2.1.248, Claude Code ran OAuth discovery for a server whose helper supplied the `Authorization` header. That discovery could fail with `Incompatible auth server: does not support dynamic client registration` instead of reporting the rejected credential.
-###
-
-
-
-MCP server rejected the elicitation capability
+### MCP server rejected the elicitation capability
An MCP server built on Java MCP SDK 0.11.0 through 0.17.0 refused the connection. Those SDK versions can’t parse the `form` and `url` [elicitation modes](</docs/en/mcp#elicitation-modes-claude-code-declares>) that Claude Code declares in its handshake. The message reads:
@@ -3573,11 +2948,7 @@
After the restart, `/mcp` shows the server as connected. Claude Code declares form mode only to that server, so remove the field once you upgrade it. A server can also fail with its own error text, such as one containing `Unrecognized field "form"`. The same fixes apply.
-###
-
-
-
-MCP permission prompt tool not found
+### MCP permission prompt tool not found
The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
@@ -3589,11 +2960,7 @@
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
* If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
-###
-
-
-
-OAuth callback port is already in use
+### OAuth callback port is already in use
When you sign in to a remote MCP server with OAuth, Claude Code starts a local listener to receive the sign-in callback. If the port that listener needs is held by another process, the sign-in fails with this message. This mostly happens with a [fixed callback port](</docs/en/mcp#use-a-fixed-oauth-callback-port>) set through the [`MCP_OAUTH_CALLBACK_PORT`](</docs/en/env-vars>) variable or `--callback-port`, since without one Claude Code picks an available port.
@@ -3605,11 +2972,7 @@
* If another program needs that port permanently, register a different redirect URI with the server and set its port with `MCP_OAUTH_CALLBACK_PORT` or `--callback-port`, whichever you use
* Then start the sign-in again, for example by selecting the server in `/mcp`
-###
-
-
-
-No available ports for OAuth redirect
+### No available ports for OAuth redirect
When you sign in to a remote MCP server with [OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>), Claude Code starts a local listener to receive the sign-in callback. The sign-in fails with this message when Claude Code can’t bind a local port for it. Something on the machine is preventing it from listening on `127.0.0.1`, for example security software or a sandbox policy that denies local listeners.
@@ -3620,11 +2983,7 @@
* Check whether security software or a sandbox policy blocks processes from listening on `127.0.0.1`, and allow Claude Code to bind a local port
* Then start the sign-in again, for example by selecting the server in `/mcp`
-###
-
-
-
-/security-review fails without origin/HEAD
+### /security-review fails without origin/HEAD
[`/security-review`](</docs/en/commands#all-commands>) builds its review context by diffing your branch against `origin/HEAD`, the local ref that records which branch is the default on your `origin` remote. When that ref doesn’t exist, the git commands that gather the diff fail and the review stops before it starts.
@@ -3650,11 +3009,7 @@
* If you’d rather not name the branch, run `git fetch origin` and then `git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
* If the repository has no remote, add one with `git remote add origin <url>` and fetch before creating the ref. If the remote is empty, push your branch first with `git push -u origin HEAD` and name that branch in the set-head command; `origin/HEAD` then points at the branch you just pushed, so `/security-review` sees an empty diff until the branch diverges from it.
-###
-
-
-
-No shell command in a skill or command was run
+### No shell command in a skill or command was run
`No shell command in <name> was run` means a `!`<command>`` [dynamic context command](</docs/en/skills#inject-dynamic-context>) in that skill or command file contains a character that the Bash or PowerShell tool refuses:
@@ -3670,11 +3025,7 @@
* Find each `�` in the command quoted at the end of the message. Remove the character it stands for from the [skill or command file](</docs/en/skills#where-skills-live>), or from the arguments or [options](</docs/en/plugins/manifest-reference#user-configuration>) substituted into the file.
-###
-
-
-
-Input must be provided when using `--print`
+### Input must be provided when using `--print`
Bare `claude` needs stdout to be a terminal to start the interactive UI. When stdout is redirected, or the console isn’t a real terminal, such as PowerShell ISE and some IDE output panes, `claude` runs [non-interactively](</docs/en/headless>) instead. That is the same mode as `claude -p`, which requires a prompt, so the message names `--print` even when you didn’t pass the flag. Passing `-p`/`--print` with no prompt and nothing piped on stdin produces the same error anywhere.
@@ -3685,11 +3036,7 @@
* For interactive use, run `claude` in a real terminal: Windows Terminal or the PowerShell console rather than ISE, and your IDE’s integrated terminal rather than an output pane
* For one-shot use, pass the prompt: `claude -p "your question"`, or pipe it with `echo "your question" | claude -p`
-###
-
-
-
-Claude Code can’t read the keyboard here
+### Claude Code can’t read the keyboard here
You ran `claude` without [`-p`](</docs/en/headless>), which starts an [interactive session](</docs/en/interactive-mode>), but its standard input isn’t a terminal. Something piped or redirected it, or the program that launched `claude` supplied its own input stream. An interactive session needs a terminal to read your keystrokes from, and what Claude Code does without one depends on your platform:
@@ -3709,11 +3056,7 @@
Before v2.1.287, Claude Code started the interface instead of printing this message, then either showed nothing on screen or failed with an error containing `Raw mode is not supported`. If you see `Raw mode is not supported` during `claude install` instead, see [`Raw mode is not supported` during install](</docs/en/troubleshoot-install#raw-mode-is-not-supported-during-install>).
-###
-
-
-
-Input contained only whitespace
+### Input contained only whitespace
In [non-interactive mode](</docs/en/headless>), Claude Code refuses a prompt made up entirely of spaces, tabs, or newlines instead of sending it, because the API rejects messages with no visible text. Which message you see depends on where the blank prompt came from:
@@ -3724,11 +3067,7 @@
* Include visible text in the prompt. If a script builds the prompt from a variable or file, check that the source isn’t empty before calling Claude Code.
-###
-
-
-
-stream-json input carried over 256M characters with no newline
+### stream-json input carried over 256M characters with no newline
Your program sent more than 268,435,456 characters on stdin without a newline to a `claude -p --input-format stream-json` run, so Claude Code prints this error to stderr and exits with code 1 instead of buffering more input. The message states that budget as `256M`. Before v2.1.257, Claude Code buffered such input without limit, growing memory until the process crashed or was killed.
@@ -3739,11 +3078,7 @@
* Check what’s piped to stdin. With [`--input-format stream-json`](</docs/en/cli-reference#cli-flags>), every message must be one newline-terminated JSON line
* To send plain text instead, drop `--input-format stream-json`; `claude -p` reads a plain-text prompt from stdin by default
-###
-
-
-
-Unknown command
+### Unknown command
In an interactive terminal session, you submitted a `/` name that doesn’t match any command in this session, so Claude Code reports the name instead of running anything:
@@ -3768,11 +3103,7 @@
* Run the suggested name, or type `/` followed by part of the name to see what’s available in this session
* If Claude Code reports a documented command as unknown, check its row in the [commands reference](</docs/en/commands>) for the requirement it names
-###
-
-
-
-Diff is too large for ultrareview
+### Diff is too large for ultrareview
The diff between your branch and the base branch, including uncommitted and staged changes, exceeds the size limits for an [ultrareview](</docs/en/ultrareview>), so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts. A refused review doesn’t use a free run and doesn’t bill usage credits. The message names the limits in effect, the size of your diff, and the files that contribute the most changed lines. Before v2.1.216, the message showed only the raw diff statistics.
@@ -3783,11 +3114,7 @@
* Pass a base branch closer to your work, such as `/code-review ultra develop`, so the review covers only the diff against that branch
* Split the change into smaller branches and review each one. The files the message names contribute the most changed lines, so start by moving those to their own branch.
-###
-
-
-
-Could not find merge-base with the base branch
+### Could not find merge-base with the base branch
`/code-review ultra` and the `claude ultrareview` subcommand review the diff between your branch and a base branch, which needs a commit the two share. When `git merge-base` finds none, Claude Code refuses the review before the cloud session starts. On a clone Claude Code can verify is complete, with at least one branch, it falls back to [reviewing every tracked file](</docs/en/ultrareview#diff-limits-and-fallbacks>) instead of refusing. You see this refusal when the base branch can’t be found at all, when Claude Code can’t verify that your clone is complete, or in the rare repository where the whole-tree diff isn’t possible, such as the SHA-256 object format.
@@ -3804,11 +3131,7 @@
* If another branch is your real base, pass it explicitly: `/code-review ultra <branch>`
* If your clone might not have full history, run `git fetch --unshallow origin` and rerun the review
-###
-
-
-
-Your checkout has no branches
+### Your checkout has no branches
A checkout can have commits but no branches: if you run `git init` followed by `git fetch <url>` and `git checkout FETCH_HEAD`, you get a detached HEAD with no refs. Claude Code packages your repository as a git bundle to upload it for an [ultrareview](</docs/en/ultrareview>), and it can’t bundle a repository that has no branches or other refs, so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts.
@@ -3818,11 +3141,7 @@
* Create a branch at your current commit with `git checkout -b <name>`, then rerun the review
-###
-
-
-
-No GitHub account is connected to your Claude account
+### No GitHub account is connected to your Claude account
You ran `/code-review ultra <PR#>` or `claude ultrareview <PR#>`, and before creating the cloud session Claude Code asks the server whether [the GitHub account connected to your Claude account](</docs/en/ultrareview#review-a-pull-request>) can reach the PR’s repository. No account is connected, or the connection expired, so the cloud clone would fail and Claude Code refuses the launch. Claude Code doesn’t spend a free run or bill usage credits for a refused launch.
@@ -3835,11 +3154,7 @@
Before v2.1.248, Claude Code didn’t check this before launch.
-###
-
-
-
-Your connected GitHub account can’t see the repository
+### Your connected GitHub account can’t see the repository
You ran `/code-review ultra <PR#>` or `claude ultrareview <PR#>`, and [the GitHub account connected to your Claude account](</docs/en/ultrareview#review-a-pull-request>) can’t read the PR’s repository, so the cloud clone would fail and Claude Code refuses the launch. Claude Code doesn’t spend a free run or bill usage credits for a refused launch.
@@ -3852,11 +3167,7 @@
Before v2.1.248, Claude Code didn’t check this before launch.
-###
-
-
-
-The GitHub App preflight failed transiently
+### The GitHub App preflight failed transiently
You started a [cloud session](</docs/en/claude-code-on-the-web>) from a local repository, and two steps failed together. Claude Code couldn’t build or upload the bundle of your repository. Before the upload, it checked whether the cloud service can clone the repository from GitHub, and rather than a definite answer, that check ended in an error that a retry could clear, such as a network error, a timeout, or a temporary server error. The full message starts with what stopped the bundle, for example `Could not upload repo bundle (<error>)`, and ends with the preflight sentence:
@@ -3869,11 +3180,7 @@
Before v2.1.251, Claude Code ended the message with `Please set up GitHub on https://claude.ai/code` even when the GitHub check failed only transiently, and setup advice can’t clear a transient failure.
-###
-
-
-
-The repository upload can’t follow a git setting
+### The repository upload can’t follow a git setting
You started a [cloud session that uploads your local repository](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>), or an [ultrareview](</docs/en/ultrareview>) of a branch, and the upload can’t follow one of the git settings that decide which attribute rules apply to your files. If the upload went ahead and missed a rule, a file that git transforms before storing it, such as one a clean filter encrypts, could reach the cloud as it is on disk. Claude Code refuses the upload instead, and nothing is uploaded:
@@ -3883,11 +3190,7 @@
* Apply the fix in the message’s final sentence
-###
-
-
-
-GitHub isn’t connected to your Claude account
+### GitHub isn’t connected to your Claude account
You started a [cloud session](</docs/en/claude-code-on-the-web>) from your local repository, for example with `/autofix-pr`. No GitHub account is connected to your Claude account, or the connection expired, so Claude Code refuses the launch:
@@ -3900,11 +3203,7 @@
Before v2.1.268, Claude Code reported this as a temporary failure of the Claude GitHub App check and suggested retrying or installing the app; neither connects a GitHub account.
-###
-
-
-
-A GitHub organization policy is blocking Claude
+### A GitHub organization policy is blocking Claude
You ran a command at the Claude Code prompt that starts a cloud session, such as [`/autofix-pr`](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>). Before it creates the session, Claude Code checks Claude’s access to the repository on GitHub, and GitHub refused because your GitHub organization has a policy that blocks Claude. Claude Code stops there and shows a message naming the policy. When an IP allow list is what blocks the access, the message reads:
@@ -3925,11 +3224,7 @@
* **Conditional Access policy** : ask your GitHub Enterprise or Microsoft Entra ID administrator to allow Claude in that policy
* After the change, run the command again
-###
-
-
-
-Single sign-on authorization needed
+### Single sign-on authorization needed
You ran [`/install-github-app`](</docs/en/github-actions#quick-setup>) and chose a repository whose organization enforces SAML single sign-on. Before setup, Claude Code checks your access to the repository with the GitHub CLI, and GitHub refused that check because your `gh` token isn’t authorized for the organization yet. The wizard shows the warning with the steps to authorize:
@@ -3944,11 +3239,7 @@
Before v2.1.273, Claude Code showed the `Admin permissions required` warning for this condition instead.
-###
-
-
-
-Failed to resume the conversation
+### Failed to resume the conversation
Claude Code couldn’t read or process the saved transcript for the session you selected from the [`claude --resume` picker](</docs/en/sessions#use-the-session-picker>), so it ends the process rather than continue in a partially loaded state. The message includes the command to retry:
@@ -3961,11 +3252,7 @@
* On a version before v2.1.285, if the retry fails the same way, run `claude update` and resume again. Those versions fail the resume when the saved transcript contains an entry they can’t read.
* If the retry fails again, run `claude` to start a new session
-###
-
-
-
-No conversation found with the session ID
+### No conversation found with the session ID
You passed a session ID to `claude --resume <session-id>` and no saved transcript matched it:
@@ -3983,11 +3270,7 @@
* For an interactive session, open the [session picker](</docs/en/sessions#use-the-session-picker>) with `claude --resume` and press `Ctrl+A` to widen it to every project on this machine, then select the session
* Sessions created with `claude -p` or the [Agent SDK](</docs/en/agent-sdk/overview>) don’t appear in the picker, so re-check the ID against the `session_id` your original run printed
-###
-
-
-
-Windows reported an error (EBADF) when Claude Code read this session’s transcript file
+### Windows reported an error (EBADF) when Claude Code read this session’s transcript file
You resumed a session on Windows, its saved [transcript file](</docs/en/sessions#where-transcripts-are-stored>) opened normally, and reading it then failed with the system error EBADF. The system error doesn’t say why the read failed, so the message suggests likely causes and what to try:
@@ -4001,11 +3284,7 @@
Before v2.1.282, the failure came with no explanation: `claude --resume <session-id>` ended at `Failed to resume session <session-id>`, and a `-p` run printed only the system error text, such as `Failed to resume session: EBADF: bad file descriptor, read`.
-###
-
-
-
-Cannot switch renderers in this session
+### Cannot switch renderers in this session
When you switch renderers, Claude Code restarts its process. You ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>) in a session Claude Code declines to restart, so it doesn’t switch and saves nothing. Which message you see tells you the cause:
@@ -4027,19 +3306,11 @@
* In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings-reference#tui>) there
-###
-
-
-
-Can’t restart while work is running or Remote Control is connected
+### Can’t restart while work is running or Remote Control is connected
Claude Code didn’t restart, and your session keeps running as it was. Follow the fix in the message.
-###
-
-
-
-Claude Code couldn’t restart
+### Claude Code couldn’t restart
When this message says your conversation is saved, the conversation is on disk and you can pick it up where it stopped. Claude Code was restarting itself, for example to switch to or from fullscreen rendering after you ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>), and couldn’t start the new process, so it exited with status 1:
@@ -4050,11 +3321,7 @@
* Run `claude` again in your shell. If the message said your conversation is saved, run [`/resume`](</docs/en/sessions#resume-a-session>) in the new session and select the conversation. If it isn’t in the list, [widen the session picker](</docs/en/sessions#where-the-session-picker-looks>)
* If restarts keep failing, start Claude Code from your shell with [`claude --debug-file claude-debug.log`](</docs/en/cli-reference#cli-flags>). If a restart from that session fails, `claude-debug.log` in the directory you started from records a `Failed to relaunch:` line with the operating system’s error. Include that line when you report the problem
-###
-
-
-
-Couldn’t open Claude Desktop
+### Couldn’t open Claude Desktop
You ran [`/desktop`](</docs/en/desktop#coming-from-the-cli>) or its alias `/app` in a session, or [`claude --desktop`](</docs/en/cli-reference#cli-flags>) in your shell, and the system command Claude Code uses to open Claude Desktop failed. After `/desktop`, the session stays in the terminal; `claude --desktop` prints the message without the `Error:` prefix and exits with status 1. The text in parentheses names the command that failed, with its exit status and the first line of its error output when it produced them. On macOS that command is `open`, as in this example; on Windows it is `rundll32`:
@@ -4067,11 +3334,7 @@
Before v2.1.285, the message ended `Open Claude Desktop and run /desktop again.` Before v2.1.275, it was `Failed to open Claude Desktop. Please try opening it manually.` and didn’t say what failed.
-###
-
-
-
-/terminal-setup left your Zed keymap unchanged
+### /terminal-setup left your Zed keymap unchanged
You ran [`/terminal-setup`](</docs/en/terminal-config#enter-multiline-prompts>) in Zed, and Claude Code couldn’t complete the update to your Zed `keymap.json`, so it left the file as it was. Each message names the path to your keymap and ends with the keybinding block to add yourself:
@@ -4093,11 +3356,7 @@
Before v2.1.247, `/terminal-setup` couldn’t parse a Zed keymap that used `//` comments or trailing commas, and it replaced the entire file with only its own binding while reporting the binding as installed. To restore a keymap an earlier version replaced, use the `.bak` backup file described under [Enter multiline prompts](</docs/en/terminal-config#enter-multiline-prompts>).
-###
-
-
-
-Skill usage reports are not available on this connection
+### Skill usage reports are not available on this connection
You ran [`/skill-doctor`](</docs/en/skills#find-unused-skills>) over [Remote Control](</docs/en/remote-control>), from your phone or browser. Claude Code doesn’t send the skill usage report over Remote Control and replies with this message instead:
@@ -4107,11 +3366,7 @@
* Run `/skill-doctor` in the terminal on the machine where the session is running, or run `claude -p "/skill-doctor"` there
-###
-
-
-
-Custom output styles can’t be selected over Remote Control
+### Custom output styles can’t be selected over Remote Control
You ran [`/output-style`](</docs/en/output-styles#change-your-output-style>) from the mobile app or web via [Remote Control](</docs/en/remote-control>), or the command arrived in a message relayed into the session. Because such a turn may not come from the account owner, Claude Code lists and selects only [built-in styles](</docs/en/output-styles#built-in-output-styles>) on it, and adds this notice whenever the command lists the styles or doesn’t recognize the name you gave. A [custom style](</docs/en/output-styles#create-a-custom-output-style>) name gets the same reply as a name that doesn’t exist:
@@ -4122,11 +3377,7 @@
* Pick a built-in style, for example `/output-style concise`
* To use a custom style, set [`outputStyle`](</docs/en/settings-reference#outputstyle>) in the project’s `.claude/settings.local.json`, or run `/output-style <style>` at the session’s own terminal if it has one
-###
-
-
-
-Output styles are saved to local settings which this session doesn’t load
+### Output styles are saved to local settings which this session doesn’t load
You tried to switch [output styles](</docs/en/output-styles>) with `/output-style <style>` or `/config outputStyle=<style>` in a session whose setting sources exclude `local`. Examples are an [Agent SDK](</docs/en/agent-sdk/typescript>) session whose [`settingSources`](</docs/en/agent-sdk/typescript#options>) leaves out `"local"` and a CLI session started with a [`--setting-sources`](</docs/en/cli-reference#cli-flags>) value that leaves out `local`. Both commands save the style to `.claude/settings.local.json`, a file such a session never reads back, so Claude Code refuses instead of writing a setting that would have no effect:
@@ -4137,11 +3388,7 @@
* Add `local` to the session’s setting sources and switch again
* Set the [`outputStyle`](</docs/en/settings-reference#outputstyle>) key in a settings file the session does load, such as `.claude/settings.json` in the project or `~/.claude/settings.json`. In the TypeScript SDK, set `outputStyle` inside the inline `settings` object instead; see [Activate an output style](</docs/en/agent-sdk/modifying-system-prompts#activate-an-output-style>)
-###
-
-
-
-/recap only runs when you ask for it yourself
+### /recap only runs when you ask for it yourself
The [`/recap`](</docs/en/interactive-mode#session-recap>) request didn’t come from your own input. It arrived in a message relayed into the session from a Slack, Teams, or [project](</docs/en/claude-projects>) thread, or in a prompt that a [cloud scheduled task](</docs/en/routines>) or another program sent. A relayed message gets the notice even when you wrote it yourself. Claude Code can’t tell that a relayed or automated message came from the person whose account runs the session, so it answers with this notice instead of a summary:
@@ -4152,11 +3399,7 @@
* Open the session yourself and run `/recap` there: in its terminal, in the [Desktop app](</docs/en/desktop>) or the [mobile app](</docs/en/mobile>), at [claude.ai/code](<https://claude.ai/code>), or over [Remote Control](</docs/en/remote-control>)
* If a cloud scheduled task or another program sent it, remove `/recap` from that prompt
-###
-
-
-
-/feedback is disabled by your organization’s policy
+### /feedback is disabled by your organization’s policy
This message means product feedback is turned off, so the command you typed doesn’t open the feedback dialog. An organization’s policy and an earlier refusal both produce the message:
@@ -4174,19 +3417,11 @@
Before v2.1.319, an earlier refusal didn’t produce this message. Before v2.1.302, the full message read `/feedback is disabled by your organization's policy. Contact your organization admin to enable it.`
-##
-
-
-
-Plugin errors
+## Plugin errors
These errors come from [plugin](</docs/en/plugins/overview>) and [marketplace](</docs/en/plugins/overview>) configuration. For plugin problems that don’t produce one of the messages on this page, such as a marketplace URL that doesn’t load or a plugin that installs but doesn’t appear, see [Plugin troubleshooting](</docs/en/plugins/troubleshooting>).
-###
-
-
-
-plugin eval is currently in early access
+### plugin eval is currently in early access
You ran [`claude plugin eval`](</docs/en/plugin-evals>) or `claude plugin eval init` and it exited 1 with one of these messages before doing anything:
@@ -4199,11 +3434,7 @@
* Run `claude --version`, then `claude update`, and run the command again in a fresh session. See the [requirements for plugin evals](</docs/en/plugin-evals#requirements>)
* If you see the second message on a current build, try again later after another `claude update`
-###
-
-
-
-Marketplace is registered from an untrusted source
+### Marketplace is registered from an untrusted source
The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugins/marketplace-reference#marketplace-file>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, an entry registered before its name became reserved kept loading.
@@ -4215,11 +3446,7 @@
* If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
* See the reserved name list under [Marketplace schema](</docs/en/plugins/marketplace-reference#marketplace-file>)
-###
-
-
-
-Marketplace name is another spelling of a reserved name
+### Marketplace name is another spelling of a reserved name
The marketplace’s name isn’t itself a reserved name, but Claude Code treats it as another spelling of one. [Reserved names](</docs/en/plugins/marketplace-reference#reserved-name-spellings>) lists which spellings count as a reserved name. Claude Code refuses such a name when you add the marketplace:
@@ -4234,11 +3461,7 @@
* Rename the marketplace to a name that doesn’t spell a reserved name and add it again
* For the ignored-entry warning, run the `claude plugin marketplace remove` command it gives, or remove the entry from `~/.claude/plugins/known_marketplaces.json`
-###
-
-
-
-Claude Code refuses the marketplace name
+### Claude Code refuses the marketplace name
A registered marketplace’s name [impersonates an official Anthropic marketplace](</docs/en/plugins/marketplace-reference#reserved-names>) under the rules that section lists. If a marketplace was registered under such a name before the check blocked it, the marketplace and the plugins installed from it stop loading, because Claude Code checks the name every time it reads the marketplace’s catalog. When the name imitates an official one, `claude plugin list` and the `/plugin` **Errors** tab report each affected plugin with a message that begins:
@@ -4254,11 +3477,7 @@
* To remove the marketplace, run `claude plugin marketplace remove <name>`. This also uninstalls the plugins installed from the marketplace and deletes their data, options, and secrets
* If you publish the marketplace, rename it in your `marketplace.json`; users then update the marketplace instead of removing it
-###
-
-
-
-Marketplace is already added from a different source
+### Marketplace is already added from a different source
You named a new marketplace source with [`--marketplace <source>` on the install command](</docs/en/plugins/install#add-a-marketplace-and-install-in-one-command>), in a session or from your shell. The catalog Claude Code fetched from that source has the same name as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
@@ -4269,11 +3488,7 @@
* If the marketplace you already added is the one you want, install from it by name: `/plugin install <plugin>@<name>`
* To switch to the new source, run `/plugin marketplace remove <name>`, then retry the install
-###
-
-
-
-Plugin command references user_config in a shell command
+### Plugin command references user_config in a shell command
A plugin hook, [monitor](</docs/en/plugins/components#monitors>), or MCP [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) command references a `${user_config.KEY}` [plugin option](</docs/en/plugins/manifest-reference#user-configuration>), and the substituted string would be passed to a shell. A configured value containing `$(...)`, backticks, or `;` would run as code there, so Claude Code refuses to start the component instead of substituting the value. The check runs on the command template, so the error appears even when no value is configured yet. Before v2.1.207, the value was substituted into the shell command. The wording depends on which surface referenced the option. A shell-form hook reports:
@@ -4293,11 +3508,7 @@
* For a monitor, drop the reference and have the monitor script read the value from a config file
* For a `headersHelper`, move `${user_config.KEY}` into the server’s `headers` field, which isn’t shell-parsed, or read the value inside the helper script
-###
-
-
-
-Plugin archive integrity check failed
+### Plugin archive integrity check failed
The plugin’s marketplace entry uses an [`archive` source](</docs/en/plugins/marketplace-reference#archive-plugin-source>) with a `sha256` pin, and the digest of the downloaded file doesn’t match the pin. Claude Code refuses the install, so nothing changes in the plugin cache. The mismatch has three possible causes:
@@ -4313,11 +3524,7 @@
* If you install the plugin, run `/plugin marketplace update <name>` to refresh the catalog in case the entry was corrected, then retry the install
* If the digests still disagree after a refresh, ask the marketplace owner which file they pinned before installing
-###
-
-
-
-Path escapes plugin directory
+### Path escapes plugin directory
One of the plugin’s component paths leads outside the plugin directory or couldn’t be confirmed inside it, so Claude Code drops that path and loads the rest of the plugin. For a path the plugin declares in `plugin.json` or its [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>), the component name in the message, such as `commands` or `hooks`, names the field that declared the path.
@@ -4327,11 +3534,10 @@
commands path escapes plugin directory: ./commands/deploy.md — it resolves to /home/user/shared/deploy.md, outside the plugin directory
-A message that gives the full path of one of a marketplace plugin’s own files, such as `hooks/hooks.json`, means Claude Code skipped that file. That happens when Claude Code can’t confirm the file is inside the plugin or, for a plugin in a [local marketplace](</docs/en/plugins/loading#in-place-and-copied-plugins>), inside that marketplace. The message reports each of these files under the component name shown:
+A message that gives the full path of one of a marketplace plugin’s own files, such as `hooks/hooks.json`, means Claude Code skipped that file. When Claude Code can’t confirm the file is inside the plugin, or inside its marketplace for a plugin in a [local marketplace](</docs/en/plugins/loading#in-place-and-copied-plugins>), it skips the file. The message reports these files under the component name shown:
* `hooks/hooks.json`: `hooks`
* `monitors/monitors.json`: `monitors`
- * `settings.json`: `settings`
* `SKILL.md` at the plugin root: `skills`
For example, this message is for a `hooks/hooks.json` that resolves outside both the plugin and its local marketplace:
@@ -4351,11 +3557,7 @@
* If the message ends with `EACCES`, restore your execute permission on every directory leading to the file or folder the path names. Check the directories above the path, then follow each symlink you reach and check the directories leading to where it points. For any other error code, look it up in the causes and steps for a path that couldn’t be checked.
* To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
-###
-
-
-
-Server file path not read
+### Server file path not read
The `path not read` message means Claude Code didn’t read an MCP or LSP server file that a plugin names, because of the file’s path. The rest of the plugin loads, without the servers the file defines. A `..` part counts even when the path stays inside the plugin, as in this example:
@@ -4367,11 +3569,7 @@
* If you maintain the plugin, keep the server file inside the plugin directory. Name it in the manifest or marketplace entry with a path that starts with `./` and has no `..`, for example `./servers/x.json`
* To share one server file between plugins in the same marketplace, link the file into each plugin with a symlink, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
-###
-
-
-
-Plugin not loaded: its manifest was not read
+### Plugin not loaded: its manifest was not read
Claude Code couldn’t confirm that a marketplace plugin’s [manifest](</docs/en/plugins/manifest-reference>) at `.claude-plugin/plugin.json` is inside the plugin, so it loads nothing from that plugin. For a plugin in a [local marketplace](</docs/en/plugins/loading#in-place-and-copied-plugins>), Claude Code also couldn’t confirm that the manifest is inside that marketplace. The message appears in the `/plugin` **Errors** tab, and the reason at its end says what Claude Code found. For example, this message is for a plugin in a local marketplace whose `.claude-plugin` folder is a symlink leading outside the marketplace:
@@ -4383,11 +3581,7 @@
* If you maintain the plugin and the reason says where the manifest resolves, the `.claude-plugin` folder or `plugin.json` itself is a symlink that leads there. Replace that link with a copy of what it points to.
* If you installed the plugin and don’t maintain it, report the message to its author
-###
-
-
-
-Path could not be checked
+### Path could not be checked
Claude Code asked the operating system whether a plugin path exists and got an error other than “not found”, so it doesn’t load what the path names. How much of the plugin loads depends on which path failed:
@@ -4413,11 +3607,7 @@
Before v2.1.265, Claude Code treated a default component folder it couldn’t check as absent and loaded the plugin without that component, with no error.
-###
-
-
-
-Marketplace entry path does not stay inside the marketplace directory
+### Marketplace entry path does not stay inside the marketplace directory
The plugin’s [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>) declares a source path that Claude Code can’t resolve to a location inside the marketplace’s own directory, so the plugin doesn’t install or load. The refusal covers:
@@ -4439,11 +3629,7 @@
* If you maintain the marketplace, write the entry’s `source` as a plain relative path with forward slashes, such as `./plugins/my-plugin`, and keep any symlink it crosses pointed inside the marketplace directory
* If you added the marketplace from a direct URL, relative entries can’t resolve. Ask the marketplace author to use [another plugin source](</docs/en/plugins/marketplace-reference#plugin-sources>), or add the marketplace from its git repository instead
-###
-
-
-
-Failed to load marketplace configuration
+### Failed to load marketplace configuration
Claude Code keeps the plugin marketplaces you’ve added in a registry file at `~/.claude/plugins/known_marketplaces.json`. A plugin command that needs the registry, such as `claude plugin install`, fails with one of two messages when Claude Code can’t use the file:
@@ -4459,11 +3645,7 @@
* Open `~/.claude/plugins/known_marketplaces.json` and repair the JSON, or fix the entries the message names as not matching the registry schema
* If you can’t repair it, delete the file or replace its contents with `{}`, then re-add each marketplace with `claude plugin marketplace add <source>`. Claude Code re-registers the marketplaces your user or managed settings declare in [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>) the next time you start it in a folder you’ve trusted.
-###
-
-
-
-Plugin is required by your organization
+### Plugin is required by your organization
You ran `claude plugin disable`, or used the `/plugin` **Installed** tab, to turn off a [plugin synced from claude.ai](</docs/en/plugins/loading#synced-plugins>) that your organization marks as required:
@@ -4473,11 +3655,7 @@
* Ask an admin of your claude.ai organization to change the plugin’s required status on claude.ai
-###
-
-
-
-Plugin was not uninstalled
+### Plugin was not uninstalled
You ran [`claude plugin uninstall`](</docs/en/plugins/cli-reference#plugin-uninstall>), or chose **Uninstall** in the `/plugin` **Installed** tab, and the uninstall stopped with a message starting `"<plugin>" was not uninstalled:`. If the text after that colon starts with `installed_plugins.json` instead of naming a settings file, the cause is content in `installed_plugins.json` that this version of Claude Code can’t read. For that form, see [`installed_plugins.json` holds a record this version can’t read](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>). When Claude Code removed the plugin’s entry from `enabledPlugins` and read that scope’s settings files back, either the plugin was still switched on there, or a file that could switch it on couldn’t be read or checked. Deleting the plugin’s saved options, secrets, and data while a settings entry could switch it back on would lose them, so the uninstall stops instead: the plugin stays installed and nothing it saved is deleted.
@@ -4494,11 +3672,7 @@
* Follow the last sentence of the message: repair or replace the settings file it names, or remove the plugin’s entry from `enabledPlugins` in that file yourself, then run the uninstall again
-###
-
-
-
-Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)
+### Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)
This message means Claude Code didn’t start a stdio [MCP server that a plugin provides](</docs/en/mcp#plugin-provided-mcp-servers>), because a connection to that server failed less than 15 minutes earlier:
@@ -4513,19 +3687,11 @@
The message replaces the error from the failed connection. If the new attempt fails too, Claude Code reports that attempt’s error instead of this message.
-##
-
-
-
-Tool errors
+## Tool errors
These errors come from Claude’s tool calls. Claude corrects most tool errors on its own. When one needs a change from you, that error’s **What to do** list says what to change.
-###
-
-
-
-No such tool available
+### No such tool available
Claude called a tool by a name that isn’t in the session’s tool list. Claude Code returns the error to Claude as the tool call’s result, and the turn continues. When Claude Code can tell why the tool is missing, it adds a sentence after the tool name that gives the reason or names the tool to call instead, as in the second line:
@@ -4537,11 +3703,7 @@
* If it happens once, you don’t need to do anything. Claude reads the error and the turn continues.
* If calls to an MCP server’s tools keep failing with this error, run `/mcp` in the session or `claude mcp list` in your shell to check the server’s [status](</docs/en/mcp#server-status>), and reconnect a failed server from `/mcp`. In the Agent SDK, see [Error handling](</docs/en/agent-sdk/mcp#error-handling>).
-###
-
-
-
-MCP server connection closed before the tool call was answered
+### MCP server connection closed before the tool call was answered
A tool call to an HTTP [MCP server](</docs/en/mcp>) or a [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) lost its connection before the server answered, so Claude Code can’t tell whether the tool ran:
@@ -4554,11 +3716,7 @@
* If the action didn’t happen, ask Claude to run the tool again. You don’t need to reconnect the server first, because Claude Code connects to it again for the next call to one of its tools. If that connection fails too, see [Mid-session drops of a remote server](</docs/en/mcp#mid-session-drops-of-a-remote-server>).
* If you build the server and the tool is safe to call twice, [mark it as safe to repeat](</docs/en/mcp#tool-calls-pending-when-a-connection-closes>) so that Claude Code can repeat a lost call
-###
-
-
-
-MCP server is disabled
+### MCP server is disabled
This message in a tool result means Claude called a tool on an [MCP server](</docs/en/mcp>) that is [turned off](</docs/en/mcp#disable-a-server-without-removing-it>). Claude Code didn’t connect to the server, so the tool didn’t run, and Claude received this text in place of a result:
@@ -4570,11 +3728,7 @@
* If Claude needs the server’s tools, turn it back on from `/mcp` at the Claude Code prompt
* In an [Agent SDK](</docs/en/agent-sdk/overview>) application, turn the server back on by calling [`toggleMcpServer()`](</docs/en/agent-sdk/typescript#togglemcpserver>) in TypeScript with `enabled` set to `true`, or [`toggle_mcp_server()`](</docs/en/agent-sdk/python#claudesdkclient>) in Python with `enabled` set to `True`
-###
-
-
-
-MCP tool call timed out with the server’s question unanswered
+### MCP tool call timed out with the server’s question unanswered
In [non-interactive mode](</docs/en/headless>), an [MCP server](</docs/en/mcp>) asked for input through [elicitation](</docs/en/mcp#respond-to-mcp-elicitation-requests>) during a tool call, and the call’s time limit ran out before an answer came:
@@ -4587,11 +3741,7 @@
* To give an answer more time, set a longer [`timeout`](</docs/en/mcp#time-limits-on-mcp-tool-calls>) in milliseconds in the server’s configuration entry, such as `"timeout": 600000` for 10 minutes
* Run the task in an interactive session instead and answer the server’s [dialog](</docs/en/mcp#respond-to-mcp-elicitation-requests>) yourself
-###
-
-
-
-Permission prompt tool returned an invalid result
+### Permission prompt tool returned an invalid result
The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) returned an answer Claude Code couldn’t read, so the tool call waiting on it didn’t run, even if the answer allowed the call:
@@ -4606,11 +3756,7 @@
* **MCP TypeScript SDK** : without `outputSchema`
* If the error comes only with inputs of about 40 KB or more, don’t copy the input into `updatedInput` or a deny’s `message`. To change an input that large, [raise your prompt tool’s output limit](</docs/en/mcp#raise-the-limit-for-a-specific-tool>).
-###
-
-
-
-Agent would be spawned with zero tools
+### Agent would be spawned with zero tools
Every entry in the subagent’s [`tools` list](</docs/en/sub-agents#supported-frontmatter-fields>) failed to match a usable tool, so Claude Code refused to launch the subagent: with no tools, it couldn’t act. The message groups your entries by what went wrong:
@@ -4632,11 +3778,7 @@
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
-###
-
-
-
-File is covered by a Read deny rule
+### File is covered by a Read deny rule
The Edit or Write tool was called on a path matched by a [`Read` deny rule](</docs/en/permissions#read-and-edit>), including creating a new file at that path. Both tools change content Claude has to be able to read back, so Claude Code refuses the call before any file access. NotebookEdit isn’t covered by `Read` deny rules. Before v2.1.228, the rule blocked the Edit tool only, and before v2.1.208, only an `Edit` deny rule blocked edits.
@@ -4647,11 +3789,7 @@
* If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings-reference#permission-settings>)
* If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path to block the NotebookEdit tool too
-###
-
-
-
-Setting blocks writes outside the working directories
+### Setting blocks writes outside the working directories
When Claude tries to write a file and the tool call fails with this message, the path is outside the session’s [working directories](</docs/en/permissions#working-directories>) and [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on:
@@ -4670,11 +3808,7 @@
* To turn `permissions.blockWritesOutsideWorkingDirectories` off, remove it from every settings file that sets it, then restart Claude Code
* If none of your settings files has `permissions.blockWritesOutsideWorkingDirectories`, it can come from `--settings` or from a host application. Claude Code also refuses these writes while it can’t read `permissions` in your [managed settings](</docs/en/managed-settings#keys-that-fail-closed>). Ask whoever launches or manages the session.
-###
-
-
-
-Writes to Claude Code settings files are blocked
+### Writes to Claude Code settings files are blocked
When Claude tries to write a file and the tool call fails with this message, Claude Code treats the file as one of its settings files and [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on:
@@ -4689,11 +3823,7 @@
* **The stored copy of[server-managed settings](</docs/en/server-managed-settings#security-considerations>) and the files kept with it**: ask an [Owner](</docs/en/server-managed-settings#access-control>) to change the setting in server-managed settings.
* **Any`.json` file, while Claude Code can’t work out where the [`managed-settings.d/`](</docs/en/managed-settings#split-a-file-based-policy-across-teams>) folder leads**: ask your administrator to check that folder
-###
-
-
-
-Path cannot contain null bytes
+### Path cannot contain null bytes
A file tool call’s path or pattern argument contained a null byte, which file systems and search tools can’t accept. Read, Write, Edit, NotebookEdit, Glob, and Grep check for this, and the message names the tool and the argument:
@@ -4705,11 +3835,7 @@
Before v2.1.281, a null byte in a Read, Write, Edit, or NotebookEdit path ended the whole turn with an error naming `Path contains null bytes`, and the tool never ran.
-###
-
-
-
-Command contains an invisible character
+### Command contains an invisible character
The [PowerShell tool](</docs/en/tools-reference#powershell-tool>) refused to run a command that contains U+FEFF or U+180E:
@@ -4720,11 +3846,7 @@
* **For a command Claude wrote** : you have nothing to fix. The message tells Claude how to rewrite the command.
* **For a skill or command file** : the message follows `No shell command in <name> was run`. See where to find the character and remove it.
-###
-
-
-
-Command approved before Claude Code restarted was not run
+### Command approved before Claude Code restarted was not run
A shell command you approved didn’t run, and Claude receives this message as the command’s result:
@@ -4734,11 +3856,7 @@
* Let Claude continue, and answer the prompt if you’re asked to approve the command again.
-###
-
-
-
-File is too large to read as an image
+### File is too large to read as an image
Claude tried to read a file as an image with the [Read tool](</docs/en/tools-reference#read-tool-behavior>), and the file is larger than 128 MB, the most Read loads from an image file. Nothing was read, and Claude receives this error as the tool result:
@@ -4754,11 +3872,7 @@
* If Claude stopped at the error, export a copy under 128 MB yourself, for example at a lower resolution, and point Claude at that file
* If the path was a pipe or a device, point Claude at a regular image file instead
-###
-
-
-
-subagent_type is required
+### subagent_type is required
subagent_type is required: the general-purpose agent is not available in this session. Available agents: ...
@@ -4774,11 +3888,7 @@
Before v2.1.235, the same call failed with `Agent type 'general-purpose' not found`.
-###
-
-
-
-Memory index is over its read limit
+### Memory index is over its read limit
Claude wrote to the [auto memory](</docs/en/memory#auto-memory>) index `MEMORY.md` and left it over one of its read limits: 200 lines or 25KB. The write succeeded, but only the first 200 lines or 25KB, whichever comes first, load at the start of a session, so everything past the limit is dropped each time the index is read. Before v2.1.210, an over-limit index was silently truncated on the next load with no write-time signal.
@@ -4789,11 +3899,7 @@
* Let Claude rewrite `MEMORY.md`, or ask it to: keep one line per entry, move detail into topic files, and merge or drop stale entries
* To trim the index yourself, see [Audit and edit your memory](</docs/en/memory#audit-and-edit-your-memory>)
-###
-
-
-
-pkill pattern matches the Claude Code process
+### pkill pattern matches the Claude Code process
A `pkill` command in a Bash tool call used a pattern, typically with `-f`, that matches the Claude Code process itself, so Claude Code refuses the command instead of letting it end the session. Claude Code tests the pattern with `pgrep` before running `pkill` and refuses when its own process ID is in the result. The check runs on Linux only; on macOS, `pkill` runs unmodified. Before v2.1.214, the command ran, and a matching pattern killed the Claude Code session mid-turn.
@@ -4804,11 +3910,7 @@
* Narrow the pattern so it matches only the intended process, for example the full path of the target binary rather than a short substring
* To stop processes started by the current shell, use `pkill -P $$` with the pattern, which limits the match to the shell’s own child processes
-###
-
-
-
-Failed to write to a teammate’s inbox
+### Failed to write to a teammate’s inbox
Claude Code couldn’t write a message to a teammate’s mailbox file under `~/.claude/teams/{team-name}/inboxes/`, so the recipient received nothing. The write fails when Claude Code can’t create or update the file, for example because the disk is full, the directory isn’t writable, or another agent holds the inbox lock for too long. Before v2.1.224, Claude Code reported the message as sent even when the write failed. The error appears in the sending agent’s tool result rather than as a banner in your terminal, and its text tells Claude to try again:
@@ -4825,11 +3927,7 @@
* Ask the sender to resend the message; contention for the inbox lock is transient and clears on retry
* Check free disk space, and check that `~/.claude/teams` and the files under it are writable by your user
-###
-
-
-
-Teammate’s agent definition was not restored
+### Teammate’s agent definition was not restored
Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from. The notice follows the resume report in the sending agent’s tool result and names the reason. When the definition file came from a folder with no saved trust, it reads:
@@ -4840,11 +3938,7 @@
* Run `claude` in the folder the [debug log](</docs/en/debug-your-config>) names and accept the trust dialog. The definition is re-applied the next time Claude Code brings the teammate back; you don’t need to restart the lead session
* Or set the `hasTrustDialogAccepted` entry to `true` in `~/.claude.json`, using the exact `projects["<path>"]` key the debug log prints
-###
-
-
-
-Only a teammate can approve a shutdown request
+### Only a teammate can approve a shutdown request
Claude Code refused an [agent team](</docs/en/agent-teams>) shutdown approval because the session that sent it isn’t running as a teammate. Nothing was sent and nothing shut down. The refusal appears in the sending session’s tool result:
@@ -4856,11 +3950,7 @@
* If the teammate is still running, ask the lead at its prompt to shut the teammate down, for example `Ask the researcher teammate to shut down`. See [Shut down teammates](</docs/en/agent-teams#shut-down-teammates>).
* If a former teammate you resumed yourself with `claude --resume` got this refusal, nothing was sent. To end that session, run `/exit` at its prompt.
-###
-
-
-
-A command-line deny rule cannot be handed to a teammate intact
+### A command-line deny rule cannot be handed to a teammate intact
This message means Claude Code didn’t start a [split-pane](</docs/en/agent-teams#choose-a-display-mode>) teammate in your [agent team](</docs/en/agent-teams>). Claude Code passes the lead’s command-line deny rules to a split-pane teammate on the teammate’s own command line, and stops when the teammate would read one of them differently:
@@ -4871,11 +3961,7 @@
* Run `/config` in the lead session and set **Teammate mode** to `in-process`, then ask Claude to start the teammate again. You don’t need to find the rule or restart the lead. An in-process teammate [runs under the lead’s live deny rules](</docs/en/agent-teams#permissions>).
* Later sessions that take [`teammateMode`](</docs/en/settings-reference#teammatemode>) from your user settings start teammates in-process too, because `/config` saves the choice there. To go back to split panes in a later session, set **Teammate mode** to `auto`, `tmux`, or `iterm2`, whichever you used before.
-###
-
-
-
-Message too large for cross-session delivery
+### Message too large for cross-session delivery
Claude’s [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine was too long to send. Claude Code refused it, and the receiving session got nothing. The refusal appears in the sending session’s tool result, not as a banner in your terminal. It names both sizes and how to make the message fit:
@@ -4888,11 +3974,7 @@
Before v2.1.235, Claude Code reported an oversized message as sent. The receiving session dropped it unread.
-###
-
-
-
-Too many messages to this session just now
+### Too many messages to this session just now
Claude sent a rapid burst of [cross-session messages](</docs/en/cross-session-messaging>) to one of your sessions on this machine, and the burst reached what that session’s inbox accepts. Claude Code refused the next send, and the receiving session got nothing from it. The refusal appears in the sending session’s tool result, not as a banner in your terminal:
@@ -4905,11 +3987,7 @@
Before v2.1.236, Claude Code reported these sends as sent. The receiving session dropped them unread.
-###
-
-
-
-Cross-session message was dropped at the recipient session’s inbox
+### Cross-session message was dropped at the recipient session’s inbox
Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient and, when the recipient gave a reason, adds the reason after a dash:
@@ -4930,11 +4008,7 @@
Before v2.1.238, the sending session got no report when the recipient’s inbox discarded a message.
-###
-
-
-
-Refusing to send a cross-session message
+### Refusing to send a cross-session message
Before Claude Code writes a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, it checks that the target session’s inbox socket is the endpoint the message was addressed to. When a check fails, Claude Code refuses the send in the sending session, and the target session receives nothing. For a message Claude sends, the refusal appears in the sending session’s tool result:
@@ -4950,11 +4024,7 @@
* Usually nothing: the checks keep a message from reaching an endpoint other than the session it was addressed to, and nothing was sent
* If `reply target is a symlink` repeats for one session, check what created a link at that session’s socket path, shown in its `/status` under `Peer address`
-###
-
-
-
-Refusing to read, write, or search a path
+### Refusing to read, write, or search a path
Claude Code checks a file path’s [permission rules](</docs/en/permissions#read-and-edit>), then confirms that resolution again when the tool opens the file or starts the search. When it can’t confirm that the path still leads to the location the check approved, Claude Code refuses the operation instead of following it. The refusal appears in the tool result:
@@ -4983,11 +4053,7 @@
Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these, only the parent-directory, through-symlink, and symlinked-directory write refusals appear on earlier versions. Before v2.1.280, the `where it leads on disk could not be determined` refusal didn’t appear.
-###
-
-
-
-The search failed, so this is not a “no matches” result
+### The search failed, so this is not a “no matches” result
A [Grep](</docs/en/tools-reference#grep-tool-behavior>) or [Glob](</docs/en/tools-reference#glob-tool-behavior>) search Claude ran failed before returning any result, so whether matches exist is unknown. The message Claude receives in place of results starts:
@@ -5002,11 +4068,7 @@
3. If the search fails again, find the line containing `rg error (signal=` in `claude-debug.log`
4. Include that line when you report the problem
-###
-
-
-
-Task output swap refused
+### Task output swap refused
Claude Code saves each Bash command’s output to a file under its temp directory. Every time it opens one of these files, it checks that the path still leads to the file it created, with no symbolic link, extra hard link, or moved directory redirecting it. This message means that check failed, so Claude Code refused the operation rather than write or read output through that path. The message appears in the Bash tool result:
@@ -5023,11 +4085,7 @@
* Or check your project’s directory under the Claude Code temp directory, `/private/tmp/claude-501/-Users-you-my-project` in the example message. If that path is a symbolic link, or a directory that shouldn’t be there, remove the link or directory itself rather than the link’s target, and restart Claude Code
* If the refusal repeats, a process is replacing, linking, or removing entries under Claude Code’s temp directory while the session runs. Set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory nothing else manages and restart
-###
-
-
-
-Disk full or disk quota used up
+### Disk full or disk quota used up
Free up space, inodes, or disk quota on the volume that holds Claude Code’s temporary directory. A line in a command’s result starting `Disk full:`, `Disk quota used up:`, or `Nearly out of inodes:` names that directory. Claude Code saves each Bash and PowerShell command’s output to a file under that directory. If it can’t create that file because the volume or your quota on it is full, your command doesn’t start, and the result Claude reads is:
@@ -5055,11 +4113,7 @@
Before v2.1.305, a command that Claude Code couldn’t start because the disk was full returned only the operating system’s error text. That text read, for example, `ENOSPC: no space left on device, open <path>.output`.
-###
-
-
-
-git is not installed on this Mac
+### git is not installed on this Mac
This message means a step in Claude Code needed git, and the git it found is Apple’s stand-in at `/usr/bin/git`. The developer tools that provide git aren’t installed. Claude Code doesn’t start the stand-in and shows this text instead, for example inside a longer message:
@@ -5069,11 +4123,7 @@
* In Terminal, run `xcode-select --install`, finish the installation it starts, then retry what you were doing in Claude Code
-###
-
-
-
-File is not valid UTF-8
+### File is not valid UTF-8
Claude used the Edit or NotebookEdit tool on a file whose bytes don’t decode as UTF-8, and Claude Code refused the change. Nothing was written, so the file is as it was. Those tools save the whole file back as UTF-8, which would have turned every byte they couldn’t decode into the replacement character `U+FFFD`. The message appears in the tool result:
@@ -5086,11 +4136,7 @@
Before v2.1.296, Edit and NotebookEdit applied such an edit and saved every byte they couldn’t decode as `U+FFFD`. On those versions, update Claude Code.
-###
-
-
-
-Refusing to apply edits: a hook is configured for file edits in this session
+### Refusing to apply edits: a hook is configured for file edits in this session
Claude tried to publish an [artifact](</docs/en/artifacts>) with a [one-step update](</docs/en/artifacts#turn-off-one-step-artifact-updates>), a small change to the artifact’s file included in the publish, and Claude Code refused. Nothing was published and the file is unchanged. The message appears in the Artifact tool result:
@@ -5103,11 +4149,7 @@
* If the message keeps coming back, quit and relaunch Claude Code
* If the message comes back even after a relaunch, [turn off one-step updates](</docs/en/artifacts#turn-off-one-step-artifact-updates>)
-###
-
-
-
-The source file is not valid UTF-8 text
+### The source file is not valid UTF-8 text
Claude tried to publish an [artifact](</docs/en/artifacts>) from a file whose bytes don’t decode as text, or whose text already contains the replacement character `U+FFFD`, so Claude Code refused the publish before uploading anything. The message appears in the Artifact tool result and names the first position to fix:
@@ -5123,11 +4165,7 @@
Before v2.1.267, Claude Code uploaded such a file without checking it, and the server refused the publish instead.
-###
-
-
-
-Not published: that file is on a network share
+### Not published: that file is on a network share
Claude tried to publish an [artifact](</docs/en/artifacts>) from a file at a path that names a network host:
@@ -5145,11 +4183,7 @@
* On Windows, to let Claude publish directly from the share, map it to a drive letter and pass the drive when you start Claude Code. In PowerShell, for example, run `net use Z: \\server\share` and then `claude --add-dir Z:\`. Claude can then publish files from that drive. Adding the drive mid-session with `/add-dir` isn’t enough.
* On macOS or Linux, mount the share at a directory such as one under `/mnt` or `/Volumes`, and publish from that path instead of the automount path
-###
-
-
-
-Not published: Claude sent the same content again after a newer version of the artifact turned it away
+### Not published: Claude sent the same content again after a newer version of the artifact turned it away
This red line under an Artifact call means Claude Code stopped a repeated publish: the [artifact](</docs/en/artifacts>) wasn’t updated, and nothing was written to the file Claude publishes from. You don’t need to do anything unless Claude stops without publishing. Earlier in the session, Claude Code turned a publish away because the artifact had a newer version, for example one that an [editor](</docs/en/artifacts#let-someone-edit-with-you>) or another of your sessions published. The line’s ending says what Claude has to do next:
@@ -5163,11 +4197,7 @@
* **Ends with`Claude needs to work from that newer version first`**: if Claude stopped there, ask it to fetch the artifact’s current version, merge its changes in, and publish again
* **Ends with`should go through`**: if Claude stopped there, ask it to publish again
-###
-
-
-
-Reading a local file from outside the connected folders in a Cowork session
+### Reading a local file from outside the connected folders in a Cowork session
In a [Cowork](<https://claude.com/docs/cowork/overview>) session running on your machine in the Claude Desktop app, Claude named a local file for an [artifact](</docs/en/artifacts>). Claude Code couldn’t confirm the file is a plain file inside the session’s connected folders: the path sits outside those folders, passes through a symbolic link, or is spelled in a way that can name a different file than it appears to. Reading such a file needs your approval, and in a session that can’t show you the approval card, such as one set to skip all approvals, Claude Code refuses the read. The refusal appears in the Artifact tool result; when the file couldn’t be examined at all, it names that failure instead:
@@ -5180,11 +4210,7 @@
* Usually nothing: the message tells Claude to use a plain file inside the connected folders instead
* To put that exact file in the artifact, copy it into one of the session’s connected folders as a regular file, not a symlink, and ask again
-###
-
-
-
-WebFetch cannot fetch localhost
+### WebFetch cannot fetch localhost
Claude called [WebFetch](</docs/en/tools-reference#webfetch-tool-behavior>) with a URL whose hostname has no dot, such as `http://localhost:3000` or a bare intranet name like `http://wiki/`. WebFetch refuses these URLs before making any request:
@@ -5196,11 +4222,7 @@
Before v2.1.268, WebFetch reported these URLs with a generic `Invalid URL` error.
-###
-
-
-
-WebFetch domain safety check failed
+### WebFetch domain safety check failed
Before fetching a URL, WebFetch sends the URL’s hostname to `api.anthropic.com` to check it against Anthropic’s [domain safety blocklist](</docs/en/data-usage#webfetch-domain-safety-check>). If the check can’t complete, WebFetch can’t confirm that the domain is safe, so it doesn’t fetch the page and the tool result carries one of these messages instead:
@@ -5213,19 +4235,11 @@
Before v2.1.286, the rate-limited message read `The safety check for domain example.com is temporarily rate-limited (too many domain checks from this network). Retry after about a minute; retrying sooner will fail the same way.`. Before v2.1.285, a rate-limited check was reported with the `Unable to verify` message instead.
-##
-
-
-
-Background session errors
+## Background session errors
[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in the terminal that attaches to one, in the session or shell you dispatch from, or, for the worktree-guard entries below, in any session isolated in a worktree or running a worktree-isolated subagent; where a message is specific to one surface, its entry says so.
-###
-
-
-
-Commands refused in a background session
+### Commands refused in a background session
Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message. For `/install-github-app` and the `/mcp` settings list, the session also appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, the session didn’t appear under **Needs input** after `/install-github-app` or the `/mcp` settings list was refused. In v2.1.213 through v2.1.215, the commands still worked while a terminal was attached, and the refusal message told you to attach and run the command again. From v2.1.208 through v2.1.212, Claude Code refused them even while a terminal was attached, with a message such as `Can't open MCP settings in a background session`; on those versions, run the command from a regular `claude` session instead, or upgrade. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
@@ -5236,11 +4250,7 @@
* Attach to the session from agent view and run the command again
* Or use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`, which work without attaching
-###
-
-
-
-Write or command blocked because the path cannot be safely resolved
+### Write or command blocked because the path cannot be safely resolved
Claude addressed a file or working directory through a spelling that the [worktree-isolation guard](</docs/en/agent-view#how-file-edits-are-isolated>) can’t resolve to one verifiable location. The guard checks writes and command working directories in [any session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), interactive or background, and in [worktree-isolated subagents](</docs/en/worktrees#isolate-subagents-with-worktrees>). It resolves symlinks before checking that the operation doesn’t reach the shared checkout, and when resolution fails, it blocks the operation rather than letting it land there. The message names the path forms it refuses and how to retry:
@@ -5251,11 +4261,7 @@
* Usually nothing: the full message goes to Claude as a tool error, and Claude retries with the direct path it names. For a blocked file edit, the conversation view shows only a short `Error editing file` line; the full message appears in the transcript view, which you open with `Ctrl+O`. A blocked command prints it in its command output.
* If the block repeats on the same file, the path likely runs through a committed symlink whose target contains `..`, such as `docs/current -> ../README.md`; ask Claude to edit the target file by its real path instead of through the link
-###
-
-
-
-Write or command blocked because the path names a network location
+### Write or command blocked because the path names a network location
Claude addressed a file or working directory through a path that names a drive that isn’t on your machine, a UNC share such as `\\server\share\file` or a `/net` automount path, while the session’s checkout is on a local disk. The same worktree-isolation guard can’t verify that such a path stays out of the shared checkout, so it blocks the operation. Isolating the session in a worktree doesn’t lift the block. The message names the form of path to use instead:
@@ -5265,11 +4271,7 @@
* Usually nothing: Claude retries with the local spelling the message asks for
-###
-
-
-
-Command blocked by the worktree isolation checks
+### Command blocked by the worktree isolation checks
Claude ran a Bash, [PowerShell](</docs/en/tools-reference#powershell-tool>), or [Monitor](</docs/en/tools-reference#monitor-tool>) command in a [session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), and Claude Code refused it for one of these reasons:
@@ -5286,11 +4288,7 @@
* **Git pointed at the main checkout, or command text that can’t be verified** : nothing. Claude reads the message and rewrites the command the way its final sentence asks. If a command you asked for keeps being refused over an expansion in its text, spell the flagged value literally and run git as its own plain command from inside the worktree
* To act on the main checkout on purpose, run the command yourself in a terminal outside the session
-###
-
-
-
-This session has no saved transcript
+### This session has no saved transcript
You attached to a session that you [moved to the background](</docs/en/agent-view#from-inside-a-session>) with `←` or `/background` and that stopped before it ran a turn of its own. Claude Code couldn’t find the conversation you moved it from, so the session has nothing to resume. The message ends with the `claude respawn` command for this session:
@@ -5301,31 +4299,24 @@
* To start the stopped session fresh, run `claude respawn <id>` with the ID from the message, or press `Enter` twice on its row in agent view
* If the session did finish a response and you still see this refusal on a version before v2.1.214, an unreadable folder in `~/.claude/projects` could make the transcript scan miss the saved conversation; update to v2.1.214 or later, which tolerates unreadable folders during the scan
-###
-
-
-
-This session is running in another terminal
+### This session is running in another terminal
You opened a stopped session’s row in [agent view](</docs/en/agent-view>), and its saved conversation is already open in another live Claude Code process on this machine, so Claude Code refuses to start a second process that would write to the same transcript. Which message you see depends on [what holds the conversation](</docs/en/agent-view#opening-a-session-says-the-conversation-is-already-open>):
Can't open — this session is running in another terminal
This conversation is already open in another running Claude session — use that one, or close it and try again
- * **`running in another terminal`** : a terminal holds the conversation, for example one where you resumed it with `claude --resume` or `/resume`. The row also shows `Open in a terminal`.
- * **`already open in another running Claude session`** : another non-interactive Claude Code process holds it, for example a [background session](</docs/en/agent-view#the-supervisor-process>) process for the same conversation that hasn’t exited yet.
-
-**What to do:**
-
- * Continue the conversation in the process that has it open, or exit that process and open the row again
+ * **`running in another terminal`** : a process other than a background session holds the conversation, for example a `claude -p` run, or a terminal where you resumed it with `claude --resume` or `/resume`. The row also shows `Open in a terminal`.
+ * **`already open in another running Claude session`** : another [background session](</docs/en/agent-view#the-supervisor-process>) holds it.
+
+**What to do:**
+
+ * For `running in another terminal`: continue in that terminal, or exit that process or let it finish, and then try again
+ * For `already open in another running Claude session`: use that session, or stop it and then try again
Before v2.1.248, only the `already open in another running Claude session` refusal existed: a conversation resumed in a terminal didn’t count as open, and opening the row started a second Claude Code process writing to the same conversation.
-###
-
-
-
-This session’s saved conversation is no longer on disk
+### This session’s saved conversation is no longer on disk
You opened a [background session](</docs/en/agent-view>) that ended while the background service was off, and [transcript cleanup](</docs/en/settings-reference#cleanupperioddays>) has since removed its saved conversation, for example after the machine was off for weeks. Opening such a row normally [resumes its saved conversation](</docs/en/agent-view#sessions-show-as-failed-after-shutdown>). With nothing left to resume, Claude Code refuses rather than re-run the session’s original prompt without asking:
@@ -5338,11 +4329,7 @@
Before v2.1.248, opening such a row re-ran the session’s original prompt instead of refusing, pulling a weeks-old task back into the foreground.
-###
-
-
-
-Worktree has commits that are not pushed anywhere
+### Worktree has commits that are not pushed anywhere
You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits unseen. `claude rm` names the branch and the unpushed commits, and says how to proceed:
@@ -5358,11 +4345,7 @@
Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or commits, and there was no discard route. You can still delete the session, losing uncommitted changes but keeping the branch and commits. Run `git worktree remove --force --force <path>` with the path the refusal printed, then `claude rm <id>`. Git needs `--force` twice for a locked worktree. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
-###
-
-
-
-Terminal host process died
+### Terminal host process died
Each [background session’s](</docs/en/agent-view>) terminal runs in a host process under the background service, and that process died while the service still held its connection, so the session couldn’t be reached. On Linux and WSL, the background service checks each host process every few seconds, marks the session failed when the process has exited but its connection to the service never closed, and shows the reason on its row in [agent view](</docs/en/agent-view#read-session-state>):
@@ -5380,11 +4363,7 @@
Before v2.1.247, a dead host process could pass every liveness check the background service ran, so opening the session showed `opening… · esc to cancel` indefinitely and `claude attach <id>` waited without reporting an error.
-###
-
-
-
-Session isn’t responding
+### Session isn’t responding
You opened a [background session](</docs/en/agent-view>) and the background service accepted the open, but no output arrived for about ten seconds, so Claude Code concludes that the process relaying the session’s terminal can’t deliver output, and ends the attempt instead of waiting. In agent view, Claude Code offers a restart in the footer:
@@ -5400,11 +4379,7 @@
* From the shell, run `claude stop <id>`, then `claude attach <id>`
* For a shell-command row, press `Ctrl+X` in agent view or run `claude stop <id>` to stop it; dispatch the command again to rerun it
-###
-
-
-
-Session was stopped while the respawn was in flight
+### Session was stopped while the respawn was in flight
You opened a [background session](</docs/en/agent-view>) whose process wasn’t running, and while Claude Code was restarting it, another Claude Code process stopped it, for example `claude stop` in another terminal. Claude Code keeps the session stopped:
@@ -5415,11 +4390,7 @@
* If you didn’t stop the session, open its row again in agent view or run `claude respawn <id>` to restart it
* If you stopped it yourself, nothing remains to do: the session stays stopped
-###
-
-
-
-Session agent no longer available
+### Session agent no longer available
You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools, so the agent’s tool restrictions no longer apply:
@@ -5431,11 +4402,7 @@
* Or resume with `--agent <name>` naming an agent that does exist, to run the session as that agent instead
* If the agent is project-scoped and you haven’t trusted the session’s original directory, run Claude Code there once, accept the trust dialog, then resume again
-###
-
-
-
-This session restarted after its next /loop wakeup was due
+### This session restarted after its next /loop wakeup was due
A [self-paced `/loop`](</docs/en/scheduled-tasks#let-claude-choose-the-interval>) in a [background session](</docs/en/agent-view>) has stopped. The session’s process ended while the loop was waiting for its next wakeup, and that wakeup came due before the session’s [next process](</docs/en/agent-view#the-supervisor-process>) started. The missed wakeup doesn’t fire late. The notice says how overdue the wakeup was when the session restarted:
@@ -5446,11 +4413,7 @@
* To continue the loop, [reply to the session](</docs/en/agent-view#peek-and-reply>) and say so, such as `keep the loop running`. Claude reads the notice with your reply and can schedule the next wakeup
* If you’re done with the loop, do nothing. It has already stopped
-###
-
-
-
-No LLM gateway: a gateway set in your shell isn’t passed to a session opened from another folder
+### No LLM gateway: a gateway set in your shell isn’t passed to a session opened from another folder
The [background session](</docs/en/agent-view>) showing this message isn’t using your [LLM gateway](</docs/en/llm-gateway>): it didn’t get the gateway’s address, so its requests fail. The message appears in the conversation in place of Claude’s reply, with your session’s ID and folder filled in:
@@ -5464,11 +4427,7 @@
Before v2.1.302, a background session in this situation showed a sign-in error such as `Not logged in · Please run /login` instead, without naming the folder.
-###
-
-
-
-CLAUDE_CODE_PROCESS_WRAPPER launcher errors
+### CLAUDE_CODE_PROCESS_WRAPPER launcher errors
[`CLAUDE_CODE_PROCESS_WRAPPER`](</docs/en/corporate-launcher>) is set, and its value can’t be used, so Claude Code refuses to start the affected process rather than run it without the launcher. Configuration problems are reported with a message that starts with the variable name and states the reason, for example:
@@ -5480,11 +4439,7 @@
* Check `/status`, which shows the resolved launch command in its Self-exec entry and warns when the running background service doesn’t match it, or run `claude daemon status` from a shell
* After fixing the value in the `env` block of [settings](</docs/en/corporate-launcher#set-up-the-launcher>), restart the background service with `claude daemon stop --any` so the next dispatch starts a wrapped one
-###
-
-
-
-EUNKNOWN when starting a background session
+### EUNKNOWN when starting a background session
Windows refused to start a program with an error code that has no standard name, so the failure surfaces as `EUNKNOWN`. The usual trigger is a software restriction policy, such as Group Policy or AppLocker, blocking the program being started. The error appears when you start a [background session](</docs/en/agent-view>) with `/background` or `claude --bg`:
@@ -5497,11 +4452,7 @@
* If the error appears on v2.1.212 or later while no npm install is running, check with your Windows administrator whether a restriction policy blocks the Claude Code executable
* If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
-###
-
-
-
-EACCES when starting a background session
+### EACCES when starting a background session
Claude Code couldn’t run its own binary to start the [background service](</docs/en/agent-view#the-supervisor-process>) that hosts background sessions. On an npm installation, this usually means `npm install -g @anthropic-ai/claude-code` was replacing the binary at that moment, whether you ran it or the [auto-updater](</docs/en/setup#auto-updates>) did. The error appears when you open a session from [agent view](</docs/en/agent-view>):
@@ -5516,11 +4467,7 @@
* Wait a few seconds, then open the session or dispatch again. When the message says Claude Code is being updated, retry after the update finishes.
* If the error persists while no npm install is running, your user can’t run the installed binary. Check its permissions and its directory’s, or reinstall Claude Code.
-###
-
-
-
-Background service exited before it became reachable
+### Background service exited before it became reachable
The process Claude Code started as the [background service](</docs/en/agent-view#the-supervisor-process>) exited before it accepted connections, so Claude Code couldn’t open your session. When the service printed an error before exiting, the reason in parentheses gives the exit code or signal and the first line the service printed, which names what stopped it:
@@ -5536,11 +4483,7 @@
* If the message quotes a line, fix what it names, then open the session or dispatch again. The next attempt starts the service again
* Run `claude daemon status` to check whether a service is running now
-###
-
-
-
-Working directory no longer exists when starting a background session
+### Working directory no longer exists when starting a background session
The directory you started a [background session](</docs/en/agent-view>) in was removed while the session was starting. Claude Code doesn’t start the session, and the message names the missing directory:
@@ -5550,11 +4493,7 @@
* Recreate the directory the message names, or dispatch from a directory that exists, then try again
-###
-
-
-
-This forked session could not be started
+### This forked session could not be started
You [forked a Remote Control session](</docs/en/remote-control#fork-a-session-from-your-browser>) from claude.ai, and Claude Code couldn’t finish starting the [background session](</docs/en/agent-view>) that runs the fork on your machine. This notice appears in the forked session’s transcript:
@@ -5564,11 +4503,7 @@
* Go back to the session you forked and fork it again once the session is idle
-###
-
-
-
-Workspace not trusted when dispatching a background session
+### Workspace not trusted when dispatching a background session
You started or restarted a [background session](</docs/en/agent-view>) in a directory you haven’t [trusted](</docs/en/permissions#project-allow-rules-and-workspace-trust>), and the workspace trust dialog couldn’t appear to ask you. Claude Code doesn’t start the session:
@@ -5585,19 +4520,11 @@
* For the home-directory message, run the command from a terminal in your home directory so the dialog can appear, or start the session from a project directory instead
* For the `could not be resolved on disk` message, recreate the directory, or start a new session from a directory that exists
-##
-
-
-
-Wrapper and IDE errors
+## Wrapper and IDE errors
These errors come from the program that launched Claude Code for you, such as an IDE extension or an [Agent SDK](</docs/en/agent-sdk/overview>) application, rather than from Claude Code itself.
-###
-
-
-
-Claude Code process exited with code N
+### Claude Code process exited with code N
The underlying `claude` process exited with a non-zero code. The exit code alone doesn’t say what failed: the real error is in the process’s own output, which the wrapper appends when it captured any and otherwise keeps in its logs.
@@ -5610,11 +4537,7 @@
* Run `claude` in a terminal in the same project. The failure usually reproduces there with its real error message, which you can then look up on this page.
* Run `claude doctor` in a terminal to check the installation and configuration
-###
-
-
-
-Could not locate the Claude CLI on PATH
+### Could not locate the Claude CLI on PATH
The [VS Code extension](</docs/en/vs-code>) shows this error on Windows when you open Claude Code in the integrated terminal, the terminal’s shell is PowerShell, and the extension can’t find the installed `claude` executable on PATH. The extension refuses to launch Claude Code until it finds the installed `claude` on PATH.
@@ -5626,11 +4549,7 @@
* Set the PATH entry as a user or system environment variable, not in your PowerShell profile. The extension doesn’t run your profile, so a PATH edit that lives only there never reaches it.
* Restart VS Code after changing PATH. The extension checks the PATH that VS Code captured at startup, so a PATH change takes effect only after a restart.
-###
-
-
-
-The Claude Code program for this computer could not be found
+### The Claude Code program for this computer could not be found
The [VS Code extension](</docs/en/vs-code>) looked for the copy of Claude Code bundled inside it and found none built for your computer. The message names the build your computer needs:
@@ -5644,11 +4563,7 @@
Before v2.1.290, this appeared as `Unsupported platform: <platform>-<arch>. No compatible Claude Code binary found.`
-###
-
-
-
-The connection to Claude Code ended before this message completed
+### The connection to Claude Code ended before this message completed
The [VS Code extension](</docs/en/vs-code>) sent your message to the `claude` process, and the connection ended without an error before the process acknowledged or finished it. The extension can’t tell whether the message was processed, so it asks you to send it again:
@@ -5659,19 +4574,11 @@
* Send the message again. The next message starts a fresh `claude` process that resumes the conversation.
* If it repeats, run `claude` in a terminal in the same project. A failure that keeps ending the process usually reproduces there with its real error message.
-##
-
-
-
-Rewind warnings and errors
+## Rewind warnings and errors
These messages come from a [`/rewind`](</docs/en/checkpointing>) code restore. `Restored the code, but skipped N files` is a warning that Claude Code skipped some paths. `No files were restored` is an error that means it restored nothing.
-###
-
-
-
-Restored the code, but skipped files
+### Restored the code, but skipped files
A `/rewind` code restore skipped one or more tracked paths instead of writing or deleting through them. Claude Code skips a path when:
@@ -5689,11 +4596,7 @@
* If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
* If you didn’t create the link, inspect the path before trusting its contents
-###
-
-
-
-No files were restored
+### No files were restored
Claude Code shows this message when you restore code with [`/rewind`](</docs/en/checkpointing>) and it can’t restore any of the files in that checkpoint. For each file, either the backup Claude Code saved before editing it is missing, or Claude Code couldn’t write to or delete the file.
@@ -5708,19 +4611,11 @@
Before v2.1.260, Claude Code silently skipped files whose backups were missing, and the rewind appeared to succeed.
-##
-
-
-
-Session saving warnings
+## Session saving warnings
Claude Code shows these warnings on a persistent line below the input box when it isn’t saving your session transcript. The session keeps working either way; the warnings tell you the session may be missing from [`--resume`](</docs/en/sessions>) later.
-###
-
-
-
-Transcript writes are failing
+### Transcript writes are failing
Claude Code saves the transcript to disk as you work, and its writes to [the transcript file](</docs/en/sessions#where-transcripts-are-stored>) are failing. The message names the cause with the underlying error code, for example a full disk:
@@ -5737,11 +4632,7 @@
* The warning clears on its own at the next successful write; no restart is needed
* Messages sent while the warning was showing may still be missing when you resume the session later
-###
-
-
-
-Transcript saving is off because CLAUDE_CODE_SKIP_PROMPT_HISTORY is set
+### Transcript saving is off because CLAUDE_CODE_SKIP_PROMPT_HISTORY is set
This session started with [`CLAUDE_CODE_SKIP_PROMPT_HISTORY`](</docs/en/env-vars>) set, so Claude Code writes no transcript or prompt history for it:
@@ -5752,11 +4643,7 @@
* If you set the variable on purpose, no action is needed; the notice confirms the session won’t appear in `--resume`, `--continue`, or up-arrow history
* If you didn’t, remove the variable from the shell or script that launches `claude`, then start a new session. Messages from the current session aren’t saved retroactively.
-###
-
-
-
-Transcript saving is off because of an inherited CLAUDE_CODE_CHILD_SESSION marker
+### Transcript saving is off because of an inherited CLAUDE_CODE_CHILD_SESSION marker
Claude Code sets [`CLAUDE_CODE_CHILD_SESSION`](</docs/en/env-vars>) in the subprocesses it spawns, and treats an interactive session that inherits it as nested: Claude Code saves no transcript for it, so sessions that Claude itself starts don’t fill your `--resume` list. This notice means your current session inherited the marker:
@@ -5768,11 +4655,7 @@
* If this is a top-level session, exit and restart with [`CLAUDE_CODE_FORCE_SESSION_PERSISTENCE=1`](</docs/en/env-vars>) set. Saving applies from the restart, so messages sent before it aren’t saved.
* To fix future launches from the same terminal or launcher, remove `CLAUDE_CODE_CHILD_SESSION` from its environment
-##
-
-
-
-Configuration warnings
+## Configuration warnings
To find a warning that Claude Code gave at startup in an interactive session, look below the startup banner first, then in the debug log:
@@ -5781,11 +4664,7 @@
In [non-interactive mode](</docs/en/headless>) with text output, outside a [background session](</docs/en/agent-view>), look for startup warnings on stderr. Before v2.1.305, look on stderr in an interactive session as well, including for the permission-rule warnings that now show as rows below the banner.
-###
-
-
-
-Claude Code exited after an unrecoverable interface error
+### Claude Code exited after an unrecoverable interface error
Claude Code prints this message when it exits because its terminal interface hit an error it can’t recover from, in either renderer. The second sentence appears only when the error happened while the [fullscreen](</docs/en/fullscreen>) renderer was starting:
@@ -5798,11 +4677,7 @@
Before v2.1.236, Claude Code exited without printing a message after this kind of error.
-###
-
-
-
-Agent descriptions are over the 15.0k-token limit
+### Agent descriptions are over the 15.0k-token limit
Claude Code shows this warning as a startup notice in the conversation view rather than on stderr. The combined descriptions of your [subagents](</docs/en/sub-agents>), except the built-in ones, exceed 15,000 tokens as Claude Code estimates them. Each agent counts its name plus its `description` frontmatter. Claude Code loads every agent whether or not the total is over the limit, so the warning doesn’t change what loads.
@@ -5813,11 +4688,7 @@
* Shorten the `description` frontmatter of your agent files, or ask Claude to trim them for you.
* Remove agent files you no longer use.
-###
-
-
-
-Hook needs quotes around a path with a space
+### Hook needs quotes around a path with a space
This notification in the conversation view means a hook’s script didn’t run because its path has a space and isn’t quoted. That hook is an [`asyncRewake`](</docs/en/hooks#run-hooks-in-the-background>) hook in shell form. In its `command`, an interpreter such as `python3` is followed by an unquoted path placeholder, and the resolved path contains a space. The notification starts with the hook’s event name and names the script:
@@ -5827,11 +4698,7 @@
* In the `command` of the hook that runs the script the notification names, wrap the path in double quotes. In a JSON file, write it as `"command": "python3 \"${CLAUDE_PLUGIN_ROOT}/hooks/check.py\""`.
-###
-
-
-
-Instruction file not loaded
+### Instruction file not loaded
This notice in the conversation view of an interactive session means a [memory file](</docs/en/memory#how-claude-md-files-load>) that exists wasn’t loaded. A read restriction is in force.
@@ -5853,11 +4720,7 @@
Before v2.1.292, the notice named the file at the end of the same line after the reason.
-###
-
-
-
-A skill, command, or workflow wasn’t loaded because its name is reserved
+### A skill, command, or workflow wasn’t loaded because its name is reserved
A skill folder, a frontmatter `name`, a file or subfolder in `.claude/commands/`, or a [saved workflow](</docs/en/workflows#save-the-workflow-for-reuse>) uses the name `anthropic-skills` or a name that starts with `anthropic-skills:`. Claude Code [reserves that name for skills synced from claude.ai](</docs/en/skills#names-reserved-for-synced-skills>) and doesn’t load that item. Claude Code shows this warning as a startup notice in the conversation view rather than on stderr:
@@ -5869,11 +4732,7 @@
Before v2.1.282, Claude Code loaded skills and commands with these names.
-###
-
-
-
-Skill or command name refused
+### Skill or command name refused
This startup notice means Claude Code refused the name of at least one [skill or custom command](</docs/en/skills>), so it didn’t load or loaded without its `name` field:
@@ -5887,11 +4746,7 @@
* Start Claude Code with `claude --debug` from your shell and search the [debug log](</docs/en/debug-your-config>) for `[names]`. Each name the notice counts has one line there. The line spells out some hidden characters as codes, such as `\u{200B}` for a zero-width space, so you can see where they are.
* Remove the [characters a skill name can’t hold](</docs/en/skills#characters-a-skill-name-cant-hold>) by renaming the folder or file or editing the `name:` line, or shorten a name that is over 256 characters. Then restart the session, unless the file is in a directory Claude Code [watches for changes](</docs/en/skills#live-change-detection>). For a skill from a plugin you didn’t write, ask the plugin’s author to rename it.
-###
-
-
-
-Workspace has not been trusted
+### Workspace has not been trusted
Claude Code found `permissions.allow` rules or `permissions.additionalDirectories` entries in the project’s `.claude/settings.json` or `.claude/settings.local.json` and didn’t apply them, because [allow rules from project settings require workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>). The count, the setting name, and the file named in the message vary with your configuration. `deny` and `ask` rules aren’t affected.
@@ -5903,11 +4758,7 @@
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
* If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
-###
-
-
-
-Working directory is a network path
+### Working directory is a network path
Claude Code doesn’t add network paths as working directories. Looking up a network path can contact the host it names, and on Windows that contact can send the host your credentials. Claude Code therefore refuses the path without looking it up. You see this message when you run `/add-dir` with a network path:
@@ -5927,11 +4778,7 @@
Before v2.1.257, Claude Code accepted a reachable network path as a working directory.
-###
-
-
-
-Remote managed settings failed to load
+### Remote managed settings failed to load
Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them or couldn’t apply what the server returned, so it shows this warning in interactive sessions and in Claude Desktop’s Code tab. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`. The cause `no setting in the server response could be applied as written` means the server answered but none of the settings it returned passed [validation](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>). Before v2.1.282, this cause read `server returned invalid settings`. The rest of the line says which policy the session runs on:
@@ -5952,11 +4799,7 @@
Before v2.1.248, Claude Code reported a failed settings fetch only in the debug log.
-###
-
-
-
-Claude Code couldn’t load your organization’s settings
+### Claude Code couldn’t load your organization’s settings
Your session hasn’t started because your organization’s settings, including its [server-managed settings](</docs/en/server-managed-settings>), have to load first and Claude Code couldn’t load them. For example:
@@ -5970,11 +4813,7 @@
* **`Your Claude session has expired`** : the sign-in stored on this machine is no longer valid, so retrying won’t help. In the dialog, select **Sign in again** to close Claude Code; then, in your shell, run `claude auth login`, which works even while sessions can’t start.
* **`none of the settings the server returned could be applied as written`** : ask your administrator to correct the organization’s [server-managed settings](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>), then retry.
-###
-
-
-
-Managed settings were not approved
+### Managed settings were not approved
Your organization’s [server-managed settings](</docs/en/server-managed-settings>) include settings that need your approval, and you declined the [security approval dialog](</docs/en/server-managed-settings#security-approval-dialogs>), so Claude Code exits without applying them:
@@ -5985,11 +4824,7 @@
* Start Claude Code again and approve the dialog to continue under your organization’s settings. A declined dialog isn’t remembered, so it appears again at the next start.
* If you’re unsure about a setting the dialog lists, ask whoever maintains your organization’s managed settings before approving
-###
-
-
-
-Managed settings need your approval
+### Managed settings need your approval
Your organization’s [server-managed settings](</docs/en/server-managed-settings>) include settings that need your approval in the [security approval dialog](</docs/en/server-managed-settings#security-approval-dialogs>). The `claude plugin` command you ran couldn’t read from the keyboard, so it couldn’t show that dialog. That happens when you pipe or redirect its input and, on macOS and Linux, it also can’t open `/dev/tty`. The command stopped before making any changes:
@@ -5999,11 +4834,7 @@
* Run `claude` in a terminal and approve the settings when the dialog appears, then run the same `claude plugin` command again. Claude Code keeps the approval and the approved settings in your [configuration directory](</docs/en/server-managed-settings#approval-memory>). If the command that stopped ran as another user or with `CLAUDE_CONFIG_DIR` set, run `claude` the same way so that both use the same directory.
-###
-
-
-
-Managed settings block the default model
+### Managed settings block the default model
Your organization’s [managed settings](</docs/en/managed-settings>) block the model the Default option resolves to and every model it could step down to. A session that would start on the Default option exits at startup instead of running a blocked model. Which message you see depends on the setting that blocks it. When a [`deniedModels`](</docs/en/model-config#block-specific-models-or-versions>) list blocks it, the message reads:
@@ -6018,11 +4849,7 @@
* If you administer the settings, add a model your users can run to `availableModels`, or narrow the `deniedModels` entries that block every fallback. [Block specific models or versions](</docs/en/model-config#block-specific-models-or-versions>) describes how the Default option steps down
* If you don’t administer them, send the message to your administrator. Your own settings files can’t widen a managed `availableModels` or `deniedModels` list
-###
-
-
-
-Managed settings don’t allow this API provider
+### Managed settings don’t allow this API provider
Your organization’s [managed settings](</docs/en/managed-settings>) set an [`allowedProviders`](</docs/en/settings-reference#allowedproviders>) list, and the session’s API provider isn’t on it or the session uses an endpoint that isn’t pinned the way that entry requires. Claude Code refuses at startup, before a login, or when the session next contacts the API. The message begins with the permitted providers:
@@ -6037,11 +4864,7 @@
* Follow the message’s `To continue:` steps
* If you administer the settings, the message’s lines starting `Admins:` name the entry to add or the value to pin, and the [`allowedProviders`](</docs/en/settings-reference#allowedproviders>) entry says which source’s `env` block can pin it
-###
-
-
-
-MCP server is blocked by enterprise managed policy
+### MCP server is blocked by enterprise managed policy
You selected **Reconnect** on a server in `/mcp`, or turned a disabled server back on there, and a setting that [restricts MCP servers](</docs/en/managed-mcp>) blocks that server. Claude Code refuses to connect it and shows:
@@ -6061,11 +4884,7 @@
Before v2.1.257, **Reconnect** and re-enable in `/mcp` could connect a server that a mid-session policy update blocked.
-###
-
-
-
-MCP server name is reserved
+### MCP server name is reserved
This message names one of your MCP servers, whose name is among those Claude Code reserves, such as the names of its built-in servers:
@@ -6076,11 +4895,7 @@
* Rename the server where you define it, for example from `workspace` to `my-workspace`
* For other reserved names to avoid, see [MCP configuration warnings](</docs/en/mcp#configuration-warnings>)
-###
-
-
-
-Managed settings document could not be parsed
+### Managed settings document could not be parsed
Your organization deploys [managed settings](</docs/en/managed-settings>), and one of the deployed documents is present but can’t be parsed as a JSON object, so Claude Code exits with code 1 at startup instead of running without the policy the document carries. The line names the failed source before the message:
@@ -6097,11 +4912,7 @@
* If you administer the machine, fix the named document so it parses as a JSON object, or remove the file, profile, or registry value. An empty `managed-settings.json` counts as `{}` and doesn’t block launch.
* If you don’t, ask your administrator to fix the deployed document. Nothing in your own settings files causes or clears this error.
-###
-
-
-
-Unable to read managed policy settings
+### Unable to read managed policy settings
Your organization deploys [managed settings](</docs/en/managed-settings>), and one of the deployed sources exists but couldn’t be read, for a reason such as an I/O error rather than the operating system denying the read. With no other admin source supplying a policy, Claude Code exits at startup rather than run without the policy the source may carry:
@@ -6118,11 +4929,7 @@
Before v2.1.285, only sessions signed in with claude.ai or Claude Console credentials exited with this message, and a read that the operating system denied produced it too.
-###
-
-
-
-Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded
+### Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded
This stderr block from a `-p` run means that a [managed settings](</docs/en/managed-settings>) source holds a hook entry Claude Code can’t load. That hook doesn’t run, and when a line lists the source’s `hooks` field as ignored, none of that source’s hooks run. Each line names the source, the field when there is one, and the problem, such as an unknown hook `type` or a hook declared outside the `hooks` key:
@@ -6137,11 +4944,7 @@
Before v2.1.300, a `-p` run listed this case under the `Managed settings failed to load; policies from the failed source are NOT in effect:` header.
-###
-
-
-
-otelHeadersHelper failed
+### otelHeadersHelper failed
Claude Code shows this warning as a notification in the terminal interface, once per interactive session, when the [`otelHeadersHelper`](</docs/en/settings-reference#otelheadershelper>) script fails or prints output that doesn’t meet the [script requirements](</docs/en/monitoring-usage#script-requirements>). While the script keeps failing, exports fail and your telemetry backend receives nothing from the session. The text after `See /status:` says what failed, such as the script’s exit code followed by its error output:
@@ -6155,11 +4958,7 @@
In [non-interactive mode](</docs/en/headless>) with `-p`, the same failure appears on stderr as `otelHeadersHelper failed (OpenTelemetry export headers unavailable): <error>` instead.
-###
-
-
-
-headersHelper not run
+### headersHelper not run
Claude Code connected an MCP server with its static `headers` alone and skipped the server’s [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>), because the helper is a shell command and the folder has no saved trust. A folder gets saved trust when you set its entry in `~/.claude.json` by hand or, outside your home directory, when you accept the trust dialog for it in an interactive session. See [Trust a folder before its headersHelper runs](</docs/en/mcp#trust-a-folder-before-its-headershelper-runs>) for which servers this check applies to. Claude Code writes this line in [non-interactive mode](</docs/en/headless>) only, once per server. In an interactive session it writes the same refusal to the debug log instead.
@@ -6171,11 +4970,7 @@
* Set the `hasTrustDialogAccepted` entry in `~/.claude.json` yourself, using the exact `projects` key the message prints
* If you started the session in your home directory, work from a project directory you have trusted. When you accept the trust dialog in your home directory, Claude Code holds that trust for the current session only.
-###
-
-
-
-Malformed Tool(content) rule
+### Malformed Tool(content) rule
A [permission rule](</docs/en/permissions#permission-rule-syntax>) in one of your settings files doesn’t have the shape `Tool` or `Tool(content)`, for example because text follows the closing parenthesis or one of the parentheses is missing. Claude Code skips the rule and lists it in the invalid-settings dialog when an interactive session starts, and in [`claude doctor`](</docs/en/debug-your-config#check-resolved-settings>) output:
@@ -6188,11 +4983,7 @@
Before v2.1.260, Claude Code reported a rule with unmatched parentheses as `Mismatched parentheses`.
-###
-
-
-
-Matches no tool · check for typos
+### Matches no tool · check for typos
This row below the startup banner names a deny or ask [permission rule](</docs/en/permissions>) whose tool name Claude Code doesn’t recognize, so the rule doesn’t apply to the tool you meant. A deny rule written as `Bsh` isn’t applied to Bash, and neither is one that uses the label a tool shows in the transcript instead of its canonical name. The row repeats the rule as you wrote it:
@@ -6210,11 +5001,7 @@
In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.305, an interactive session printed the longer form on stderr at startup instead of showing the row.
-###
-
-
-
-Is not matched by file permission checks
+### Is not matched by file permission checks
Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else.
@@ -6239,11 +5026,7 @@
Before v2.1.210, Claude Code accepted these rules without a warning. Before v2.1.305, an interactive session printed the full warning on stderr.
-###
-
-
-
-Has a wildcard before the rest of the command
+### Has a wildcard before the rest of the command
Claude Code found a `Bash` allow rule whose `*` comes before a later word that determines which command it is, such as `Bash(git * main)` or `Bash(git -C * status *)`, in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in an `--allowedTools` or `--settings` flag value. The `*` matches any text, including options inserted at that position: `Bash(git * main)` also approves `git -c core.fsmonitor=<script> diff main`, where `-c` makes git run a program the command names. [Wildcard patterns](</docs/en/permissions#wildcard-patterns>) shows the matching rules. The warning exists so you can narrow a rule whose wildcard is broader than you intended. Claude Code keeps the rule and changes nothing about how it matches. In [non-interactive mode](</docs/en/headless>) with text output, the warning on stderr names the rule and its source in parentheses:
@@ -6262,11 +5045,7 @@
In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning. Before v2.1.305, an interactive session printed the full warning on stderr instead of showing a row.
-###
-
-
-
-Denying Bash also turns off the PowerShell tool
+### Denying Bash also turns off the PowerShell tool
You removed the whole Bash tool, for example with `--disallowedTools Bash` or with a bare `Bash` or `Bash(*)` [deny rule](</docs/en/permissions#match-all-uses-of-a-tool>) in one of your settings files. On Windows with Git Bash installed, [denying Bash also turns the PowerShell tool off](</docs/en/tools-reference#bash-deny-rules-also-turn-off-the-powershell-tool>), so the session starts with no shell tool. In [non-interactive mode](</docs/en/headless>) with text output, Claude Code prints this warning on stderr at startup, and an interactive session writes it only to the debug log:
@@ -6279,11 +5058,7 @@
In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.287, Claude Code turned the PowerShell tool off the same way without printing a warning. Before v2.1.305, an interactive session printed the warning on stderr at startup too.
-###
-
-
-
-crossSessionInbound must be one of accept, hold, refuse
+### crossSessionInbound must be one of accept, hold, refuse
A settings file sets [`crossSessionInbound`](</docs/en/settings-reference#crosssessioninbound>) to a value Claude Code doesn’t recognize, such as the typo `"reject"`. The warning’s second sentence depends on which file holds the value; in a user, project, local, or `--settings` file it reads:
@@ -6296,11 +5071,7 @@
Before v2.1.248, Claude Code ignored an unrecognized value without warning.
-###
-
-
-
-ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name
+### ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name
You set [`ANTHROPIC_FOUNDRY_RESOURCE`](</docs/en/env-vars>) to something other than a bare [Microsoft Foundry](</docs/en/microsoft-foundry>) resource name, such as the endpoint URL or its host name. Claude Code refused the value before sending a request. The message appears in place of Claude’s reply, not as a startup warning:
@@ -6311,11 +5082,7 @@
* Set `ANTHROPIC_FOUNDRY_RESOURCE` to the resource name alone and restart Claude Code. For the endpoint `https://my-resource.services.ai.azure.com/anthropic`, the name is `my-resource`.
* To give the full endpoint URL instead, set [`ANTHROPIC_FOUNDRY_BASE_URL`](</docs/en/env-vars>) to the URL and remove `ANTHROPIC_FOUNDRY_RESOURCE`, then restart Claude Code. Claude Code accepts only one of the two variables.
-###
-
-
-
-The 200K limit isn’t enforced
+### The 200K limit isn’t enforced
You set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>), which normally makes [auto-compaction](</docs/en/model-config#default-auto-compact-thresholds>) hold sessions on 1M-context models to a 200K window, but no compaction threshold caps this session at or below 200K, so the conversation can grow past it.
@@ -6334,11 +5101,7 @@
In [non-interactive mode](</docs/en/headless>) with text output, this warning appears on stderr. In an interactive session, a [background session](</docs/en/agent-view>), or with `--output-format json` or `stream-json`, it goes to the debug log instead. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.305, an interactive session printed the warning on stderr at startup.
-###
-
-
-
-Unrecognized model ID on a request
+### Unrecognized model ID on a request
Claude Code sent a request for a model ID that your Claude Code version doesn’t recognize, and found no [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry that maps that ID to a model it does recognize. Claude Code still sends the request with the ID as you configured it, and doesn’t exit or switch models.
@@ -6370,11 +5133,7 @@
Before v2.1.233, Claude Code wrote no line when it sent a request for a model ID it didn’t recognize.
-###
-
-
-
-Sandbox allow entries are ignored under a managed lock
+### Sandbox allow entries are ignored under a managed lock
This warning in `/status` and `claude doctor` means managed settings set [`allowManagedReadPathsOnly`](</docs/en/settings-reference#sandbox-filesystem-allowmanagedreadpathsonly>) or [`allowManagedDomainsOnly`](</docs/en/settings-reference#sandbox-network-allowmanageddomainsonly>), so the [`allowRead`](</docs/en/settings-reference#sandbox-filesystem-allowread>) or [`allowedDomains`](</docs/en/settings-reference#sandbox-network-alloweddomains>) entries in the file it names don’t apply:
@@ -6386,11 +5145,7 @@
* If you need those paths or domains and your organization’s managed settings set the lock, ask your administrator to add them to those settings. The warning stays until you also remove the entries from the named file.
* To clear the warning, remove the entries from the named file. For a file you share, such as a project’s `.claude/settings.json`, you can leave the entries in for teammates without the lock and leave the warning showing.
-###
-
-
-
-Sandbox mask files left behind at write-deny paths
+### Sandbox mask files left behind at write-deny paths
This warning in `claude doctor` and `/status` lists mask files: 0-byte read-only placeholder files at paths the [sandbox](</docs/en/sandboxing>) denies writes to. It appears on Linux and WSL2 when sandboxing is enabled with filesystem isolation on. Delete them from your shell once no Claude Code session is open in the project that holds them. The sandbox creates a placeholder while a sandboxed command runs and removes it when the command ends. One stays behind in cases such as these:
@@ -6410,11 +5165,7 @@
Before v2.1.309, the warning read `Stale sandbox mask files left by a killed session`. Before v2.1.257, `claude doctor` didn’t flag these files; earlier versions leave the same placeholders behind when a session is killed.
-###
-
-
-
-Two Claude Code config files exist
+### Two Claude Code config files exist
Claude Code is using the first file this message names, so what’s in the second file isn’t in effect. The first is `.config.json`, an older name for [`.claude.json`](</docs/en/claude-directory#ce-claude-json>). The message includes a check for which file holds your setup:
@@ -6455,11 +5206,7 @@
The message stops once one of the two files is gone.
-###
-
-
-
-Make this change again later: ~/.claude.json could not be updated
+### Make this change again later: ~/.claude.json could not be updated
This notice on stderr means a change to [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>), such as a sign-in or an answer to a trust prompt, wasn’t saved to the file:
@@ -6469,11 +5216,7 @@
* Make the change again in a later session. For example, run `/login` again or answer the trust prompt again.
-##
-
-
-
-Responses seem lower quality than usual
+## Responses seem lower quality than usual
If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code doesn’t silently change model versions. It can switch to a fallback model in these cases:
@@ -6490,11 +5233,7 @@
When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment. If Claude warns about a suspected prompt injection, or refuses a request because of a suspected injection, and the text the warning names is context Claude Code adds to the conversation automatically rather than file or web content, run `claude update` and retry. If the warning repeats after updating, report it rather than pasting the flagged content back into the prompt. Before v2.1.201, Sonnet 5 refused some requests the same way.
-##
-
-
-
-Report an error
+## Report an error
For errors from components this page doesn’t cover, see the relevant guide:
--- a/errors.md
+++ b/errors.md
@@ -2230,7 +2230,7 @@
**What to do:**
* **Not signed in** : the message continues `: not signed in. Run /login, then retry.` Run `/login`, then send again
- * **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` If the message adds `To report a bug, open an issue`, do so at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). `/feedback` can then answer that it’s disabled by your organization’s policy for seven days. A queued draft stays queued and still [expires on schedule](</docs/en/tools-reference#discard-or-keep-a-draft>)
+ * **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` `/feedback` can then answer that it’s disabled by your organization’s policy for seven days. A queued draft stays queued and still [expires on schedule](</docs/en/tools-reference#discard-or-keep-a-draft>)
* **Refused credentials** : the message continues `: the sign-in this session uses is not allowed to send feedback` or `: the server did not accept the credentials this session uses`. Run `/status` at the Claude Code prompt to see which login, token, or API key this session sends
* **`(request timed out)` or `(couldn't reach the service)` straight after `Couldn't send feedback`**: send the report or the queued draft again. The dialog keeps your text, and a queued draft’s message says `The draft is still queued.` If other requests are failing too, check your network connection and see Unable to connect to API. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
* **`(server returned<status>)`, or no reason, straight after `Couldn't send feedback`**: the status is the service’s response code. The service’s own message follows it when one was sent, as in `(server returned 403: Access Forbidden)`. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
@@ -6433,7 +6433,7 @@
Update every host that shares the home directory
-If several hosts share this home directory, first update Claude Code on every host to the version the message names or later. An older version can write a moved `.config.json` back.
+If several hosts share this home directory, first update Claude Code on every host to the version the message names or later.
3
Show diff (270 lines)
--- a/errors.md
+++ b/errors.md
@@ -96,6 +96,8 @@
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`Could not refresh your login because another Claude Code process is refreshing it`| Authentication
`Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh`| Authentication
+`Could not refresh your login: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
+`Failed to refresh OAuth token: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full`| Authentication
`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
@@ -314,6 +316,7 @@
`The packages it lists are not installed` / `The packages it lists were not installed, because`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#the-packages-it-lists-are-not-installed>)
`does not load (...), so Claude Code ignores the whole file`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#does-not-load-so-claude-code-ignores-the-whole-file>)
`path escapes plugin directory`| Plugin errors
+`path not read: <path> is absolute or has a ".." part`| Plugin errors
`Plugin not loaded: its manifest <path> was not read`| Plugin errors
`path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
@@ -362,6 +365,7 @@
`Refusing to write <path>: where it leads on disk could not be determined` / `Refusing to read <path>: where it leads on disk could not be determined`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
+`The search failed, so this is not a "no matches" result: matches may exist`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
`Command killed: its output file was replaced or could no longer be verified`| Tool errors
`Disk full: this computer's volume holding <dir> (Claude Code's temporary directory) has <n> MB free` / `Nearly out of inodes: this computer's volume holding <dir>`| Tool errors
@@ -371,6 +375,7 @@
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`git is not installed on this Mac. To install it, run xcode-select --install, then try again.`| Tool errors
+`Refusing to apply edits to <path>: a hook is configured for file edits in this session`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
@@ -381,7 +386,7 @@
`The safety check for domain ... is rate-limited`| Tool errors
`The safety check for domain ... is temporarily rate-limited`| Tool errors
`Unable to verify if domain ... is safe to fetch`| Tool errors
-`MCP tool "<tool>" on server "<server>" gave no answer that could be read` / `answered without its text`| [How an MCP tool hook’s result is read](</docs/en/hooks#how-the-tool%E2%80%99s-result-is-read>)
+`MCP tool "<tool>" on server "<server>" gave no answer that could be read` / `answered without its text`| [How an MCP tool hook’s result is read](</docs/en/hooks#how-the-tools-result-is-read>)
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -392,6 +397,7 @@
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
+`This forked session could not be started. Fork the conversation again to retry.`| Background session errors
`Bypass permissions was requested at launch and ignored`| [Bypass permissions ignored in a background session](</docs/en/permission-modes#bypass-permissions-ignored-in-a-background-session>)
`kept <id> — its worktree is still at <path>`| Background session errors if the message’s next line mentions unpushed commits, otherwise [What deleting a session removes](</docs/en/agent-view#what-deleting-a-session-removes>)
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
@@ -557,12 +563,24 @@
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
+`CLAUDE_CODE_RETRY_WATCHDOG_MAX_USAGE_LIMIT_WAIT_MS`| no cap| With `CLAUDE_CODE_RETRY_WATCHDOG` set, the longest time in milliseconds one request waits for your plan’s usage limit, such as the session or weekly limit, to reset. When the reset is further away than this cap, the request fails at once, unless usage credits have room or the API couldn’t check them. In those cases it’s retried, and fails if the cap passes before it succeeds. Requires Claude Code v2.1.301 or later.
[`CLAUDE_CODE_RETRY_WATCHDOG_USAGE_LIMIT_RECHECK_MS`](</docs/en/env-vars>)| unset| Minimum interval in milliseconds between checks of whether a usage limit was already lifted, while a request waits for that limit to reset with `CLAUDE_CODE_RETRY_WATCHDOG` set. When a check finds the limit lifted, the request goes out at once. Give plain digits from `60000` to `10800000`. When unset or outside that range, no checks are made. For when Claude Code skips these checks, see the [environment variables reference](</docs/en/env-vars>). Requires Claude Code v2.1.305 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 64000, so that later retries keep spreading apart when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.296 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Time in milliseconds that each request attempt has to receive its response headers. It doesn’t limit how long a streaming response runs after that. Raise it for slow networks or proxies. For how it caps the first-byte deadline, see No response from API.
-[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
+[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. For each attempt’s timeout, see How long a non-streaming attempt waits. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
+
+####
+
+
+
+How long a non-streaming attempt waits
+
+A non-streaming attempt ends at its request timeout or at the body idle timeout, whichever comes first:
+
+ * **Request timeout** : `API_TIMEOUT_MS` when you set a positive value, otherwise 300 seconds in a local session.
+ * **[Body idle timeout](</docs/en/network-config#streaming-idle-watchdogs>)** : 5 to 6 minutes without a response, however high you set `API_TIMEOUT_MS`, where it runs and you haven’t turned it off.
##
@@ -1408,6 +1426,25 @@
+Could not refresh your login: the disk that holds the Claude Code config directory is full
+
+Free space on the disk that holds the Claude Code config directory, then send your message again. Signing in wouldn’t help while the disk is full, because a new login couldn’t be saved. The config directory is `~/.claude` in your home directory unless you set [`CLAUDE_CONFIG_DIR`](</docs/en/env-vars>).
+
+ Could not refresh your login: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full · Delete files you no longer need on that disk, then try again · Signing in again won't help
+
+In [non-interactive mode](</docs/en/headless>) (`-p`) and the [Agent SDK](</docs/en/agent-sdk/overview>), the message reads:
+
+ Failed to refresh OAuth token: the disk that holds the Claude Code config directory (~/.claude by default), or your disk quota on it, is full. Delete files you no longer need on that disk and retry; signing in again won't help
+
+**What to do:**
+
+ * For a script, rerun its `claude -p` command
+ * If the disk already shows free space, running out of disk quota or of inodes produces the same message. Delete your own files on that disk. If the message returns, delete many small files rather than a few large ones, because each file takes one inode whatever its size.
+
+###
+
+
+
Couldn’t save your login
You signed in with claude.ai, but Claude Code couldn’t save the login to its credential store, so the login didn’t complete. On macOS this can happen when the login keychain locks, for example on sleep or idle, after Claude Code has already read or saved credentials in it during the same session.
@@ -2061,12 +2098,12 @@
You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This error is not a client-side network problem. Cloud sessions and [cloud scheduled tasks](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist:
* **GitHub and connector traffic** : [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked
- * **Default environment** : the **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path
+ * **Default environment** : the **Default** environment uses **Limited** access with **Allow package managers** checked. Its sessions reach the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains.
**What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
* Open your environment for editing, either from the [cloud scheduled task’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
- * In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * In the **Edit cloud environment** dialog, select **Limited** under **Network access** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Allow package managers** to allow the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your own domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -2300,17 +2337,22 @@
Context exceeds the token limit
-`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window. Requests fail with `Prompt is too long` until you free space. An interactive session shows that error as the `Context limit reached` line.
+`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window:
Context exceeds the 200k-token limit by 94k tokens — run /compact or /clear to continue.
+After a `Context exceeds` warning, you don’t need to run either command while [auto-compact](</docs/en/settings-reference#autocompactenabled>) is on, which is the default:
+
+ * **Auto-compact on** : send your next message. If it still fails with `Prompt is too long`, see that entry.
+ * **Auto-compact off** : in the session, run `/compact` if the warning names it, or `/clear` to start over. Until you run one, messages fail with `Context limit reached`, or `Prompt is too long` in `-p` output.
+
When the limit you exceeded is a compaction window, such as the 200K boundary on 1M-context models, the warning reads differently. A compaction window can sit below the model’s context window, so requests past it can still succeed.
Context is 94k tokens past the 200k-token compaction window — run /compact to reduce usage.
Both forms name `/clear` instead of `/compact` when you have set [`DISABLE_COMPACT`](</docs/en/env-vars>). **What to do:**
- * In a multi-turn conversation, run `/compact` to summarize earlier turns and free space. To start fresh instead, run `/clear`
+ * **After a compaction-window warning** : in a multi-turn conversation, run `/compact` to summarize earlier turns and free space. To start fresh instead, run `/clear`.
* For more ways to reduce usage, see Prompt is too long
Before v2.1.216, `/context` showed usage above 100% with no warning line explaining what that meant or how to recover.
@@ -3138,7 +3180,7 @@
Configuration error in ~/.claude.json
-Claude Code couldn’t parse `~/.claude.json`, the file that holds your account details, MCP servers, and per-project state. Your file is unchanged. A [non-interactive](</docs/en/headless>) start such as `claude -p` exits with code 1 each time until you repair the file. When Claude Code finds a [backup](</docs/en/claude-directory#cleaned-up-automatically>), the output names it and prints a `cp` line that copies it back:
+Claude Code couldn’t parse `~/.claude.json`, the file that holds your account details, MCP servers, and per-project state. A [non-interactive](</docs/en/headless>) start such as `claude -p` exits with code 1. When Claude Code finds a [backup](</docs/en/claude-directory#cleaned-up-automatically>), the output names it and prints a `cp` line that copies it back:
Claude configuration file at /home/user/.claude.json is corrupted: <JSON parser's message>
The corrupted file has been backed up to: /home/user/.claude/backups/.claude.json.corrupted.1793664000000
@@ -3149,10 +3191,9 @@
**What to do:**
- * **The output has a`cp` line**: run that line in your terminal. On Windows, run it in PowerShell. It replaces the broken file with the backup, an earlier version of `~/.claude.json`.
- * **The output has no`cp` line, or the error returns after you run it**: fix the JSON in `~/.claude.json`, copy another `.claude.json.backup.<timestamp>` file from [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) over it if there is one, or rename it. With no file at `~/.claude.json`, Claude Code starts with default settings and none of what the file held.
-
-Before v2.1.318, you were left with defaults in `~/.claude.json` after a non-interactive start printed this error, so the next start ran without your configuration.
+ * **The output has a`cp` line**: run that line in your terminal. On Windows, run it in PowerShell.
+ * **The output has no`cp` line, or the error returns after you run it**: if `~/.claude.json` still has your configuration, fix its JSON. If you can’t, copy another `.claude.json.backup.<timestamp>` file from [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) over it if there is one, or rename it. With no file at `~/.claude.json`, Claude Code starts with default settings and none of what the file held.
+ * **`~/.claude.json` no longer has your configuration**: find a `.claude.json.corrupted.<timestamp>` file that still has it, in [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) or your home directory. Fix its JSON, then copy it over `~/.claude.json`. If you can’t find or fix one, try the same steps with a `.claude.json.backup.<timestamp>` file that has your configuration. If none does, rename `~/.claude.json` and add your MCP servers again with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>).
###
@@ -3358,7 +3399,7 @@
* You haven’t started a session since installing, so Claude Code hasn’t fetched the flag yet. The first `claude import` can print this even when the feature is available to you.
* You use Claude Code through Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or Claude Platform on AWS, or through a [Claude apps gateway](</docs/en/claude-apps-gateway#availability-and-limitations>). Claude Code doesn’t fetch feature flags in these sessions, so `claude import` stays unavailable.
- * You set `DISABLE_TELEMETRY`, `DO_NOT_TRACK`, `DISABLE_GROWTHBOOK`, or [`CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`](</docs/en/env-vars>), which turn off feature-flag fetching, so `claude import` stays unavailable.
+ * You set `DISABLE_TELEMETRY`, `DO_NOT_TRACK`, [`CLAUDE_CODE_DISABLE_FEATURE_FLAGS`](</docs/en/env-vars#variables>), `DISABLE_GROWTHBOOK`, or [`CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`](</docs/en/env-vars>), which turn off feature-flag fetching, so `claude import` stays unavailable.
**What to do:**
@@ -4309,6 +4350,22 @@
* If the message says a path the plugin declares contains a backslash, write the path with forward slashes, for example `./commands/deploy.md`
* If the message ends with `EACCES`, restore your execute permission on every directory leading to the file or folder the path names. Check the directories above the path, then follow each symlink you reach and check the directories leading to where it points. For any other error code, look it up in the causes and steps for a path that couldn’t be checked.
* To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
+
+###
+
+
+
+Server file path not read
+
+The `path not read` message means Claude Code didn’t read an MCP or LSP server file that a plugin names, because of the file’s path. The rest of the plugin loads, without the servers the file defines. A `..` part counts even when the path stays inside the plugin, as in this example:
+
+ mcp-servers path not read: ./sub/../x.json is absolute or has a ".." part
+
+**What to do:**
+
+ * If you installed the plugin and don’t maintain it, report the message to its author
+ * If you maintain the plugin, keep the server file inside the plugin directory. Name it in the manifest or marketplace entry with a path that starts with `./` and has no `..`, for example `./servers/x.json`
+ * To share one server file between plugins in the same marketplace, link the file into each plugin with a symlink, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
###
@@ -4930,6 +4987,25 @@
+The search failed, so this is not a “no matches” result
+
+A [Grep](</docs/en/tools-reference#grep-tool-behavior>) or [Glob](</docs/en/tools-reference#glob-tool-behavior>) search Claude ran failed before returning any result, so whether matches exist is unknown. The message Claude receives in place of results starts:
+
+ The search failed, so this is not a "no matches" result: matches may exist. What happened to the search program (ripgrep) is not known, and no results were read. Run the search once more. If it fails again, tell the user that searches are failing.
+
+**What to do:**
+
+ * **The first time it appears** : nothing. The message asks Claude to search again first.
+ * **If Claude says searches are failing** : capture ripgrep’s error for a bug report:
+ 1. From your shell, start a session with the same flags as the session where searches failed, plus [`--debug-file claude-debug.log`](</docs/en/cli-reference#cli-flags>)
+ 2. Send Claude the request that led to the failed search
+ 3. If the search fails again, find the line containing `rg error (signal=` in `claude-debug.log`
+ 4. Include that line when you report the problem
+
+###
+
+
+
Task output swap refused
Claude Code saves each Bash command’s output to a file under its temp directory. Every time it opens one of these files, it checks that the path still leads to the file it created, with no symbolic link, extra hard link, or moved directory redirecting it. This message means that check failed, so Claude Code refused the operation rather than write or read output through that path. The message appears in the Bash tool result:
@@ -5014,6 +5090,23 @@
+Refusing to apply edits: a hook is configured for file edits in this session
+
+Claude tried to publish an [artifact](</docs/en/artifacts>) with a [one-step update](</docs/en/artifacts#turn-off-one-step-artifact-updates>), a small change to the artifact’s file included in the publish, and Claude Code refused. Nothing was published and the file is unchanged. The message appears in the Artifact tool result:
+
+ Refusing to apply edits to <path>: a hook is configured for file edits in this session, so a publish can't apply edits here. Edit the file, then publish it without edits. Nothing was published.
+
+Claude Code doesn’t allow one-step updates while your session has a [`PreToolUse` hook](</docs/en/hooks#pretooluse>) or [mod](</docs/en/plugins/mods/overview>) on `Edit` or `Write`. **What to do:**
+
+ * Nothing, if Claude went on to edit the file and publish it
+ * If Claude stopped at the message, ask Claude to edit the file and publish
+ * If the message keeps coming back, quit and relaunch Claude Code
+ * If the message comes back even after a relaunch, [turn off one-step updates](</docs/en/artifacts#turn-off-one-step-artifact-updates>)
+
+###
+
+
+
The source file is not valid UTF-8 text
Claude tried to publish an [artifact](</docs/en/artifacts>) from a file whose bytes don’t decode as text, or whose text already contains the replacement character `U+FFFD`, so Claude Code refused the publish before uploading anything. The message appears in the Artifact tool result and names the first position to fix:
@@ -5456,6 +5549,20 @@
Before v2.1.257, the session appeared to start and then showed in agent view as a failed row with the same reason. Before v2.1.281, this message also appeared when the directory was already gone before you started the session. That case reports `could not be resolved on disk`. **What to do:**
* Recreate the directory the message names, or dispatch from a directory that exists, then try again
+
+###
+
+
+
+This forked session could not be started
+
+You [forked a Remote Control session](</docs/en/remote-control#fork-a-session-from-your-browser>) from claude.ai, and Claude Code couldn’t finish starting the [background session](</docs/en/agent-view>) that runs the fork on your machine. This notice appears in the forked session’s transcript:
+
+ This forked session could not be started. Fork the conversation again to retry.
+
+The session you forked keeps running. **What to do:**
+
+ * Go back to the session you forked and fork it again once the session is idle
###
Show diff (280 lines)
--- a/errors.md
+++ b/errors.md
@@ -44,7 +44,7 @@
`Credit balance is too low`| Usage limits
`You've hit your monthly spend limit` / `You've hit your individual spend limit` / `You've hit your org's monthly spend limit` / `You've hit your channel's monthly spend limit` / `You've hit your team's shared budget` / `You've hit your individual usage limit`| Usage limits
`Could not update your spend limit`| Usage limits
-`spend limit reached` / `spend limit unavailable`| Usage limits
+`spend limit reached` / `spend limit unavailable` / `This request exceeds your group's budget`| Usage limits
`Not logged in · Please run /login`| Authentication
`Couldn't save your login`| Authentication
`Sign in again to take your previous account or API key off the config file.`| Authentication
@@ -234,10 +234,12 @@
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
`Temp directory <dir> ... Refusing to use it` / `Claude Code's temporary directory <dir> could not be created`| Command-line errors
`ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
+`Error: Claude Code could not save ... because the disk is full (ENOSPC)` / `because your disk quota is used up (EDQUOT)`| Command-line errors
`couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
`Error: Workspace not trusted` when running `claude ultrareview`| Command-line errors
`Ultrareview did not start`| Command-line errors
+`Remote Control did not start: "<question>" got no answer`| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
`--sandbox is not supported by claude remote-control` / `--no-sandbox is not supported by claude remote-control`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
@@ -328,6 +330,7 @@
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
`MCP server "<name>" is disabled — re-enable it via /mcp to use its tools`| Tool errors
`MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit.`| Tool errors
+`Permission prompt tool returned an invalid result`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`<path> is outside <dirs>; the permissions.blockWritesOutsideWorkingDirectories setting blocks writes outside the working directories`| Tool errors
@@ -378,6 +381,7 @@
`The safety check for domain ... is rate-limited`| Tool errors
`The safety check for domain ... is temporarily rate-limited`| Tool errors
`Unable to verify if domain ... is safe to fetch`| Tool errors
+`MCP tool "<tool>" on server "<server>" gave no answer that could be read` / `answered without its text`| [How an MCP tool hook’s result is read](</docs/en/hooks#how-the-tool%E2%80%99s-result-is-read>)
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -412,6 +416,7 @@
`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
+`The file backups are still being copied. Nothing was changed. Try again in a moment.`| Select the same point in [`/rewind`](</docs/en/checkpointing>) again. When you restore code soon after [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code can still be copying the file backups to the new session.
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
@@ -423,6 +428,7 @@
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
`N skill or command names refused: run with --debug to see which ([names]), rename, then restart`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`Two Claude Code config files exist: this run uses <path>, not <path>`| Configuration warnings
`Make this change again later: <path> could not be updated, so it applies to this session only`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
@@ -460,6 +466,7 @@
`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" isn't a usable size, so Claude Code ignores it`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
`Model "<model>" isn't recognized · context assumed to be 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`Claude Code doesn't recognize the model "<model>", so it assumes a context window of 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
+`Model "<model>" isn't recognized · did you mean "<suggestion>"?` / `Claude Code doesn't recognize the model "<model>". Did you mean "<suggestion>"?`| [Fix a mistyped model name](</docs/en/model-config#fix-a-mistyped-model-name>)
`[claude-code:unrecognized_model]`| Configuration warnings
`is ignored — managed settings set allowManagedReadPathsOnly` / `is ignored — managed settings set allowManagedDomainsOnly`| Configuration warnings
`Sandbox mask files left behind at write-deny paths`| Configuration warnings
@@ -951,14 +958,23 @@
Spend limit reached
-You connect through a [Claude apps gateway](</docs/en/claude-apps-gateway>) and have passed a [spend cap](</docs/en/claude-apps-gateway-spend-limits>) your gateway operator set. The gateway blocks your requests until the named period resets or the operator raises the cap. It marks each blocked `429` response `x-should-retry: false`, so Claude Code shows this message without retrying.
-
- spend limit reached (daily; resets 2026-08-09 00:00 UTC)
-
-The message names the cap’s period and reset time, and when the operator configured a `blocked_message`, their instructions follow it. Before v2.1.225, the message read only `spend limit reached`; a gateway on an older version still sends that shorter form. **What to do:**
-
- * Wait for the reset time the message names, or follow the operator’s instructions if the message carries them
- * Ask your gateway operator to raise the cap if you hit it routinely
+You connect through a [Claude apps gateway](</docs/en/claude-apps-gateway>) and have reached a [spend cap](</docs/en/claude-apps-gateway-spend-limits>) your gateway operator set. The gateway blocks your requests until the operator raises the cap, or until the cap resets if it’s above $0. It marks each blocked `429` response `x-should-retry: false`, so in the terminal Claude Code shows this message without retrying.
+
+ spend limit reached · resets Dec 1
+
+Check the message for a date:
+
+ * **With a date** : the cap resets at 00:00 UTC on that date
+ * **With no date** : your cap is $0, or your gateway runs a version earlier than v2.1.225
+
+Any further text in the message is a note from your gateway operator. From v2.1.225 until v2.1.319 on the gateway server, the message named the cap’s period and reset time, as in `spend limit reached (daily; resets 2026-08-09 00:00 UTC)`. **What to do:**
+
+ * If the message has a date, wait for the reset, or follow the operator’s note if the message carries one
+ * Ask your gateway operator to raise the cap if the message has no date, if you’re still blocked after the date, or if you hit the cap routinely
+
+A second gateway message, `This request exceeds your group's budget`, means your group’s [pooled budget](</docs/en/claude-apps-gateway-config#pooled-budget-order>) is used up. Follow the steps it names:
+
+ This request exceeds your group's budget. Ask your organization's admins to raise it, or try again after it resets on November 1 at 00:00 UTC.
A related message, `spend limit unavailable`, means the gateway could not read its spend records and blocked the request as a precaution rather than over your cap. It usually clears on its own; if it persists, tell your gateway operator.
@@ -1361,7 +1377,7 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-For a `Login expired` message that ends with `or re-authenticate your Anthropic profile`, see Anthropic profile login expired. This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
+For a `Login expired` message that ends with `or re-authenticate your Anthropic profile`, see Anthropic profile login expired. This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* If you sign in with your claude.ai account in another Claude Code window, see Not logged in for when this session starts using that login on its own.
@@ -1382,7 +1398,7 @@
Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh. This is usually transient; retry in a minute, and if it persists close other Claude Code processes or sign in again
-Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. **What to do:**
+**What to do:**
* Try again in a minute. If another process completes the refresh first, this session uses the renewed login.
* If the message keeps returning, close other Claude Code windows and processes, then retry.
@@ -2168,7 +2184,7 @@
Couldn’t send feedback
-A message starting `Couldn't send feedback` means the feedback service didn’t confirm the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>). Treat it as not received. When a sentence about your organization follows the colon, your organization refuses feedback and the same report gets the same answer. The second of these two examples is an organization’s refusal:
+A message starting `Couldn't send feedback` means the feedback service didn’t confirm the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>). Treat it as not received. When a sentence about your organization follows the colon, your organization refuses feedback. The second example is an organization’s refusal:
Couldn't send feedback (couldn't reach the service). If it keeps failing, you can file at https://github.com/anthropics/claude-code/issues instead.
@@ -2177,7 +2193,7 @@
**What to do:**
* **Not signed in** : the message continues `: not signed in. Run /login, then retry.` Run `/login`, then send again
- * **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` If the message adds `To report a bug, open an issue`, do so at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). A queued draft stays queued, and you can [discard it](</docs/en/tools-reference#discard-or-keep-a-draft>)
+ * **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` If the message adds `To report a bug, open an issue`, do so at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). `/feedback` can then answer that it’s disabled by your organization’s policy for seven days. A queued draft stays queued and still [expires on schedule](</docs/en/tools-reference#discard-or-keep-a-draft>)
* **Refused credentials** : the message continues `: the sign-in this session uses is not allowed to send feedback` or `: the server did not accept the credentials this session uses`. Run `/status` at the Claude Code prompt to see which login, token, or API key this session sends
* **`(request timed out)` or `(couldn't reach the service)` straight after `Couldn't send feedback`**: send the report or the queued draft again. The dialog keeps your text, and a queued draft’s message says `The draft is still queued.` If other requests are failing too, check your network connection and see Unable to connect to API. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
* **`(server returned<status>)`, or no reason, straight after `Couldn't send feedback`**: the status is the service’s response code. The service’s own message follows it when one was sent, as in `(server returned 403: Access Forbidden)`. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
@@ -3201,6 +3217,21 @@
+Claude Code could not save because the disk is full
+
+This line on stderr after a [`claude -p`](</docs/en/headless>) run means the disk is full or your disk quota is used up, so Claude Code couldn’t save everything from the run:
+
+ Error: Claude Code could not save all of this session's transcript under /Users/you/.claude because the disk is full (ENOSPC). If you resume this session, part of the conversation may be missing. Free up space on that disk before the next run.
+
+With text or `json` output, the run exits with code 1, and the answer has already been printed. With `stream-json` output, the run keeps its usual exit code, and the answer still arrives. **What to do:**
+
+ * **`the disk is full (ENOSPC)`** : before your next run, free up space on the disk that holds the path in the message
+ * **`your disk quota is used up (EDQUOT)`** : before your next run, free up space or ask for a larger quota
+
+###
+
+
+
Directory couldn’t be resolved to a real location
You ran `/add-dir` for a subdirectory of your working directory, and Claude Code couldn’t resolve the directory to its real location. You already have file access to a subdirectory of the working directory, so `/add-dir` only loads its skills, commands, and agents. Before loading them, Claude Code checks that the directory’s real location, with any symlinks resolved, is inside the working directory. When Claude Code can’t resolve that location, it loads nothing and shows this message:
@@ -3261,6 +3292,22 @@
* **`Ultrareview did not start: `--trust-workspace` takes no value`** : something other than a flag follows `--trust-workspace`, such as a PR number or `false`. If you don’t trust the folder, leave the flag out. To trust it for this run, put the PR number or base branch before the flag: `claude ultrareview 1234 --trust-workspace`.
Before v2.1.309, `claude ultrareview` didn’t accept `--trust-workspace`.
+
+###
+
+
+
+Remote Control did not start because a question got no answer
+
+This message means [`claude remote-control`](</docs/en/remote-control>) asked the first-run question quoted in the message and got no answer:
+
+ Remote Control did not start: "Enable Remote Control?" got no answer. Run `claude remote-control` at a terminal and answer y once; it won't ask again.
+ Remote Control did not start: "Choose [1/2] (default: 1):" got no answer. You can run `claude remote-control` and choose, or pass --spawn=same-dir or --spawn=worktree.
+
+**What to do:**
+
+ * **`Enable Remote Control?`** : in a script or a service, standard input ends before anyone can answer. Run `claude remote-control` once in a terminal, as the user your script or service runs as, and answer `y`.
+ * **`Choose [1/2] (default: 1):`** : run `claude remote-control` again and [choose a spawn mode](</docs/en/remote-control#set-the-default-spawn-mode-for-a-project>), or pass [`--spawn=same-dir` or `--spawn=worktree`](</docs/en/remote-control#start-a-remote-control-session>) to skip the question
###
@@ -4070,15 +4117,21 @@
/feedback is disabled by your organization’s policy
-This message means your organization’s policy doesn’t allow product feedback from Claude Code, so `/feedback`, `/bug`, and `/share` don’t open the feedback dialog. The message names the command you typed at the Claude Code prompt:
+This message means product feedback is turned off, so the command you typed doesn’t open the feedback dialog. An organization’s policy and an earlier refusal both produce the message:
+
+ * **Organization policy** : your organization’s policy doesn’t allow product feedback from Claude Code. `/feedback`, `/bug`, and `/share` all answer with the message.
+ * **Earlier refusal** : the feedback service refused a report you sent, for example with `Couldn't send feedback: Feedback has not been enabled for your organization.` `/feedback` and `/bug` can then answer with the message. It lasts seven days from that refusal on this machine. This applies on every plan, including Pro and Max.
+
+The message names the command you typed at the Claude Code prompt:
/feedback is disabled by your organization's policy. To report a bug, open an issue at https://github.com/anthropics/claude-code/issues. Issues are public, so leave out anything confidential.
The message can also be its first sentence alone. **What to do:**
* To report a bug, open an issue at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). Anyone can read issues there, so leave out code, transcripts, and anything else confidential.
-
-Before v2.1.302, the full message read `/feedback is disabled by your organization's policy. Contact your organization admin to enable it.`
+ * After an earlier refusal, wait until the seven days have passed, then send a report again to see whether the service still refuses it
+
+Before v2.1.319, an earlier refusal didn’t produce this message. Before v2.1.302, the full message read `/feedback is disabled by your organization's policy. Contact your organization admin to enable it.`
##
@@ -4476,6 +4529,25 @@
* In a TypeScript Agent SDK application, make your [`onElicitation`](</docs/en/agent-sdk/typescript#options>) callback return its answer before the limit runs out
* To give an answer more time, set a longer [`timeout`](</docs/en/mcp#time-limits-on-mcp-tool-calls>) in milliseconds in the server’s configuration entry, such as `"timeout": 600000` for 10 minutes
* Run the task in an interactive session instead and answer the server’s [dialog](</docs/en/mcp#respond-to-mcp-elicitation-requests>) yourself
+
+###
+
+
+
+Permission prompt tool returned an invalid result
+
+The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) returned an answer Claude Code couldn’t read, so the tool call waiting on it didn’t run, even if the answer allowed the call:
+
+ Permission prompt tool returned an invalid result. Expected a single text block param with type="text" and a string text value.
+
+**What to do:**
+
+ * Return one text block whose text is `{"behavior": "allow"}` or `{"behavior": "deny", "message": "<reason>"}`. To change the input, add `updatedInput` to the `allow` object. From v2.1.86 through v2.1.206, an `allow` needed `"updatedInput": {}` to keep the input.
+ * Return no [`structuredContent`](</docs/en/agent-sdk/custom-tools#return-structured-data>), which your MCP SDK may add on its own. For example, register the tool:
+ * **`FastMCP` or `MCPServer` from `mcp.server`**: with `structured_output=False`
+ * **`FastMCP` from `fastmcp`**: with `output_schema=None`, and return a string
+ * **MCP TypeScript SDK** : without `outputSchema`
+ * If the error comes only with inputs of about 40 KB or more, don’t copy the input into `updatedInput` or a deny’s `message`. To change an input that large, [raise your prompt tool’s output limit](</docs/en/mcp#raise-the-limit-for-a-specific-tool>).
###
@@ -6235,6 +6307,51 @@
+Two Claude Code config files exist
+
+Claude Code is using the first file this message names, so what’s in the second file isn’t in effect. The first is `.config.json`, an older name for [`.claude.json`](</docs/en/claude-directory#ce-claude-json>). The message includes a check for which file holds your setup:
+
+ Two Claude Code config files exist: this run uses /home/you/.claude/.config.json, not /home/you/.claude.json. The file with the higher count here is usually yours, and this prints nothing else from them: grep -c -E '"(hasCompletedOnboarding|mcpServers)"' "/home/you/.claude/.config.json" "/home/you/.claude.json". To end this: if several hosts share this home, first get every host to version 2.1.319 or later, since an older one can write a moved .config.json back. Then stop your Claude processes on every host, move aside the one you do not want, and start none until no host lists it.
+
+On Windows, `The one with hasCompletedOnboarding or mcpServers in it is usually yours.` replaces the sentence with the `grep` command. **What to do:**
+
+1
+
+Find the file that holds your setup
+
+ * **On Windows** : open both files and see which one has `hasCompletedOnboarding` or `mcpServers` in it
+ * **On other platforms** : in your shell, run the `grep` command from the message and see which file has the higher count
+
+2
+
+Update every host that shares the home directory
+
+If several hosts share this home directory, first update Claude Code on every host to the version the message names or later. An older version can write a moved `.config.json` back.
+
+3
+
+Stop Claude Code
+
+Stop your Claude Code processes on every host.
+
+4
+
+Move the file you don't want
+
+Move the file you don’t want out of its folder. Move it rather than delete it, so you can put it back.
+
+5
+
+Wait before you start Claude Code again
+
+Don’t start Claude Code on any host until no host still lists the moved file at its old path.
+
+The message stops once one of the two files is gone.
+
+###
+
+
+
Make this change again later: ~/.claude.json could not be updated
This notice on stderr means a change to [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>), such as a sign-in or an answer to a trust prompt, wasn’t saved to the file:
--- a/errors.md
+++ b/errors.md
@@ -883,7 +883,7 @@
Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
+The messages name the session’s Fable model, so on Fable 5.2 they read `continuing on Fable 5.2` and `Fable 5.2 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
* Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
* Run `/model` to switch to a model that doesn’t bill usage credits
@@ -6255,7 +6255,7 @@
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable, or your account [loses access to it mid-session](</docs/en/amazon-bedrock#when-a-model-is-disabled-mid-session>)
- * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, Opus 5.5, Sonnet 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable models, Opus 5.5, Sonnet 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one. A notice appears in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
--- a/errors.md
+++ b/errors.md
@@ -3398,13 +3398,16 @@
MCP server was not saved or removed
-You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>). Both scopes are stored in `~/.claude.json`, and the change isn’t in that file when Claude Code reads it back after writing. The command exits with this error instead of its success line.
-
- MCP server "example" was not saved to /home/user/.claude.json. If that file is read-only or protected by a sandbox, make it writable or run the command outside the sandbox, then add the server again.
-
-After a remove, the message reads `was not removed from` and ends with `then remove the server again`. For a `local`-scope server, the path is followed by the project directory the entry belongs to, as `(local scope for /path/to/project)`. Before v2.1.283, `claude mcp add`, `claude mcp add-json`, and `claude mcp remove` reported success even when the change didn’t reach the file. **What to do:**
-
- * Make the file the message names writable, or run the command outside the sandbox, then run the same add or remove command again.
+This error means a command such as `claude mcp add` or `claude mcp remove` didn’t get your change into `~/.claude.json`. Other Claude Code processes may have kept the file locked, or the file may be read-only or protected by a sandbox.
+
+ MCP server "example" was not saved to /home/user/.claude.json. If other Claude Code processes use that file, they may have kept it locked: add the server again, with CLAUDE_CODE_CONFIG_LOCK_WAIT_MS=60000 set to wait up to a minute. If that file is read-only or protected by a sandbox, make it writable or run the command outside the sandbox first.
+
+After a remove, the message reads `was not removed from` in place of `was not saved to`, and `remove the server again` in place of `add the server again`. For a `local`-scope server, the path is followed by the project directory the entry belongs to, as `(local scope for /path/to/project)`. **What to do:**
+
+ * **Other Claude Code processes are running** : the command waits about 10 to 20 seconds for the lock on the file, then gives up without writing. Run the same command again with [`CLAUDE_CODE_CONFIG_LOCK_WAIT_MS`](</docs/en/env-vars#variables>) set to a longer wait in milliseconds, such as `60000`.
+ * **The file is read-only or sandbox-protected** : make the file the message names writable and run the same add or remove command again, or run that command outside the sandbox.
+
+Before v2.1.283, `claude mcp add`, `claude mcp add-json`, and `claude mcp remove` reported success even when the change didn’t reach the file. Before v2.1.318, the message didn’t mention the lock, and Claude Code didn’t read [`CLAUDE_CODE_CONFIG_LOCK_WAIT_MS`](</docs/en/env-vars#variables>).
###
@@ -3412,11 +3415,11 @@
MCP server may not have been saved or removed
-You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>), and Claude Code couldn’t read `~/.claude.json` back to confirm the change. The change may or may not be on disk. The text in parentheses is the error from that read.
+You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>), and Claude Code couldn’t read `~/.claude.json` back to confirm the change. The change may or may not be on disk. The parentheses after `to confirm the change` give the reason.
MCP server "example" may not have been saved: /home/user/.claude.json could not be read to confirm the change (EACCES: permission denied, open '/home/user/.claude.json'). Run `claude mcp get example` to check, then add the server again if it is missing.
-After a remove, the message reads `may not have been removed` and ends with `then remove the server again if it is still listed`. Before v2.1.283, the commands reported success even when the change couldn’t be confirmed. **What to do:**
+After a remove, the message reads `may not have been removed` and ends with `then remove the server again if it is still listed`. If the reason is `the file was not found`, the server may still be configured. Before v2.1.283, the commands reported success even when the change couldn’t be confirmed. **What to do:**
* Run `claude mcp get <name>` to check whether the change is on disk. For a `local`-scope server, run it from the project directory the server belongs to, since local scope is per project.
* If the server is missing after an add, or still listed after a remove, run the same add or remove command again.
--- a/errors.md
+++ b/errors.md
@@ -53,7 +53,9 @@
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`Your apiKeyHelper script is failing`| Authentication
-`Claude Code didn't send your claude.ai login, because the API key helper your administrator set isn't in effect`| Authentication
+`Your organization's settings need an update`| Authentication
+`Couldn't load your organization's settings. Check your connection`| Authentication
+`Restart Claude Code to finish signing in`| Authentication
`Invalid auth token · Fix external auth token`| Authentication
`Invalid ANTHROPIC_CUSTOM_HEADERS · Fix the environment variable`| Authentication
`Invalid request header from the environment · Fix the environment variable`| Authentication
@@ -1083,14 +1085,21 @@
Claude Code didn’t send your claude.ai login
-Send this full message to your administrator. It lists the changes they can make. The message means Claude Code refused your prompt. While you use your claude.ai login, Claude Code keeps refusing prompts, after a restart too:
-
- Claude Code didn't send your claude.ai login, because the API key helper your administrator set isn't in effect. Your organization's managed settings may be overriding it. Ask your administrator to keep the key helper and its API address in effect, to name Anthropic's API address in those managed settings, or to remove the key helper. Run /status to see your setting sources.
-
-**What to do:**
-
- * To tell your administrator which managed sources your machine has, run `/status` at the Claude Code prompt and copy the [`Setting sources` line](</docs/en/managed-settings#read-the-source-in-/status>). If a `Skipped sources` line appears, copy it too
- * If you administer the settings, see [why the machine’s key helper isn’t in effect](</docs/en/server-managed-settings#machine-apikeyhelper-not-in-effect>)
+These messages mean Claude Code refused your request and didn’t send your claude.ai login:
+
+ Your organization's settings need an update. Ask your administrator to fix the API key helper configuration.
+ Couldn't load your organization's settings. Check your connection, then restart Claude Code.
+ Restart Claude Code to finish signing in.
+
+**What to do:**
+
+ * `Your organization's settings need an update`: ask your administrator to fix the API key helper configuration
+ * To tell your administrator which managed sources your machine has, run `/status` at the Claude Code prompt and copy the [`Setting sources` line](</docs/en/managed-settings#read-the-source-in-/status>). If a `Skipped sources` line appears, copy it too
+ * If you administer the settings and the helper is in a machine’s managed settings file or MDM policy, see [When a machine’s `apiKeyHelper` isn’t in effect](</docs/en/server-managed-settings#machine-apikeyhelper-not-in-effect>)
+ * `Couldn't load your organization's settings`: check your connection, then restart Claude Code. If the message comes back after a restart, tell your administrator
+ * `Restart Claude Code to finish signing in`: restart Claude Code
+
+Before v2.1.315, a refused prompt or file upload printed one message that began `Claude Code didn't send your claude.ai login`.
###
Show diff (236 lines)
--- a/errors.md
+++ b/errors.md
@@ -47,6 +47,8 @@
`spend limit reached` / `spend limit unavailable`| Usage limits
`Not logged in · Please run /login`| Authentication
`Couldn't save your login`| Authentication
+`Sign in again to take your previous account or API key off the config file.`| Authentication
+`Your account or API key may still be in the config file. Run claude auth logout.`| Authentication
`Authentication required · Sign in again to continue`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
@@ -74,6 +76,9 @@
`Couldn't verify your organization's policy for remote control`| [Troubleshoot Remote Control](</docs/en/remote-control#couldnt-verify-your-organizations-policy-for-remote-control>)
`Remote Control is disabled by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-is-disabled-by-your-organizations-policy>)
`Remote Control was turned off by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-was-turned-off-by-your-organizations-policy>)
+`Session failed: working folder not found:`| [Troubleshoot Remote Control](</docs/en/remote-control#working-folder-not-found>)
+`The program file this Remote Control started from is gone`| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
+`Session failed: spawn error:` followed by an `ENOENT` message| [Troubleshoot Remote Control](</docs/en/remote-control#program-file-is-gone>)
`OAuth token revoked` / `OAuth token has expired`| Authentication
`Failed to authenticate: OAuth token revoked`| Authentication
`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
@@ -157,6 +162,7 @@
`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
`API Error: an image in the conversation could not be processed and was removed`| Request errors
+`An image in the conversation exceeds the dimension limit for many-image requests`| Request errors
`Unable to resize image`| Request errors
`Request rejected as unprocessable by the model`| Request errors
`PDF too large` / `PDF is password protected` / `pdftoppm is not installed`| Request errors
@@ -221,6 +227,8 @@
`Error: --agents takes a JSON object, or a file path only with --print (-p)`| Command-line errors
`Error: --agents file not found`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
+`Configuration error in`| Command-line errors
+`Claude configuration file at <path> was empty and no backup holds anything: starting with defaults.`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
`Temp directory <dir> ... Refusing to use it` / `Claude Code's temporary directory <dir> could not be created`| Command-line errors
`ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
@@ -326,6 +334,7 @@
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
`command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run`| Tool errors
+`This call was not run. The command was approved before Claude Code restarted`| Tool errors
`File is too large to read as an image (the limit is 128MB)`| Tool errors
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
@@ -412,11 +421,15 @@
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
`N skill or command names refused: run with --debug to see which ([names]), rename, then restart`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`Make this change again later: <path> could not be updated, so it applies to this session only`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
`Your organization requires remote managed settings to load, but they could not be loaded`| [Enforce fail-closed startup](</docs/en/server-managed-settings#enforce-fail-closed-startup>)
`Remote managed settings are still loading`| Configuration warnings
`Remote managed settings did not load`| Configuration warnings
+`Claude Code couldn't load your organization's settings` / `Claude Code couldn't reach Anthropic to load your organization's settings` / `requires them before a session can start`| Configuration warnings
+`Claude Code can't start this session yet`| Configuration warnings
+`Your Claude session has expired. Sign in again to continue (claude auth login).`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
`Your organization's managed settings need your approval, which couldn't be asked for here.`| Configuration warnings
`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
@@ -1002,6 +1015,7 @@
* Run `/login` to authenticate with your Claude subscription or Console account
* If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
* For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script that fetches a key at startup
+ * If `claude -p` jobs exit with this message when someone signs in again to the same claude.ai account and organization, update Claude Code where that sign-in runs. Before v2.1.318, Claude Code removed the stored login during that sign-in, before saving the new one.
* See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential Claude Code uses when several are present
If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock checks and macOS credential-storage recovery steps.
@@ -1381,6 +1395,34 @@
* On macOS, unlock the login keychain, then run `/login` again
* On other platforms, run `/login` again
* If the login still doesn’t save, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for the keychain unlock command and other credential-storage recovery steps
+
+###
+
+
+
+Sign in again to take your previous account or API key off the config file
+
+This warning after you sign in means any account you were signed in with before may still be stored in [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>):
+
+ Sign in again to take your previous account or API key off the config file.
+
+An API key may still be in `~/.claude.json` too if a Console login created one on Linux or Windows. **What to do:**
+
+ * Run `claude auth login` in your shell to sign in again. Claude Code then retries the save that takes the replaced account or API key off the file.
+
+###
+
+
+
+Your account or API key may still be in the config file
+
+You ran `/logout` or `claude auth logout`, and Claude Code signed this process out but couldn’t confirm that [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>) no longer holds your account. Either the save didn’t land, or the file couldn’t be read back to check.
+
+ Your account or API key may still be in the config file. Run claude auth logout.
+
+An API key may still be in `~/.claude.json` too if a Console login created one on Linux or Windows. **What to do:**
+
+ * Run `claude auth logout` in your shell to try the save again. When the save goes through, the command prints `Successfully logged out from your Anthropic account.`
###
@@ -2281,6 +2323,7 @@
Image was too large. Double press esc to go back and try again with a smaller image.
API Error: 400 ... image dimensions exceed max allowed size
API Error: an image in the conversation could not be processed and was removed.
+ An image in the conversation exceeds the dimension limit for many-image requests (3000px). Run /compact to remove old images from context, or start a new session.
The `could not be processed and was removed` line means the API refused an image in the conversation, such as one over the size or dimension limits. If one of these errors keeps coming back, update Claude Code. On older versions, an image error could repeat for reasons such as these:
@@ -2292,6 +2335,9 @@
* Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 3000 pixels when more than 20 images are in context.
* Take a tighter screenshot of the relevant region instead of the full screen
+ * For the `dimension limit for many-image requests` message, run `/compact` at the Claude Code prompt if the message names it, or start a new session with fewer images
+
+The `dimension limit for many-image requests` message shows the pixel limit named in the API’s error.
###
@@ -3060,6 +3106,45 @@
Claude Code rejects a `--settings` path that isn’t a regular file the same way: a device, FIFO, or socket reports `Error: Cannot use settings file (Not a regular file (device, FIFO, or socket))` followed by the path, and a directory reports an `EISDIR` reason. **What to do:**
* Point `--settings` at a regular JSON settings file under 2 MiB. See [Settings](</docs/en/settings>) for the format.
+
+###
+
+
+
+Configuration error in ~/.claude.json
+
+Claude Code couldn’t parse `~/.claude.json`, the file that holds your account details, MCP servers, and per-project state. Your file is unchanged. A [non-interactive](</docs/en/headless>) start such as `claude -p` exits with code 1 each time until you repair the file. When Claude Code finds a [backup](</docs/en/claude-directory#cleaned-up-automatically>), the output names it and prints a `cp` line that copies it back:
+
+ Claude configuration file at /home/user/.claude.json is corrupted: <JSON parser's message>
+ The corrupted file has been backed up to: /home/user/.claude/backups/.claude.json.corrupted.1793664000000
+ A backup file exists at: /home/user/.claude/backups/.claude.json.backup.1793660400000
+ You can manually restore it by running: cp -f "/home/user/.claude/backups/.claude.json.backup.1793660400000" "/home/user/.claude.json"
+
+ Configuration error in /home/user/.claude.json: <JSON parser's message>
+
+**What to do:**
+
+ * **The output has a`cp` line**: run that line in your terminal. On Windows, run it in PowerShell. It replaces the broken file with the backup, an earlier version of `~/.claude.json`.
+ * **The output has no`cp` line, or the error returns after you run it**: fix the JSON in `~/.claude.json`, copy another `.claude.json.backup.<timestamp>` file from [`~/.claude/backups/`](</docs/en/claude-directory#cleaned-up-automatically>) over it if there is one, or rename it. With no file at `~/.claude.json`, Claude Code starts with default settings and none of what the file held.
+
+Before v2.1.318, you were left with defaults in `~/.claude.json` after a non-interactive start printed this error, so the next start ran without your configuration.
+
+###
+
+
+
+Claude configuration file was empty and no backup holds anything
+
+This message at startup means the file it names was blank and none of the file’s [`.backup` copies](</docs/en/claude-directory#cleaned-up-automatically>) holds anything. Claude Code started with defaults for what that file holds. Your `settings.json` files and `.mcp.json` are separate files.
+
+ Claude configuration file at /home/user/.claude.json was empty and no backup holds anything: starting with defaults.
+
+**What to do:**
+
+ * Set up again what you had configured in that file. For example, add your `user` and `local` scope [MCP servers](</docs/en/mcp#mcp-installation-scopes>) with `claude mcp add` from your terminal.
+ * Sign in again if Claude Code asks you to
+
+Before v2.1.318, Claude Code reported a blank file with no backup as corrupted.
###
@@ -4493,6 +4578,20 @@
* **For a command Claude wrote** : you have nothing to fix. The message tells Claude how to rewrite the command.
* **For a skill or command file** : the message follows `No shell command in <name> was run`. See where to find the character and remove it.
+
+###
+
+
+
+Command approved before Claude Code restarted was not run
+
+A shell command you approved didn’t run, and Claude receives this message as the command’s result:
+
+ This call was not run. The command was approved before Claude Code restarted, and Claude Code could not confirm that the shell is back in the directory where it was approved. That directory may be gone or replaced, lie outside the directory where the session started, or be one that Claude Code needs approval to enter or is not allowed to examine. The shell's directory is <directory>. If the command still makes sense, cd to the directory it was meant for and make the call again; it may need approval again.
+
+The message’s third sentence can instead read `It does not keep track of that directory across a restart in a session that has been in a worktree.` **What to do:**
+
+ * Let Claude continue, and answer the prompt if you’re asked to approve the command again.
###
@@ -5666,6 +5765,24 @@
+Claude Code couldn’t load your organization’s settings
+
+Your session hasn’t started because your organization’s settings, including its [server-managed settings](</docs/en/server-managed-settings>), have to load first and Claude Code couldn’t load them. For example:
+
+ Claude Code couldn't reach Anthropic to load your organization's settings (could not connect). <Organization name> requires them before a session can start.
+
+If the message is in a dialog titled `Claude Code can't start this session yet`, the dialog closes and the session starts as soon as the settings load. In [non-interactive mode](</docs/en/headless>) and in [background sessions](</docs/en/agent-view>), Claude Code prints the message and exits with status 1 instead. **What to do:**
+
+ * **`could not connect`, or `the reply came from a network proxy, not Anthropic`**: check your network connection, and on a corporate network ask IT to allow HTTPS to `api.anthropic.com/api/claude_code/policy_limits` and `api.anthropic.com/api/claude_code/settings`. Then select **Retry now** , or run your command again.
+ * **`timed out`, `Anthropic returned an error`, or `Anthropic asked it to retry shortly`**: let the dialog retry, or run your command again later. Check [status.anthropic.com](<https://status.anthropic.com>) if it keeps happening.
+ * **`still loading`, or `couldn't verify your sign-in with Anthropic yet`**: let the dialog retry, or run your command again. If the sign-in message keeps coming back, sign in again by running `claude auth login` in your shell.
+ * **`Your Claude session has expired`** : the sign-in stored on this machine is no longer valid, so retrying won’t help. In the dialog, select **Sign in again** to close Claude Code; then, in your shell, run `claude auth login`, which works even while sessions can’t start.
+ * **`none of the settings the server returned could be applied as written`** : ask your administrator to correct the organization’s [server-managed settings](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>), then retry.
+
+###
+
+
+
Managed settings were not approved
Your organization’s [server-managed settings](</docs/en/server-managed-settings>) include settings that need your approval, and you declined the [security approval dialog](</docs/en/server-managed-settings#security-approval-dialogs>), so Claude Code exits without applying them:
@@ -6102,6 +6219,20 @@
Before v2.1.309, the warning read `Stale sandbox mask files left by a killed session`. Before v2.1.257, `claude doctor` didn’t flag these files; earlier versions leave the same placeholders behind when a session is killed.
+###
+
+
+
+Make this change again later: ~/.claude.json could not be updated
+
+This notice on stderr means a change to [`~/.claude.json`](</docs/en/claude-directory#ce-claude-json>), such as a sign-in or an answer to a trust prompt, wasn’t saved to the file:
+
+ Make this change again later: /home/user/.claude.json could not be updated, so it applies to this session only.
+
+**What to do:**
+
+ * Make the change again in a later session. For example, run `/login` again or answer the trust prompt again.
+
##
Show diff (106 lines)
--- a/errors.md
+++ b/errors.md
@@ -58,7 +58,8 @@
`This organization has been disabled`| Authentication
`Your organization has disabled API key authentication`| Authentication
`Your organization has disabled Claude subscription access`| Authentication
-`Routines are disabled by your organization's policy`| Authentication
+`Scheduled tasks are off for your organization`| Authentication
+`Routines are off for your organization`| Authentication
`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
`OAuth token refresh failed — run /login to re-authenticate`| Authentication
`JWT refresh failed: no OAuth token — run /login`| Authentication
@@ -413,6 +414,9 @@
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
+`Your organization requires remote managed settings to load, but they could not be loaded`| [Enforce fail-closed startup](</docs/en/server-managed-settings#enforce-fail-closed-startup>)
+`Remote managed settings are still loading`| Configuration warnings
+`Remote managed settings did not load`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
`Your organization's managed settings need your approval, which couldn't be asked for here.`| Configuration warnings
`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
@@ -445,6 +449,8 @@
`is ignored — managed settings set allowManagedReadPathsOnly` / `is ignored — managed settings set allowManagedDomainsOnly`| Configuration warnings
`Sandbox mask files left behind at write-deny paths`| Configuration warnings
`Stale sandbox mask files left by a killed session`| Configuration warnings
+`Ubuntu's AppArmor restriction on user namespaces stops bubblewrap here`| [Sandboxing troubleshooting](</docs/en/sandboxing#apparmor-restriction-stops-bubblewrap>)
+`bwrap: setting up uid map: Permission denied` / `bwrap: loopback: Failed RTM_NEWADDR: Operation not permitted`| [Sandboxing troubleshooting](</docs/en/sandboxing#bwrap-uid-map-permission-denied>)
Responses seem lower quality than usual| Response quality
##
@@ -731,7 +737,7 @@
Auto mode is unavailable — the server returned no safety verdict for the last 10 responses, so Claude stopped. Send a message to try again, or switch out of auto mode.
-The stop message appears in a different place in each kind of session:
+Some denials don’t count toward the ten, including a denial from a hook or mod’s change. The stop message appears in a different place in each kind of session:
* In an interactive session, the message appears as a warning in the transcript and the turn ends
* In a [non-interactive](</docs/en/headless>) `-p` run, the run ends and reports an execution error. With the default text output, the message prints on stderr.
@@ -748,6 +754,21 @@
Before v2.1.280, Claude Code denied each action from a response without a verdict immediately and never stopped the turn. Before v2.1.302, on a direct connection to the Anthropic API, Claude Code didn’t compact a conversation that had grown too long for the server’s check.
+####
+
+
+
+`a hook changed this call's input after auto mode reviewed it`
+
+This denial means a hook or mod [changed the call’s input](</docs/en/hooks#pretooluse-updatedinput-in-auto-mode>) after the server reviewed it, so the review doesn’t cover what would run. It isn’t a judgment that the action is unsafe. Later calls in the same Claude response can be denied with this reason:
+
+ another call in this response was changed by a hook after auto mode reviewed it, or could not be confirmed unchanged
+
+Claude can then issue each denied call again so the server reviews it. If a permission prompt opens, answer it. You don’t need to do anything else unless Claude says in its reply that auto mode couldn’t check the call. Then stop the change or approve the call yourself, and ask Claude to try the call again:
+
+ * **Stop the change** : turn off the [hook](</docs/en/hooks#disable-or-remove-hooks>) or [mod](</docs/en/plugins/mods/overview#turn-mods-on-or-off>) that changed the call or an earlier call in the same Claude response, or ask your administrator to turn it off. To look for a hook, run [`/hooks`](</docs/en/hooks#the-%2Fhooks-menu>) at the Claude Code prompt. In a terminal session, run `/plugin` to see the active mods.
+ * **Approve the call yourself** : [switch to Manual mode](</docs/en/permission-modes#switch-permission-modes>)
+
###
@@ -1146,15 +1167,16 @@
-Routines are disabled by your organization’s policy
-
-An Owner in your Team or Enterprise organization has turned off [cloud scheduled tasks](</docs/en/routines>), formerly routines, at the organization level. The error appears when you try to create or run one, for example at [claude.ai/code/routines](<https://claude.ai/code/routines>). On Claude Code v2.1.227 or later, the same setting also [hides `/schedule`](</docs/en/routines#troubleshooting>) in the CLI.
-
- Routines are disabled by your organization's policy.
-
-This is a server-side setting, so it can’t be overridden from local settings, environment variables, or CLI flags. **What to do:**
-
- * Ask an Owner in your organization to turn on the **Scheduled tasks (Was Routines)** toggle at [**Organization settings > Capabilities > Remote sessions**](<https://claude.ai/admin-settings/capabilities>)
+Scheduled tasks are off for your organization
+
+[Cloud scheduled tasks](</docs/en/routines>) are off for your organization, so you can’t create or run them. The message from claude.ai calls them scheduled tasks or routines, and a sentence about your admin follows:
+
+ Scheduled tasks are off for your organization. …
+ Routines are off for your organization. …
+
+You can’t turn them on with local settings, environment variables, or CLI flags. **What to do:**
+
+ * Ask your Team or Enterprise Owner whether they can turn on the toggle labeled **Scheduled tasks (Was Routines)** or **Routines** at [**Organization settings > Capabilities > Remote sessions**](<https://claude.ai/admin-settings/capabilities>)
###
@@ -5621,10 +5643,16 @@
Remote managed settings failed to load
-Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them or couldn’t apply what the server returned, so it shows this warning in interactive sessions. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`. The cause `no setting in the server response could be applied as written` means the server answered but none of the settings it returned passed [validation](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>). Before v2.1.282, this cause read `server returned invalid settings`. The rest of the line says which policy the session runs on:
+Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them or couldn’t apply what the server returned, so it shows this warning in interactive sessions and in Claude Desktop’s Code tab. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`. The cause `no setting in the server response could be applied as written` means the server answered but none of the settings it returned passed [validation](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>). Before v2.1.282, this cause read `server returned invalid settings`. The rest of the line says which policy the session runs on:
* **Settings cached from an earlier successful fetch** : Claude Code runs the session on that cached policy, except the [withheld environment variables](</docs/en/server-managed-settings#fetch-and-caching-behavior>), and the line reads `using cached policy`.
* **No cache** : Claude Code runs the session without server-managed settings, and the line reads `no remote policy applied`.
+
+In the Code tab, the warning appears as a line in the conversation when you send a message, and a new line appears when the state of the fetch changes. Three related messages appear the same way:
+
+ * `Remote managed settings are still loading`: the fetch was still running when the session went ahead
+ * `Remote managed settings did not load`: the fetch ended without an answer
+ * `Remote managed settings have now loaded`: the settings loaded after one of these warnings, and the rest of the line says whether a remote policy applies
**What to do:**
Show diff (105 lines)
--- a/errors.md
+++ b/errors.md
@@ -51,6 +51,7 @@
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`Your apiKeyHelper script is failing`| Authentication
+`Claude Code didn't send your claude.ai login, because the API key helper your administrator set isn't in effect`| Authentication
`Invalid auth token · Fix external auth token`| Authentication
`Invalid ANTHROPIC_CUSTOM_HEADERS · Fix the environment variable`| Authentication
`Invalid request header from the environment · Fix the environment variable`| Authentication
@@ -557,7 +558,7 @@
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
- * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every request fails this way, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
+ * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every request fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable in your environment.
###
@@ -814,7 +815,7 @@
* Run `/usage-credits` to buy additional usage on Pro, Max, and Ultra, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
-Before a window runs out, Claude Code can warn you that you’ve used most of it, with a message such as `You've used 85% of your session limit · resets 3:45pm`. To watch your remaining allowance continuously, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
+Before a window runs out, Claude Code can warn you that you’ve used most of it, with a message such as `You've used 85% of your session limit · resets 3:45pm`. To watch your remaining allowance, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>).
###
@@ -1040,6 +1041,21 @@
* Fix the command so it prints only the key to stdout, as a single token of printable ASCII up to 16,384 characters, and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
* Run `/status` to see the failure and confirm `apiKeyHelper` is the active credential source. The `apiKeyHelper` row shows `Failing` with the last failure’s detail, such as the exit code and the command’s error output, and disappears after the next successful run. Before v2.1.274, `/status` showed only the credential source, not the failure.
* Each time the command fails, its exit code and error output also appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
+
+###
+
+
+
+Claude Code didn’t send your claude.ai login
+
+Send this full message to your administrator. It lists the changes they can make. The message means Claude Code refused your prompt. While you use your claude.ai login, Claude Code keeps refusing prompts, after a restart too:
+
+ Claude Code didn't send your claude.ai login, because the API key helper your administrator set isn't in effect. Your organization's managed settings may be overriding it. Ask your administrator to keep the key helper and its API address in effect, to name Anthropic's API address in those managed settings, or to remove the key helper. Run /status to see your setting sources.
+
+**What to do:**
+
+ * To tell your administrator which managed sources your machine has, run `/status` at the Claude Code prompt and copy the [`Setting sources` line](</docs/en/managed-settings#read-the-source-in-/status>). If a `Skipped sources` line appears, copy it too
+ * If you administer the settings, see [why the machine’s key helper isn’t in effect](</docs/en/server-managed-settings#machine-apikeyhelper-not-in-effect>)
###
@@ -1284,7 +1300,7 @@
* If `/status` shows only your login, run `/login` once. If the credential was revoked, a fresh login replaces it.
* If the same message returns for the same login account, the account or organization is no longer active. Check the account and organization that `/status` reports, and ask your organization admin to restore access.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
- * If every request fails with a `401` once your gateway has the credential it expects, check whether the gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
+ * If every request fails with a `401` once your gateway has the credential it expects, check that the gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
###
@@ -1828,7 +1844,7 @@
* Confirm you can reach the API host from the same shell by running `curl -I https://api.anthropic.com`. On Windows PowerShell use `curl.exe -I https://api.anthropic.com` so the built-in `Invoke-WebRequest` alias is not used.
* If you are behind a corporate proxy, set `HTTPS_PROXY` before launching Claude Code and see [Network configuration](</docs/en/network-config>)
* If you route through an LLM gateway or relay, set [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) to its address. See [Connect Claude Code to an LLM gateway](</docs/en/llm-gateway-connect>) for setup.
- * If `ANTHROPIC_BASE_URL` already points at your gateway and every request ends in `Connection dropped`, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
+ * If `ANTHROPIC_BASE_URL` already points at your gateway and every request ends in `Connection dropped`, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* Ensure your firewall allows the hosts listed in [Network access requirements](</docs/en/network-config#network-access-requirements>)
* Intermittent failures are retried automatically
@@ -2327,9 +2343,7 @@
Claude Code sends beta-only fields such as `context_management` and tool search’s `defer_loading` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. When a gateway forwards an Anthropic-format body to an upstream with a different schema, that upstream rejects such fields. [Beta header and body field pairs](</docs/en/llm-gateway-protocol#beta-header-and-body-field-pairs>) covers both cases. **What to do:**
* If the message contains `context_management: Extra inputs are not permitted`, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.304 or later. After you update, Claude Code answers this rejection by sending the request once more without the field. Before v2.1.304, Claude Code didn’t retry this rejection.
- * If the message names `defer_loading` or `tool_reference`, update Claude Code or turn [tool search](</docs/en/mcp#tool-search-through-a-gateway>) off:
- * [Update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.305 or later. Claude Code then answers this rejection by sending the request once more without tool search fields.
- * If you can’t update, or the message still appears after you do, set `ENABLE_TOOL_SEARCH=false` in your shell or your [settings `env`](</docs/en/settings-reference#env>). If a settings file already sets the variable, change it there, since that value [can override a shell export](</docs/en/settings-reference#how-env-values-interact-with-your-shell>). Claude Code then loads MCP tools upfront.
+ * If the message names `defer_loading` or `tool_reference`, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.305 or later. Claude Code then answers this rejection by [sending the request once more](</docs/en/llm-gateway-protocol#retry-without-tool-search>) without tool search fields.
* If your gateway drops the header, configure it to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers the exact scope.
@@ -2404,7 +2418,7 @@
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
* Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
- * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
+ * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check that your gateway and its upstream accept [tool search](</docs/en/mcp#tool-search-through-a-gateway>) fields. By default, Claude Code sends `defer_loading` tool fields and `tool_reference` blocks, with the `anthropic-beta` header that enables them. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
###
@@ -5997,14 +6011,14 @@
In a script or harness that reads stderr, match on the `[claude-code:unrecognized_model]` prefix. After the prefix and one space, Claude Code writes a one-line JSON object. Claude Code can add fields to it in a later version, so ignore any field you don’t expect. It writes at least these two:
* `model`: the model string as you configured it
- * `query_source`: the request path that used the model. Claude Code reports `sdk` for a `-p` run and a value that starts with `agent:` for a subagent.
+ * `query_source`: the request path that used the model. For example, the value is `sdk` for the main conversation of a `-p` run and starts with `agent:` for a subagent.
Claude Code writes the line to one of two places, depending on how you run it:
* In [non-interactive mode](</docs/en/headless>) with `-p`, Claude Code writes it to stderr under every `--output-format`, so you can parse stdout without filtering the line out
* In an interactive session or a [background session](</docs/en/agent-view>), Claude Code writes it to the debug log instead; run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`
-Claude Code writes the line once per model string per process. It writes a separate line for each further unrecognized ID, such as one that a [subagent](</docs/en/sub-agents#choose-a-model>) or [background functionality](</docs/en/costs#background-token-usage>) uses. Claude Code doesn’t write the line for provider IDs it resolves to a model it recognizes, such as Amazon Bedrock `us.anthropic.claude-...` IDs, Google Cloud’s Agent Platform IDs with an `@` version suffix, and Microsoft Foundry deployment names that contain a Claude model ID. Claude Code checks the model behind an Amazon Bedrock [application inference profile ARN](</docs/en/amazon-bedrock#map-each-model-version-to-an-inference-profile>) rather than the ARN itself. It writes no line for an ARN it can’t resolve, such as a mistyped one. **What to do:**
+Claude Code writes the line once per model ID per process. It writes a separate line for each further unrecognized ID, such as one that a [subagent](</docs/en/sub-agents#choose-a-model>) or [background functionality](</docs/en/model-config#environment-variables>) uses. Claude Code doesn’t write the line for provider IDs it resolves to a model it recognizes, such as Amazon Bedrock `us.anthropic.claude-...` IDs, Google Cloud’s Agent Platform IDs with an `@` version suffix, and Microsoft Foundry deployment names that contain a Claude model ID. Claude Code checks the model behind an Amazon Bedrock [application inference profile ARN](</docs/en/amazon-bedrock#map-each-model-version-to-an-inference-profile>) rather than the ARN itself. It writes no line for an ARN it can’t resolve, such as a mistyped one. **What to do:**
* If you set the ID on purpose, such as an [LLM gateway](</docs/en/llm-gateway>) alias, add a [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry to your [settings file](</docs/en/settings#where-settings-live>) with the ID as its value. Use an Anthropic model ID as the key, not a family alias such as `opus`. For `my-proxy-model` from the example line, add this entry:
--- a/errors.md
+++ b/errors.md
@@ -318,6 +318,9 @@
`MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit.`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
+`<path> is outside <dirs>; the permissions.blockWritesOutsideWorkingDirectories setting blocks writes outside the working directories`| Tool errors
+`<path>: Writes outside the working directories are blocked (permissions.blockWritesOutsideWorkingDirectories)`| Tool errors
+`Writes to Claude Code settings files are blocked while permissions.blockWritesOutsideWorkingDirectories is on`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
`command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run`| Tool errors
@@ -666,7 +669,7 @@
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
-In an interactive session, a dim `Not run · auto mode's check had no usable answer` row appears under the tool call instead of this message. Press `Ctrl+O` to read the message in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>). The `gave no verdict` denials under The server returned no safety verdict show the same row. Before v2.1.296, the message appeared under the call as a red error. When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
+In an interactive session, a dim `Not run · auto mode's check had no usable answer` row appears under the tool call instead of this message. The row can also replace a message saying the server gave no verdict or, outside a remote session, one starting `Auto mode could not evaluate`. Press `Ctrl+O` to read its message in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>). Before v2.1.296, the message appeared as a red error. When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
@@ -4381,6 +4384,48 @@
* If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings-reference#permission-settings>)
* If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path to block the NotebookEdit tool too
+
+###
+
+
+
+Setting blocks writes outside the working directories
+
+When Claude tries to write a file and the tool call fails with this message, the path is outside the session’s [working directories](</docs/en/permissions#working-directories>) and [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on:
+
+ <path> is outside <dirs>; the permissions.blockWritesOutsideWorkingDirectories setting blocks writes outside the working directories. Ask the user to add the directory with /add-dir, or to remove that setting.
+
+Claude Code refuses that write in every permission mode. The refusal can also read:
+
+ <path>: Writes outside the working directories are blocked (permissions.blockWritesOutsideWorkingDirectories). Add the directory with /add-dir, or remove that setting.
+
+**What to do:**
+
+ * If Claude shouldn’t write there, do nothing
+ * To let Claude write to an existing directory that contains the path, run `/add-dir <directory>` at the Claude Code prompt, or pass `--add-dir <directory>` when you start Claude Code
+ * If the path is a Claude Code settings file, such as `~/.claude/settings.json`, edit it yourself. Adding its directory with `/add-dir` doesn’t help, because Claude Code then refuses the write as a settings file.
+ * To keep a directory writable in every session, list it under [`permissions.additionalDirectories`](</docs/en/settings-reference#permissions-additionaldirectories>) in your user or managed settings
+ * To turn `permissions.blockWritesOutsideWorkingDirectories` off, remove it from every settings file that sets it, then restart Claude Code
+ * If none of your settings files has `permissions.blockWritesOutsideWorkingDirectories`, it can come from `--settings` or from a host application. Claude Code also refuses these writes while it can’t read `permissions` in your [managed settings](</docs/en/managed-settings#keys-that-fail-closed>). Ask whoever launches or manages the session.
+
+###
+
+
+
+Writes to Claude Code settings files are blocked
+
+When Claude tries to write a file and the tool call fails with this message, Claude Code treats the file as one of its settings files and [`permissions.blockWritesOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockwritesoutsideworkingdirectories>) is on:
+
+ <path>: Writes to Claude Code settings files are blocked while permissions.blockWritesOutsideWorkingDirectories is on, because a settings file can lift that block. While a managed settings folder cannot be resolved, any .json file counts as one.
+
+**What to do:**
+
+ * To change a setting, edit the settings file yourself
+ * To let Claude edit settings files again, remove `permissions.blockWritesOutsideWorkingDirectories` from every settings file that sets it, then restart Claude Code
+ * If the file isn’t one of your settings files, find it among the other files Claude Code treats as settings files:
+ * **A file you passed to`--agents` or `--mcp-config`**: edit it yourself
+ * **The stored copy of[server-managed settings](</docs/en/server-managed-settings#security-considerations>) and the files kept with it**: ask an [Owner](</docs/en/server-managed-settings#access-control>) to change the setting in server-managed settings.
+ * **Any`.json` file, while Claude Code can’t work out where the [`managed-settings.d/`](</docs/en/managed-settings#split-a-file-based-policy-across-teams>) folder leads**: ask your administrator to check that folder
###
--- a/errors.md
+++ b/errors.md
@@ -808,7 +808,7 @@
* In the Code tab of the [Desktop app](</docs/en/desktop>), the session-limit card offers an **Auto-continue when limits reset** checkbox. The weekly-limit card doesn’t. When it’s checked, the Desktop app retries the interrupted turn after the reset and shows the retry time on the card. The Desktop checkbox and the CLI’s **Continue automatically at usage limit** setting in `/config` are separate, so turn each off on its own.
* For the Opus or Sonnet limit, run `/model` and switch to a model outside that family to keep working. Each model has its own prompt cache, so the next request re-reads the whole conversation with no cache hits; see [Switching models](</docs/en/prompt-caching#switching-models>)
* Run `/usage` to see your plan limits and when they reset
- * Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
+ * Run `/usage-credits` to buy additional usage on Pro, Max, and Ultra, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
Before a window runs out, Claude Code can warn you that you’ve used most of it, with a message such as `You've used 85% of your session limit · resets 3:45pm`. To watch your remaining allowance continuously, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
@@ -826,7 +826,7 @@
In a session the Claude Desktop app runs, the hint names no commands: it points at the claude.ai usage settings page, or on Team and Enterprise plans says to turn on usage credits at claude.ai/admin-settings/usage or to ask your admin. This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
- * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Once usage credits are on, restart Claude Code or start a new session, whichever the message says. Until then, the session stays at the standard context limit.
+ * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro, Max, and Ultra, or to request usage credits from your admin on Team and Enterprise. Once usage credits are on, restart Claude Code or start a new session, whichever the message says. Until then, the session stays at the standard context limit.
* If the error persists after `/model`, a 1M model ID may be set elsewhere. See [Setting your model](</docs/en/model-config#setting-your-model>) for the configuration locations to check in priority order.
* To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
@@ -899,7 +899,7 @@
`team's shared budget` is a pooled budget an admin assigned to a group you belong to; the message doesn’t name the group. `channel's monthly spend limit` is the budget of the one Slack channel the session runs in, so your organization may still have budget outside it. When one of your plan’s windows is what ran out, the message also says when that window resets, for example `· your session limit resets 3:45pm`, and access returns then without anyone raising the limit. On organizations with usage-based billing, the message says `usage limit` in place of `spend limit`, as in `You've hit your individual usage limit`. If you connect through a Claude apps gateway and see lowercase `spend limit reached`, that is your gateway operator’s cap instead; see Spend limit reached. **What to do:**
- * On Pro and Max, increase your monthly spend limit in [**Settings > Usage**](<https://claude.ai/settings/usage>) on claude.ai, or run `/usage-credits`
+ * On Pro, Max, and Ultra, increase your monthly spend limit in [**Settings > Usage**](<https://claude.ai/settings/usage>) on claude.ai, or run `/usage-credits`
* On Team and Enterprise, increase the limit in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>) if you manage billing, or ask an admin to. `/usage-credits` sends that request to your admin for you
* For a channel’s limit, ask an org owner or the channel’s manager to raise it on claude.ai. See [Per-channel limits](<https://claude.com/docs/claude-tag/admins/set-spend-limit#per-channel-limits>) in the Claude Tag documentation
* If the message names a reset time for your plan’s window, you can wait for it instead
@@ -934,7 +934,7 @@
**What to do:**
- * If you have a Pro, Max, Team, or Enterprise plan and see this, run `/status` and check the `API key` row. An approved `ANTHROPIC_API_KEY` in your environment routes requests through that key instead of your subscription. Unset it in the current shell and remove it from your shell profile, then relaunch `claude`. Run `/login` if you haven’t signed in with your subscription yet.
+ * If you have a Pro, Max, Ultra, Team, or Enterprise plan and see this, run `/status` and check the `API key` row. An approved `ANTHROPIC_API_KEY` in your environment routes requests through that key instead of your subscription. Unset it in the current shell and remove it from your shell profile, then relaunch `claude`. Run `/login` if you haven’t signed in with your subscription yet.
* Add credits at [platform.claude.com/settings/billing](<https://platform.claude.com/settings/billing>), and consider enabling auto-reload there so the balance refills before it hits zero
* Set per-workspace spend caps in the Console to prevent a single project from draining the org balance. See [Manage costs effectively](</docs/en/costs>).
@@ -1078,7 +1078,7 @@
Your ANTHROPIC_API_KEY belongs to a disabled organization · Update or unset the environment variable
API Error: 400 ... This organization has been disabled.
-The hint after the `·` depends on your saved credentials: the first form appears when a stored `/login` can take over after you unset the key, and the second when the key is your only credential. Environment variables take precedence over `/login`, so a key exported in your shell profile or loaded from a `.env` file is used even when you have a working Pro or Max subscription. In non-interactive mode (`-p`), the key is always used when present. **What to do:**
+The hint after the `·` depends on your saved credentials: the first form appears when a stored `/login` can take over after you unset the key, and the second when the key is your only credential. If you export a key in your shell profile or load one from `.env`, Claude Code uses it instead of `/login`, even with a working Pro, Max, or Ultra subscription. In non-interactive mode (`-p`), the key is always used when present. **What to do:**
* Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
* If the message says `Update or unset`, you have no saved login to fall back to. Unset the key and run `/login`, or replace the key with one from an active Console organization.
--- a/errors.md
+++ b/errors.md
@@ -269,6 +269,8 @@
`Windows reported an error (EBADF) when Claude Code read this session's transcript file`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
+`Can't restart while work is running in the background — wait for it to finish (or stop it via /tasks), then try again.`| Command-line errors
+`Can't restart while Remote Control is connected. To use the installed version, exit and start Claude Code again, then run /resume.`| Command-line errors
`Claude Code couldn't restart`| Command-line errors
`Couldn't open Claude Desktop`| Command-line errors
`Failed to open Claude Desktop. Please try opening it manually.`| Command-line errors
@@ -836,7 +838,7 @@
The prompt to confirm went unanswered
-If your account requires the [Fable usage-credits consent](</docs/en/model-config#fable-and-usage-credits>), Claude Code asks you to confirm before a Fable request bills usage credits. When the consent prompt closes with nobody answering it, Claude Code ends the turn with one of these messages:
+When the [Fable usage-credits consent prompt](</docs/en/model-config#fable-and-usage-credits>) closes with nobody answering it, Claude Code ends the turn with one of these messages:
Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
@@ -3800,6 +3802,14 @@
**What to do:**
* In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings-reference#tui>) there
+
+###
+
+
+
+Can’t restart while work is running or Remote Control is connected
+
+Claude Code didn’t restart, and your session keeps running as it was. Follow the fix in the message.
###
Show diff (136 lines)
--- a/errors.md
+++ b/errors.md
@@ -211,6 +211,7 @@
`Cloud sessions use your claude.ai login`, at the end of a policy denial that names a credential| Command-line errors
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
`Cloud sessions aren't available:` followed by why your organization’s policy couldn’t be loaded| Command-line errors
+`Cloud sessions aren't available with this Console sign-in. They need a claude.ai sign-in.`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Cloud sessions need a claude.ai sign-in`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Nothing was stashed: "<path>" is now a folder in place of a tracked file or link` / `are now folders in place of tracked files or links`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
@@ -317,6 +318,7 @@
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
+`command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run`| Tool errors
`File is too large to read as an image (the limit is 128MB)`| Tool errors
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
@@ -389,6 +391,7 @@
`Claude Code process exited with code N`| Wrapper and IDE errors
`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
+`The Claude Code program for this computer, the <build> build, could not be found`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
`Transcript writes are failing (...)`| Session saving warnings
@@ -477,13 +480,21 @@
What you see while Claude Code retries or waits
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. After the abort, what you see depends on how far the response had got:
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations.
+
+####
+
+
+
+Waiting for API response
+
+The `Waiting for API response · will retry in … · check your network` banner means that Claude Code has waited at least 20 seconds without receiving any data for a request. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. If the abort happens:
* Before Claude has completed a block of text or a tool call, or started one after finishing its thinking, Claude Code retries the request or ends the turn with an error. Automatic retries says which stalls it retries and how many times.
* After Claude has completed a block of text or a tool call, or started one after finishing its thinking, but before Claude has finished the response, Claude Code keeps what Claude completed, continues the turn from any tool calls Claude finished, and shows The response above may be incomplete. In a non-interactive session, and for a subagent’s response in any session, Claude Code may first prompt Claude to continue the response; that entry says when it does and when you still see the notice there.
* After Claude finished the response, Claude Code ends the turn normally.
-The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. If you connect through a gateway, see The waiting banner comes and goes behind a gateway. Before v2.1.185, the banner appeared after 10 seconds with different wording.
####
@@ -2332,7 +2343,7 @@
The first form means the schema isn’t valid JSON Schema draft 2020-12. The second means a top-level property name doesn’t match the pattern the message quotes. Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a [deployment where flag fetching is off](</docs/en/env-vars#features-that-need-feature-flag-fetching>), or on a machine whose flags have never arrived, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`. Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though the top-level property-name check still applies. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
- * If your Claude Code version is earlier than v2.1.216, run `claude update`.
+ * If your Claude Code version is earlier than v2.1.300, run [`claude update`](</docs/en/setup#update-claude-code>) in your shell. Before v2.1.300, Claude Code didn’t [retry the request without the rejected tool’s parameters](</docs/en/mcp#tools-whose-input-schema-the-api-refuses>), so this error repeated on every request that included the tool.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
* If you maintain the server, fix the tool’s `input_schema`. The schema must be valid JSON Schema, and top-level property names must be 1 to 64 characters long and use only ASCII letters and digits, `_`, `.`, and `-`. See [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>).
@@ -3406,7 +3417,6 @@
* `Shell command permission check failed for pattern "..."`: the command’s permission check didn’t allow it. [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>) covers which results abort in each permission mode and how to pre-approve a command with `allowed-tools`
* `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
- * `No shell command in <name> was run`: one of the file’s `!` commands contains a raw control character other than tab or newline, so none of them runs. See how to find and remove the character
**What to do:**
@@ -3420,14 +3430,19 @@
No shell command in a skill or command was run
-One of the `!`<command>`` [dynamic context commands](</docs/en/skills#inject-dynamic-context>) in a skill or custom command file contains a raw control character other than tab or newline. Claude Code refuses the whole invocation before any of the file’s commands runs. The message names the shell tool that would have run the commands, Bash or PowerShell, and ends with the refused command. Each such character is replaced by `�` so you can see where it is:
+`No shell command in <name> was run` means a `!`<command>`` [dynamic context command](</docs/en/skills#inject-dynamic-context>) in that skill or command file contains a character that the Bash or PowerShell tool refuses:
+
+ * **Either tool** : a raw control character other than a tab or newline
+ * **PowerShell tool** : also U+FEFF or U+180E
+
+The message ends with the refused command, showing each refused character as `�`, as in this Bash tool example:
No shell command in /my-skill was run, because the Bash tool does not accept one of them: command contains control characters that would be hidden in the approval dialog. Unprintable characters are shown as � below: remove them from the skill or command file, or from the arguments or options substituted into it.
build.sh --target�dist
**What to do:**
- * Find each `�` in the command quoted at the end of the message. Remove the character it stands for from the skill or command file, or from the arguments or options substituted into the file.
+ * Find each `�` in the command quoted at the end of the message. Remove the character it stands for from the [skill or command file](</docs/en/skills#where-skills-live>), or from the arguments or [options](</docs/en/plugins/manifest-reference#user-configuration>) substituted into the file.
###
@@ -4372,6 +4387,21 @@
* Nothing on your side: the error is returned to Claude as the tool’s result, and the message itself tells Claude to remove the null byte and try again
Before v2.1.281, a null byte in a Read, Write, Edit, or NotebookEdit path ended the whole turn with an error naming `Path contains null bytes`, and the tool never ran.
+
+###
+
+
+
+Command contains an invisible character
+
+The [PowerShell tool](</docs/en/tools-reference#powershell-tool>) refused to run a command that contains U+FEFF or U+180E:
+
+ Error: command contains the invisible character U+FEFF (byte order mark) or U+180E (Mongolian vowel separator), and was not run. Remove the character, keep the text that needs it in a file that the command reads, or write it as $([char]0xFEFF) or $([char]0x180E) inside a double-quoted string
+
+**What to do:**
+
+ * **For a command Claude wrote** : you have nothing to fix. The message tells Claude how to rewrite the command.
+ * **For a skill or command file** : the message follows `No shell command in <name> was run`. See where to find the character and remove it.
###
@@ -5219,6 +5249,24 @@
+The Claude Code program for this computer could not be found
+
+The [VS Code extension](</docs/en/vs-code>) looked for the copy of Claude Code bundled inside it and found none built for your computer. The message names the build your computer needs:
+
+ The Claude Code program for this computer, the Linux (linux-x64) build, could not be found.
+
+**What to do:**
+
+ * If the message says which build the extension holds, you have the extension package for another platform: install the package made for the build the message names
+ * If the message doesn’t say which build the extension holds, reinstall the Claude Code extension from your editor’s Extensions view
+ * Or, in either case, set [`claudeCode.claudeProcessWrapper`](</docs/en/vs-code#extension-settings>) to a separately installed `claude` binary
+
+Before v2.1.290, this appeared as `Unsupported platform: <platform>-<arch>. No compatible Claude Code binary found.`
+
+###
+
+
+
The connection to Claude Code ended before this message completed
The [VS Code extension](</docs/en/vs-code>) sent your message to the `claude` process, and the connection ended without an error before the process acknowledged or finished it. The extension can’t tell whether the message was processed, so it asks you to send it again:
--- a/errors.md
+++ b/errors.md
@@ -138,6 +138,7 @@
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
`Couldn't send feedback`| Network
+`Feedback payload too large. Try again without the transcript, or shorten the details.`| Network
`MCP server "<name>" connection timed out. Your computer went to sleep or its clock changed while connecting.`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
@@ -327,6 +328,7 @@
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
`Only a teammate can approve a shutdown request`| Tool errors
+`A command-line deny rule cannot be handed to a teammate intact`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
`Cross-session message was dropped at the recipient session's inbox`| Tool errors
@@ -2061,7 +2063,7 @@
Couldn’t send feedback
-A message starting `Couldn't send feedback` means the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>), wasn’t sent. When a sentence about your organization follows the colon, your organization refuses feedback and the same report gets the same answer. The first of these two examples is a network failure and the second is an organization’s refusal:
+A message starting `Couldn't send feedback` means the feedback service didn’t confirm the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>). Treat it as not received. When a sentence about your organization follows the colon, your organization refuses feedback and the same report gets the same answer. The second of these two examples is an organization’s refusal:
Couldn't send feedback (couldn't reach the service). If it keeps failing, you can file at https://github.com/anthropics/claude-code/issues instead.
@@ -2072,10 +2074,24 @@
* **Not signed in** : the message continues `: not signed in. Run /login, then retry.` Run `/login`, then send again
* **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` If the message adds `To report a bug, open an issue`, do so at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). A queued draft stays queued, and you can [discard it](</docs/en/tools-reference#discard-or-keep-a-draft>)
* **Refused credentials** : the message continues `: the sign-in this session uses is not allowed to send feedback` or `: the server did not accept the credentials this session uses`. Run `/status` at the Claude Code prompt to see which login, token, or API key this session sends
- * **`(request timed out)` or `(couldn't reach the service)` straight after `Couldn't send feedback`**: these are network failures. Send the report or the queued draft again. The dialog keeps your text, and a queued draft’s message says `The draft is still queued.` If other requests are failing too, check your network connection and see Unable to connect to API. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
+ * **`(request timed out)` or `(couldn't reach the service)` straight after `Couldn't send feedback`**: send the report or the queued draft again. The dialog keeps your text, and a queued draft’s message says `The draft is still queued.` If other requests are failing too, check your network connection and see Unable to connect to API. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
* **`(server returned<status>)`, or no reason, straight after `Couldn't send feedback`**: the status is the service’s response code. The service’s own message follows it when one was sent, as in `(server returned 403: Access Forbidden)`. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
Issues at github.com/anthropics/claude-code are public, so leave out code, transcripts, and anything else confidential when you open one. Before v2.1.281, every send failed with this message once a Remote Control **Stop** or an urgent cross-session message had arrived while the dialog was open. On those versions, close the dialog, reopen it, and send again.
+
+###
+
+
+
+Feedback payload too large
+
+This message in the [review screen](</docs/en/tools-reference#review-and-edit-a-draft>) for a [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>) means Claude Code has no confirmation that the service accepted the draft. Treat it as not received. The draft stays in your `/feedback` queue, so you can send it again.
+
+ Feedback payload too large. Try again without the transcript, or shorten the details.
+
+**What to do:**
+
+ * In the review screen, set **Send transcript** to `no`, then send the draft again. Shortening the details removes at most 10 KB of text, which is all a draft’s details can hold.
###
@@ -3297,7 +3313,7 @@
MCP server rejected the elicitation capability
-An MCP server built on Java MCP SDK 0.11.0 through 0.17.0 refused the connection. Those SDK versions can’t parse the `form` and `url` [elicitation modes](</docs/en/mcp#elicitation-modes-claude-code-declares>) that Claude Code declares in its handshake. `claude mcp list` shows the server as failed with this message in place of the server’s own error:
+An MCP server built on Java MCP SDK 0.11.0 through 0.17.0 refused the connection. Those SDK versions can’t parse the `form` and `url` [elicitation modes](</docs/en/mcp#elicitation-modes-claude-code-declares>) that Claude Code declares in its handshake. The message reads:
This server (Java MCP SDK 0.17.0 or older) rejected Claude Code's elicitation capability. Set "bareElicitationCapability": true for it, or upgrade to Java MCP SDK 0.17.1+ (Spring AI 1.0.7+ or 1.1.6+).
@@ -4478,6 +4494,21 @@
* If the refusal appeared in your lead session, first check whether the teammate has since shut down. The refusal goes back to Claude with the instruction to send a `shutdown_request` instead, and the turn continues. In an interactive lead session, `<name> has shut down.` appears when the teammate approves a shutdown request.
* If the teammate is still running, ask the lead at its prompt to shut the teammate down, for example `Ask the researcher teammate to shut down`. See [Shut down teammates](</docs/en/agent-teams#shut-down-teammates>).
* If a former teammate you resumed yourself with `claude --resume` got this refusal, nothing was sent. To end that session, run `/exit` at its prompt.
+
+###
+
+
+
+A command-line deny rule cannot be handed to a teammate intact
+
+This message means Claude Code didn’t start a [split-pane](</docs/en/agent-teams#choose-a-display-mode>) teammate in your [agent team](</docs/en/agent-teams>). Claude Code passes the lead’s command-line deny rules to a split-pane teammate on the teammate’s own command line, and stops when the teammate would read one of them differently:
+
+ A command-line deny rule cannot be handed to a teammate intact, so the teammate would not enforce it — spawn aborted
+
+**What to do:**
+
+ * Run `/config` in the lead session and set **Teammate mode** to `in-process`, then ask Claude to start the teammate again. You don’t need to find the rule or restart the lead. An in-process teammate [runs under the lead’s live deny rules](</docs/en/agent-teams#permissions>).
+ * Later sessions that take [`teammateMode`](</docs/en/settings-reference#teammatemode>) from your user settings start teammates in-process too, because `/config` saves the choice there. To go back to split panes in a later session, set **Teammate mode** to `auto`, `tmux`, or `iterm2`, whichever you used before.
###
--- a/errors.md
+++ b/errors.md
@@ -236,6 +236,7 @@
`MCP server "<name>" was not saved to` / `was not removed from`| Command-line errors
`MCP server "<name>" may not have been saved` / `may not have been removed`| Command-line errors
`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
+`This server (Java MCP SDK 0.17.0 or older) rejected Claude Code's elicitation capability`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`OAuth callback port <port> is already in use — another process may be holding it`| Command-line errors
`No available ports for OAuth redirect`| Command-line errors
@@ -366,7 +367,7 @@
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
`Bypass permissions was requested at launch and ignored`| [Bypass permissions ignored in a background session](</docs/en/permission-modes#bypass-permissions-ignored-in-a-background-session>)
-`kept <id> — its worktree is still at <path>`| Background session errors
+`kept <id> — its worktree is still at <path>`| Background session errors if the message’s next line mentions unpushed commits, otherwise [What deleting a session removes](</docs/en/agent-view#what-deleting-a-session-removes>)
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
@@ -3294,6 +3295,35 @@
+MCP server rejected the elicitation capability
+
+An MCP server built on Java MCP SDK 0.11.0 through 0.17.0 refused the connection. Those SDK versions can’t parse the `form` and `url` [elicitation modes](</docs/en/mcp#elicitation-modes-claude-code-declares>) that Claude Code declares in its handshake. `claude mcp list` shows the server as failed with this message in place of the server’s own error:
+
+ This server (Java MCP SDK 0.17.0 or older) rejected Claude Code's elicitation capability. Set "bareElicitationCapability": true for it, or upgrade to Java MCP SDK 0.17.1+ (Spring AI 1.0.7+ or 1.1.6+).
+
+**What to do:**
+
+ * Upgrade the server to Java MCP SDK 0.17.1 or later, or to one of the Spring AI releases the message names
+ * Or add `"bareElicitationCapability": true` to that server’s entry in your MCP configuration, then restart Claude Code. The field is accepted on stdio, `sse`, `http`, and `ws` entries and requires Claude Code v2.1.281 or later
+
+This `.mcp.json` entry sets the field for one HTTP server:
+
+ {
+ "mcpServers": {
+ "inventory": {
+ "type": "http",
+ "url": "https://mcp.example.com/mcp",
+ "bareElicitationCapability": true
+ }
+ }
+ }
+
+After the restart, `/mcp` shows the server as connected. Claude Code declares form mode only to that server, so remove the field once you upgrade it. A server can also fail with its own error text, such as one containing `Unrecognized field "form"`. The same fixes apply.
+
+###
+
+
+
MCP permission prompt tool not found
The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
@@ -4895,10 +4925,10 @@
When Claude Code can’t summarize the commits, the detail line reads `The worktree has unpushed commits` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
* To keep the commits, push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
- * To discard the commits, run the `claude rm <id> --discard-unpushed` command the message printed, or press `Ctrl+X` twice on the session’s row in agent view again. This removes the session and the worktree along with its branch, the unpushed commits, and any uncommitted changes. If the worktree has gained a commit since the refusal, Claude Code keeps it again and shows the updated state
+ * To discard the commits, run the `claude rm <id> --discard-unpushed` command the message printed, or press `Ctrl+X` twice on the session’s row in agent view again. This removes the session and the worktree along with its branch, the unpushed commits, and any uncommitted changes. If the delete is refused again, follow the new message.
* When the message says the worktree is also recorded by another finished session, deleting again doesn’t discard it: push the commits, then delete the session again
-Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or the commits, and deleting again was refused the same way: deleting the session without pushing meant removing the worktree yourself with `git worktree remove --force <path>`, then running `claude rm <id>` again. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
+Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or commits, and there was no discard route. You can still delete the session, losing uncommitted changes but keeping the branch and commits. Run `git worktree remove --force --force <path>` with the path the refusal printed, then `claude rm <id>`. Git needs `--force` twice for a locked worktree. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
###
--- a/errors.md
+++ b/errors.md
@@ -319,6 +319,8 @@
`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
+`Sandbox is required but failed to initialize: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
+`Sandbox is required (sandbox.failIfUnavailable) and stopped being available in this session: <reason>`| [Sandboxing troubleshooting](</docs/en/sandboxing#commands-refused-with-sandbox-is-required>)
`pkill: refusing to run`| Tool errors
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
Show diff (111 lines)
--- a/errors.md
+++ b/errors.md
@@ -309,6 +309,7 @@
`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
`Error: No such tool available: <tool name>`| Tool errors
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
+`MCP server "<name>" is disabled — re-enable it via /mcp to use its tools`| Tool errors
`MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit.`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
@@ -341,6 +342,7 @@
`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)` / `The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
+`git is not installed on this Mac. To install it, run xcode-select --install, then try again.`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
@@ -478,6 +480,20 @@
The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+####
+
+
+
+The waiting banner comes and goes behind a gateway
+
+If the `Waiting for API response` banner comes and goes while Claude thinks and you connect through a gateway, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.309 or later. The banner appears after 45 seconds without data on these connections:
+
+ * [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) set to a host other than the Anthropic API, such as an [LLM gateway](</docs/en/llm-gateway>)
+ * A [Claude apps gateway](</docs/en/claude-apps-gateway>) session
+ * [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) with `ANTHROPIC_AWS_BASE_URL` set
+
+Before v2.1.309, the banner appeared after 20 seconds on these connections.
+
###
@@ -3068,7 +3084,7 @@
For example, the subcommand can’t ask when its standard input or standard output isn’t a terminal. Sending the output to a file, as in `claude ultrareview --json > findings.json`, means standard output isn’t a terminal. **What to do:**
- * In a script or CI job, append `--trust-workspace` to trust the checkout for that run only: `claude ultrareview --trust-workspace`. Append it only for code you trust, because the checkout’s git configuration and Claude Code project settings can then run programs. To review a pull request whose code you don’t trust, see [how to review it from a checkout you do trust](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>).
+ * In a script or CI job, append `--trust-workspace` to trust the folder for that run: `claude ultrareview --trust-workspace`. Append it only for code you trust, because git and Claude Code can then run programs named in the folder’s git configuration and project settings. For a pull request whose code you don’t trust, [run the review from a branch you trust](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>).
* On your own machine, run `claude` in that folder and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
Each of these messages from `claude ultrareview` means that no review started and the exit code is 1:
@@ -4218,6 +4234,22 @@
* If the action happened, don’t run the tool again. Claude received this message in place of the tool’s result, so tell Claude the outcome.
* If the action didn’t happen, ask Claude to run the tool again. You don’t need to reconnect the server first, because Claude Code connects to it again for the next call to one of its tools. If that connection fails too, see [Mid-session drops of a remote server](</docs/en/mcp#mid-session-drops-of-a-remote-server>).
* If you build the server and the tool is safe to call twice, [mark it as safe to repeat](</docs/en/mcp#tool-calls-pending-when-a-connection-closes>) so that Claude Code can repeat a lost call
+
+###
+
+
+
+MCP server is disabled
+
+This message in a tool result means Claude called a tool on an [MCP server](</docs/en/mcp>) that is [turned off](</docs/en/mcp#disable-a-server-without-removing-it>). Claude Code didn’t connect to the server, so the tool didn’t run, and Claude received this text in place of a result:
+
+ MCP server "<name>" is disabled — re-enable it via /mcp to use its tools
+
+**What to do:**
+
+ * If you meant to turn the server off, you don’t need to do anything
+ * If Claude needs the server’s tools, turn it back on from `/mcp` at the Claude Code prompt
+ * In an [Agent SDK](</docs/en/agent-sdk/overview>) application, turn the server back on by calling [`toggleMcpServer()`](</docs/en/agent-sdk/typescript#togglemcpserver>) in TypeScript with `enabled` set to `true`, or [`toggle_mcp_server()`](</docs/en/agent-sdk/python#claudesdkclient>) in Python with `enabled` set to `True`
###
@@ -4558,7 +4590,7 @@
The command was not started: this computer's disk is full (ENOSPC) on the volume holding /tmp/claude-501 (Claude Code's temporary directory), so the file that captures command output could not be created there and nothing ran. Free space on that volume, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another one, then retry. If this is the user's own computer, tell them before deleting anything to make room.
-The other three messages follow a command that ran and exited with a nonzero code. This example is the `Disk full:` form:
+The `Disk full:`, `Disk quota used up:`, and `Nearly out of inodes:` messages follow a command that ran and exited with a nonzero code. For example:
Disk full: this computer's volume holding /tmp/claude-501 (Claude Code's temporary directory) has 3 MB free, so whatever this command printed was lost and its own writes may have failed with "No space left on device". Free space on that volume, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another one, then retry. If this is the user's own computer, tell them before deleting anything to make room.
@@ -4566,8 +4598,7 @@
* On macOS and Linux, run `df -h <dir>` in your shell to see which volume holds the directory and how full it is. `df -i <dir>` shows how many inodes are free. `<dir>` is the directory your message names, as in `df -i /tmp/claude-501`
* **`Disk full: this computer's volume` or `disk is full (ENOSPC)`**: anywhere on that volume, delete files you don’t need
- * **`Disk quota used up:` or `Disk full: a test write`**: delete your own files on that volume, even if it still shows free space
- * **`disk quota is used up (EDQUOT)`** : delete your own files on that volume
+ * **`Disk quota used up:`, `disk quota is used up (EDQUOT)`, or `Disk full: a test write`**: delete your own files on that volume, even if it still shows free space
* **`Nearly out of inodes:`** : delete many files on that volume. Each takes one inode whatever its size, so their number matters, not their size
* Or restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a directory on a volume with room
* Then have Claude run the command again
@@ -4580,6 +4611,20 @@
* `The command was not started: this computer's disk is full (ENOSPC), so the file that captures command output could not be created. Nothing ran.`, or the same with `(EDQUOT)`. This form names no directory: look on the volume holding your system temp directory, such as `/tmp`, or the directory set in `CLAUDE_CODE_TMPDIR`
Before v2.1.305, a command that Claude Code couldn’t start because the disk was full returned only the operating system’s error text. That text read, for example, `ENOSPC: no space left on device, open <path>.output`.
+
+###
+
+
+
+git is not installed on this Mac
+
+This message means a step in Claude Code needed git, and the git it found is Apple’s stand-in at `/usr/bin/git`. The developer tools that provide git aren’t installed. Claude Code doesn’t start the stand-in and shows this text instead, for example inside a longer message:
+
+ git is not installed on this Mac. To install it, run xcode-select --install, then try again.
+
+**What to do:**
+
+ * In Terminal, run `xcode-select --install`, finish the installation it starts, then retry what you were doing in Claude Code
###
--- a/errors.md
+++ b/errors.md
@@ -309,6 +309,7 @@
`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
`Error: No such tool available: <tool name>`| Tool errors
`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
+`MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit.`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
@@ -4222,6 +4223,23 @@
+MCP tool call timed out with the server’s question unanswered
+
+In [non-interactive mode](</docs/en/headless>), an [MCP server](</docs/en/mcp>) asked for input through [elicitation](</docs/en/mcp#respond-to-mcp-elicitation-requests>) during a tool call, and the call’s time limit ran out before an answer came:
+
+ MCP server "<name>" tool "<tool>" timed out after <N>s. The server asked the user a question, and no answer came before the time limit. Do not call this tool again in this turn. Tell the user that the server's question got no answer, and wait for their reply.
+
+Before v2.1.310, the result ended at `timed out after <N>s` and said nothing about the question. **What to do:**
+
+ * Set up an [`Elicitation` hook](</docs/en/hooks#elicitation>) that answers the server’s requests
+ * In a TypeScript Agent SDK application, make your [`onElicitation`](</docs/en/agent-sdk/typescript#options>) callback return its answer before the limit runs out
+ * To give an answer more time, set a longer [`timeout`](</docs/en/mcp#time-limits-on-mcp-tool-calls>) in milliseconds in the server’s configuration entry, such as `"timeout": 600000` for 10 minutes
+ * Run the task in an interactive session instead and answer the server’s [dialog](</docs/en/mcp#respond-to-mcp-elicitation-requests>) yourself
+
+###
+
+
+
Agent would be spawned with zero tools
Every entry in the subagent’s [`tools` list](</docs/en/sub-agents#supported-frontmatter-fields>) failed to match a usable tool, so Claude Code refused to launch the subagent: with no tools, it couldn’t act. The message groups your entries by what went wrong:
Show diff (408 lines)
--- a/errors.md
+++ b/errors.md
@@ -99,6 +99,8 @@
`(check the helper, then start a new task or chat)` / `(update it, then start a new task or chat)`| Authentication
`MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate`| Authentication
`MCP server "<name>" requires re-authorization (token expired)`| Authentication
+`Couldn't read the stored credentials for MCP server "<name>", so the request didn't run`| Authentication
+`A request to MCP server "<name>" was sent without your stored credentials`| Authentication
`This server's URL is missing or not a valid URL, so sign-in can't start`| Authentication
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
`Refusing to send credentials to non-https token endpoint` / `<short-name> from the MCP SDK for <server-url>`| Authentication
@@ -136,6 +138,7 @@
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
`Couldn't send feedback`| Network
+`MCP server "<name>" connection timed out. Your computer went to sleep or its clock changed while connecting.`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
`Prompt is too long · this conversation is a single exchange` / `A single-exchange conversation cannot be compacted`| Request errors
@@ -215,9 +218,12 @@
`Error: --agents file not found`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
-`Temp directory <dir> ... Refusing to use it` / `ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
+`Temp directory <dir> ... Refusing to use it` / `Claude Code's temporary directory <dir> could not be created`| Command-line errors
+`ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
`couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
+`Error: Workspace not trusted` when running `claude ultrareview`| Command-line errors
+`Ultrareview did not start`| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
`--sandbox is not supported by claude remote-control` / `--no-sandbox is not supported by claude remote-control`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
@@ -300,7 +306,9 @@
`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
`Plugin directory does not exist: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-directory-does-not-exist>)
+`Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)`| Plugin errors
`Error: No such tool available: <tool name>`| Tool errors
+`MCP server "<name>" connection closed before the tool call was answered`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
@@ -326,10 +334,11 @@
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
`Command killed: its output file was replaced or could no longer be verified`| Tool errors
-`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)`| Tool errors
-`The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
+`Disk full: this computer's volume holding <dir> (Claude Code's temporary directory) has <n> MB free` / `Nearly out of inodes: this computer's volume holding <dir>`| Tool errors
+`Disk full: a test write beside this command's output file` / `Disk quota used up: a test write beside this command's output file`| Tool errors
+`The command was not started: this computer's disk is full (ENOSPC)` / `the user's disk quota is used up (EDQUOT)`| Tool errors
+`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)` / `The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
-`The command was not started: this computer's disk is full (ENOSPC)` / `(EDQUOT)`| Tool errors
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
@@ -417,6 +426,7 @@
`Claude Code doesn't recognize the model "<model>", so it assumes a context window of 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`[claude-code:unrecognized_model]`| Configuration warnings
`is ignored — managed settings set allowManagedReadPathsOnly` / `is ignored — managed settings set allowManagedDomainsOnly`| Configuration warnings
+`Sandbox mask files left behind at write-deny paths`| Configuration warnings
`Stale sandbox mask files left by a killed session`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -433,7 +443,7 @@
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
* A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and streams the request again at most once. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
- * A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
+ * A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>). At the deadline, Claude Code aborts the request and re-sends it within the retry budget. If the deadline fires for a re-send too, the turn ends with No response from API. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, Claude Code keeps re-sending within the budget instead.
* A streaming response that the API’s output content filter stops before Claude has either finished thinking or started any text or tool call. Claude Code re-sends the request once, within the retry budget, and shows Output blocked by content filtering policy if the filter stops the second response too.
* Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
* When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
@@ -551,7 +561,7 @@
No response from API
-Claude Code sent a streaming request and the API returned no response headers within the deadline for the first byte, so Claude Code aborted the request instead of waiting for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default. Claude Code sends the request again at most once, if the retry budget allows. When the retry goes unanswered too, the turn ends with this message, which shows how long each attempt waited. When you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), the one-retry cap doesn’t apply and Claude Code retries under the budget described in Tune retry behavior.
+Claude Code sent a streaming request, and the API returned no response headers within the deadline for the first byte. Claude Code aborts such a request rather than wait for the full `API_TIMEOUT_MS` request timeout, and sends it again if the retry budget allows. When the deadline passes for the retry too, the turn ends with this message, which shows how long each attempt waited. If you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), Claude Code keeps retrying under the budget described in Tune retry behavior instead of ending the turn.
API Error: No response from API (waited 3m, then 10m on the retry). If a proxy or gateway on your network holds responses until they complete, raise API_TIMEOUT_MS or CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS to wait longer.
@@ -560,14 +570,14 @@
* **First attempt** : [`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>) when you set it to 1 or more, clamped to between 10 seconds and 30 minutes. Otherwise Claude Code uses the byte-level watchdog timeout listed in [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>), so the variables that change that timeout change this wait too. Either way, Claude Code adds one second for every 32KB of request body.
* **Retry** : one second less than `API_TIMEOUT_MS`, just under 10 minutes by default, so that the retry can outlast a proxy or gateway that holds the response until generation completes. On Amazon Bedrock, the retry uses the same deadline as the first attempt, and the message shows one duration instead of two. Except on Amazon Bedrock, if you set `API_TIMEOUT_MS` to `0`, the retry waits 10 minutes plus one second per 32KB, or as long as the first attempt if that’s longer.
-Neither wait exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
+Neither wait exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. In a [Claude apps gateway](</docs/en/claude-apps-gateway>) session, this deadline runs only when you [turn it on](</docs/en/claude-apps-gateway-deploy#retry-an-unanswered-request-sooner-with-the-first-byte-deadline>) by setting `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` to `1` or more. **What to do:**
* Send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
* If it repeats, treat it as a network or proxy problem.
* If a proxy or gateway on your network holds responses until they complete, raise `API_TIMEOUT_MS` so the retry waits longer. On Amazon Bedrock, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` as well.
* If the first attempt keeps timing out and the retry then succeeds, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` so the first attempt waits long enough too.
-Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request. Before v2.1.261, the retry waited the same deadline as the first attempt and the message showed no durations.
+Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request. Before v2.1.261, the retry waited the same deadline as the first attempt and the message showed no durations. Before v2.1.307, Claude Code ignored `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` in a Claude apps gateway session.
###
@@ -1485,6 +1495,37 @@
+Couldn’t read the stored credentials for MCP server
+
+Claude Code keeps your sign-ins for OAuth [MCP servers](</docs/en/mcp>) in a credential store. This message means Claude Code couldn’t read that store, so a request to the server didn’t run:
+
+ Couldn't read the stored credentials for MCP server "<name>", so the request didn't run. If your Mac's keychain is locked, unlock it, then try again.
+ Couldn't read the stored credentials for MCP server "<name>", so the request didn't run. Try again.
+
+Your stored sign-ins are unchanged: try again once the store can be read, and sign in again only if the server then asks you to. In a [`claude -p`](</docs/en/headless>) or [Agent SDK](</docs/en/agent-sdk/overview>) run on macOS, the keychain can become readable after a request has already gone out without the stored sign-in. That request fails with:
+
+ A request to MCP server "<name>" was sent without your stored credentials, so the server rejected it. The credentials are available now. Try again.
+
+**What to do:**
+
+ * If the message asks you to unlock your Mac’s keychain, run [`claude doctor`](</docs/en/cli-reference#cli-commands>) in the shell session you run Claude Code from, and check its report for a keychain warning:
+ * If the report lists a warning that starts with `macOS Keychain is not writable`, or your shell has no `claude` command, run this unlock command in that shell session:
+
+ security unlock-keychain ~/Library/Keychains/login.keychain-db
+
+ * If the report lists no keychain warning, skip the unlock command
+ * Try again where you saw the message:
+ * For `claude -p`, run the command again
+ * In an interactive session, reconnect the server from `/mcp` if it shows as failed there, then ask Claude to try again
+ * In an Agent SDK application that keeps running, call [`reconnectMcpServer()`](</docs/en/agent-sdk/typescript#methods>) in TypeScript or [`ClaudeSDKClient.reconnect_mcp_server()`](</docs/en/agent-sdk/python#methods>) in Python, or start a new session
+ * If the server then reports that it needs authentication, Claude Code found no sign-in it can use for that server. Sign in interactively: run `/mcp` in a Claude Code session, or [`claude mcp login <name>`](</docs/en/mcp#authenticate-from-the-command-line>) in your shell. In an Agent SDK application, see [OAuth2 authentication in the Agent SDK](</docs/en/agent-sdk/mcp#oauth2-authentication>).
+
+Before v2.1.307, a `claude -p` or Agent SDK run on a Mac with a locked login keychain reported the server as needing authentication instead of showing either message.
+
+###
+
+
+
MCP server URL is missing or not a valid URL
Claude Code refused to start an OAuth sign-in for a remote MCP server because the server’s configured `url` doesn’t parse as a URL. Unless Claude Code has a more specific configuration problem to report for the server, running [`claude mcp login <name>`](</docs/en/mcp#authenticate-from-the-command-line>) in your shell prints the refusal as:
@@ -2000,22 +2041,40 @@
Couldn’t send feedback
-You sent a report from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>) and the upload to Anthropic failed. The dialog keeps your text so you can retry.
+A message starting `Couldn't send feedback` means the report you submitted from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>), or a queued [feedback draft](</docs/en/tools-reference#sendfeedback-tool-behavior>), wasn’t sent. When a sentence about your organization follows the colon, your organization refuses feedback and the same report gets the same answer. The first of these two examples is a network failure and the second is an organization’s refusal:
Couldn't send feedback (couldn't reach the service). If it keeps failing, you can file at https://github.com/anthropics/claude-code/issues instead.
-The text after the prefix names what failed:
-
- * **`: not signed in. Run /login, then retry.`** : the dialog uploads only when Claude Code found Anthropic credentials as it opened, and none were usable by the time you sent. For example, you signed out on this machine in the meantime, or your login could no longer be refreshed.
- * **A parenthetical** : `(server returned <status>)` is the service’s response code; `(request timed out)` and `(couldn't reach the service)` are network failures. When Claude Code can’t name a reason, the parenthetical is absent.
-
-In the [feedback drafts queue](</docs/en/tools-reference#sendfeedback-tool-behavior>), the same failure ends with `The draft is still queued. Try again later.` instead, and the draft stays in the queue for another attempt. **What to do:**
-
- * For the not-signed-in wording, run `/login` and send again
- * Otherwise, send again; if other requests are failing too, check your network connection and see Unable to connect to API
- * If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>), as the message says
-
-Before v2.1.281, every send failed with this message once a Remote Control **Stop** or an urgent cross-session message had arrived while the dialog was open. On those versions, close the dialog, reopen it, and send again.
+ Couldn't send feedback: Feedback has not been enabled for your organization. To report a bug, open an issue at https://github.com/anthropics/claude-code/issues. Issues are public, so leave out anything confidential.
+
+**What to do:**
+
+ * **Not signed in** : the message continues `: not signed in. Run /login, then retry.` Run `/login`, then send again
+ * **Your organization’s refusal** : for example `: Feedback has not been enabled for your organization.` or `: Feedback collection is not available for organizations with custom data retention policies.` If the message adds `To report a bug, open an issue`, do so at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). A queued draft stays queued, and you can [discard it](</docs/en/tools-reference#discard-or-keep-a-draft>)
+ * **Refused credentials** : the message continues `: the sign-in this session uses is not allowed to send feedback` or `: the server did not accept the credentials this session uses`. Run `/status` at the Claude Code prompt to see which login, token, or API key this session sends
+ * **`(request timed out)` or `(couldn't reach the service)` straight after `Couldn't send feedback`**: these are network failures. Send the report or the queued draft again. The dialog keeps your text, and a queued draft’s message says `The draft is still queued.` If other requests are failing too, check your network connection and see Unable to connect to API. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
+ * **`(server returned<status>)`, or no reason, straight after `Couldn't send feedback`**: the status is the service’s response code. The service’s own message follows it when one was sent, as in `(server returned 403: Access Forbidden)`. If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>)
+
+Issues at github.com/anthropics/claude-code are public, so leave out code, transcripts, and anything else confidential when you open one. Before v2.1.281, every send failed with this message once a Remote Control **Stop** or an urgent cross-session message had arrived while the dialog was open. On those versions, close the dialog, reopen it, and send again.
+
+###
+
+
+
+MCP server connection timed out during a sleep or clock change
+
+This message means a connection to an [MCP server](</docs/en/mcp>) timed out, and Claude Code found that your system clock jumped forward during the attempt:
+
+ MCP server "<name>" connection timed out. Your computer went to sleep or its clock changed while connecting.
+
+Claude Code can’t tell whether your computer slept or its clock was set forward, so the message names both. **What to do:** Connect to the server again, and keep your computer awake until the attempt finishes. If the server connects, you have nothing to fix.
+
+ * **In an interactive session** : run `/mcp`, select the server, and select **Reconnect**
+ * **In your shell** : run the [`claude -p`](</docs/en/headless>), [`claude mcp list`](</docs/en/mcp#managing-your-servers>), or `claude mcp get` command again. If the server then fails with a message that starts `Skipping connection (recent failure cached`, wait 15 minutes and run the command again.
+ * **In an[Agent SDK](</docs/en/agent-sdk/overview>) application**: call [`reconnectMcpServer()`](</docs/en/agent-sdk/typescript#methods>) in TypeScript or [`ClaudeSDKClient.reconnect_mcp_server()`](</docs/en/agent-sdk/python#methods>) in Python
+ * **If the server fails again** : if the message differs from this one, see [what to check when an MCP server doesn’t connect](</docs/en/mcp-quickstart#troubleshooting>). If this message comes back although your computer stayed awake and nothing changed its clock, see Report an error.
+
+Before v2.1.307, Claude Code showed a timeout message such as `MCP server "<name>" connection timed out after <N>ms` instead of this one.
##
@@ -2336,7 +2395,7 @@
Couldn’t confirm model with the API
-You switched models through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), and the request that confirms the model ID with your API endpoint got no answer within five seconds. The session keeps its current model.
+You switched models through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), and the request that confirms the model ID with your API endpoint got no answer within 15 seconds. The session keeps its current model.
Couldn't confirm model "claude-sonnet-5" with the API. Try again, or run /model to see available models.
@@ -2939,7 +2998,7 @@
On macOS and Linux, Claude Code creates a private temp directory at startup, `claude-<uid>` under the system temp directory or the [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) override. When the directory can’t be created, or an entry already at that path fails the safety checks, Claude Code prints the failure to stderr and exits with code 1 rather than start the session:
- ENOSPC: no space left on device, mkdir '/tmp/claude-501'
+ Claude Code's temporary directory /tmp/claude-501 could not be created: the volume holding /tmp is full (ENOSPC). Free space on that volume, or set CLAUDE_CODE_TMPDIR to a directory on another one, then try again.
Temp directory /tmp/claude-501 is not a directory (may be an attacker-planted symlink). Refusing to use it. Set CLAUDE_CODE_TMPDIR to a directory you control, or ask an administrator to remove it.
@@ -2949,11 +3008,13 @@
**What to do:**
- * For `ENOSPC`, free disk space on the volume that holds the temp directory
+ * For `could not be created` followed by `is full (ENOSPC)`, free disk space on the volume the message names. When it says `your disk quota on the volume holding /tmp is used up (EDQUOT)` instead, delete your own files on that volume that you no longer need
* For the `Refusing to use it` forms, remove the named entry itself, not what a link points to, and start Claude Code again; for the `owned by uid` form, only an administrator or that user can remove it
* For `is not readable`, run `chmod 0700` on the named directory, or remove it and start again
* In any of these cases, set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory you control and start Claude Code again, leaving the refused path alone
+Before v2.1.309, Claude Code printed only the operating system’s error text when the volume was full or your quota was used up. An example is `ENOSPC: no space left on device, mkdir '/tmp/claude-501'`, and the same steps apply.
+
###
@@ -2977,6 +3038,8 @@
Workspace not trusted when starting Remote Control
+If `claude ultrareview` printed `Error: Workspace not trusted`, see Workspace not trusted when running claude ultrareview instead.
+
You started [Remote Control](</docs/en/remote-control>) server mode with `claude remote-control` or its `claude rc` alias in a directory you haven’t trusted, and the command couldn’t ask you whether to trust it. For example, the command’s standard input or standard output isn’t a terminal because one of them is redirected or piped. The command exits with code 1:
Error: Workspace not trusted. Please run `claude` in /Users/you/project first to review and accept the workspace trust dialog.
@@ -2991,6 +3054,31 @@
* In your home directory, change to a project directory and start Remote Control there
Before v2.1.284, the command never asked, even in a terminal.
+
+###
+
+
+
+Workspace not trusted when running claude ultrareview
+
+In a folder you haven’t trusted, when [`claude ultrareview`](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>) can’t ask whether you trust it, the run exits with code 1 before the review starts:
+
+ Error: Workspace not trusted. Please run `claude` in /Users/you/project first to review and accept the workspace trust dialog. Or, in a script or CI job, pass `--trust-workspace` to trust the folder for this run only.
+
+For example, the subcommand can’t ask when its standard input or standard output isn’t a terminal. Sending the output to a file, as in `claude ultrareview --json > findings.json`, means standard output isn’t a terminal. **What to do:**
+
+ * In a script or CI job, append `--trust-workspace` to trust the checkout for that run only: `claude ultrareview --trust-workspace`. Append it only for code you trust, because the checkout’s git configuration and Claude Code project settings can then run programs. To review a pull request whose code you don’t trust, see [how to review it from a checkout you do trust](</docs/en/ultrareview#trust-the-folder-before-the-review-runs>).
+ * On your own machine, run `claude` in that folder and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
+
+Each of these messages from `claude ultrareview` means that no review started and the exit code is 1:
+
+ * **`Error: Workspace not trusted. This terminal ...`** : the terminal reported no row and column count, or can’t fit the trust question and its warnings. Enlarge it or use a terminal that reports its size, then run `claude ultrareview` again. Outside your home directory, you can also run `claude` in that folder once and accept the trust dialog, so later runs there don’t ask.
+ * **`Error: Workspace not trusted.<folder> is your home directory`**: because trust for your home directory is never saved, running `claude` there first can’t help. Run `claude ultrareview` from a project directory instead, after running `claude` there once to accept the trust dialog, or append `--trust-workspace`.
+ * **`No answer in time.` followed by `Error: Workspace not trusted`**: the `Trust <folder>? [y/N]` question went unanswered for 5 minutes. Run `claude ultrareview` again and answer it.
+ * **`Ultrareview did not start:<folder> is not trusted`**: you declined at the `Trust <folder>? [y/N]` question, for example by answering `n` or pressing Enter. To start the review, run `claude ultrareview` again and answer `y`.
+ * **`Ultrareview did not start: `--trust-workspace` takes no value`** : something other than a flag follows `--trust-workspace`, such as a PR number or `false`. If you don’t trust the folder, leave the flag out. To trust it for this run, put the PR number or base branch before the flag: `claude ultrareview 1234 --trust-workspace`.
+
+Before v2.1.309, `claude ultrareview` didn’t accept `--trust-workspace`.
###
@@ -4070,6 +4158,25 @@
* Follow the last sentence of the message: repair or replace the settings file it names, or remove the plugin’s entry from `enabledPlugins` in that file yourself, then run the uninstall again
+###
+
+
+
+Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)
+
+This message means Claude Code didn’t start a stdio [MCP server that a plugin provides](</docs/en/mcp#plugin-provided-mcp-servers>), because a connection to that server failed less than 15 minutes earlier:
+
+ Skipping connection (recent failure cached; retries automatically in 15 min, or edit the plugin config to retry now)
+
+The session continues without the server’s tools, and Claude Code doesn’t try the server again in that session when the 15 minutes end. When you start a new session or [`claude -p`](</docs/en/headless>) run at least 15 minutes after the most recent failed connection, Claude Code tries the server again. **What to do:** To have Claude Code try the server again without waiting:
+
+ * **In an interactive session** : run `/mcp`, select the server, and select **Reconnect**
+ * **In an[Agent SDK](</docs/en/agent-sdk/overview>) application**: call [`reconnectMcpServer()`](</docs/en/agent-sdk/typescript#methods>) in TypeScript or [`ClaudeSDKClient.reconnect_mcp_server()`](</docs/en/agent-sdk/python#methods>) in Python with the server’s name
+ * **In`claude -p`**: start an interactive session that loads the same plugin, on the same machine and with the same operating system account and [`CLAUDE_CONFIG_DIR`](</docs/en/env-vars>) value as your runs. Reconnect the server there from `/mcp`. Once it connects, Claude Code tries the connection in your next run.
+ * **If you’re developing the plugin** : change the server’s `command`, `args`, or `env` in the plugin’s `.mcp.json` or `plugin.json`. Claude Code tries the connection in the next session or `claude -p` run that loads the changed entry.
+
+The message replaces the error from the failed connection. If the new attempt fails too, Claude Code reports that attempt’s error instead of this message.
+
##
@@ -4093,6 +4200,23 @@
* If it happens once, you don’t need to do anything. Claude reads the error and the turn continues.
* If calls to an MCP server’s tools keep failing with this error, run `/mcp` in the session or `claude mcp list` in your shell to check the server’s [status](</docs/en/mcp#server-status>), and reconnect a failed server from `/mcp`. In the Agent SDK, see [Error handling](</docs/en/agent-sdk/mcp#error-handling>).
+
+###
+
+
+
+MCP server connection closed before the tool call was answered
+
+A tool call to an HTTP [MCP server](</docs/en/mcp>) or a [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) lost its connection before the server answered, so Claude Code can’t tell whether the tool ran:
+
+ MCP server "<name>" connection closed before the tool call was answered. The tool may have run: check whether it did before running it again.
+
+Repeating the call could repeat the tool’s action, such as creating a second issue. Claude Code therefore repeats the call on its own, once, when the server marks the tool as safe to repeat. **What to do:**
+
+ * Check in the service the tool acts on whether the action happened, for example whether the issue or record it was meant to create is there
+ * If the action happened, don’t run the tool again. Claude received this message in place of the tool’s result, so tell Claude the outcome.
+ * If the action didn’t happen, ask Claude to run the tool again. You don’t need to reconnect the server first, because Claude Code connects to it again for the next call to one of its tools. If that connection fails too, see [Mid-session drops of a remote server](</docs/en/mcp#mid-session-drops-of-a-remote-server>).
+ * If you build the server and the tool is safe to call twice, [mark it as safe to repeat](</docs/en/mcp#tool-calls-pending-when-a-connection-closes>) so that Claude Code can repeat a lost call
###
@@ -4410,28 +4534,32 @@
-Disk quota or temp filesystem is full
-
-Claude Code saves each Bash and PowerShell command’s output to a file under its temp directory. These messages in a command’s result mean that the filesystem holding that directory, or your disk quota on it, is full. If Claude Code can’t create that file because the filesystem or your quota on it is full, your command doesn’t start, and the result reads:
-
- The command was not started: this computer's disk is full (ENOSPC), so the file that captures command output could not be created. Nothing ran. If this is the user's own computer, tell them before deleting anything to make room.
-
-When a command exits with a nonzero code and no output at all, Claude Code checks the filesystem holding the output file. If that filesystem is out of space or inodes, or your disk quota on it is used up, a diagnostic replaces the empty output in the command’s result:
-
- Your disk quota is full on the filesystem with Claude Code's temp directory /private/tmp/claude-501/-Users-you-my-project/1f0e62dc-4b0a-4f5e-9c2d-8a7b6c5d4e3f/tasks (EDQUOT), so any output this command printed was lost, and it may have failed because it could not write. Delete files you no longer need there, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another filesystem.
-
-The message names what ran out:
-
- * `Your disk quota is full ... (EDQUOT)`: your own quota on that filesystem is used up. A quota can be full while the filesystem still shows free space
- * `The filesystem with Claude Code's temp directory ..., or your disk quota on it, is full (ENOSPC)`: the filesystem, or your quota on it, has no space left
- * `Command output was lost: the temp filesystem at ... is full` or `... is out of inodes`: the filesystem has almost no free space left, or is running out of inodes
- * `The command was not started: this computer's disk is full (ENOSPC)` or `... (EDQUOT)`: the filesystem has no space left for the output file, or with `EDQUOT` your own quota on it is used up
-
-**What to do:**
-
- * Delete files you no longer need on the filesystem that holds Claude Code’s temp directory. If your message doesn’t name that directory, look up its default location in the [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) reference. For `EDQUOT`, delete files that count against your own quota. For `out of inodes`, delete many files rather than a few large ones, since each file takes one inode whatever its size
- * Or restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a directory on a filesystem with room
+Disk full or disk quota used up
+
+Free up space, inodes, or disk quota on the volume that holds Claude Code’s temporary directory. A line in a command’s result starting `Disk full:`, `Disk quota used up:`, or `Nearly out of inodes:` names that directory. Claude Code saves each Bash and PowerShell command’s output to a file under that directory. If it can’t create that file because the volume or your quota on it is full, your command doesn’t start, and the result Claude reads is:
+
+ The command was not started: this computer's disk is full (ENOSPC) on the volume holding /tmp/claude-501 (Claude Code's temporary directory), so the file that captures command output could not be created there and nothing ran. Free space on that volume, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another one, then retry. If this is the user's own computer, tell them before deleting anything to make room.
+
+The other three messages follow a command that ran and exited with a nonzero code. This example is the `Disk full:` form:
+
+ Disk full: this computer's volume holding /tmp/claude-501 (Claude Code's temporary directory) has 3 MB free, so whatever this command printed was lost and its own writes may have failed with "No space left on device". Free space on that volume, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another one, then retry. If this is the user's own computer, tell them before deleting anything to make room.
+
+**What to do:**
+
+ * On macOS and Linux, run `df -h <dir>` in your shell to see which volume holds the directory and how full it is. `df -i <dir>` shows how many inodes are free. `<dir>` is the directory your message names, as in `df -i /tmp/claude-501`
+ * **`Disk full: this computer's volume` or `disk is full (ENOSPC)`**: anywhere on that volume, delete files you don’t need
+ * **`Disk quota used up:` or `Disk full: a test write`**: delete your own files on that volume, even if it still shows free space
+ * **`disk quota is used up (EDQUOT)`** : delete your own files on that volume
+ * **`Nearly out of inodes:`** : delete many files on that volume. Each takes one inode whatever its size, so their number matters, not their size
+ * Or restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a directory on a volume with room
* Then have Claude run the command again
+
+Before v2.1.309, the messages read as follows, and the same steps apply:
+
+ * `Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)`
+ * `The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`
+ * `Command output was lost: the temp filesystem at <dir> is full` or `... is out of inodes`
+ * `The command was not started: this computer's disk is full (ENOSPC), so the file that captures command output could not be created. Nothing ran.`, or the same with `(EDQUOT)`. This form names no directory: look on the volume holding your system temp directory, such as `/tmp`, or the directory set in `CLAUDE_CODE_TMPDIR`
Before v2.1.305, a command that Claude Code couldn’t start because the disk was full returned only the operating system’s error text. That text read, for example, `ENOSPC: no space left on device, open <path>.output`.
@@ -5683,19 +5811,25 @@
-Stale sandbox mask files left by a killed session
-
-`claude doctor` prints this warning in its diagnostics, and `/status` lists the same line. It appears on Linux and WSL2 when [sandboxing](</docs/en/sandboxing>) is enabled with filesystem isolation on. While a sandboxed command runs, the sandbox holds a write denial on a file that doesn’t exist yet by creating a 0-byte read-only placeholder there, and removes it afterward. A session killed before that cleanup runs, for example by SIGKILL, leaves the placeholders behind. Later sessions bind them read-only again on every start, so a settings write such as saving “Yes, and don’t ask again” fails where one sits.
-
- - Stale sandbox mask files left by a killed session: /home/you/project/.claude/settings.local.json
- Fix: Remove each with `rm <path>` while no other Claude Code session is running in that project — a 0-byte read-only file where a settings file belongs makes "Yes, and don't ask again" fail to save, and the sandbox binds it read-only again on every start
-
-**What to do:**
-
- * Quit any other Claude Code session running in that project, then delete each listed file with `rm`. The warning names up to three files and counts the rest, so rerun `claude doctor` after deleting until the warning no longer appears. A placeholder that another session’s sandbox is still using is a live part of that session’s write protection
+Sandbox mask files left behind at write-deny paths
+
+This warning in `claude doctor` and `/status` lists mask files: 0-byte read-only placeholder files at paths the [sandbox](</docs/en/sandboxing>) denies writes to. It appears on Linux and WSL2 when sandboxing is enabled with filesystem isolation on. Delete them from your shell once no Claude Code session is open in the project that holds them. The sandbox creates a placeholder while a sandboxed command runs and removes it when the command ends. One stays behind in cases such as these:
+
+ * The session is killed before the command ends, for example by SIGKILL
+ * You quit the session while a sandboxed command is still running, such as one in the background
+
+In `claude doctor`, the warning reads:
+
+ - Sandbox mask files left behind at write-deny paths: /home/you/project/.claude/settings.local.json
+ Fix: A session leaves one where it was killed, or where it exited while a sandboxed command was still running. Remove each with `rm <path>` while no other Claude Code session is running in that project — a 0-byte read-only file where a settings file belongs makes "Yes, and don't ask again" fail to save, and the sandbox binds it read-only again on every start
+
+**What to do:**
+
+ * Quit every Claude Code session open in the project that holds the listed files, including any session where `/status` showed the warning, then work from your shell. A placeholder that another session’s sandbox is still using is a live part of that session’s write protection
+ * In your shell, delete each listed file with `rm`, and confirm if `rm` asks about a write-protected file. The warning names up to three files and counts the rest, so run `claude doctor` again after deleting until the warning no longer appears
* If a permission choice you saved with “Yes, and don’t ask again” didn’t stick, save it again after deleting the placeholder
-Before v2.1.257, `claude doctor` didn’t flag these files; earlier versions leave the same placeholders behind when a session is killed.
+Before v2.1.309, the warning read `Stale sandbox mask files left by a killed session`. Before v2.1.257, `claude doctor` didn’t flag these files; earlier versions leave the same placeholders behind when a session is killed.
##
--- a/errors.md
+++ b/errors.md
@@ -17,6 +17,7 @@
`Opus is experiencing high load` / `Fable is experiencing high load`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`API Error: No response from API`| Server errors
+`API Error: Stream idle timeout - no chunks received`| [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>), or [Long thinking ends in proxy timeouts](</docs/en/claude-apps-gateway-deploy#long-thinking-ends-in-proxy-timeouts>) behind a Claude apps gateway
`Server error mid-response. The response above may be incomplete.`| Server errors
`Connection lost mid-response` / `Your computer went to sleep mid-response` / `The response stopped arriving`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
@@ -25,6 +26,7 @@
`Connection lost before a response was produced` / `Your computer went to sleep before a response was produced` / `The response stalled before a response was produced`| Automatic retries
`Connection closed while thinking` / `Response stalled while thinking`| Automatic retries
`Connection lost while your computer was asleep`| Automatic retries
+`The model's tool call could not be parsed (retry also failed).`| Automatic retries
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Not run · auto mode's check had no usable answer`| Server errors
@@ -386,6 +388,7 @@
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
+`Your organization's managed settings need your approval, which couldn't be asked for here.`| Configuration warnings
`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
`Your organization's managed settings allow Claude Code to use: <providers>`| Configuration warnings
`Your organization's managed settings allow Claude Code to use no API provider at all`| Configuration warnings
@@ -437,6 +440,7 @@
* A request rejected because the input plus `max_tokens` exceeds the context limit. Re-sending it unchanged would fail the same way, so Claude Code retries with a reduced `max_tokens`, and stops retrying and compacts instead in two cases:
* When no reduction can fit, for example when the conversation itself nearly fills the context window.
* When a retry can’t shrink `max_tokens` any further. Before v2.1.218, Claude Code could re-send a reduced request that still didn’t fit, such as when the extended thinking budget exceeded the remaining context, until the retry budget ran out.
+ * A response that says Claude is calling a tool but contains no tool call. Claude Code retries by asking Claude for the tool call, up to two times. If both retries fail the same way, you see `The model's tool call could not be parsed (retry also failed).` and the turn ends. To try again, send another message. Before v2.1.307, Claude Code retried once before ending the turn.
* An expired or missing Google Cloud credential on [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), or AWS credentials that fail to load on your machine. Claude Code discards its cached credentials and retries up to two times, then reports the error so you can re-authenticate right away, as described under Could not load AWS or Google Cloud credentials. Before v2.1.228, Claude Code retried a failing Google Cloud credential through the full retry budget before showing the error.
* A `401` or `403` from the Anthropic API, directly or through an [LLM gateway](</docs/en/llm-gateway>), while an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script supplies the credential. Claude Code re-runs the script and retries with its fresh output, within the full retry budget. When the script itself fails on the re-run, Claude Code shows Your apiKeyHelper script is failing instead.
@@ -2068,7 +2072,9 @@
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
* If the error appears near 200K tokens on a model that accepts more, one cause is a model ID that Claude Code doesn’t recognize. Claude Code assumes a 200K window for such an ID, so to keep working past that point, [give it the model’s real context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>).
+ * If you use a custom [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) and the error starts with `Prompt is too long · automatic compaction failed`, [set the model’s context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>) or [update](</docs/en/setup#update-claude-code>) to v2.1.299 or later. Before v2.1.299, Claude Code ended the turn with that message near the assumed 200K window instead of sending the request.
* If the error appeared right after you stopped Claude while it was compacting the conversation, your conversation is unchanged and still large enough to need compacting. Run `/compact` and send your message again. To keep the error from recurring, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.304 or later. Before v2.1.304, stopping at that moment could end the turn with this error.
+ * On v2.1.305, with many MCP tools and a direct connection to the Anthropic API, this error can hide an unrelated 400 or 422 error from the API. [Update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.306 or later to see the original error.
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
@@ -3048,7 +3054,7 @@
Could not read Claude Code config
-You ran [`claude import`](</docs/en/cli-reference#cli-commands>) while Claude Code couldn’t parse `~/.claude.json`, the file where it stores your login and per-project state. The subcommand reads that file to check availability but doesn’t show the recovery dialog the interactive session shows, so it exits with code 1. Before v2.1.222, `claude import` with an unreadable config file started an interactive session, whose recovery dialog handled the file.
+You ran [`claude import`](</docs/en/cli-reference#cli-commands>) while Claude Code couldn’t parse `~/.claude.json`, the file where it stores your account details and per-project state. The subcommand reads that file to check availability but doesn’t show the recovery dialog the interactive session shows, so it exits with code 1. Before v2.1.222, `claude import` with an unreadable config file started an interactive session, whose recovery dialog handled the file.
Could not read Claude Code config — run `claude` with no arguments to recover it.
@@ -5232,7 +5238,7 @@
Mapped drive letters and `\\wsl$` paths don’t count as network paths. **What to do:**
- * On Windows, map the share to a drive letter, for example with `net use Z: \\server\share`, and pass the drive at launch with `claude --add-dir Z:\`.
+ * On Windows, map the share to a drive letter and pass the drive at launch. In PowerShell, for example, run `net use Z: \\server\share` and then `claude --add-dir Z:\`.
* On macOS or Linux, mount the share at a local path and add that path instead.
* If the path is in `permissions.additionalDirectories`, remove it from the settings file that lists it.
@@ -5271,6 +5277,20 @@
* Start Claude Code again and approve the dialog to continue under your organization’s settings. A declined dialog isn’t remembered, so it appears again at the next start.
* If you’re unsure about a setting the dialog lists, ask whoever maintains your organization’s managed settings before approving
+
+###
+
+
+
+Managed settings need your approval
+
+Your organization’s [server-managed settings](</docs/en/server-managed-settings>) include settings that need your approval in the [security approval dialog](</docs/en/server-managed-settings#security-approval-dialogs>). The `claude plugin` command you ran couldn’t read from the keyboard, so it couldn’t show that dialog. That happens when you pipe or redirect its input and, on macOS and Linux, it also can’t open `/dev/tty`. The command stopped before making any changes:
+
+ Your organization's managed settings need your approval, which couldn't be asked for here. Run `claude` in a terminal and approve them, then run this command again.
+
+**What to do:**
+
+ * Run `claude` in a terminal and approve the settings when the dialog appears, then run the same `claude plugin` command again. Claude Code keeps the approval and the approved settings in your [configuration directory](</docs/en/server-managed-settings#approval-memory>). If the command that stopped ran as another user or with `CLAUDE_CONFIG_DIR` set, run `claude` the same way so that both use the same directory.
###
Show diff (656 lines)
--- a/errors.md
+++ b/errors.md
@@ -75,6 +75,8 @@
`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`The browser can't return the sign-in to Claude Code automatically`| Authentication
+`Couldn't start the local listener that receives the browser sign-in. Try again.`| Authentication
`Failed to start OAuth callback server`| Authentication
`Claude login not accepted · Run /login, then try again`| Authentication
`Artifacts need a claude.ai login`| Authentication
@@ -92,6 +94,7 @@
`claude.ai rejected the session token` / `session token rejected`| Authentication
`MCP server "<name>" needs you to sign in again (run /mcp to re-authenticate)`| Authentication
`rejected the credential from its headersHelper` / `rejected the Authorization header in its config`| Authentication
+`(check the helper, then start a new task or chat)` / `(update it, then start a new task or chat)`| Authentication
`MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate`| Authentication
`MCP server "<name>" requires re-authorization (token expired)`| Authentication
`This server's URL is missing or not a valid URL, so sign-in can't start`| Authentication
@@ -192,6 +195,8 @@
`Installation was killed before it could finish (exit code 137)`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#installation-was-killed-before-it-could-finish>)
`The connection dropped while downloading the update`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
`Download timed out: exceeded the total deadline`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
+`Release verification failed for Claude Code <version> (<reason>). The update was not installed.`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#release-verification-failed>)
+`Auto-update failed · Run claude doctor`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#auto-update-failed>)
`--bg and --print conflict`| Command-line errors
`Couldn't tell whether --bg is a flag or text here, so nothing was started`| Command-line errors
`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
@@ -262,6 +267,7 @@
`Custom output styles can't be selected over Remote Control or from a relayed message`| Command-line errors
`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
`/recap only runs when you ask for it yourself in this session`| Command-line errors
+`/feedback is disabled by your organization's policy`, or the same for `/bug` or `/share`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`cannot be evaluated where sessions load it`| [Test plugins with evals](</docs/en/plugin-evals#cannot-be-evaluated-where-sessions-load-it>)
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
@@ -281,6 +287,7 @@
`The packages it lists are not installed` / `The packages it lists were not installed, because`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#the-packages-it-lists-are-not-installed>)
`does not load (...), so Claude Code ignores the whole file`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#does-not-load-so-claude-code-ignores-the-whole-file>)
`path escapes plugin directory`| Plugin errors
+`Plugin not loaded: its manifest <path> was not read`| Plugin errors
`path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
`Plugin source path refused`| Plugin errors
@@ -296,12 +303,15 @@
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
`Path contains null bytes`| Tool errors
+`File is too large to read as an image (the limit is 128MB)`| Tool errors
+`Cannot read this as an image: <path> is a pipe or a device`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`pkill: refusing to run`| Tool errors
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
+`Only a teammate can approve a shutdown request`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
`Cross-session message was dropped at the recipient session's inbox`| Tool errors
@@ -317,10 +327,12 @@
`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)`| Tool errors
`The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
+`The command was not started: this computer's disk is full (ENOSPC)` / `(EDQUOT)`| Tool errors
`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
+`Not published: Claude sent the same content again after a newer version of the artifact turned it away` / `Not published: Claude sent its changes again over the same file after a newer version of the artifact turned them away`| Tool errors
`Reading a local file from outside this session's connected folders, or through a link, needs the approval card`| Tool errors
`cannot read file_path (...) — the file could not be examined, and no one can answer the approval card`| Tool errors
`WebFetch cannot fetch localhost or other hostnames without a dot`| Tool errors
@@ -337,7 +349,7 @@
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
-`Bypass permissions was requested at launch and ignored`| [Skip all checks with bypassPermissions mode](</docs/en/permission-modes#bypass-permissions-acceptance>)
+`Bypass permissions was requested at launch and ignored`| [Bypass permissions ignored in a background session](</docs/en/permission-modes#bypass-permissions-ignored-in-a-background-session>)
`kept <id> — its worktree is still at <path>`| Background session errors
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
@@ -346,6 +358,8 @@
`Session <id> was stopped while the respawn was in flight`| Background session errors
`This session was running agent '<name>', which is no longer available`| Background session errors
`This session restarted <time> after its next /loop wakeup was due, so that wakeup will not fire`| Background session errors
+`No LLM gateway: a gateway set in your shell isn't passed to a session opened from another folder`| Background session errors
+`No LLM gateway: opened from another folder · respawn from <folder>`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`EACCES: permission denied, posix_spawn`| Background session errors
@@ -386,10 +400,16 @@
`API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
+`matches no tool · check for typos` / `matches no known tool — check for typos`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
+`Write(<path>) never matches · use Edit(<path>)` / `Glob(<path>) never matches · use Read(<path>)`| Configuration warnings
`... has a wildcard before the rest of the command`| Configuration warnings
+`allows any option at its * · use an exact value`| Configuration warnings
`Denying Bash also turns off the PowerShell tool, so Claude has neither`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
+`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" reads as <N> tokens, so Claude Code treats it as the 100k minimum`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
+`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" is too large, so Claude Code treats it as the 1M maximum`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
+`CLAUDE_CODE_AUTO_COMPACT_WINDOW="<value>" isn't a usable size, so Claude Code ignores it`| [Values and warnings for `CLAUDE_CODE_AUTO_COMPACT_WINDOW`](</docs/en/model-config#claude_code_auto_compact_window-values>)
`Model "<model>" isn't recognized · context assumed to be 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`Claude Code doesn't recognize the model "<model>", so it assumes a context window of 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`[claude-code:unrecognized_model]`| Configuration warnings
@@ -456,6 +476,7 @@
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
+[`CLAUDE_CODE_RETRY_WATCHDOG_USAGE_LIMIT_RECHECK_MS`](</docs/en/env-vars>)| unset| Minimum interval in milliseconds between checks of whether a usage limit was already lifted, while a request waits for that limit to reset with `CLAUDE_CODE_RETRY_WATCHDOG` set. When a check finds the limit lifted, the request goes out at once. Give plain digits from `60000` to `10800000`. When unset or outside that range, no checks are made. For when Claude Code skips these checks, see the [environment variables reference](</docs/en/env-vars>). Requires Claude Code v2.1.305 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 64000, so that later retries keep spreading apart when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.296 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Time in milliseconds that each request attempt has to receive its response headers. It doesn’t limit how long a streaming response runs after that. Raise it for slow networks or proxies. For how it caps the first-byte deadline, see No response from API.
@@ -484,6 +505,7 @@
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
+ * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every request fails this way, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable in your environment.
###
@@ -512,8 +534,9 @@
Request timed out
-The default request timeout is 10 minutes. **What to do:**
-
+The default request timeout is 10 minutes. If you set [`API_TIMEOUT_MS`](</docs/en/env-vars>) to `0`, this request timeout is off. The first-byte deadline and the body idle timeout don’t turn off when you set `0`, so a streaming request still runs under [whichever of them apply to your connection](</docs/en/network-config#streaming-idle-watchdogs>). A non-streaming attempt keeps its 300-second limit in a local session and can still end with this message. **What to do:**
+
+ * If every request fails with this message and you set `API_TIMEOUT_MS` to `0`, check `claude --version`. On a version before v2.1.305, update Claude Code or set a positive value.
* Retry the request
* If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
* If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
@@ -531,7 +554,7 @@
Claude Code sets the first attempt’s wait for response headers and the retry’s wait separately:
* **First attempt** : [`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>) when you set it to 1 or more, clamped to between 10 seconds and 30 minutes. Otherwise Claude Code uses the byte-level watchdog timeout listed in [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>), so the variables that change that timeout change this wait too. Either way, Claude Code adds one second for every 32KB of request body.
- * **Retry** : one second less than `API_TIMEOUT_MS`, just under 10 minutes by default, so that the retry can outlast a proxy or gateway that holds the response until generation completes. On Amazon Bedrock, the retry uses the same deadline as the first attempt, and the message shows one duration instead of two.
+ * **Retry** : one second less than `API_TIMEOUT_MS`, just under 10 minutes by default, so that the retry can outlast a proxy or gateway that holds the response until generation completes. On Amazon Bedrock, the retry uses the same deadline as the first attempt, and the message shows one duration instead of two. Except on Amazon Bedrock, if you set `API_TIMEOUT_MS` to `0`, the retry waits 10 minutes plus one second per 32KB, or as long as the first attempt if that’s longer.
Neither wait exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
@@ -809,7 +832,7 @@
* Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
* Check your provider console for the active limits and request a higher tier if needed
* For Anthropic API keys, see the [rate limits reference](<https://platform.claude.com/docs/en/api/rate-limits>) for how tiers work and how to set per-workspace caps
- * Reduce concurrency: lower [`CLAUDE_CODE_MAX_TOOL_USE_CONCURRENCY`](</docs/en/env-vars>), avoid running many parallel subagents, or switch to a smaller model with `/model` for high-volume scripted runs
+ * Reduce concurrency: avoid running many parallel subagents, or switch to a smaller model with `/model` for high-volume scripted runs
###
@@ -1209,6 +1232,7 @@
* If `/status` shows only your login, run `/login` once. If the credential was revoked, a fresh login replaces it.
* If the same message returns for the same login account, the account or organization is no longer active. Check the account and organization that `/status` reports, and ask your organization admin to restore access.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
+ * If every request fails with a `401` once your gateway has the credential it expects, check whether the gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
###
@@ -1272,16 +1296,24 @@
-Failed to start OAuth callback server
-
-When `/login`, `claude auth login`, or `claude setup-token` signs you in through the browser, Claude Code opens a listening port on `127.0.0.1` so your browser can return the sign-in result to it. This message means Claude Code couldn’t open that port, and the sign-in stops before a browser window or login URL appears:
-
- Failed to start OAuth callback server: Failed to start server. Is port 0 in use?
-
-If your message ends with `Is port 0 in use?`, the attempt to listen on the IPv4 loopback address `127.0.0.1` failed outright. Because the failure happens before a login URL exists, the `Paste code here if prompted` flow isn’t available as a workaround. **What to do:**
-
- * To sign in right away without the local listener: if you use a claude.ai subscription, run [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) on a machine where sign-in works and set the token it prints as `CLAUDE_CODE_OAUTH_TOKEN` on this machine. Otherwise set `ANTHROPIC_API_KEY` to a key from the [Claude Console](<https://platform.claude.com/settings/keys>). [Authentication precedence](</docs/en/authentication#authentication-precedence>) explains how Claude Code chooses between credentials.
- * To use browser sign-in on this machine instead, Claude Code must be able to listen on `127.0.0.1`. If it runs inside a sandbox, check that the sandbox’s policy allows listening on local ports, then run `/login` again. If it should be able to and still fails, run `/feedback` so the report includes your environment details.
+Couldn’t start the local listener that receives the browser sign-in
+
+Each of these messages from `/login`, `claude auth login`, or `claude setup-token` means Claude Code couldn’t open the port on `127.0.0.1` where your browser returns the sign-in result. With the notice that begins `The browser can't return the sign-in to Claude Code automatically`, the sign-in continues without that port. No browser opens, and the notice appears above a URL where you sign in instead:
+
+ The browser can't return the sign-in to Claude Code automatically. After you sign in, paste the code shown.
+
+With the message that includes `Couldn't start the local listener`, the sign-in stopped. That happens, for example, when you pipe input into `claude auth login`:
+
+ Couldn't start the local listener that receives the browser sign-in. Try again.
+
+**What to do:**
+
+ * **`The browser can't return the sign-in to Claude Code automatically`** : you don’t need to fix anything first. Open the URL shown under the notice in a browser and sign in. The browser then shows a code: paste it into Claude Code at the `Paste code here >` prompt, and the sign-in continues from there.
+ * **`Couldn't start the local listener that receives the browser sign-in`** : run the same command again. If it stops the same way, sign in with a token or API key instead of the browser. Or, if you piped input into `claude auth login`, run it in a terminal so it can take a pasted code.
+ * **To sign in with a token or API key instead of the browser** : if you use a claude.ai subscription, run [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) on a machine where sign-in works. Then set the token it prints as the [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>) environment variable on this machine. Otherwise set the `ANTHROPIC_API_KEY` environment variable to a key from the [Claude Console](<https://platform.claude.com/settings/keys>). [Authentication precedence](</docs/en/authentication#authentication-precedence>) explains how Claude Code chooses between credentials.
+ * **To get the automatic browser return back** : Claude Code must be able to listen on `127.0.0.1`. If it runs inside a sandbox, check that the sandbox’s policy allows listening on local ports, then sign in again. If listening should work there and the notice still appears, run `/feedback` so the report includes your environment details.
+
+Before v2.1.305, the sign-in stopped as soon as the port couldn’t be opened and showed no URL to sign in at. The message read, for example, `Failed to start OAuth callback server: Failed to start server. Is port 0 in use?`. On those versions, update Claude Code and sign in again, or sign in with a token or API key instead of the browser.
###
@@ -1431,7 +1463,15 @@
MCP server "<name>" rejected the Authorization header in its config (update it, then run /mcp to reconnect)
-Update the header value where the server is configured, then reconnect from `/mcp`. Before v2.1.273, the expired sign-in, `headersHelper`, and `Authorization` header cases all showed `MCP server "<name>" requires re-authorization (token expired)`. A server can also refuse a tool call with HTTP 403 `insufficient_scope` to ask you to authorize a scope, sometimes one your token already lists. The message names that scope:
+Update the header value where the server is configured, then reconnect from `/mcp`. In a [Cowork](<https://claude.com/docs/cowork/overview>) session on your machine in the Claude Desktop app, these messages mean the MCP server rejected a credential it was given. Fix the one the message names, then start a new task or chat in Cowork:
+
+ MCP server "<name>" rejected the credential from its headersHelper (check the helper, then start a new task or chat)
+ MCP server "<name>" rejected the Authorization header in its config (update it, then start a new task or chat)
+
+ * **`headersHelper` credential rejected**: check that the helper returns a credential the server accepts, then start a new task or chat in Cowork
+ * **`Authorization` header rejected**: update the `Authorization` value under `headers` in that server’s configuration, then start a new task or chat in Cowork
+
+Before v2.1.302, a Cowork session showed the `run /mcp to reconnect` endings instead, although `/mcp` isn’t available there. If you see such an ending in Cowork, still check the helper or update the header, then start a new task or chat. Before v2.1.273, the expired sign-in, `headersHelper`, and `Authorization` header cases all showed `MCP server "<name>" requires re-authorization (token expired)`. A server can also refuse a tool call with HTTP 403 `insufficient_scope` to ask you to authorize a scope, sometimes one your token already lists. The message names that scope:
MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate
@@ -1705,8 +1745,9 @@
* Confirm you can reach the API host from the same shell by running `curl -I https://api.anthropic.com`. On Windows PowerShell use `curl.exe -I https://api.anthropic.com` so the built-in `Invoke-WebRequest` alias is not used.
* If you are behind a corporate proxy, set `HTTPS_PROXY` before launching Claude Code and see [Network configuration](</docs/en/network-config>)
* If you route through an LLM gateway or relay, set [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) to its address. See [Connect Claude Code to an LLM gateway](</docs/en/llm-gateway-connect>) for setup.
+ * If `ANTHROPIC_BASE_URL` already points at your gateway and every request ends in `Connection dropped`, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* Ensure your firewall allows the hosts listed in [Network access requirements](</docs/en/network-config#network-access-requirements>)
- * Intermittent failures are retried automatically; persistent failures point to a local network issue
+ * Intermittent failures are retried automatically
If `curl` succeeds but Claude Code still fails, the cause is usually something between the runtime and the network rather than the network itself:
@@ -2027,6 +2068,7 @@
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
* If the error appears near 200K tokens on a model that accepts more, one cause is a model ID that Claude Code doesn’t recognize. Claude Code assumes a 200K window for such an ID, so to keep working past that point, [give it the model’s real context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>).
+ * If the error appeared right after you stopped Claude while it was compacting the conversation, your conversation is unchanged and still large enough to need compacting. Run `/compact` and send your message again. To keep the error from recurring, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.304 or later. Before v2.1.304, stopping at that moment could end the turn with this error.
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
@@ -2161,14 +2203,20 @@
Extra inputs are not permitted
-A proxy or LLM gateway between Claude Code and the API stripped the `anthropic-beta` request header, so the API rejected fields that depend on it.
-
- API Error: 400 ... Extra inputs are not permitted ... context_management
-
-Claude Code sends beta-only fields such as `context_management` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
-
- * Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
+The endpoint that received the request rejected one of the request’s fields as an input it doesn’t accept, and the endpoint’s message names that field.
+
+ API Error: 400 ... context_management: Extra inputs are not permitted
+
+Claude Code sends beta-only fields such as `context_management` and tool search’s `defer_loading` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. When a gateway forwards an Anthropic-format body to an upstream with a different schema, that upstream rejects such fields. [Beta header and body field pairs](</docs/en/llm-gateway-protocol#beta-header-and-body-field-pairs>) covers both cases. **What to do:**
+
+ * If the message contains `context_management: Extra inputs are not permitted`, [update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.304 or later. After you update, Claude Code answers this rejection by sending the request once more without the field. Before v2.1.304, Claude Code didn’t retry this rejection.
+ * If the message names `defer_loading` or `tool_reference`, update Claude Code or turn [tool search](</docs/en/mcp#tool-search-through-a-gateway>) off:
+ * [Update Claude Code](</docs/en/setup#update-claude-code>) to v2.1.305 or later. Claude Code then answers this rejection by sending the request once more without tool search fields.
+ * If you can’t update, or the message still appears after you do, set `ENABLE_TOOL_SEARCH=false` in your shell or your [settings `env`](</docs/en/settings-reference#env>). If a settings file already sets the variable, change it there, since that value [can override a shell export](</docs/en/settings-reference#how-env-values-interact-with-your-shell>). Claude Code then loads MCP tools upfront.
+ * If your gateway drops the header, configure it to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers the exact scope.
+
+Before v2.1.302, this error could also name the field `diagnostics` with no gateway involved. It appeared when a session that had already used the Anthropic API moved to Amazon Bedrock or Google Cloud’s Agent Platform without a restart. For example, a session you left open moves to Bedrock when you run [`/setup-bedrock`](</docs/en/commands>) in another Claude Code window. On those versions, run `/clear` in that session or restart it.
###
@@ -2239,6 +2287,7 @@
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
* Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
+ * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>) and every model fails this way, check whether your gateway is rejecting the tool search fields Claude Code sends by default. To check, set `ENABLE_TOOL_SEARCH=false` as [Tool search through an LLM gateway](</docs/en/mcp#tool-search-through-a-gateway>) describes, then try again. Before v2.1.304, tool search was off behind a gateway unless you turned it on with `ENABLE_TOOL_SEARCH`.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
###
@@ -2439,7 +2488,7 @@
Other messages report the same condition:
* In an interactive session, a notification reads `Advisor will not activate on the main model (advisor is less capable); subagents may still use it and may use more tokens · /advisor`.
- * At launch with the `--advisor` flag, a warning reads `"<advisor>" cannot advise "<main model>" (the advisor must be at least as capable as the main model). The advisor will not be used for the main model.` and the session starts anyway.
+ * When you launch with the `--advisor` flag in [non-interactive mode](</docs/en/headless>), and the run isn’t a [background session](</docs/en/agent-view>), a warning goes to stderr and the run starts anyway. It reads `"<advisor>" cannot advise "<main model>" (the advisor must be at least as capable as the main model). The advisor will not be used for the main model.` An interactive session writes that warning only to the debug log.
**What to do:**
@@ -3303,7 +3352,7 @@
Claude Code suggests the closest command name or alias that the menu lists in this session. When nothing is close, the message ends after the name. The cause is usually one of the following:
* A typo, such as `/hepl` for `/help`. [How the command menu matches what you type](</docs/en/commands#how-the-command-menu-matches-what-you-type>) covers picking a close match before you submit
- * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them, such as `Cloud sessions are disabled by your organization's policy`
+ * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. See the entry for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>), [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>), or [`/auto-mode-setup`](</docs/en/auto-mode-config#auto-mode-setup-returns-unknown-command>). Some commands answer with their own message when your organization’s policy disables them, such as `Cloud sessions are disabled by your organization's policy`
* A command from a [plugin](</docs/en/plugins/overview>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
Claude Code answers an unmatched `/` name this way only in an interactive terminal session. In every other session, it sends the prompt to Claude as a normal message instead, with a note that the command didn’t run and a list of commands Claude can run in the session. Those sessions include:
@@ -3694,6 +3743,22 @@
* Open the session yourself and run `/recap` there: in its terminal, in the [Desktop app](</docs/en/desktop>) or the [mobile app](</docs/en/mobile>), at [claude.ai/code](<https://claude.ai/code>), or over [Remote Control](</docs/en/remote-control>)
* If a cloud scheduled task or another program sent it, remove `/recap` from that prompt
+
+###
+
+
+
+/feedback is disabled by your organization’s policy
+
+This message means your organization’s policy doesn’t allow product feedback from Claude Code, so `/feedback`, `/bug`, and `/share` don’t open the feedback dialog. The message names the command you typed at the Claude Code prompt:
+
+ /feedback is disabled by your organization's policy. To report a bug, open an issue at https://github.com/anthropics/claude-code/issues. Issues are public, so leave out anything confidential.
+
+The message can also be its first sentence alone. **What to do:**
+
+ * To report a bug, open an issue at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>). Anyone can read issues there, so leave out code, transcripts, and anything else confidential.
+
+Before v2.1.302, the full message read `/feedback is disabled by your organization's policy. Contact your organization admin to enable it.`
##
@@ -3840,7 +3905,7 @@
Path escapes plugin directory
-A plugin component path, declared in the plugin’s `plugin.json` or in its [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>), resolves outside the plugin’s own directory. Claude Code drops that path and loads the rest of the plugin. The component name in the message, such as `commands` or `hooks`, names the field that declared the path.
+One of the plugin’s component paths leads outside the plugin directory or couldn’t be confirmed inside it, so Claude Code drops that path and loads the rest of the plugin. For a path the plugin declares in `plugin.json` or its [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>), the component name in the message, such as `commands` or `hooks`, names the field that declared the path.
commands path escapes plugin directory: ./../shared.md
@@ -3848,16 +3913,45 @@
commands path escapes plugin directory: ./commands/deploy.md — it resolves to /home/user/shared/deploy.md, outside the plugin directory
+A message that gives the full path of one of a marketplace plugin’s own files, such as `hooks/hooks.json`, means Claude Code skipped that file. That happens when Claude Code can’t confirm the file is inside the plugin or, for a plugin in a [local marketplace](</docs/en/plugins/loading#in-place-and-copied-plugins>), inside that marketplace. The message reports each of these files under the component name shown:
+
+ * `hooks/hooks.json`: `hooks`
+ * `monitors/monitors.json`: `monitors`
+ * `settings.json`: `settings`
+ * `SKILL.md` at the plugin root: `skills`
+
+For example, this message is for a `hooks/hooks.json` that resolves outside both the plugin and its local marketplace:
+
+ hooks path escapes plugin directory: /home/user/my-marketplace/my-plugin/hooks/hooks.json — it resolves to /home/user/dotfiles/hooks.json, outside the plugin directory and its marketplace directory
+
On macOS and Linux, Claude Code also rejects a component path that contains a backslash anywhere in it, even when the path stays inside the plugin. A plugin whose component paths use Windows-style separators loads on Windows and triggers this rejection on the other platforms:
commands path escapes plugin directory: ./commands\deploy.md — its path contains a backslash, which is not resolved reliably on this platform
-Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Before v2.1.257, the check looked only at the path’s spelling, not at where a symlink leads. **What to do:**
-
- * Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
- * If the path is a symlink to a file outside the plugin, replace the symlink with a copy of the file
- * If the message says the path contains a backslash, write the path with forward slashes, for example `./commands/deploy.md`
+Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Before v2.1.257, the check on paths the plugin declares looked only at the path’s spelling, not at where a symlink leads. **What to do:**
+
+ * If you installed the plugin and don’t maintain it, report the message to its author
+ * For a path the plugin declares, move the referenced file inside the plugin directory and point the path at it with a `./` relative path
+ * If the path, or a folder above it inside the plugin, is a symlink leading outside the plugin, replace the symlink with a copy of what it points to
+ * If the message says a path the plugin declares contains a backslash, write the path with forward slashes, for example `./commands/deploy.md`
+ * If the message ends with `EACCES`, restore your execute permission on every directory leading to the file or folder the path names. Check the directories above the path, then follow each symlink you reach and check the directories leading to where it points. For any other error code, look it up in the causes and steps for a path that couldn’t be checked.
* To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
+
+###
+
+
+
+Plugin not loaded: its manifest was not read
+
+Claude Code couldn’t confirm that a marketplace plugin’s [manifest](</docs/en/plugins/manifest-reference>) at `.claude-plugin/plugin.json` is inside the plugin, so it loads nothing from that plugin. For a plugin in a [local marketplace](</docs/en/plugins/loading#in-place-and-copied-plugins>), Claude Code also couldn’t confirm that the manifest is inside that marketplace. The message appears in the `/plugin` **Errors** tab, and the reason at its end says what Claude Code found. For example, this message is for a plugin in a local marketplace whose `.claude-plugin` folder is a symlink leading outside the marketplace:
+
+ Plugin not loaded: its manifest /home/user/my-marketplace/my-plugin/.claude-plugin/plugin.json was not read, because it resolves to /home/user/dotfiles/my-plugin/.claude-plugin/plugin.json, outside the plugin directory and its marketplace directory
+
+**What to do:**
+
+ * If the reason ends with `EACCES`, restore your execute permission on every directory leading to the manifest. Check the directories above the manifest, then follow each symlink you reach and check the directories leading to where it points. For any other error code, look it up in the causes and steps for a path that couldn’t be checked.
+ * If you maintain the plugin and the reason says where the manifest resolves, the `.claude-plugin` folder or `plugin.json` itself is a symlink that leads there. Replace that link with a copy of what it points to.
+ * If you installed the plugin and don’t maintain it, report the message to its author
###
@@ -4055,6 +4149,26 @@
+File is too large to read as an image
+
+Claude tried to read a file as an image with the [Read tool](</docs/en/tools-reference#read-tool-behavior>), and the file is larger than 128 MB, the most Read loads from an image file. Nothing was read, and Claude receives this error as the tool result:
+
+ File is too large to read as an image (the limit is 128MB): <path>. If it is an image, resize it or export a smaller copy, then read that.
+
+When the path is a pipe or a device rather than a regular file, Read stops once more than 128 MB has arrived and returns this error instead:
+
+ Cannot read this as an image: <path> is a pipe or a device, not a regular file, and it sent more than 128MB without ending.
+
+**What to do:**
+
+ * If Claude followed the `File is too large` message and went on to resize the image or read a smaller copy, do nothing
+ * If Claude stopped at the error, export a copy under 128 MB yourself, for example at a lower resolution, and point Claude at that file
+ * If the path was a pipe or a device, point Claude at a regular image file instead
+
+###
+
+
+
subagent_type is required
subagent_type is required: the general-purpose agent is not available in this session. Available agents: ...
@@ -4136,6 +4250,22 @@
* Run `claude` in the folder the [debug log](</docs/en/debug-your-config>) names and accept the trust dialog. The definition is re-applied the next time Claude Code brings the teammate back; you don’t need to restart the lead session
* Or set the `hasTrustDialogAccepted` entry to `true` in `~/.claude.json`, using the exact `projects["<path>"]` key the debug log prints
+
+###
+
+
+
+Only a teammate can approve a shutdown request
+
+Claude Code refused an [agent team](</docs/en/agent-teams>) shutdown approval because the session that sent it isn’t running as a teammate. Nothing was sent and nothing shut down. The refusal appears in the sending session’s tool result:
+
+ Only a teammate can approve a shutdown request, and this session is not running as one. Nothing was sent. To shut down a teammate, send that teammate a shutdown_request message. The teammate is the one that approves it.
+
+**What to do:**
+
+ * If the refusal appeared in your lead session, first check whether the teammate has since shut down. The refusal goes back to Claude with the instruction to send a `shutdown_request` instead, and the turn continues. In an interactive lead session, `<name> has shut down.` appears when the teammate approves a shutdown request.
+ * If the teammate is still running, ask the lead at its prompt to shut the teammate down, for example `Ask the researcher teammate to shut down`. See [Shut down teammates](</docs/en/agent-teams#shut-down-teammates>).
+ * If a former teammate you resumed yourself with `claude --resume` got this refusal, nothing was sent. To end that session, run `/exit` at its prompt.
###
@@ -4276,7 +4406,11 @@
Disk quota or temp filesystem is full
-Claude Code saves each Bash and PowerShell command’s output to a file under its temp directory. When a command exits with a nonzero code and no output at all, Claude Code checks whether the filesystem holding that file is out of space or inodes, or whether your disk quota on it is used up. If so, a diagnostic appears in the command’s result in place of the empty output:
+Claude Code saves each Bash and PowerShell command’s output to a file under its temp directory. These messages in a command’s result mean that the filesystem holding that directory, or your disk quota on it, is full. If Claude Code can’t create that file because the filesystem or your quota on it is full, your command doesn’t start, and the result reads:
+
+ The command was not started: this computer's disk is full (ENOSPC), so the file that captures command output could not be created. Nothing ran. If this is the user's own computer, tell them before deleting anything to make room.
+
+When a command exits with a nonzero code and no output at all, Claude Code checks the filesystem holding the output file. If that filesystem is out of space or inodes, or your disk quota on it is used up, a diagnostic replaces the empty output in the command’s result:
Your disk quota is full on the filesystem with Claude Code's temp directory /private/tmp/claude-501/-Users-you-my-project/1f0e62dc-4b0a-4f5e-9c2d-8a7b6c5d4e3f/tasks (EDQUOT), so any output this command printed was lost, and it may have failed because it could not write. Delete files you no longer need there, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another filesystem.
@@ -4285,12 +4419,15 @@
* `Your disk quota is full ... (EDQUOT)`: your own quota on that filesystem is used up. A quota can be full while the filesystem still shows free space
* `The filesystem with Claude Code's temp directory ..., or your disk quota on it, is full (ENOSPC)`: the filesystem, or your quota on it, has no space left
* `Command output was lost: the temp filesystem at ... is full` or `... is out of inodes`: the filesystem has almost no free space left, or is running out of inodes
-
-**What to do:**
-
- * Delete files you no longer need on the filesystem that holds Claude Code’s temp directory. For `EDQUOT`, delete files that count against your own quota. For `out of inodes`, delete many files rather than a few large ones, since each file takes one inode whatever its size
+ * `The command was not started: this computer's disk is full (ENOSPC)` or `... (EDQUOT)`: the filesystem has no space left for the output file, or with `EDQUOT` your own quota on it is used up
+
+**What to do:**
+
+ * Delete files you no longer need on the filesystem that holds Claude Code’s temp directory. If your message doesn’t name that directory, look up its default location in the [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) reference. For `EDQUOT`, delete files that count against your own quota. For `out of inodes`, delete many files rather than a few large ones, since each file takes one inode whatever its size
* Or restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a directory on a filesystem with room
- * Then have Claude run the command again. The output it printed was lost, not truncated
+ * Then have Claude run the command again
+
+Before v2.1.305, a command that Claude Code couldn’t start because the disk was full returned only the operating system’s error text. That text read, for example, `ENOSPC: no space left on device, open <path>.output`.
###
@@ -4355,6 +4492,24 @@
+Not published: Claude sent the same content again after a newer version of the artifact turned it away
+
+This red line under an Artifact call means Claude Code stopped a repeated publish: the [artifact](</docs/en/artifacts>) wasn’t updated, and nothing was written to the file Claude publishes from. You don’t need to do anything unless Claude stops without publishing. Earlier in the session, Claude Code turned a publish away because the artifact had a newer version, for example one that an [editor](</docs/en/artifacts#let-someone-edit-with-you>) or another of your sessions published. The line’s ending says what Claude has to do next:
+
+ Not published: Claude sent the same content again after a newer version of the artifact turned it away. Claude needs to work from that newer version first.
+ Not published: Claude sent the same content again after a newer version of the artifact turned it away. The artifact hasn't changed since, so publishing it once more should go through.
+ Not published: Claude sent its changes again over the same file after a newer version of the artifact turned them away. Claude needs to work from that newer version first.
+ Not published: Claude sent its changes again over the same file after a newer version of the artifact turned them away. The artifact hasn't changed since, so publishing once more should go through.
+
+**What to do:**
+
+ * **Ends with`Claude needs to work from that newer version first`**: if Claude stopped there, ask it to fetch the artifact’s current version, merge its changes in, and publish again
+ * **Ends with`should go through`**: if Claude stopped there, ask it to publish again
+
+###
+
+
+
Reading a local file from outside the connected folders in a Cowork session
In a [Cowork](<https://claude.com/docs/cowork/overview>) session running on your machine in the Claude Desktop app, Claude named a local file for an [artifact](</docs/en/artifacts>). Claude Code couldn’t confirm the file is a plain file inside the session’s connected folders: the path sits outside those folders, passes through a symbolic link, or is spelled in a way that can name a different file than it appears to. Reading such a file needs your approval, and in a session that can’t show you the approval card, such as one set to skip all approvals, Claude Code refuses the read. The refusal appears in the Artifact tool result; when the file couldn’t be examined at all, it names that failure instead:
@@ -4633,6 +4788,24 @@
* To continue the loop, [reply to the session](</docs/en/agent-view#peek-and-reply>) and say so, such as `keep the loop running`. Claude reads the notice with your reply and can schedule the next wakeup
* If you’re done with the loop, do nothing. It has already stopped
+
+###
+
+
+
+No LLM gateway: a gateway set in your shell isn’t passed to a session opened from another folder
+
+The [background session](</docs/en/agent-view>) showing this message isn’t using your [LLM gateway](</docs/en/llm-gateway>): it didn’t get the gateway’s address, so its requests fail. The message appears in the conversation in place of Claude’s reply, with your session’s ID and folder filled in:
+
+ No LLM gateway: a gateway set in your shell isn't passed to a session opened from another folder. To fix, run `claude respawn abc12345` from ~/project in another terminal where your gateway is set, or set ANTHROPIC_BASE_URL and its API key or token in a settings file's env block.
+
+While you’re attached to the session, the notice under its prompt shows the short form `No LLM gateway: opened from another folder · respawn from ~/project`. You dispatched, woke, or restarted the session from a folder other than the one the message names, while `ANTHROPIC_BASE_URL` was set to your gateway. For the cases where a shell-exported gateway does reach a background session, see [LLM gateway](</docs/en/agent-view#llm-gateway>). **What to do:**
+
+ * **You used agent view in a project whose settings set the gateway** : put `ANTHROPIC_BASE_URL` and its API key or token in [a settings file’s `env` block](</docs/en/llm-gateway-connect#set-in-a-settings-file>). Use `~/.claude/settings.json`, or `.claude/settings.local.json` in the session’s own project, both of which a respawned session reads. Then run `claude respawn <id>` in your shell from any folder.
+ * **You exported the gateway in your terminal** : in a terminal where you’ve exported the gateway variables, `cd` to the folder the message names and run the message’s `claude respawn <id>` command. The session restarts from its saved conversation.
+ * The gateway reaches the session only when the [supervisor](</docs/en/agent-view#the-supervisor-process>) was itself started from a shell that exported the same gateway. If the supervisor wasn’t, restart it from that terminal as [Dispatch fails with `Could not resolve authentication method`](</docs/en/agent-view#dispatch-fails-with-could-not-resolve-authentication-method>) describes, then run the respawn command again.
+
+Before v2.1.302, a background session in this situation showed a sign-in error such as `Not logged in · Please run /login` instead, without naming the folder.
###
@@ -4912,7 +5085,12 @@
Configuration warnings
-Claude Code writes most of these messages to stderr, not into the conversation, and writes most of them at startup. An entry says so when its message appears somewhere else, such as in the debug log or as a startup notice in the conversation view, or at another time, such as the unrecognized-model diagnostic line at request time.
+To find a warning that Claude Code gave at startup in an interactive session, look below the startup banner first, then in the debug log:
+
+ * **Row below the startup banner** : some warnings about [permission rules](</docs/en/permissions>), such as `⚠ Deny rule Bsh matches no tool · check for typos`
+ * **Debug log** : Claude Code keeps this log only in debug mode. To read the warnings in it, start Claude Code from your shell with `claude --debug-file <path>`, then open the file at that path.
+
+In [non-interactive mode](</docs/en/headless>) with text output, outside a [background session](</docs/en/agent-view>), look for startup warnings on stderr. Before v2.1.305, look on stderr in an interactive session as well, including for the permission-rule warnings that now show as rows below the banner.
###
@@ -5042,11 +5220,11 @@
Working directory is a network path
-Claude Code doesn’t add network paths as working directories. Looking up a network path can contact the host it names, and on Windows that contact can send the host your credentials, so Claude Code refuses the path without looking it up. You see this message when you run `/add-dir` with such a path, or as a warning at startup. When it appears at startup, Claude Code starts without that directory.
+Claude Code doesn’t add network paths as working directories. Looking up a network path can contact the host it names, and on Windows that contact can send the host your credentials. Claude Code therefore refuses the path without looking it up. You see this message when you run `/add-dir` with a network path:
\\server\share is a network path, which cannot be added as a working directory. On Windows, map the share to a drive letter and pass it at launch with --add-dir (a drive letter added mid-session does not yet carry remote-read trust).
-Paths that Claude Code refuses this way include:
+When you pass one at startup instead, with `--add-dir` or in `permissions.additionalDirectories`, Claude Code starts without that directory. In an interactive session you don’t see the message at startup, because it goes to the debug log with the other startup warnings. Paths that Claude Code refuses this way include:
* UNC shares such as `\\server\share`
* Automount paths such as `/net/<host>`, unless you launched Claude Code from a directory under that host’s automount. Reads under that automount still go through the [network path check](</docs/en/permissions#network-paths>).
@@ -5287,21 +5465,52 @@
+Matches no tool · check for typos
+
+This row below the startup banner names a deny or ask [permission rule](</docs/en/permissions>) whose tool name Claude Code doesn’t recognize, so the rule doesn’t apply to the tool you meant. A deny rule written as `Bsh` isn’t applied to Bash, and neither is one that uses the label a tool shows in the transcript instead of its canonical name. The row repeats the rule as you wrote it:
+
+ ⚠ Deny rule Bsh matches no tool · check for typos
+
+In [non-interactive mode](</docs/en/headless>) with text output, Claude Code prints the warning on stderr in its longer form instead:
+
+ Permission deny rule "Bsh" matches no known tool — check for typos.
+
+**What to do:**
+
+ * Correct the tool name in the rule, for example `Bash` in place of `Bsh`. Look up canonical names in the [tools reference](</docs/en/tools-reference>).
+ * To find where the rule is defined, run `/permissions` in the session and select the rule. Its details say where it comes from, such as `From project local settings`, or `From CLI argument` for a `--disallowedTools` value.
+ * If the details read `From enterprise managed settings`, forward the row to whoever maintains your [managed settings](</docs/en/managed-settings>), since you can’t change that rule yourself.
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.305, an interactive session printed the longer form on stderr at startup instead of showing the row.
+
+###
+
+
+
Is not matched by file permission checks
-Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else; the warning names the rule, its source in parentheses, and the replacement to write:
-
- Permission deny rule (.claude/settings.json): Write(docs/**) is not matched by file permission checks — only Edit(path) rules are. Use Edit(docs/**) instead (Edit rules cover all file-editing tools).
+Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else.
+
+ * **Interactive session** : the full warning goes to the debug log, and a deny or ask rule of this shape also shows as this row below the startup banner:
+
+ ⚠ Deny rule Write(docs/**) never matches · use Edit(docs/**)
+
+An allow rule of this shape gets no row. To find where the rule is defined, run `/permissions` in the session and select the rule.
+ * **[Non-interactive mode](</docs/en/headless>) with text output**: the full warning on stderr names the rule, its source in parentheses, and the replacement to write:
+
+ Permission deny rule (.claude/settings.json): Write(docs/**) is not matched by file permission checks — only Edit(path) rules are. Use Edit(docs/**) instead (Edit rules cover all file-editing tools).
+
+ * **[Background session](</docs/en/agent-view>), or `--output-format json` or `stream-json`**: the full warning goes to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`.
**What to do:**
* Replace `Write(path)`, `NotebookEdit(path)`, and legacy `MultiEdit(path)` rules with `Edit(path)`. `Edit` rules cover all file-editing tools.
* Except in `--allowedTools`, where Claude Code accepts a `Glob` rule without warning, replace `Glob(path)` rules with `Read(path)`.
- * Fix the rule at the source the warning names in parentheses: a settings file path, or the flag itself for `--allowed-tools` and `--disallowed-tools`. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
+ * Fix the rule at its source, which the full warning names in parentheses: a settings file path, or the flag itself for `--allowed-tools` and `--disallowed-tools`. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
* Leave bare tool-name rules such as `Write` or `Glob` alone. Claude Code matches them at the [tool level](</docs/en/permissions#match-all-uses-of-a-tool>) and doesn’t warn about them.
- * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings, since you can’t clear it yourself.
-
-In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.210, Claude Code accepted these rules without a warning.
+ * For a rule from managed settings, the full warning’s parentheses read `managed policy settings` and the rule’s details in `/permissions` read `From enterprise managed settings`. Forward that warning to whoever maintains your managed settings, since you can’t clear it yourself.
+
+Before v2.1.210, Claude Code accepted these rules without a warning. Before v2.1.305, an interactive session printed the full warning on stderr.
###
@@ -5309,18 +5518,22 @@
Has a wildcard before the rest of the command
-Claude Code found a `Bash` allow rule whose `*` comes before a later word that determines which command it is, such as `Bash(git * main)` or `Bash(git -C * status *)`, in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in an `--allowedTools` or `--settings` flag value. The `*` matches any text, including options inserted at that position: `Bash(git * main)` also approves `git -c core.fsmonitor=<script> diff main`, where `-c` makes git run a program the command names. [Wildcard patterns](</docs/en/permissions#wildcard-patterns>) shows the matching rules. The warning exists so you can narrow a rule whose wildcard is broader than you intended. Claude Code keeps the rule and changes nothing about how it matches; the warning names the rule and its source in parentheses:
+Claude Code found a `Bash` allow rule whose `*` comes before a later word that determines which command it is, such as `Bash(git * main)` or `Bash(git -C * status *)`, in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in an `--allowedTools` or `--settings` flag value. The `*` matches any text, including options inserted at that position: `Bash(git * main)` also approves `git -c core.fsmonitor=<script> diff main`, where `-c` makes git run a program the command names. [Wildcard patterns](</docs/en/permissions#wildcard-patterns>) shows the matching rules. The warning exists so you can narrow a rule whose wildcard is broader than you intended. Claude Code keeps the rule and changes nothing about how it matches. In [non-interactive mode](</docs/en/headless>) with text output, the warning on stderr names the rule and its source in parentheses:
Permission allow rule (.claude/settings.json): Bash(git -C * status *) has a wildcard before the rest of the command, so it also matches any options inserted at that position and approves them without a prompt. For git, options such as -c and --exec-path can run arbitrary commands. Replace that * with the exact value you mean, or only use * after the subcommand (for example Bash(git status *)).
-**What to do:**
+In an interactive session, the full warning goes to the debug log and the rule shows as this row below the startup banner:
+
+ ⚠ Allow rule Bash(git -C * status *) allows any option at its * · use an exact value
+
+To find where the rule is defined, run `/permissions` in the session and select the rule. **What to do:**
* Replace the `*` before the subcommand with the exact value you mean: `Bash(git checkout main)` in place of `Bash(git * main)`.
* Move every `*` after the subcommand: `Bash(git status *)` in place of `Bash(git -C * status *)`. Write one rule per subcommand you want to allow.
- * Fix the rule at the source the warning names in parentheses: a settings file path, or the `--allowed-tools` flag itself. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
- * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings, since you can’t clear it yourself.
-
-In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning.
+ * Fix the rule at its source, which the full warning names in parentheses: a settings file path, or the `--allowed-tools` flag itself. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
+ * For a rule from managed settings, the full warning’s parentheses read `managed policy settings` and the rule’s details in `/permissions` read `From enterprise managed settings`. Forward that warning to whoever maintains your managed settings, since you can’t clear it yourself.
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning. Before v2.1.305, an interactive session printed the full warning on stderr instead of showing a row.
###
@@ -5328,7 +5541,7 @@
Denying Bash also turns off the PowerShell tool
-You removed the whole Bash tool, for example with `--disallowedTools Bash` or with a bare `Bash` or `Bash(*)` [deny rule](</docs/en/permissions#match-all-uses-of-a-tool>) in one of your settings files. On Windows with Git Bash installed, [denying Bash also turns the PowerShell tool off](</docs/en/tools-reference#bash-deny-rules-also-turn-off-the-powershell-tool>), so the session starts with no shell tool. Claude Code prints this warning at startup:
+You removed the whole Bash tool, for example with `--disallowedTools Bash` or with a bare `Bash` or `Bash(*)` [deny rule](</docs/en/permissions#match-all-uses-of-a-tool>) in one of your settings files. On Windows with Git Bash installed, [denying Bash also turns the PowerShell tool off](</docs/en/tools-reference#bash-deny-rules-also-turn-off-the-powershell-tool>), so the session starts with no shell tool. In [non-interactive mode](</docs/en/headless>) with text output, Claude Code prints this warning on stderr at startup, and an interactive session writes it only to the debug log:
Denying Bash also turns off the PowerShell tool, so Claude has neither. To use PowerShell, set CLAUDE_CODE_USE_POWERSHELL_TOOL=1.
@@ -5337,7 +5550,7 @@
* To have Claude use PowerShell, set [`CLAUDE_CODE_USE_POWERSHELL_TOOL`](</docs/en/env-vars>) to `1` in your environment or in the `env` block of a settings file, as [Enable the PowerShell tool](</docs/en/tools-reference#enable-the-powershell-tool>) shows. The PowerShell tool then stays on alongside your Bash deny rule.
* To block particular commands instead of the whole tool, replace the bare `Bash` entry with scoped rules such as `Bash(git push *)` in the same settings file or flag. Claude keeps the Bash tool, and the PowerShell tool stays off until you also set the variable or add a scoped [`PowerShell` permission rule](</docs/en/permissions#powershell>).
-In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.287, Claude Code turned the PowerShell tool off the same way without printing a warning.
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.287, Claude Code turned the PowerShell tool off the same way without printing a warning. Before v2.1.305, an interactive session printed the warning on stderr at startup too.
###
@@ -5392,7 +5605,7 @@
* If the message names a model ID this version doesn’t recognize, run `claude update`. A version that recognizes the ID as a 1M-context model enforces the limit without further configuration.
* If you want the session to use the model’s full window instead, unset `CLAUDE_CODE_DISABLE_1M_CONTEXT`; the warning reports only that the 200K limit isn’t enforced
-In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr.
+In [non-interactive mode](</docs/en/headless>) with text output, this warning appears on stderr. In an interactive session, a [background session](</docs/en/agent-view>), or with `--output-format json` or `stream-json`, it goes to the debug log instead. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.305, an interactive session printed the warning on stderr at startup.
###
@@ -5500,6 +5713,7 @@
If an error is not listed here or the suggested fix does not help:
* Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. Sending to Anthropic requires [authentication](</docs/en/authentication>). On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and other third-party providers, or when no Anthropic credentials are configured, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
+ * If `/feedback` answers that it’s disabled by your organization’s policy, see that message’s entry
* Run `claude doctor` from your shell for a read-only diagnostic of your installation, or run the `/doctor` checkup inside Claude Code to find and fix setup problems
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub
Show diff (186 lines)
--- a/errors.md
+++ b/errors.md
@@ -31,6 +31,7 @@
`Auto mode classifier transcript exceeded context window`| Server errors
`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
`The server-side auto mode classifier gave no verdict`| Server errors
+`<tool> was not reviewed and did not run: the conversation is too long for auto mode's classifier`| Server errors
`Auto mode is unavailable — the server returned no safety verdict for the last 10 responses`| Server errors
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit` / `You've hit your Opus limit` / `You've hit your Sonnet limit`| Usage limits
@@ -121,7 +122,7 @@
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`unable to get local issuer certificate`| Network
-`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
+`403` with `x-deny-reason: host_not_allowed` in a cloud session or cloud scheduled task| Network
`proxy refused the connection`| Network
`403` with `GitHub GraphQL is not available from Claude Code sessions` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
@@ -457,7 +458,7 @@
[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 64000, so that later retries keep spreading apart when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.296 or later.
-[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
+[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Time in milliseconds that each request attempt has to receive its response headers. It doesn’t limit how long a streaming response runs after that. Raise it for slow networks or proxies. For how it caps the first-byte deadline, see No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
@@ -511,7 +512,7 @@
Request timed out
-This can happen during periods of high load or when the model is generating a very large response. The default request timeout is 10 minutes. **What to do:**
+The default request timeout is 10 minutes. **What to do:**
* Retry the request
* If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
@@ -593,11 +594,12 @@
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
-In an interactive session, a dim `Not run · auto mode's check had no usable answer` row appears under the tool call instead of this message. Press `Ctrl+O` to read the message in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>). The denials under The server returned no safety verdict show the same row. Before v2.1.296, the message appeared under the call as a red error. When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
+In an interactive session, a dim `Not run · auto mode's check had no usable answer` row appears under the tool call instead of this message. Press `Ctrl+O` to read the message in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>). The `gave no verdict` denials under The server returned no safety verdict show the same row. Before v2.1.296, the message appeared under the call as a red error. When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
* On Amazon Bedrock, if the message returns on every retry, check that your account can invoke the model it names: for standard Amazon Bedrock models, confirm your [IAM policy](</docs/en/amazon-bedrock#iam-configuration>) allows invoking it; for Mantle model IDs, [contact your AWS account team](</docs/en/amazon-bedrock#mantle-endpoint-errors>)
+ * If the message returns on every retry and names the model you set in [`CLAUDE_CODE_AUTO_MODE_MODEL`](</docs/en/permission-modes#choose-the-classifier-model>), check that the API or cloud provider your session runs on serves that model ID. If it doesn’t, set the variable to a model ID it serves, or unset the variable to use the [default classifier model](</docs/en/permission-modes#default-classifier-model>).
When a classifier request fails because your OAuth token expired or was rotated by another session, Claude Code refreshes the token and retries the request once, so a routine token expiry doesn’t surface as this message. Before v2.1.216, an expired or rotated token failed each classifier request, and auto mode denied every checked action with this message until the token was refreshed. When the classifier returned an unparseable response:
@@ -624,7 +626,7 @@
* In an interactive session, switch to a different [permission mode](</docs/en/permission-modes>) so you can approve the action when prompted
* Start a fresh conversation without the triggering content
-When the conversation has grown larger than the classifier’s context window:
+When the conversation is too long for Claude Code’s classifier request and Claude Code can’t compact it on its own:
Auto mode classifier transcript exceeded context window — falling back to manual approval (try /compact to reduce conversation size)
@@ -661,12 +663,34 @@
**What to do:**
+ * In an interactive session, press `Ctrl+O` to read the denial text in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>).
+ * If the denial names `(the conversation is too long for the check)`, run `/compact` at the Claude Code prompt to shorten the conversation. Until the conversation is shorter, sending another message gets the same denial. If you turned [auto-compact](</docs/en/settings-reference#autocompactenabled>) off, turn it back on so Claude Code compacts on its own next time.
* Send another message to have Claude try again. The count of responses starts over.
* If the stop repeats and your requests go through an [LLM gateway or proxy](</docs/en/llm-gateway>), check whether it cuts streaming responses short or rewrites them. [Server-side classifier review](</docs/en/permission-modes#server-side-classifier-review>) says which gateway behavior causes denials, and the [gateway compatibility guide](</docs/en/llm-gateway-protocol#feature-pass-through>) lists what to pass through unchanged.
* Set `CLAUDE_CODE_AUTO_MODE_SERVER=0` before you start Claude Code to use its own classifier requests instead. Before v2.1.281, Claude Code didn’t read the variable on a direct connection to the Anthropic API.
* To approve the actions yourself instead, [switch out of auto mode](</docs/en/permission-modes#switch-permission-modes>)
-Before v2.1.280, Claude Code denied each action from a response without a verdict immediately and never stopped the turn.
+Before v2.1.280, Claude Code denied each action from a response without a verdict immediately and never stopped the turn. Before v2.1.302, on a direct connection to the Anthropic API, Claude Code didn’t compact a conversation that had grown too long for the server’s check.
+
+###
+
+
+
+Was not reviewed and did not run
+
+A `was not reviewed and did not run` denial means the conversation is too long for the [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) classifier to check the action, so the action didn’t run. Claude Code returns this message to Claude:
+
+ <tool> was not reviewed and did not run: the conversation is too long for auto mode's classifier. Claude Code will try to compact the conversation before the next request; if this action is still needed after that, issue it again and it will be reviewed normally.
+
+If the compaction fails, later actions the classifier can’t check get one of two other messages:
+
+ * A `gave no verdict (the conversation is too long for the check)` denial
+ * The `Auto mode classifier transcript exceeded context window` message
+
+**What to do:**
+
+ * If the compaction the message announces succeeds, you don’t need to do anything.
+ * If you see either of those two messages, run `/compact` at the Claude Code prompt to shorten the conversation yourself. If you turned [auto-compact](</docs/en/settings-reference#autocompactenabled>) off, turn it back on so Claude Code compacts on its own next time.
###
@@ -1033,14 +1057,13 @@
Routines are disabled by your organization’s policy
-An Owner in your Team or Enterprise organization has turned off routines at the organization level. The error appears when you try to create or run a routine, for example from the [Routines](</docs/en/routines>) UI on claude.ai/code. On Claude Code v2.1.227 or later, the same setting also [hides `/schedule`](</docs/en/routines#troubleshooting>) in the CLI.
+An Owner in your Team or Enterprise organization has turned off [cloud scheduled tasks](</docs/en/routines>), formerly routines, at the organization level. The error appears when you try to create or run one, for example at [claude.ai/code/routines](<https://claude.ai/code/routines>). On Claude Code v2.1.227 or later, the same setting also [hides `/schedule`](</docs/en/routines#troubleshooting>) in the CLI.
Routines are disabled by your organization's policy.
This is a server-side setting, so it can’t be overridden from local settings, environment variables, or CLI flags. **What to do:**
- * Ask an Owner in your organization to enable the **Routines** toggle at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
- * For one-off scheduled work that does not require organization-level routines, see [scheduled tasks](</docs/en/scheduled-tasks>)
+ * Ask an Owner in your organization to turn on the **Scheduled tasks (Was Routines)** toggle at [**Organization settings > Capabilities > Remote sessions**](<https://claude.ai/admin-settings/capabilities>)
###
@@ -1801,14 +1824,19 @@
Host not allowed in a cloud session
-An outbound HTTP request from a cloud session or routine was blocked by the environment’s network policy.
+An outbound HTTP request from a cloud session or cloud scheduled task was blocked by the environment’s network policy.
HTTP 403
x-deny-reason: host_not_allowed
-You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
-
- * Open your environment for editing, either from the [routine’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
+You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This error is not a client-side network problem. Cloud sessions and [cloud scheduled tasks](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist:
+
+ * **GitHub and connector traffic** : [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked
+ * **Default environment** : the **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path
+
+**What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
+
+ * Open your environment for editing, either from the [cloud scheduled task’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
* In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
@@ -3284,9 +3312,9 @@
* [Agent SDK](</docs/en/agent-sdk/overview>) applications
* The Code tab of the [Desktop app](</docs/en/desktop>)
* The chat panel of the [VS Code extension](</docs/en/vs-code>)
- * [Cloud sessions](</docs/en/claude-code-on-the-web>) and [routines](</docs/en/routines>)
-
-For a built-in command that can’t run in one of those sessions, Claude Code still answers that the command isn’t available instead of sending it to Claude. Before v2.1.274, only cloud sessions and routines sent an unmatched name to Claude. Before v2.1.273, they answered `Unknown command` too. Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
+ * [Cloud sessions](</docs/en/claude-code-on-the-web>) and [cloud scheduled tasks](</docs/en/routines>)
+
+For a built-in command that can’t run in one of those sessions, Claude Code still answers that the command isn’t available instead of sending it to Claude. Before v2.1.274, only cloud sessions and cloud scheduled tasks sent an unmatched name to Claude. Before v2.1.273, they answered `Unknown command` too. Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
* Run the suggested name, or type `/` followed by part of the name to see what’s available in this session
* If Claude Code reports a documented command as unknown, check its row in the [commands reference](</docs/en/commands>) for the requirement it names
@@ -3416,7 +3444,7 @@
GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud. Run /web-setup to connect with your GitHub CLI login, or connect on the web at https://claude.ai/connect-github
-When you create a routine with [`/schedule`](</docs/en/routines>), the same message appears as a setup note that names the repository; the note doesn’t block creating the routine. **What to do:**
+When you create a cloud scheduled task with [`/schedule`](</docs/en/routines>), the same message appears as a setup note that names the repository; the note doesn’t block creating the task. **What to do:**
* Run `/web-setup` to connect your GitHub CLI login to your Claude account, or connect an account at [claude.ai/connect-github](<https://claude.ai/connect-github>). See [GitHub authentication options](</docs/en/claude-code-on-the-web#github-authentication-options>) for how the two differ.
* Rerun the command a minute after connecting
@@ -3658,14 +3686,14 @@
/recap only runs when you ask for it yourself
-The [`/recap`](</docs/en/interactive-mode#session-recap>) request didn’t come from your own input. It arrived in a message relayed into the session from a Slack, Teams, or [project](</docs/en/claude-projects>) thread, or in a prompt that a [routine](</docs/en/routines>) or another program sent. A relayed message gets the notice even when you wrote it yourself. Claude Code can’t tell that a relayed or automated message came from the person whose account runs the session, so it answers with this notice instead of a summary:
+The [`/recap`](</docs/en/interactive-mode#session-recap>) request didn’t come from your own input. It arrived in a message relayed into the session from a Slack, Teams, or [project](</docs/en/claude-projects>) thread, or in a prompt that a [cloud scheduled task](</docs/en/routines>) or another program sent. A relayed message gets the notice even when you wrote it yourself. Claude Code can’t tell that a relayed or automated message came from the person whose account runs the session, so it answers with this notice instead of a summary:
/recap only runs when you ask for it yourself in this session: from the terminal, the Claude app or claude.ai/code, or over Remote Control. A message relayed from Slack, Teams or a project thread, or sent by a routine or another program, can't request it.
A `/recap` you pass to `claude -p`, or that your own [Agent SDK](</docs/en/agent-sdk/overview>) application sends to a session it launched, counts as your own input. **What to do:**
* Open the session yourself and run `/recap` there: in its terminal, in the [Desktop app](</docs/en/desktop>) or the [mobile app](</docs/en/mobile>), at [claude.ai/code](<https://claude.ai/code>), or over [Remote Control](</docs/en/remote-control>)
- * If a routine or another program sent it, remove `/recap` from that prompt
+ * If a cloud scheduled task or another program sent it, remove `/recap` from that prompt
##
@@ -3987,7 +4015,8 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
* If the entry names a connected MCP server, compare the entry with that server’s name as the server’s [tool names](</docs/en/permissions#mcp>) spell it, such as `reports__v2` in `mcp__reports__v2__get_totals`. For that server, write `mcp__reports__v2__*`, which is `mcp__` followed by the whole name and `__*`. With the shorter `mcp__reports`, which names a server called `reports`, the subagent gets none of the `reports__v2` tools
- * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `CronCreate`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
+ * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `CronCreate`, remove the entry
+ * To keep a tool such as `CronCreate` instead, [let Claude wait for the subagent](</docs/en/sub-agents#let-claude-wait-for-a-subagent>), since a subagent Claude waits for runs in the foreground and keeps the tool. If the definition sets `background: true`, remove that field first, because it keeps the subagent in the background
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
--- a/errors.md
+++ b/errors.md
@@ -336,6 +336,7 @@
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
+`Bypass permissions was requested at launch and ignored`| [Skip all checks with bypassPermissions mode](</docs/en/permission-modes#bypass-permissions-acceptance>)
`kept <id> — its worktree is still at <path>`| Background session errors
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
@@ -408,7 +409,7 @@
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
* A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and streams the request again at most once. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
- * A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. On other connections, the request waits out `API_TIMEOUT_MS`. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
+ * A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
* A streaming response that the API’s output content filter stops before Claude has either finished thinking or started any text or tool call. Claude Code re-sends the request once, within the retry budget, and shows Output blocked by content filtering policy if the filter stops the second response too.
* Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
* When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
@@ -3985,6 +3986,7 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
+ * If the entry names a connected MCP server, compare the entry with that server’s name as the server’s [tool names](</docs/en/permissions#mcp>) spell it, such as `reports__v2` in `mcp__reports__v2__get_totals`. For that server, write `mcp__reports__v2__*`, which is `mcp__` followed by the whole name and `__*`. With the shorter `mcp__reports`, which names a server called `reports`, the subagent gets none of the `reports__v2` tools
* For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `CronCreate`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
Show diff (360 lines)
--- a/errors.md
+++ b/errors.md
@@ -62,6 +62,7 @@
`Claude.ai login was rejected — run /login, then /remote-control`| Authentication
`OAuth token unavailable — run /login to restore Remote Control`| Authentication
`Signed out of Claude — run /login, then /remote-control`| Authentication
+`Remote Control could not renew this computer's connection`| Authentication
`signed-in claude.ai account or organization changed on this machine`| Authentication
`Remote Control stopped — the app running this session is now signed in to a different Claude account`| Authentication
`Remote Control stopped — the app running this session is signed out of Claude`| Authentication
@@ -143,6 +144,7 @@
`Request too large`| Request errors
`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
+`API Error: an image in the conversation could not be processed and was removed`| Request errors
`Unable to resize image`| Request errors
`Request rejected as unprocessable by the model`| Request errors
`PDF too large` / `PDF is password protected` / `pdftoppm is not installed`| Request errors
@@ -169,6 +171,7 @@
`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
`effort '<level>' is not supported when thinking is disabled`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
+`Claude's response exceeded the ... output token maximum`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
`API Error: 400 orphaned tool_result in conversation history`| Request errors
`API Error: 400 duplicate tool_use ID in conversation history`| Request errors
@@ -189,6 +192,7 @@
`The connection dropped while downloading the update`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
`Download timed out: exceeded the total deadline`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
`--bg and --print conflict`| Command-line errors
+`Couldn't tell whether --bg is a flag or text here, so nothing was started`| Command-line errors
`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Cloud sessions are disabled by your organization's policy`| Command-line errors
@@ -207,6 +211,7 @@
`couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
+`--sandbox is not supported by claude remote-control` / `--no-sandbox is not supported by claude remote-control`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
@@ -223,6 +228,7 @@
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
+`No shell command in <name> was run, because the <tool> tool does not accept one of them`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Claude Code can't read the keyboard here: stdin is not a terminal`| Command-line errors
`Error: Input contained only whitespace`| Command-line errors
@@ -357,6 +363,7 @@
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`hook needs quotes around a path with a space`| Configuration warnings
+`Instruction file not loaded`| Configuration warnings
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
`N skill or command names refused: run with --debug to see which ([names]), rename, then restart`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
@@ -367,9 +374,11 @@
`Your organization's managed settings allow Claude Code to use: <providers>`| Configuration warnings
`Your organization's managed settings allow Claude Code to use no API provider at all`| Configuration warnings
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
+`"<name>" is a reserved MCP server name and was not loaded`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
`Unable to read managed policy settings`| Configuration warnings
+`Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:`| Configuration warnings
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name`| Configuration warnings
@@ -379,7 +388,10 @@
`... has a wildcard before the rest of the command`| Configuration warnings
`Denying Bash also turns off the PowerShell tool, so Claude has neither`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
+`Model "<model>" isn't recognized · context assumed to be 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
+`Claude Code doesn't recognize the model "<model>", so it assumes a context window of 200k tokens`| [Correct the window for a gateway or custom model ID](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>)
`[claude-code:unrecognized_model]`| Configuration warnings
+`is ignored — managed settings set allowManagedReadPathsOnly` / `is ignored — managed settings set allowManagedDomainsOnly`| Configuration warnings
`Stale sandbox mask files left by a killed session`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -1087,6 +1099,21 @@
+Remote Control could not renew this computer’s connection
+
+This warning appears in the terminal running [`claude remote-control`](</docs/en/remote-control#start-a-remote-control-session>) when the server can’t use your claude.ai login to renew its connection’s credential before it expires. The warning’s last sentence says how long the current credential still works, or that it has already expired:
+
+ Remote Control could not renew this computer's connection: claude.ai did not accept the sign-in it uses. Run `claude /login` to sign in again. The connection keeps working for about 26 hours; if it still cannot sign in then, it stops.
+
+**What to do:**
+
+ * If the warning tells you to run `claude /login`, open another terminal on the machine running the server, run `claude /login` there, and sign in with your claude.ai account
+ * If the server still can’t sign in once the connection’s credential has expired, it prints an error containing `Poll: Authentication failed (401)` and stops. Sign in again as the warning’s second sentence says, then run `claude remote-control` again in the terminal where the server stopped.
+
+###
+
+
+
Remote Control stopped because the signed-in account changed
Claude Code shows this line during a [Remote Control](</docs/en/remote-control>) session when you sign in to a different claude.ai account or organization on this machine. You made the switch outside the Claude Code session, for example by running `/login` in another terminal. A Remote Control session that you started while signed in through `/login` belongs to the claude.ai account and organization that were signed in at the time.
@@ -1970,6 +1997,7 @@
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
+ * If the error appears near 200K tokens on a model that accepts more, one cause is a model ID that Claude Code doesn’t recognize. Claude Code assumes a 200K window for such an ID, so to keep working past that point, [give it the model’s real context window](</docs/en/model-config#correct-the-window-for-a-gateway-or-custom-model-id>).
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
@@ -2026,8 +2054,15 @@
Image was too large. Double press esc to go back and try again with a smaller image.
API Error: 400 ... image dimensions exceed max allowed size
-
-Claude Code replaces the unprocessable image with a text placeholder and retries, so subsequent messages succeed. On versions before 2.1.142, a pasted image could remain in the conversation and repeat the same error on every subsequent message. To recover on those versions, press Esc twice and step back past the turn where the image was added. **What to do:**
+ API Error: an image in the conversation could not be processed and was removed.
+
+The `could not be processed and was removed` line means the API refused an image in the conversation, such as one over the size or dimension limits. If one of these errors keeps coming back, update Claude Code. On older versions, an image error could repeat for reasons such as these:
+
+ * Before v2.1.299, in a long conversation with many images, Claude Code could remove the images you attached last instead of the one over the limit. The `was removed` line then repeated on every turn, and Claude didn’t see your new images.
+ * Before v2.1.299, in VS Code, the Desktop app, and the Agent SDK, images you attached while Claude was working didn’t get the resizing that other attached images get. They reached the API at their original size, which led to repeated image errors in long conversations.
+ * Before v2.1.166, a pasted image could remain in the conversation, and the same error then repeated on every subsequent message
+
+**What to do:**
* Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 3000 pixels when more than 20 images are in context.
* Take a tighter screenshot of the relevant region instead of the full screen
@@ -2437,6 +2472,23 @@
+Response exceeded the output token maximum
+
+Claude’s reply reached the largest number of output tokens the request allowed and was cut off there:
+
+ API Error: Claude's response exceeded the ... output token maximum. To configure this behavior, set the CLAUDE_CODE_MAX_OUTPUT_TOKENS environment variable.
+ API Error: Claude's response exceeded the 64000 output token maximum for a request sent without streaming. The CLAUDE_CODE_MAX_OUTPUT_TOKENS environment variable cannot raise this limit.
+
+The form that names `a request sent without streaming` means a streaming request failed and Claude Code re-sent it without streaming, which limits the reply to 64,000 output tokens. Before v2.1.299, a reply cut off on such a re-sent request ended the turn without this message, as if the reply were complete. **What to do:**
+
+ * If Claude wrote some text before the reply was cut off, reply `continue` in an interactive session to ask for the rest. That text stays in the conversation.
+ * If the message says to set `CLAUDE_CODE_MAX_OUTPUT_TOKENS`, see [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) for how the value is capped and [Set environment variables](</docs/en/env-vars#set-environment-variables>) for where to set it
+ * To keep each reply under the limit, ask Claude for the output in smaller pieces, such as one file or one section per reply
+
+###
+
+
+
Tool use or thinking block mismatch
The conversation history reached the API in an inconsistent state.
@@ -2544,13 +2596,19 @@
The model’s safety measures flagged content in the conversation as a cybersecurity topic. The message names the model that flagged the request:
- API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-
-If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. This message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. Models with [automatic model fallback](</docs/en/model-config#automatic-model-fallback>) print a different message, without this link; on Opus 5.5 and Sonnet 5.5 it opens with `<model>'s safeguards flagged this session`. That section also covers when Claude Code switches models instead. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+ API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
+
+If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. This message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. Models with [automatic model fallback](</docs/en/model-config#automatic-model-fallback>) print a different message, without this link; on Opus 5.5 and Sonnet 5.5 it opens with `<model>'s safeguards flagged this session`. That section also covers when Claude Code switches models instead. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
* To keep working in the same session, press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the flag, then take a different approach. See [Checkpointing](</docs/en/checkpointing>).
+
+If the message you see is worded like one of these instead, it’s the same flag on an earlier Claude Code version:
+
+ * From v2.1.219 through v2.1.296, the message could also include `Apply to the Cyber Verification Program to reduce these interruptions.` before its closing sentence
+ * From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link. In interactive sessions, it continued with `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.`
+ * Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link
###
@@ -2613,6 +2671,20 @@
+Couldn’t tell whether `--bg` is a flag or text
+
+You ran `claude` with `--bg` or `--background` at a position where Claude Code couldn’t tell whether you meant it as the background flag or as text. The command started nothing, printed this line, and exited with code 1:
+
+ Couldn't tell whether --bg is a flag or text here, so nothing was started. To start a background session put it first: claude --bg <prompt>
+
+If you typed `--background`, the line names `--background` instead. **What to do:**
+
+ * To start a [background session](</docs/en/agent-view#from-your-shell>), run the command again in your shell with the flag first: `claude --bg --name nightly-audit "<task>"`
+
+###
+
+
+
Conflict between a system prompt flag and its file form
You passed [`--append-subagent-system-prompt`](</docs/en/cli-reference#cli-flags>) together with `--append-subagent-system-prompt-file` in one `claude` invocation, so `claude` exits with code 1 instead of starting the session:
@@ -2857,6 +2929,24 @@
+`--sandbox` or `--no-sandbox` is not supported by claude remote-control
+
+This error means the command that starts your [Remote Control](</docs/en/remote-control>) server passes `--sandbox` or `--no-sandbox` after `remote-control`, and `claude remote-control` accepts neither flag. The server exits with code 1 instead of starting:
+
+ Error: --sandbox is not supported by claude remote-control. The flag had no effect and was removed. To sandbox sessions, set sandbox.enabled to true in settings.
+ Error: --no-sandbox is not supported by claude remote-control. The flag had no effect and was removed. Remove it from the command.
+
+**What to do:**
+
+ * Remove the flag from the command, including in a script or service definition that starts the server for you, then run it again
+ * To sandbox the sessions the server starts, turn on [sandboxing](</docs/en/sandboxing>) by setting [`sandbox.enabled`](</docs/en/settings-reference#sandbox-enabled>) to `true` in a [settings file](</docs/en/settings#where-settings-live>)
+
+Both flags were removed from `claude remote-control` in v2.1.300, so a command written for an earlier version can still carry one.
+
+###
+
+
+
claude import is not yet available in this build
You ran [`claude import`](</docs/en/cli-reference#cli-commands>), and Claude Code found the import flow turned off, so the command exits with code 1 instead of starting the import. Before v2.1.222, a build with the import flow off treated `import` as a prompt and started an interactive session instead of printing this message.
@@ -3075,16 +3165,32 @@
* A remote whose server-side HEAD points at a branch nobody pushed
* A repository with no `origin` remote, or one you never fetched
-Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>), and a failed injected command aborts that skill’s invocation. Two sibling strings fire before the command runs at all:
+Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>), and a failed injected command aborts that skill’s invocation. Sibling strings fire before the command runs at all:
* `Shell command permission check failed for pattern "..."`: the command’s permission check didn’t allow it. [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>) covers which results abort in each permission mode and how to pre-approve a command with `allowed-tools`
* `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
+ * `No shell command in <name> was run`: one of the file’s `!` commands contains a raw control character other than tab or newline, so none of them runs. See how to find and remove the character
**What to do:**
* Create the ref by naming your remote’s default branch: `git remote set-head origin <default-branch>`. This works whenever the local tracking ref `origin/<default-branch>` exists. If it doesn’t, as in single-branch clones, fetch the branch first: run `git remote set-branches --add origin <branch>`, then `git fetch origin`, then rerun the set-head command. Rerun `/security-review`.
* If you’d rather not name the branch, run `git fetch origin` and then `git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
* If the repository has no remote, add one with `git remote add origin <url>` and fetch before creating the ref. If the remote is empty, push your branch first with `git push -u origin HEAD` and name that branch in the set-head command; `origin/HEAD` then points at the branch you just pushed, so `/security-review` sees an empty diff until the branch diverges from it.
+
+###
+
+
+
+No shell command in a skill or command was run
+
+One of the `!`<command>`` [dynamic context commands](</docs/en/skills#inject-dynamic-context>) in a skill or custom command file contains a raw control character other than tab or newline. Claude Code refuses the whole invocation before any of the file’s commands runs. The message names the shell tool that would have run the commands, Bash or PowerShell, and ends with the refused command. Each such character is replaced by `�` so you can see where it is:
+
+ No shell command in /my-skill was run, because the Bash tool does not accept one of them: command contains control characters that would be hidden in the approval dialog. Unprintable characters are shown as � below: remove them from the skill or command file, or from the arguments or options substituted into it.
+ build.sh --target�dist
+
+**What to do:**
+
+ * Find each `�` in the command quoted at the end of the message. Remove the character it stands for from the skill or command file, or from the arguments or options substituted into the file.
###
@@ -4827,6 +4933,32 @@
+Instruction file not loaded
+
+This notice in the conversation view of an interactive session means a [memory file](</docs/en/memory#how-claude-md-files-load>) that exists wasn’t loaded. A read restriction is in force.
+
+ Instruction file not loaded (a Read deny rule covers it):
+ path: .claude/rules/shared.md
+
+The parenthetical names the reason, for example:
+
+ * **`a Read deny rule covers it`** : a `Read` [deny rule](</docs/en/permissions#read-and-edit>) matches the file’s path as written or where a link on it leads
+ * **`it's read from outside your working directories, where reads are blocked`** : the file resolves outside the [working directories](</docs/en/settings-reference#permissions-blockreadsoutsideworkingdirectories>) while [`permissions.blockReadsOutsideWorkingDirectories`](</docs/en/settings-reference#permissions-blockreadsoutsideworkingdirectories>) is on
+ * **`where it leads couldn't be worked out`** : for example, the file is a link that leads back to itself, directly or through other links
+
+When a subdirectory’s own memory file can’t be loaded as Claude works with files there, the same lines appear in the conversation during the turn. When more files are withheld than the lines name, a final line counts the rest, such as `and 3 more instruction files not loaded`. **What to do:**
+
+ * Nothing, if the restriction is intended: the session runs without that file’s instructions.
+ * To load a file withheld because `a Read deny rule covers it`, [remove or narrow that rule](</docs/en/permissions#manage-permissions>). Then start a new session.
+ * To load a file withheld because `it's read from outside your working directories, where reads are blocked`, move it or its link target inside the working directories. Then start a new session.
+ * To load a file withheld because `where it leads couldn't be worked out`, check whether the file is a link that leads back to itself. If it is, point the link at a file that exists or put a regular file in its place. Then start a new session.
+
+Before v2.1.292, the notice named the file at the end of the same line after the reason.
+
+###
+
+
+
A skill, command, or workflow wasn’t loaded because its name is reserved
A skill folder, a frontmatter `name`, a file or subfolder in `.claude/commands/`, or a [saved workflow](</docs/en/workflows#save-the-workflow-for-reuse>) uses the name `anthropic-skills` or a name that starts with `anthropic-skills:`. Claude Code [reserves that name for skills synced from claude.ai](</docs/en/skills#names-reserved-for-synced-skills>) and doesn’t load that item. Claude Code shows this warning as a startup notice in the conversation view rather than on stderr:
@@ -4997,6 +5129,21 @@
+MCP server name is reserved
+
+This message names one of your MCP servers, whose name is among those Claude Code reserves, such as the names of its built-in servers:
+
+ "workspace" is a reserved MCP server name and was not loaded
+
+**What to do:**
+
+ * Rename the server where you define it, for example from `workspace` to `my-workspace`
+ * For other reserved names to avoid, see [MCP configuration warnings](</docs/en/mcp#configuration-warnings>)
+
+###
+
+
+
Managed settings document could not be parsed
Your organization deploys [managed settings](</docs/en/managed-settings>), and one of the deployed documents is present but can’t be parsed as a JSON object, so Claude Code exits with code 1 at startup instead of running without the policy the document carries. The line names the failed source before the message:
@@ -5034,6 +5181,25 @@
* If you don’t, send the message to your administrator. Nothing in your own settings files causes or clears this error
Before v2.1.285, only sessions signed in with claude.ai or Claude Console credentials exited with this message, and a read that the operating system denied produced it too.
+
+###
+
+
+
+Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded
+
+This stderr block from a `-p` run means that a [managed settings](</docs/en/managed-settings>) source holds a hook entry Claude Code can’t load. That hook doesn’t run, and when a line lists the source’s `hooks` field as ignored, none of that source’s hooks run. Each line names the source, the field when there is one, and the problem, such as an unknown hook `type` or a hook declared outside the `hooks` key:
+
+ Managed settings contain invalid entries, including PreToolUse/PermissionRequest hooks that are NOT loaded; fix or remove each entry:
+ <source> (<field>): <message>
+
+**What to do:**
+
+ * If you administer the source, fix or remove each entry the block lists. [Hook configuration](</docs/en/hooks#configuration>) shows the shape Claude Code expects under `hooks`.
+ * If a line’s source is `parent managed settings`, the application that launched Claude Code passed that entry in as [parent settings](</docs/en/managed-settings#parent-settings-from-embedding-hosts>), so report it to that application’s developer
+ * Otherwise, send the block to your administrator
+
+Before v2.1.300, a `-p` run listed this case under the `Managed settings failed to load; policies from the failed source are NOT in effect:` header.
###
@@ -5237,6 +5403,22 @@
+Sandbox allow entries are ignored under a managed lock
+
+This warning in `/status` and `claude doctor` means managed settings set [`allowManagedReadPathsOnly`](</docs/en/settings-reference#sandbox-filesystem-allowmanagedreadpathsonly>) or [`allowManagedDomainsOnly`](</docs/en/settings-reference#sandbox-network-allowmanageddomainsonly>), so the [`allowRead`](</docs/en/settings-reference#sandbox-filesystem-allowread>) or [`allowedDomains`](</docs/en/settings-reference#sandbox-network-alloweddomains>) entries in the file it names don’t apply:
+
+ sandbox.filesystem.allowRead is ignored — managed settings set allowManagedReadPathsOnly, so only allowRead paths from managed settings are honored. The 3 entries in /home/you/.claude/settings.json will NOT apply (see https://code.claude.com/docs/en/settings#sandbox-settings).
+
+For the network lock, the warning names `sandbox.network.allowedDomains` and `allowManagedDomainsOnly`, and says `only allowed domains (and WebFetch domain rules) from managed settings are honored`. **What to do:**
+
+ * You don’t have to act on the warning
+ * If you need those paths or domains and your organization’s managed settings set the lock, ask your administrator to add them to those settings. The warning stays until you also remove the entries from the named file.
+ * To clear the warning, remove the entries from the named file. For a file you share, such as a project’s `.claude/settings.json`, you can leave the entries in for teammates without the lock and leave the warning showing.
+
+###
+
+
+
Stale sandbox mask files left by a killed session
`claude doctor` prints this warning in its diagnostics, and `/status` lists the same line. It appears on Linux and WSL2 when [sandboxing](</docs/en/sandboxing>) is enabled with filesystem isolation on. While a sandboxed command runs, the sandbox holds a write denial on a file that doesn’t exist yet by creating a 0-byte read-only placeholder there, and removes it afterward. A session killed before that cleanup runs, for example by SIGKILL, leaves the placeholders behind. Later sessions bind them read-only again on every start, so a settings write such as saving “Yes, and don’t ask again” fails where one sits.
--- a/errors.md
+++ b/errors.md
@@ -356,7 +356,9 @@
`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>)
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
+`hook needs quotes around a path with a space`| Configuration warnings
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
+`N skill or command names refused: run with --debug to see which ([names]), rename, then restart`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
@@ -1779,7 +1781,7 @@
You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
* Open your environment for editing, either from the [routine’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
- * In the **Edit environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -4811,6 +4813,20 @@
+Hook needs quotes around a path with a space
+
+This notification in the conversation view means a hook’s script didn’t run because its path has a space and isn’t quoted. That hook is an [`asyncRewake`](</docs/en/hooks#run-hooks-in-the-background>) hook in shell form. In its `command`, an interpreter such as `python3` is followed by an unquoted path placeholder, and the resolved path contains a space. The notification starts with the hook’s event name and names the script:
+
+ Stop hook needs quotes around a path with a space (check.py)
+
+**What to do:**
+
+ * In the `command` of the hook that runs the script the notification names, wrap the path in double quotes. In a JSON file, write it as `"command": "python3 \"${CLAUDE_PLUGIN_ROOT}/hooks/check.py\""`.
+
+###
+
+
+
A skill, command, or workflow wasn’t loaded because its name is reserved
A skill folder, a frontmatter `name`, a file or subfolder in `.claude/commands/`, or a [saved workflow](</docs/en/workflows#save-the-workflow-for-reuse>) uses the name `anthropic-skills` or a name that starts with `anthropic-skills:`. Claude Code [reserves that name for skills synced from claude.ai](</docs/en/skills#names-reserved-for-synced-skills>) and doesn’t load that item. Claude Code shows this warning as a startup notice in the conversation view rather than on stderr:
@@ -4822,6 +4838,24 @@
* Rename the item the notice names, or edit the `name:` line it points to, then restart the session.
Before v2.1.282, Claude Code loaded skills and commands with these names.
+
+###
+
+
+
+Skill or command name refused
+
+This startup notice means Claude Code refused the name of at least one [skill or custom command](</docs/en/skills>), so it didn’t load or loaded without its `name` field:
+
+ 1 skill or command name refused: run with --debug to see which ([names]), rename, then restart — a name may not hold hidden, direction-changing or blank-like characters, < or >, or be over 256 characters
+
+ * **Not loaded** : Claude Code refused the name a skill or command goes by, such as its directory name or a command file’s name or subfolder. It’s missing from the `/` menu and Claude can’t invoke it. Its line in the debug log reads `<name> is not offered`.
+ * **`name` field ignored**: Claude Code refused a skill’s frontmatter `name`. The skill still loads, but the `/` menu doesn’t show the `name` value and typing it doesn’t invoke the skill. Its line in the debug log reads `<name value> is not shown for <skill>`.
+
+**What to do:**
+
+ * Start Claude Code with `claude --debug` from your shell and search the [debug log](</docs/en/debug-your-config>) for `[names]`. Each name the notice counts has one line there. The line spells out some hidden characters as codes, such as `\u{200B}` for a zero-width space, so you can see where they are.
+ * Remove the [characters a skill name can’t hold](</docs/en/skills#characters-a-skill-name-cant-hold>) by renaming the folder or file or editing the `name:` line, or shorten a name that is over 256 characters. Then restart the session, unless the file is in a directory Claude Code [watches for changes](</docs/en/skills#live-change-detection>). For a skill from a plugin you didn’t write, ask the plugin’s author to rename it.
###
Show diff (197 lines)
--- a/errors.md
+++ b/errors.md
@@ -124,6 +124,7 @@
`proxy refused the connection`| Network
`403` with `GitHub GraphQL is not available from Claude Code sessions` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
+`Failed to fetch session from Sessions API: Failed to fetch session logs`| Network
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
@@ -143,9 +144,12 @@
`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
`Unable to resize image`| Request errors
+`Request rejected as unprocessable by the model`| Request errors
`PDF too large` / `PDF is password protected` / `pdftoppm is not installed`| Request errors
`Extra inputs are not permitted`| Request errors
`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid` / `Property keys should match pattern`| Request errors
+`Tool "mcp__<server>__<tool>" is not sent to Claude: its name has <N> characters and the API accepts at most 128`| Request errors
+`tools.N.custom.name: String should have at most 128 characters`| Request errors
`tool_use.name: String should have at most 200 characters`| Request errors
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
@@ -188,8 +192,11 @@
`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Cloud sessions are disabled by your organization's policy`| Command-line errors
+`Cloud sessions use your claude.ai login`, at the end of a policy denial that names a credential| Command-line errors
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
+`Cloud sessions aren't available:` followed by why your organization’s policy couldn’t be loaded| Command-line errors
`Cloud sessions need a claude.ai sign-in`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
+`Nothing was stashed: "<path>" is now a folder in place of a tracked file or link` / `are now folders in place of tracked files or links`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Invalid --agents configuration:`| Command-line errors
`Error: --agents takes a JSON object, or a file path only with --print (-p)`| Command-line errors
@@ -249,6 +256,7 @@
`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
`/recap only runs when you ask for it yourself in this session`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
+`cannot be evaluated where sessions load it`| [Test plugins with evals](</docs/en/plugin-evals#cannot-be-evaluated-where-sessions-load-it>)
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Claude Code refuses the marketplace name "<name>"`| Plugin errors
`Marketplace name impersonates an official Anthropic/Claude marketplace`| Plugin errors
@@ -433,6 +441,7 @@
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
+[`CLAUDE_CODE_OVERLOADED_RETRY_MAX_DELAY_MS`](</docs/en/env-vars>)| 32000| Ceiling in milliseconds on the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 64000, so that later retries keep spreading apart when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.296 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
@@ -1824,6 +1833,22 @@
+Failed to fetch session from Sessions API
+
+This message means Claude Code found the [cloud session you asked to pull into your terminal](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>) but couldn’t read its conversation history from Anthropic’s servers, so it didn’t open it:
+
+ Failed to fetch session from Sessions API: Failed to fetch session logs
+
+You see it after `claude --teleport`, `/teleport`, or choosing the session in the [`/tasks`](</docs/en/commands>) list. `claude --teleport <session-id>` prints it and exits with code 1. **What to do:**
+
+ * Run the same teleport again. If it fails the same way, report the problem
+
+Before v2.1.296, Claude Code didn’t retry a failed read, and after one it could open the session with an empty conversation and report success instead of printing this message.
+
+###
+
+
+
Couldn’t reconnect to your Remote Control session
Couldn't reconnect to your Remote Control session. Retry, or start a fresh session without --resume.
@@ -2031,6 +2056,20 @@
+Request rejected as unprocessable by the model
+
+The API refused the request as one the model can’t process. The message is the API’s own.
+
+ API Error: 400 Request rejected as unprocessable by the model (too many or oversized images, or unsupported parameters)
+
+Claude Code can remove the oldest images and documents from a refused request and send it again. Before v2.1.290, Claude Code didn’t remove images on this refusal, so a long session that accumulated hundreds of them could fail with this error on every turn. **What to do:**
+
+ * If the message keeps appearing in a conversation with images or documents, remove them yourself. Press Esc twice to step back past the turns that added them, or run `/clear` to start fresh.
+
+###
+
+
+
PDF errors
The PDF you attached couldn’t be processed. The messages are shown here in their non-interactive form; in an interactive session they instead prompt you to double press esc and try again.
@@ -2081,6 +2120,24 @@
* If your Claude Code version is earlier than v2.1.216, run `claude update`.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
* If you maintain the server, fix the tool’s `input_schema`. The schema must be valid JSON Schema, and top-level property names must be 1 to 64 characters long and use only ASCII letters and digits, `_`, `.`, and `-`. See [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>).
+
+###
+
+
+
+MCP tool name over 128 characters
+
+An MCP server lists a tool whose full name, such as `mcp__<server>__<tool>`, is longer than the 128 characters the API accepts. Claude Code [leaves that tool out of the tools it sends to Claude](</docs/en/mcp#tools-with-names-longer-than-128-characters>), and the server’s other tools keep working. In a session you start with `claude --debug` from your shell, Claude Code writes this message to the debug log at `~/.claude/debug/<session-id>.txt`:
+
+ Tool "mcp__<server>__<tool>" is not sent to Claude: its name has <N> characters and the API accepts at most 128
+
+**What to do:**
+
+ * If you maintain the server, shorten the tool’s name.
+ * If the server is in your [MCP configuration](</docs/en/mcp#mcp-installation-scopes>), give it a shorter name there, such as `db` in place of `analytics-database`. Then update what refers to the server or its tools by the old name, such as [permission rules](</docs/en/permissions#mcp>) and [hook matchers](</docs/en/hooks#match-mcp-tools>).
+ * If a [plugin bundles the server](</docs/en/mcp#plugin-provided-mcp-servers>), the tool’s full name also includes the plugin name. Ask the plugin’s maintainer to shorten the server or tool name.
+
+Before v2.1.292, Claude Code sent the tool anyway, and the API rejected every request that included it with `API Error: 400 ... tools.N.custom.name: String should have at most 128 characters`.
###
@@ -2617,10 +2674,58 @@
Cloud sessions are disabled by your organization's policy. Contact your organization admin to enable them.
-The message appears when you [create a cloud session from the terminal](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) and when you submit a command that needs cloud sessions, such as `/teleport`, `/remote-env`, or `/web-setup`. Before v2.1.268, submitting one of those commands returned `Unknown command` instead. This is a server-side organization policy, so it can’t be overridden from local settings, environment variables, or CLI flags. If Claude Code hasn’t loaded your organization’s policy yet or can’t fetch it, those commands answer `Couldn't verify your organization's policy for cloud sessions. Check your network connection, then restart Claude Code and try again.` instead. **What to do:**
+The message appears when you [create a cloud session from the terminal](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) and when you submit a command that needs cloud sessions, such as `/teleport`, `/remote-env`, or `/web-setup`. Before v2.1.268, submitting one of those commands returned `Unknown command` instead. If the message instead names a credential this session is using and ends with `Cloud sessions use your claude.ai login.`, see Cloud sessions use your claude.ai login. If Claude Code couldn’t load your organization’s policy at all, you see a different message instead. **What to do:**
* Ask an [Owner](</docs/en/server-managed-settings#access-control>) in your organization to enable cloud sessions in the Claude Code admin settings at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
- * If the message says it couldn’t verify the policy, check your network connection, then restart Claude Code and try again
+
+###
+
+
+
+Cloud sessions use your claude.ai login
+
+When the policy denial names a credential this session is using and ends with this sentence, Claude Code checked the cloud-session policy of the organization that issued that credential. That organization can differ from the one your claude.ai login belongs to:
+
+ Cloud sessions are disabled by your organization's policy. This session is using ANTHROPIC_API_KEY, so Claude Code checked the policy for the organization that key belongs to. Cloud sessions use your claude.ai login.
+
+The last sentence means that cloud sessions run on your claude.ai login rather than on that credential. This form appears when you start, resume, or message a cloud session from your shell, such as with `--cloud` or `--teleport`. Before v2.1.296, Claude Code printed the form that tells you to contact your organization admin in this case too.
+
+###
+
+
+
+Couldn’t verify your organization’s policy for cloud sessions
+
+These messages mean Claude Code couldn’t load your organization’s policy, which it checks before it creates, resumes, or messages a [cloud session](</docs/en/claude-code-on-the-web>). While the policy request hasn’t finished, the message is:
+
+ Couldn't verify your organization's policy for cloud sessions. Check your network connection and try again.
+
+Inside a session, a command that needs cloud sessions, such as `/teleport` or `/web-setup`, gives this message too. It does so even where your shell would print a `Cloud sessions aren't available:` form, and its second sentence reads `Check your network connection, then restart Claude Code and try again.` Once the policy request has failed, the message says what failed. This applies when you start, resume, or message a cloud session from your shell with a flag such as `--cloud` or `--teleport`. With no route to the API, it reads:
+
+ Cloud sessions aren't available: couldn't reach api.anthropic.com to load your organization's policy. Check your network or proxy.
+
+Other failures follow the same opening with their own cause, such as a proxy that refused the request with HTTP 403, a server error, or credentials the API didn’t accept. When the API didn’t accept a credential that this session uses in place of your claude.ai login, such as an `ANTHROPIC_API_KEY` environment variable, the message can also name it and say to unset it:
+
+ Cloud sessions aren't available: api.anthropic.com didn't accept this session's credentials when Claude Code asked for your organization's policy. Cloud sessions use your claude.ai login. ANTHROPIC_API_KEY is set, so this session is using API-key auth — unset it (or run in a shell without it) to use cloud sessions.
+
+Before v2.1.296, these failures printed the `Couldn't verify` message too. **What to do:**
+
+ * For the `Couldn't verify` message, check your network connection and try again. Inside a session, restart Claude Code first
+ * For a `Cloud sessions aren't available:` message, do what its cause calls for, such as checking your proxy or unsetting the credential it names, then run the command again
+
+###
+
+
+
+Nothing was stashed because a folder replaced a tracked file
+
+This message means a folder in your checkout now sits where a git-tracked file or link used to be. It appears after you choose the stash option while pulling a [cloud session](</docs/en/claude-code-on-the-web#from-cloud-to-terminal>) into your terminal, for example with `claude --teleport` or `/teleport`. Stashing that state could delete the files inside the folder, so Claude Code refuses the stash and leaves your checkout and index unchanged:
+
+ Error: Nothing was stashed: "f" is now a folder in place of a tracked file or link, and stashing could delete what's in it for good. Commit the change or move the folder somewhere else, then try again.
+
+**What to do:**
+
+ * Commit the change or move the folder somewhere else, as the message says, then run the teleport again
###
@@ -3342,13 +3447,13 @@
Claude Code couldn’t restart
-Claude Code was restarting, for example to switch to or from fullscreen rendering after you ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>). It closed the session but couldn’t start the new process, so it printed this message and exited with status 1:
+When this message says your conversation is saved, the conversation is on disk and you can pick it up where it stopped. Claude Code was restarting itself, for example to switch to or from fullscreen rendering after you ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>), and couldn’t start the new process, so it exited with status 1:
Claude Code couldn't restart. Your conversation is saved. Start Claude Code again and run /resume to pick it up.
When the restart had no conversation to reopen, for example because `/tui` was your first input in a new session, the message reads `Claude Code couldn't restart. Start Claude Code again.` **What to do:**
- * Run `claude` again in your shell from the same directory. If the message said your conversation is saved, run [`/resume`](</docs/en/sessions#resume-a-session>) in the new session and select it
+ * Run `claude` again in your shell. If the message said your conversation is saved, run [`/resume`](</docs/en/sessions#resume-a-session>) in the new session and select the conversation. If it isn’t in the list, [widen the session picker](</docs/en/sessions#where-the-session-picker-looks>)
* If restarts keep failing, start Claude Code from your shell with [`claude --debug-file claude-debug.log`](</docs/en/cli-reference#cli-flags>). If a restart from that session fails, `claude-debug.log` in the directory you started from records a `Failed to relaunch:` line with the operating system’s error. Include that line when you report the problem
###
--- a/errors.md
+++ b/errors.md
@@ -84,6 +84,7 @@
`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
+`Login expired · Run /login to sign in again, or re-authenticate your Anthropic profile`| Authentication
`Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
@@ -1161,7 +1162,7 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
+For a `Login expired` message that ends with `or re-authenticate your Anthropic profile`, see Anthropic profile login expired. This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* If you sign in with your claude.ai account in another Claude Code window, see Not logged in for when this session starts using that login on its own.
@@ -1298,22 +1299,26 @@
Anthropic profile login expired
-Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying, because a retry would read the same expired credential.
+Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying.
Anthropic profile login expired · Re-authenticate your Anthropic profile
- Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile
-
-This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. On a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login`, choose the Anthropic Console account, and sign in again to renew a profile that the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote. Claude Code replaces the expired credential in that profile. For a federation profile or one another tool created, `/login` doesn’t renew the credential. Which form you see depends on whether you selected the profile or Claude Code discovered it:
-
- * When you set `ANTHROPIC_PROFILE` explicitly, the message ends with `Re-authenticate your Anthropic profile`.
- * When Claude Code discovered the profile from your configuration directory, the message offers `/login`, because Claude Code gives a working `/login` precedence over the discovered profile and then authenticates with your claude.ai or Console account instead. Before v2.1.234, Claude Code showed the `Re-authenticate your Anthropic profile` form in this case too.
-
-**What to do:**
-
- * Sign in to the profile again, then retry: on a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login` and choose the Anthropic Console account for a profile the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote; for other profiles, use the tool that created them
+ Login expired · Run /login to sign in again, or re-authenticate your Anthropic profile
+
+**What to do:**
+
+ * If the message leads with `Login expired`, run `/login` to sign in again
+ * To renew a profile that the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote, run `/login` on a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>). Choose the Anthropic Console account, then **Sign in with your Console account**. Claude Code replaces the expired credential in that profile
+ * To renew a profile that another tool created, sign in again with that tool. If you choose **Sign in with your Console account** at `/login` instead, Claude Code leaves the profile as it is and creates an API key
* If an administrator provisioned the profile’s credential, ask them to issue a new one
* Run `/status` to confirm the active credential source and profile name
* To stop using the profile, unset `ANTHROPIC_PROFILE` if you set it, then authenticate another way, such as `/login` or `ANTHROPIC_API_KEY`
+
+How the message starts tells you how Claude Code found the profile:
+
+ * When Claude Code discovered the profile from your configuration directory and its auth mode is `user_oauth`, the message leads with `Login expired` and offers `/login` first. Claude Code gives a working `/login` precedence over the discovered profile and then authenticates with your claude.ai account instead. From v2.1.234 until v2.1.277, this form read `Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`. Before v2.1.234, Claude Code showed the `Re-authenticate your Anthropic profile` form in this case too.
+ * When you selected the profile with `ANTHROPIC_PROFILE`, the message leads with `Anthropic profile login expired`.
+
+This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message.
###
@@ -3520,8 +3525,12 @@
For an imitating name, the marketplace’s own error reads `Claude Code refuses this marketplace's name: it looks like one of Anthropic's own` instead. `claude plugin marketplace add` refuses any impersonating name with `Marketplace name impersonates an official Anthropic/Claude marketplace`. Before v2.1.282, `claude plugin list` and `/plugin` reported the plugins of an imitating name as failed to load too, without naming the marketplace’s name as the cause. **What to do:**
- * Run `claude plugin marketplace remove <name>`. This also uninstalls the plugins installed from the marketplace and deletes their saved data
- * To keep the marketplace instead, wait until its maintainer renames it, then run `claude plugin marketplace update <name>`
+ * To keep a marketplace that a settings file declares inline with `"source": "settings"`, rename it before you remove the old name, because removing the marketplace also deletes its entry from your settings files. Claude Code v2.1.292 or later lists these steps in the message:
+ 1. In each settings file that lists the marketplace under `extraKnownMarketplaces`, give the entry’s key and its `source.name` one new plain-ASCII name that doesn’t look like an official one. If an administrator adds the marketplace through your organization’s managed settings, the administrator does this step
+ 2. Run `claude plugin marketplace remove <old-name>`, or remove the old name in the **Marketplaces** tab in `/plugin`. This also uninstalls its plugins and deletes their data, options, and secrets
+ 3. Start Claude Code again, in the project’s folder if the file is a project’s settings file. Then install the plugins from the renamed marketplace
+ * To keep any other marketplace, wait until its maintainer renames it, then run `claude plugin marketplace update <name>`
+ * To remove the marketplace, run `claude plugin marketplace remove <name>`. This also uninstalls the plugins installed from the marketplace and deletes their data, options, and secrets
* If you publish the marketplace, rename it in your `marketplace.json`; users then update the marketplace instead of removing it
###
--- a/errors.md
+++ b/errors.md
@@ -27,6 +27,7 @@
`Connection lost while your computer was asleep`| Automatic retries
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
+`Not run · auto mode's check had no usable answer`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
`The server-side auto mode classifier gave no verdict`| Server errors
@@ -253,6 +254,7 @@
`Marketplace "<name>" is already added from a different source`| Plugin errors
`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
`Cannot add marketplace "<name>": Claude Code cannot install plugins from a marketplace with this name`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#cannot-install-plugins-from-a-marketplace-with-this-name>)
+`Cannot add marketplace "<name>": Claude Code reserves this name and cannot register a marketplace under it`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#claude-code-reserves-this-name>)
`Marketplace "<name>" is added but ignored`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`Marketplace "<name>" is registered but was refused (see the debug log)`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`references ${user_config.*} in a shell-form command`| Plugin errors
@@ -299,6 +301,7 @@
`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)`| Tool errors
`The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
+`File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Not published: that file is on a network share`| Tool errors
@@ -565,7 +568,7 @@
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
-When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
+In an interactive session, a dim `Not run · auto mode's check had no usable answer` row appears under the tool call instead of this message. Press `Ctrl+O` to read the message in the [transcript viewer](</docs/en/interactive-mode#transcript-viewer>). The denials under The server returned no safety verdict show the same row. Before v2.1.296, the message appeared under the call as a red error. When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
@@ -1658,7 +1661,7 @@
Connection to api.anthropic.com timed out after 10 seconds
A proxy is configured via HTTPS_PROXY. Check that it allows connections to the host above.
-Claude Code sends the check through the same [proxy configuration](</docs/en/network-config>) as API requests and gives each probe 10 seconds. When the failed probe went through a proxy, the message names the environment variable that configured it, such as `HTTPS_PROXY`. Before v2.1.222, the check used a different proxy transport with no timeout: behind a proxy URL with the `https://` scheme, it could stall on `Checking connectivity...` indefinitely and then fail even though API requests through the same proxy succeed. Claude Code skips this check when a [managed settings file, MDM policy, or policy helper](</docs/en/managed-settings>) sets [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"`, or sets [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>) without `forceLoginMethod`. With either configuration, Claude Code opens the sign-in step on the **Cloud gateway** screen rather than an Anthropic sign-in method. Claude Code also skips the check when a managed settings source on the machine exists but can’t be read, since that source may hold the gateway configuration. Before v2.1.247, Claude Code ran the check under this configuration too, and exited with this error when Anthropic’s endpoints were unreachable. **What to do:**
+Claude Code sends the check through the same [proxy configuration](</docs/en/network-config>) as API requests and gives each probe 10 seconds. When the failed probe went through a proxy, the message names the environment variable that configured it, such as `HTTPS_PROXY`. Before v2.1.222, the check used a different proxy transport with no timeout: behind a proxy URL with the `https://` scheme, it could stall on `Checking connectivity...` indefinitely and then fail even though API requests through the same proxy succeed. Claude Code skips this check when a [managed settings file, MDM policy, or policy helper](</docs/en/managed-settings>) sets [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"`, or sets [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>) without `forceLoginMethod`. With either configuration, Claude Code opens the sign-in step on the **Cloud gateway** screen rather than an Anthropic sign-in method. Claude Code also skips the check when a managed settings source on the machine exists but can’t be read, since that source may hold the gateway configuration. Before v2.1.247, Claude Code ran the check under this configuration too, and exited with this error when Anthropic’s endpoints were unreachable. Claude Code also skips the check on a machine with no managed settings when your own `~/.claude/settings.json` [names a gateway](</docs/en/claude-apps-gateway#set-the-gateway-url-in-user-settings>) with `forceLoginMethod` and `forceLoginGatewayUrl`. Before v2.1.295, Claude Code ran the check in that case. **What to do:**
* If the message names a proxy variable, check that its value points at the right proxy and ask your network team to allow HTTPS connections through it to the host in the message. See [Network configuration](</docs/en/network-config>).
* Work through the checks in Unable to connect to API. The `curl` test and firewall guidance there apply to this check too.
@@ -3272,7 +3275,7 @@
No conversation found with session ID: <session-id>
-Claude Code exits with code 1 after showing the message. Claude Code [searches the current project first, then every other project on this machine](</docs/en/sessions#resume-a-session>) for the ID. Before v2.1.223, the lookup stopped at the current project directory and its git worktrees, so resume from the directory the session last worked in. Common causes:
+Claude Code exits with code 1 after showing the message. Claude Code [searches the current project first, then every other project on this machine](</docs/en/sessions#where-the-session-picker-looks>) for the ID. Before v2.1.223, the lookup stopped at the current project directory and its git worktrees, so resume from the directory the session last worked in. Common causes:
* **Mistyped ID** : for a non-interactive run, the ID is the `session_id` field of the [`--output-format json` output](</docs/en/headless#get-structured-output>)
* **Deleted transcript** : Claude Code removes transcripts after the [retention period](</docs/en/sessions#where-transcripts-are-stored>), 30 days by default, following the [retention sweep rules](</docs/en/claude-directory#cleaned-up-automatically>)
@@ -4040,6 +4043,23 @@
+File is not valid UTF-8
+
+Claude used the Edit or NotebookEdit tool on a file whose bytes don’t decode as UTF-8, and Claude Code refused the change. Nothing was written, so the file is as it was. Those tools save the whole file back as UTF-8, which would have turned every byte they couldn’t decode into the replacement character `U+FFFD`. The message appears in the tool result:
+
+ File is not valid UTF-8. It may use a legacy encoding such as Windows-1252, Shift-JIS or GBK, or be binary. This tool saves the whole file as UTF-8, which would replace every byte it cannot decode with U+FFFD. Nothing was written. Make the change with a shell command that reads and writes the file in its own encoding, or ask the user whether to convert the file to UTF-8 first.
+
+A file that is meant to be UTF-8 gets this message too when it contains even one invalid byte sequence, because the check covers the file’s bytes as a whole. **What to do:**
+
+ * To keep the file in its current encoding, let Claude make the change with a shell command that reads and writes the file in that encoding, as the message tells it to
+ * To keep editing the file with the Edit tool, convert it to UTF-8, or fix the invalid bytes in a file that is meant to be UTF-8, then ask Claude to make the edit again
+
+Before v2.1.296, Edit and NotebookEdit applied such an edit and saved every byte they couldn’t decode as `U+FFFD`. On those versions, update Claude Code.
+
+###
+
+
+
The source file is not valid UTF-8 text
Claude tried to publish an [artifact](</docs/en/artifacts>) from a file whose bytes don’t decode as text, or whose text already contains the replacement character `U+FFFD`, so Claude Code refused the publish before uploading anything. The message appears in the Artifact tool result and names the first position to fix:
@@ -4718,7 +4738,7 @@
Paths that Claude Code refuses this way include:
* UNC shares such as `\\server\share`
- * Automount paths such as `/net/<host>`, unless you launched Claude Code from a directory under that host’s automount
+ * Automount paths such as `/net/<host>`, unless you launched Claude Code from a directory under that host’s automount. Reads under that automount still go through the [network path check](</docs/en/permissions#network-paths>).
* Local paths that reach a network location through a symbolic link or junction
Mapped drive letters and `\\wsl$` paths don’t count as network paths. **What to do:**
Show diff (183 lines)
--- a/errors.md
+++ b/errors.md
@@ -179,9 +179,9 @@
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Details: `[reasoning_extraction]``| Request errors
`API Error: Output blocked by content filtering policy`| Request errors
-`Installation was killed before it could finish (exit code 137)`| Installation errors
-`The connection dropped while downloading the update`| Installation errors
-`Download timed out: exceeded the total deadline`| Installation errors
+`Installation was killed before it could finish (exit code 137)`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#installation-was-killed-before-it-could-finish>)
+`The connection dropped while downloading the update`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
+`Download timed out: exceeded the total deadline`| [Troubleshoot installation and login](</docs/en/troubleshoot-install#the-connection-dropped-while-downloading-the-update>)
`--bg and --print conflict`| Command-line errors
`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
@@ -237,6 +237,7 @@
`Windows reported an error (EBADF) when Claude Code read this session's transcript file`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
+`Claude Code couldn't restart`| Command-line errors
`Couldn't open Claude Desktop`| Command-line errors
`Failed to open Claude Desktop. Please try opening it manually.`| Command-line errors
`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
@@ -251,6 +252,7 @@
`Marketplace name impersonates an official Anthropic/Claude marketplace`| Plugin errors
`Marketplace "<name>" is already added from a different source`| Plugin errors
`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
+`Cannot add marketplace "<name>": Claude Code cannot install plugins from a marketplace with this name`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#cannot-install-plugins-from-a-marketplace-with-this-name>)
`Marketplace "<name>" is added but ignored`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`Marketplace "<name>" is registered but was refused (see the debug log)`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`references ${user_config.*} in a shell-form command`| Plugin errors
@@ -259,6 +261,7 @@
`Plugin archive integrity check failed`| Plugin errors
`An npm plugin source must name a registry package`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#an-npm-plugin-source-must-name-a-registry-package>)
`The packages it lists are not installed` / `The packages it lists were not installed, because`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#the-packages-it-lists-are-not-installed>)
+`does not load (...), so Claude Code ignores the whole file`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#does-not-load-so-claude-code-ignores-the-whole-file>)
`path escapes plugin directory`| Plugin errors
`path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
@@ -269,6 +272,7 @@
`"<plugin>" was not uninstalled: it is still switched on in <file>`| Plugin errors
`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
+`Plugin directory does not exist: <path>`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#plugin-directory-does-not-exist>)
`Error: No such tool available: <tool name>`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
@@ -321,6 +325,7 @@
`Session isn't responding` / `Press enter again to restart this session — it isn't responding`| Background session errors
`Session <id> was stopped while the respawn was in flight`| Background session errors
`This session was running agent '<name>', which is no longer available`| Background session errors
+`This session restarted <time> after its next /loop wakeup was due, so that wakeup will not fire`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`EACCES: permission denied, posix_spawn`| Background session errors
@@ -422,6 +427,7 @@
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
+[`CLAUDE_CODE_RETRY_WATCHDOG_MAX_WAIT_MS`](</docs/en/env-vars>)| unset| Maximum time in milliseconds that each API request spends waiting out `429` and `529` errors when `CLAUDE_CODE_RETRY_WATCHDOG` is set. When unset, the wait has no limit. Requires Claude Code v2.1.295 or later.
[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
@@ -2517,47 +2523,6 @@
-Installation errors
-
-These errors appear while installing or updating Claude Code, from the [install script](</docs/en/setup#install-claude-code>), `claude install`, or `claude update`. For `command not found`, PATH, permission, and TLS problems during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>).
-
-###
-
-
-
-Installation was killed before it could finish
-
-The install script reports when the `claude install` step is terminated by a signal. On Linux, exit code 137 means the process received SIGKILL, and on a low-memory host that’s usually the kernel out-of-memory (OOM) killer. The script prints this explanation and exits with code 137:
-
- Installation was killed before it could finish (exit code 137). This usually means the system ran out of memory.
- Claude Code needs roughly 512MB of free memory to install. Free up memory, then run this script again.
-
-For any other fatal signal, and for exit code 137 on macOS, the script prints `Installation was killed before it could finish (exit code <N>)` with the actual exit code and omits the out-of-memory explanation. The message comes from the install script macOS and Linux use, which also covers installs inside WSL; the native Windows install scripts never print it. Before v2.1.200, the script exited with only the shell’s bare `Killed` line. **What to do:**
-
- * Stop other processes to free memory, then rerun the installer
- * Add swap space or move to a larger instance. See [Install killed on low-memory Linux servers](</docs/en/troubleshoot-install#install-killed-on-low-memory-linux-servers>) for the swap-file commands.
-
-###
-
-
-
-The connection dropped while downloading the update
-
-The connection to the download server closed while `claude install` or `claude update` was fetching the Claude Code binary, and the retries didn’t recover. Claude Code retries the download when the connection drops, the transfer stalls, or the downloaded file fails its checksum, up to three attempts in total. A completed HTTP error, such as a 404, isn’t retried because the server already answered. Before v2.1.202, a single dropped connection failed the download immediately with the bare error `aborted` instead of retrying.
-
- The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
-
-The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. A proxy or gateway can close a long transfer before it finishes, and the Claude Code binary is a large download. **What to do:**
-
- * Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run. For the timed-out message, run it again from a faster or less throttled network.
- * If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](</docs/en/troubleshoot-install#check-network-connectivity>).
- * If a corporate proxy keeps closing the transfer, ask your network team to allow the full download from `downloads.claude.ai`. See [Network access requirements](</docs/en/network-config#network-access-requirements>).
- * Run `claude doctor` from your shell for installation diagnostics
-
-##
-
-
-
Command-line errors
These errors come from the `claude` command line and its subcommands, from a command name you submit at the prompt, and from commands such as `/security-review` that gather context by running shell commands before their prompt runs. They also come from `/tui`, which relaunches the CLI.
@@ -3362,6 +3327,21 @@
**What to do:**
* In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings-reference#tui>) there
+
+###
+
+
+
+Claude Code couldn’t restart
+
+Claude Code was restarting, for example to switch to or from fullscreen rendering after you ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>). It closed the session but couldn’t start the new process, so it printed this message and exited with status 1:
+
+ Claude Code couldn't restart. Your conversation is saved. Start Claude Code again and run /resume to pick it up.
+
+When the restart had no conversation to reopen, for example because `/tui` was your first input in a new session, the message reads `Claude Code couldn't restart. Start Claude Code again.` **What to do:**
+
+ * Run `claude` again in your shell from the same directory. If the message said your conversation is saved, run [`/resume`](</docs/en/sessions#resume-a-session>) in the new session and select it
+ * If restarts keep failing, start Claude Code from your shell with [`claude --debug-file claude-debug.log`](</docs/en/cli-reference#cli-flags>). If a restart from that session fails, `claude-debug.log` in the directory you started from records a `Failed to relaunch:` line with the operating system’s error. Include that line when you report the problem
###
@@ -4206,19 +4186,19 @@
Command blocked by the worktree isolation checks
-Claude ran a Bash or Monitor command in a [session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), and Claude Code refused it for one of two reasons:
-
- * The command points git at the main checkout.
- * Claude Code can’t verify from the command text that any git the command runs stays inside the worktree. A command that never names git can still be refused for this reason, because expanding a variable indirection such as `${!name}` or running a Bash function substitution such as `${ command; }` produces a value at runtime that can itself be a command.
-
-The middle of the message names what couldn’t be verified:
+Claude ran a Bash, [PowerShell](</docs/en/tools-reference#powershell-tool>), or [Monitor](</docs/en/tools-reference#monitor-tool>) command in a [session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), and Claude Code refused it for one of these reasons:
+
+ * The command would run in the main checkout or in another worktree. The message says its working directory `resolved to the shared checkout` or `is in a different worktree`.
+ * A Bash or Monitor command points git at the main checkout.
+ * Claude Code can’t verify from a Bash or Monitor command’s text that any git the command runs stays inside the worktree. A command that never names git can still be refused for this reason, because expanding a variable indirection such as `${!name}` or running a Bash function substitution such as `${ command; }` produces a value at runtime that can itself be a command.
+
+The message says `is isolated in the worktree <path>, but this command`, followed by the reason, such as a command whose text Claude Code couldn’t verify:
This session is isolated in the worktree /path/to/worktree, but this command evaluates ${!x@P} arithmetically inside a construct too complex to verify, which can run a command hidden in a variable's value. Refusing to run it — a worktree-isolated session's git operations must target its own worktree. Split it into plain, separate commands and run them from /path/to/worktree.
**What to do:**
- * Usually nothing: Claude reads the message and rewrites the command the way its final sentence asks
- * If a command you asked for keeps being refused, spell the flagged value literally: replace the indirection or substitution with its value, and run git as its own plain command from inside the worktree
+ * **Git pointed at the main checkout, or command text that can’t be verified** : nothing. Claude reads the message and rewrites the command the way its final sentence asks. If a command you asked for keeps being refused over an expansion in its text, spell the flagged value literally and run git as its own plain command from inside the worktree
* To act on the main checkout on purpose, run the command yourself in a terminal outside the session
###
@@ -4365,6 +4345,21 @@
* Re-create the agent file at `.claude/agents/<name>.md` in the session’s project, or at `~/.claude/agents/<name>.md` for a personal agent, then resume again
* Or resume with `--agent <name>` naming an agent that does exist, to run the session as that agent instead
* If the agent is project-scoped and you haven’t trusted the session’s original directory, run Claude Code there once, accept the trust dialog, then resume again
+
+###
+
+
+
+This session restarted after its next /loop wakeup was due
+
+A [self-paced `/loop`](</docs/en/scheduled-tasks#let-claude-choose-the-interval>) in a [background session](</docs/en/agent-view>) has stopped. The session’s process ended while the loop was waiting for its next wakeup, and that wakeup came due before the session’s [next process](</docs/en/agent-view#the-supervisor-process>) started. The missed wakeup doesn’t fire late. The notice says how overdue the wakeup was when the session restarted:
+
+ This session restarted 12m after its next /loop wakeup was due, so that wakeup will not fire. The loop stays stopped until Claude schedules it again: reply to continue it.
+
+Before v2.1.295, the loop stopped in this situation without a notice. **What to do:**
+
+ * To continue the loop, [reply to the session](</docs/en/agent-view#peek-and-reply>) and say so, such as `keep the loop running`. Claude reads the notice with your reply and can schedule the next wakeup
+ * If you’re done with the loop, do nothing. It has already stopped
###
--- a/errors.md
+++ b/errors.md
@@ -376,7 +376,7 @@
* A server error or overloaded response that arrives after Claude has finished thinking but before it has started any text or tool call. Claude Code retries a server error at that point up to two times. Before v2.1.284, Claude Code ended the turn with the error at that point.
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
- * A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
+ * A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and streams the request again at most once. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
* A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. On other connections, the request waits out `API_TIMEOUT_MS`. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
* A streaming response that the API’s output content filter stops before Claude has either finished thinking or started any text or tool call. Claude Code re-sends the request once, within the retry budget, and shows Output blocked by content filtering policy if the filter stops the second response too.
* Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
@@ -422,6 +422,7 @@
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
+[`CLAUDE_CODE_OVERLOADED_RETRY_BASE_DELAY_MS`](</docs/en/env-vars>)| 500| Starting delay in milliseconds of the backoff between retries of a request that the API rejects with a `529` overloaded error. Raise it, up to 32000, to spread the retries over a longer window when the API is at capacity. Has no effect when `CLAUDE_CODE_RETRY_WATCHDOG` is set to `1`, or when the rejected request was sent in [fast mode](</docs/en/fast-mode#handle-rate-limits>). Requires Claude Code v2.1.292 or later.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
@@ -760,13 +761,13 @@
Your plan’s included usage can’t cover this request, and the [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) that would otherwise pay for it have reached a spend limit. That happens when one of your plan’s usage windows has run out, or when the request is one that only usage credits pay for, such as a request to a model that [bills to usage credits](</docs/en/model-config#fable-and-usage-credits>). The message names whose limit blocked you. The text after the `·` says how to get that limit increased, and varies with your plan and whether you manage billing:
- You've hit your monthly spend limit · raise it at claude.ai/settings/usage
+ You've hit your monthly spend limit · raise it at https://claude.ai/settings/usage?from=cc_cli_limit_message
You've hit your individual spend limit · ask your admin for a higher limit
- You've hit your org's monthly spend limit · visit claude.ai/admin-settings/usage to raise it
- You've hit your team's shared budget · ask your admin to raise it at claude.ai/admin-settings/usage
+ You've hit your org's monthly spend limit · visit https://claude.ai/admin-settings/usage to raise it
+ You've hit your team's shared budget · ask your admin to raise it at https://claude.ai/admin-settings/usage
You've hit your channel's monthly spend limit · an org owner or channel manager can raise it in the channel's Claude settings
-`team's shared budget` is a pooled budget an admin assigned to a group you belong to; the message doesn’t name the group. `channel's monthly spend limit` is the budget of the one Slack channel the session runs in, so your organization may still have budget outside it. When one of your plan’s windows is what ran out, the message also says when that window resets, for example `· your session limit resets 3:45pm`, and access returns then without anyone raising the limit. On organizations with usage-based billing, the message says `usage limit` in place of `spend limit`, as in `You've hit your individual usage limit`. Before v2.1.239, the message didn’t name the plan window’s reset time. Before v2.1.268, a group’s pooled budget produced the `individual spend limit` message instead of `team's shared budget`. If you connect through a Claude apps gateway and see lowercase `spend limit reached`, that is your gateway operator’s cap instead; see Spend limit reached. **What to do:**
+`team's shared budget` is a pooled budget an admin assigned to a group you belong to; the message doesn’t name the group. `channel's monthly spend limit` is the budget of the one Slack channel the session runs in, so your organization may still have budget outside it. When one of your plan’s windows is what ran out, the message also says when that window resets, for example `· your session limit resets 3:45pm`, and access returns then without anyone raising the limit. On organizations with usage-based billing, the message says `usage limit` in place of `spend limit`, as in `You've hit your individual usage limit`. If you connect through a Claude apps gateway and see lowercase `spend limit reached`, that is your gateway operator’s cap instead; see Spend limit reached. **What to do:**
* On Pro and Max, increase your monthly spend limit in [**Settings > Usage**](<https://claude.ai/settings/usage>) on claude.ai, or run `/usage-credits`
* On Team and Enterprise, increase the limit in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>) if you manage billing, or ask an admin to. `/usage-credits` sends that request to your admin for you
@@ -2472,7 +2473,7 @@
API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5 and Sonnet 5.5, the message opens with `<model>'s safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. This message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. Models with [automatic model fallback](</docs/en/model-config#automatic-model-fallback>) print a different message, without this link; on Opus 5.5 and Sonnet 5.5 it opens with `<model>'s safeguards flagged this session`. That section also covers when Claude Code switches models instead. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
@@ -3546,7 +3547,7 @@
Marketplace is already added from a different source
-You confirmed adding a marketplace through [`/plugin install <plugin> --marketplace <source>`](</docs/en/plugins/install#add-a-marketplace-and-install-in-one-command>), and the catalog Claude Code fetched from that source names itself the same as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
+You named a new marketplace source with [`--marketplace <source>` on the install command](</docs/en/plugins/install#add-a-marketplace-and-install-in-one-command>), in a session or from your shell. The catalog Claude Code fetched from that source has the same name as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
Marketplace "acme-tools" is already added from a different source (github:acme/plugins). To use this source instead, remove that marketplace first with /plugin marketplace remove acme-tools.
@@ -4226,14 +4227,13 @@
This session has no saved transcript
-You attached to a stopped [background session](</docs/en/agent-view>) that was backgrounded from another conversation with `←` or `/background` and stopped before its first response finished. Until that first response finishes, the conversation still lives only in the session it was backgrounded from, so `claude attach` refuses to start the stopped session rather than begin a blank conversation under the same session ID. The message ends with the `claude respawn` command for this session:
+You attached to a session that you [moved to the background](</docs/en/agent-view#from-inside-a-session>) with `←` or `/background` and that stopped before it ran a turn of its own. Claude Code couldn’t find the conversation you moved it from, so the session has nothing to resume. The message ends with the `claude respawn` command for this session:
This session has no saved transcript — it was stopped before its first response finished. If it was backgrounded from another conversation, that one is still intact; `claude respawn <id>` starts this one fresh.
-Opening the same session’s row in [agent view](</docs/en/agent-view>) shows `Press enter again to restart this session fresh` below the list instead, and a second `Enter` on the row restarts the session with an empty conversation. Before v2.1.212, opening the row showed the refusal message with no way to restart from agent view. Before v2.1.211, opening the stopped session silently started that blank conversation and could re-run the session’s original prompt. **What to do:**
-
- * The conversation you backgrounded from is intact: resume it with [`claude --resume`](</docs/en/sessions>) or keep working in it
- * To start the stopped session fresh anyway, run `claude respawn <id>` with the ID from the message, or press `Enter` twice on its row in agent view
+Opening the same session’s row in [agent view](</docs/en/agent-view>) shows `Press enter again to restart this session fresh` below the list instead, and a second `Enter` on the row restarts the session with an empty conversation. **What to do:**
+
+ * To start the stopped session fresh, run `claude respawn <id>` with the ID from the message, or press `Enter` twice on its row in agent view
* If the session did finish a response and you still see this refusal on a version before v2.1.214, an unreadable folder in `~/.claude/projects` could make the transcript scan miss the saved conversation; update to v2.1.214 or later, which tolerates unreadable folders during the scan
###
@@ -4250,7 +4250,7 @@
* **`running in another terminal`** : a terminal holds the conversation, for example one where you resumed it with `claude --resume` or `/resume`. The row also shows `Open in a terminal`.
* **`already open in another running Claude session`** : another non-interactive Claude Code process holds it, for example a [background session](</docs/en/agent-view#the-supervisor-process>) process for the same conversation that hasn’t exited yet.
-Claude Code saves a reply you typed when opening the row and sends it as the session’s next prompt when the session next starts. **What to do:**
+**What to do:**
* Continue the conversation in the process that has it open, or exit that process and open the row again
--- a/errors.md
+++ b/errors.md
@@ -120,7 +120,7 @@
`unable to get local issuer certificate`| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`proxy refused the connection`| Network
-`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
+`403` with `GitHub GraphQL is not available from Claude Code sessions` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
--- a/errors.md
+++ b/errors.md
@@ -187,6 +187,7 @@
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Cloud sessions are disabled by your organization's policy`| Command-line errors
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
+`Cloud sessions need a claude.ai sign-in`| [Unable to get organization UUID](</docs/en/claude-code-on-the-web#unable-to-get-organization-uuid>)
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Invalid --agents configuration:`| Command-line errors
`Error: --agents takes a JSON object, or a file path only with --print (-p)`| Command-line errors
@@ -377,6 +378,7 @@
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
* A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
* A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. On other connections, the request waits out `API_TIMEOUT_MS`. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
+ * A streaming response that the API’s output content filter stops before Claude has either finished thinking or started any text or tool call. Claude Code re-sends the request once, within the retry budget, and shows Output blocked by content filtering policy if the filter stops the second response too.
* Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
* When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
* A request rejected because the input plus `max_tokens` exceeds the context limit. Re-sending it unchanged would fail the same way, so Claude Code retries with a reduced `max_tokens`, and stops retrying and compacts instead in two cases:
@@ -393,7 +395,6 @@
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
* A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
- * A response the API’s output content filter blocked. Claude Code shows Output blocked by content filtering policy at once and doesn’t retry or re-send that request.
###
@@ -1502,7 +1503,7 @@
Could not load AWS or Google Cloud credentials
-Claude Code couldn’t obtain usable credentials from the AWS credential provider chain or from your Google application default credentials on the machine it runs on, so no request reached your cloud provider. Claude Code clears its cached credentials and retries twice before showing this message. The detail after the `·` names the specific cause, such as an expired SSO session, missing application default credentials reported as `Could not load the default credentials`, or a revoked sign-in reported as `invalid_grant`:
+Claude Code couldn’t obtain usable credentials from the AWS credential provider chain or from your Google application default credentials on the machine it runs on, so no request reached your cloud provider. The detail after the `·` names the specific cause, such as an expired SSO session, missing application default credentials reported as `Could not load the default credentials`, or a revoked sign-in reported as `invalid_grant`:
API Error: Could not load AWS credentials · Could not load credentials from any providers. Check or refresh your AWS credentials and try again.
API Error: Could not load Google Cloud credentials · invalid_grant. Check or refresh your Google Cloud credentials and try again.
@@ -1986,7 +1987,7 @@
Claude Code replaces the unprocessable image with a text placeholder and retries, so subsequent messages succeed. On versions before 2.1.142, a pasted image could remain in the conversation and repeat the same error on every subsequent message. To recover on those versions, press Esc twice and step back past the turn where the image was added. **What to do:**
- * Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 2000 pixels when many images are in context.
+ * Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 3000 pixels when more than 20 images are in context.
* Take a tighter screenshot of the relevant region instead of the full screen
###
@@ -2506,7 +2507,7 @@
API Error: Output blocked by content filtering policy
-Claude Code shows the error as soon as the block arrives and ends the request there. It doesn’t retry the request, re-send it without streaming, or switch to a [fallback model](</docs/en/model-config#fallback-model-chains>). Before v2.1.285, Claude Code could re-send and retry a blocked request, sometimes for minutes, before showing you the error. **What to do:**
+**What to do:**
* Rephrase your last message or take a different approach
* To step back to a checkpoint before the turn that triggered the block, press Esc twice or run `/rewind`. See [Checkpointing](</docs/en/checkpointing>)
--- a/errors.md
+++ b/errors.md
@@ -177,6 +177,7 @@
`<model>'s safeguards flagged this message`| Request errors
`<model>'s safeguards flagged this session`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
+`Details: `[reasoning_extraction]``| Request errors
`API Error: Output blocked by content filtering policy`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
@@ -767,7 +768,7 @@
`team's shared budget` is a pooled budget an admin assigned to a group you belong to; the message doesn’t name the group. `channel's monthly spend limit` is the budget of the one Slack channel the session runs in, so your organization may still have budget outside it. When one of your plan’s windows is what ran out, the message also says when that window resets, for example `· your session limit resets 3:45pm`, and access returns then without anyone raising the limit. On organizations with usage-based billing, the message says `usage limit` in place of `spend limit`, as in `You've hit your individual usage limit`. Before v2.1.239, the message didn’t name the plan window’s reset time. Before v2.1.268, a group’s pooled budget produced the `individual spend limit` message instead of `team's shared budget`. If you connect through a Claude apps gateway and see lowercase `spend limit reached`, that is your gateway operator’s cap instead; see Spend limit reached. **What to do:**
* On Pro and Max, increase your monthly spend limit in [**Settings > Usage**](<https://claude.ai/settings/usage>) on claude.ai, or run `/usage-credits`
- * On Team and Enterprise, increase the limit in [**Admin settings > Usage**](<https://claude.ai/admin-settings/usage>) if you manage billing, or ask an admin to. `/usage-credits` sends that request to your admin for you
+ * On Team and Enterprise, increase the limit in [**Organization settings > Usage**](<https://claude.ai/admin-settings/usage>) if you manage billing, or ask an admin to. `/usage-credits` sends that request to your admin for you
* For a channel’s limit, ask an org owner or the channel’s manager to raise it on claude.ai. See [Per-channel limits](<https://claude.com/docs/claude-tag/admins/set-spend-limit#per-channel-limits>) in the Claude Tag documentation
* If the message names a reset time for your plan’s window, you can wait for it instead
* Run `/usage` to see your plan’s windows and when each resets
@@ -2448,7 +2449,7 @@
Usage Policy refusal
-The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID and a Message ID you can quote to support if you believe the refusal is incorrect.
+The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. The message includes a Request ID and a Message ID you can quote to support if you believe the refusal is incorrect.
API Error: Opus 4.6 can't help with this. Start a new session to continue.
@@ -2470,11 +2471,30 @@
API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5 and Sonnet 5.5, the message opens with `<model>'s safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+If the message includes the line `Details: `[reasoning_extraction]``, see Safeguards flagged a request for Claude’s reasoning. The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5 and Sonnet 5.5, the message opens with `<model>'s safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
* To keep working in the same session, press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the flag, then take a different approach. See [Checkpointing](</docs/en/checkpointing>).
+
+###
+
+
+
+Safeguards flagged a request for Claude’s reasoning
+
+The API declined the request because safeguards flagged it as asking the model to reproduce its internal reasoning in the response. The API names this [refusal category](<https://platform.claude.com/docs/en/build-with-claude/refusals-and-fallback#refusal-response>) `reasoning_extraction`, and the refusal message includes this line:
+
+ Details: `[reasoning_extraction]`
+
+Before v2.1.234, refusal messages didn’t include the `Details` line. **What to do:**
+
+ * Remove or reword any instruction that asks Claude to write out its thinking or reasoning verbatim or in a fixed format, such as a `<thinking>` section, a scratchpad section, or a `reasoning` field in JSON output. The instruction can be in your prompt or in a customization that Claude Code loads with it, such as CLAUDE.md, a skill, a subagent prompt, an output style, or an MCP tool description.
+ * To check whether a customization is the trigger, run [`claude --safe-mode`](</docs/en/cli-reference#cli-flags>) in your terminal to start a session with customizations disabled, then send the same prompt
+ * After you change a customization, start a new session
+ * To reword a prompt you already sent, see [Rewind and summarize](</docs/en/checkpointing#rewind-and-summarize>)
+ * You can still ask Claude to explain its answer. Ask for a short explanation, the evidence behind a result, or a summary of the actions it took. To read summaries of Claude’s thinking, see [`showThinkingSummaries`](</docs/en/settings-reference#showthinkingsummaries>).
+ * For more examples, and what to do if a reworded request is still declined, see [Keep reasoning in thinking blocks](<https://platform.claude.com/docs/en/build-with-claude/refusals-and-fallback#keep-reasoning-in-thinking-blocks>)
###
--- a/errors.md
+++ b/errors.md
@@ -356,6 +356,7 @@
`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
`... has a wildcard before the rest of the command`| Configuration warnings
+`Denying Bash also turns off the PowerShell tool, so Claude has neither`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
`[claude-code:unrecognized_model]`| Configuration warnings
`Stale sandbox mask files left by a killed session`| Configuration warnings
@@ -4944,6 +4945,23 @@
+Denying Bash also turns off the PowerShell tool
+
+You removed the whole Bash tool, for example with `--disallowedTools Bash` or with a bare `Bash` or `Bash(*)` [deny rule](</docs/en/permissions#match-all-uses-of-a-tool>) in one of your settings files. On Windows with Git Bash installed, [denying Bash also turns the PowerShell tool off](</docs/en/tools-reference#bash-deny-rules-also-turn-off-the-powershell-tool>), so the session starts with no shell tool. Claude Code prints this warning at startup:
+
+ Denying Bash also turns off the PowerShell tool, so Claude has neither. To use PowerShell, set CLAUDE_CODE_USE_POWERSHELL_TOOL=1.
+
+**What to do:**
+
+ * To have Claude use PowerShell, set [`CLAUDE_CODE_USE_POWERSHELL_TOOL`](</docs/en/env-vars>) to `1` in your environment or in the `env` block of a settings file, as [Enable the PowerShell tool](</docs/en/tools-reference#enable-the-powershell-tool>) shows. The PowerShell tool then stays on alongside your Bash deny rule.
+ * To block particular commands instead of the whole tool, replace the bare `Bash` entry with scoped rules such as `Bash(git push *)` in the same settings file or flag. Claude keeps the Bash tool, and the PowerShell tool stays off until you also set the variable or add a scoped [`PowerShell` permission rule](</docs/en/permissions#powershell>).
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.287, Claude Code turned the PowerShell tool off the same way without printing a warning.
+
+###
+
+
+
crossSessionInbound must be one of accept, hold, refuse
A settings file sets [`crossSessionInbound`](</docs/en/settings-reference#crosssessioninbound>) to a value Claude Code doesn’t recognize, such as the typo `"reject"`. The warning’s second sentence depends on which file holds the value; in a user, project, local, or `--settings` file it reads:
--- a/errors.md
+++ b/errors.md
@@ -177,6 +177,7 @@
`<model>'s safeguards flagged this message`| Request errors
`<model>'s safeguards flagged this session`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
+`API Error: Output blocked by content filtering policy`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
`Download timed out: exceeded the total deadline`| Installation errors
@@ -390,6 +391,7 @@
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
* A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
+ * A response the API’s output content filter blocked. Claude Code shows Output blocked by content filtering policy at once and doesn’t retry or re-send that request.
###
@@ -418,6 +420,7 @@
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
+[`CLAUDE_CODE_NONSTREAMING_TIMEOUT_RETRIES`](</docs/en/env-vars>)| unset| Limit on re-sends of a non-streaming request that times out. At the limit, the request fails. A response from Claude that takes longer than the timeout to generate times out again on every re-send, so set a low number such as `0` to fail sooner. Each non-streaming attempt times out after 300 seconds in a local session, or after `API_TIMEOUT_MS` when you set a positive value. Requires Claude Code v2.1.285 or later.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
##
@@ -1749,7 +1752,7 @@
You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
* Open your environment for editing, either from the [routine’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
- * In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * In the **Edit environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -2200,6 +2203,7 @@
The binary the [VS Code extension](</docs/en/vs-code>) bundles| Update the extension
The binary an Agent SDK package bundles| [Upgrade the SDK package](</docs/en/agent-sdk/hosting#runtime-dependencies>), then restart your application. In a [compiled single-file executable](</docs/en/agent-sdk/typescript#compile-to-a-single-executable>), rebuild it
+ * If you run `claude update` on the [stable release channel](</docs/en/setup#configure-release-channel>), it doesn’t move you past the newest stable release, which can still be below the required minimum. Move to the latest channel, then update again. If your organization pins your channel or version through [managed settings](</docs/en/managed-settings>), ask your admin to change it
* For the per-model wording, you can keep working in the current session by switching to another model: run `/model` in the CLI, call [`setModel()`](</docs/en/agent-sdk/typescript#query-object>) on the TypeScript SDK’s `Query` object in streaming input mode, or call [`set_model()`](</docs/en/agent-sdk/python#claudesdkclient>) on the Python SDK’s `ClaudeSDKClient`
* For the organization-policy wording, update before you continue
@@ -2316,6 +2320,7 @@
**What to do:**
* Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later. Opus 5.5 needs v2.1.280 or later. Sonnet 5.5 needs v2.1.284 or later
+ * On the [stable release channel](</docs/en/setup#configure-release-channel>), updating doesn’t move you past the newest stable release, which can still be older than these versions. Move to the latest channel, then update
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
* If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later. Sonnet 5.5 needs TypeScript SDK v0.3.284 or later
@@ -2470,6 +2475,21 @@
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
* To keep working in the same session, press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the flag, then take a different approach. See [Checkpointing](</docs/en/checkpointing>).
+###
+
+
+
+Output blocked by content filtering policy
+
+The API’s output content filter stopped the response Claude was generating. The message text comes from the API:
+
+ API Error: Output blocked by content filtering policy
+
+Claude Code shows the error as soon as the block arrives and ends the request there. It doesn’t retry the request, re-send it without streaming, or switch to a [fallback model](</docs/en/model-config#fallback-model-chains>). Before v2.1.285, Claude Code could re-send and retry a blocked request, sometimes for minutes, before showing you the error. **What to do:**
+
+ * Rephrase your last message or take a different approach
+ * To step back to a checkpoint before the turn that triggered the block, press Esc twice or run `/rewind`. See [Checkpointing](</docs/en/checkpointing>)
+
##
@@ -3849,7 +3869,7 @@
Teammate’s agent definition was not restored
-Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from, because its definition file came from a folder with no saved trust. The notice follows the resume report in the sending agent’s tool result:
+Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from. The notice follows the resume report in the sending agent’s tool result and names the reason. When the definition file came from a folder with no saved trust, it reads:
Its agent definition was not restored: the folder its definition file came from is not trusted (source: projectSettings), so the teammate is running with the team-essential tools and no custom instructions. To restore it, the user needs to run Claude Code in that folder once and accept the trust dialog (the --debug log names the folder); do not change trust settings on the user's behalf.
@@ -3898,7 +3918,7 @@
Cross-session message was dropped at the recipient session’s inbox
-Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient’s address and, when the recipient gave a reason, adds the reason after a dash:
+Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient and, when the recipient gave a reason, adds the reason after a dash:
Cross-session message was dropped at the recipient session's inbox (recipient: uds:/tmp/cc-socks/13605.sock) and not delivered — its queue of undelivered peer messages was full. Claude was told not to resend right away.
Show diff (497 lines)
--- a/errors.md
+++ b/errors.md
@@ -65,7 +65,11 @@
`Remote Control stopped — the app running this session is now signed in to a different Claude account`| Authentication
`Remote Control stopped — the app running this session is signed out of Claude`| Authentication
`Couldn't verify your organization's policy for remote control`| [Troubleshoot Remote Control](</docs/en/remote-control#couldnt-verify-your-organizations-policy-for-remote-control>)
+`Remote Control is disabled by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-is-disabled-by-your-organizations-policy>)
+`Remote Control was turned off by your organization's policy`| [Troubleshoot Remote Control](</docs/en/remote-control#remote-control-was-turned-off-by-your-organizations-policy>)
`OAuth token revoked` / `OAuth token has expired`| Authentication
+`Failed to authenticate: OAuth token revoked`| Authentication
+`Your account does not have access to Claude. Please login again or contact your administrator.`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Failed to start OAuth callback server`| Authentication
@@ -154,6 +158,7 @@
`Can't switch to the default model`| Request errors
`Model switch ... blocked by a PreModelSwitch hook`| Request errors
`couldn't save it as your default` / `couldn't confirm it was saved as your default`| Request errors
+`is less capable than the current main model` / `Advisor will not activate on the main model` / `cannot advise`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
`effort '<level>' is not supported when thinking is disabled`| Request errors
@@ -176,6 +181,7 @@
`The connection dropped while downloading the update`| Installation errors
`Download timed out: exceeded the total deadline`| Installation errors
`--bg and --print conflict`| Command-line errors
+`Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.`| Command-line errors
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Cloud sessions are disabled by your organization's policy`| Command-line errors
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
@@ -193,6 +199,7 @@
`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`Cannot add MCP server to scope: managed`| Command-line errors
+`Cannot add MCP server: your organization's managed settings allow only MCP servers that plugins provide`| Command-line errors
`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
`Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes`| Command-line errors
`MCP server "<name>" was not saved to` / `was not removed from`| Command-line errors
@@ -205,6 +212,7 @@
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
+`Claude Code can't read the keyboard here: stdin is not a terminal`| Command-line errors
`Error: Input contained only whitespace`| Command-line errors
`Blank prompt — the message was only whitespace, so nothing was sent to the model.`| Command-line errors
`Error: stream-json input carried over 256M characters with no newline`| Command-line errors
@@ -217,6 +225,9 @@
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
`Not uploading this working tree` with `the upload cannot follow that setting`| Command-line errors
`GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud`| Command-line errors
+`Your GitHub organization has an IP allowlist that is blocking Claude`| Command-line errors
+`Your GitHub organization requires single sign-on`| Command-line errors
+`Your GitHub organization's identity provider (Microsoft Entra ID) has a Conditional Access policy that is blocking Claude`| Command-line errors
`Single sign-on authorization needed`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
@@ -230,16 +241,21 @@
`Skill usage reports are not available on this connection.`| Command-line errors
`Custom output styles can't be selected over Remote Control or from a relayed message`| Command-line errors
`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
+`/recap only runs when you ask for it yourself in this session`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Claude Code refuses the marketplace name "<name>"`| Plugin errors
`Marketplace name impersonates an official Anthropic/Claude marketplace`| Plugin errors
`Marketplace "<name>" is already added from a different source`| Plugin errors
`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
+`Marketplace "<name>" is added but ignored`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
+`Marketplace "<name>" is registered but was refused (see the debug log)`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#marketplace-is-added-but-ignored>)
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`Plugin archive integrity check failed`| Plugin errors
+`An npm plugin source must name a registry package`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#an-npm-plugin-source-must-name-a-registry-package>)
+`The packages it lists are not installed` / `The packages it lists were not installed, because`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#the-packages-it-lists-are-not-installed>)
`path escapes plugin directory`| Plugin errors
`path could not be checked`| Plugin errors
`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
@@ -250,6 +266,7 @@
`"<plugin>" was not uninstalled: it is still switched on in <file>`| Plugin errors
`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
+`Error: No such tool available: <tool name>`| Tool errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
@@ -277,9 +294,13 @@
`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
+`Not published: that file is on a network share`| Tool errors
`Reading a local file from outside this session's connected folders, or through a link, needs the approval card`| Tool errors
`cannot read file_path (...) — the file could not be examined, and no one can answer the approval card`| Tool errors
`WebFetch cannot fetch localhost or other hostnames without a dot`| Tool errors
+`The safety check for domain ... is rate-limited`| Tool errors
+`The safety check for domain ... is temporarily rate-limited`| Tool errors
+`Unable to verify if domain ... is safe to fetch`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -329,6 +350,7 @@
`Unable to read managed policy settings`| Configuration warnings
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
+`API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
@@ -347,6 +369,7 @@
Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure. Claude Code retries these failures:
* Server errors, overloaded responses, and request timeouts that arrive before any of Claude’s response has streamed.
+ * A server error or overloaded response that arrives after Claude has finished thinking but before it has started any text or tool call. Claude Code retries a server error at that point up to two times. Before v2.1.284, Claude Code ended the turn with the error at that point.
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
* A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
@@ -642,7 +665,7 @@
You've hit your Opus limit · resets 3:45pm
You've hit your Sonnet limit · resets 3:45pm
-Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus and Sonnet limits each apply only to requests to that model family, so switching to a model outside the family with `/model` keeps you working. In an interactive session signed in with a claude.ai subscription, Claude Code can also wait in the open session and continue the interrupted task shortly after the reset. While it waits, a line at the bottom of the session reads `Usage limit reached · continuing automatically at 3:45pm · esc to cancel`. Press `Esc` at an empty prompt to cancel the wait. See [Wait for a usage limit to reset](</docs/en/interactive-mode#wait-for-a-usage-limit-to-reset>) for what you see, how to start or cancel a wait, and how to turn automatic continue off. Before v2.1.234, Claude Code didn’t offer this wait. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
+Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus and Sonnet limits each apply only to requests to that model family, so switching to a model outside the family with `/model` keeps you working. In an interactive session signed in with a claude.ai subscription, Claude Code can also wait in the open session and continue the interrupted task shortly after the reset. See [Wait for a usage limit to reset](</docs/en/interactive-mode#wait-for-a-usage-limit-to-reset>) for what you see, how to start or cancel a wait, and how to turn automatic continue off. Before v2.1.234, Claude Code didn’t offer this wait. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
* Wait for the reset time shown in the error
* In the Code tab of the [Desktop app](</docs/en/desktop>), the session-limit card offers an **Auto-continue when limits reset** checkbox. The weekly-limit card doesn’t. When it’s checked, the Desktop app retries the interrupted turn after the reset and shows the retry time on the card. The Desktop checkbox and the CLI’s **Continue automatically at usage limit** setting in `/config` are separate, so turn each off on its own.
@@ -812,7 +835,7 @@
Not logged in · Please run /login
-In a session the Claude Desktop app runs, such as the Code tab or Cowork, the message reads `Authentication required · Sign in again to continue`, and you sign in again from the app. **What to do:**
+In a session the Claude Desktop app runs, such as the Code tab or Cowork, the message reads `Authentication required · Sign in again to continue`, and you sign in again from the app. If you sign in with your claude.ai account in another Claude Code window that uses the same [configuration directory](</docs/en/claude-directory>), an interactive session showing this message starts using that login on its own. You don’t need to restart it. Before v2.1.286 on macOS, the session could keep showing the message after you signed in from another window. On those versions, restart the session that shows the message. **What to do:**
* Run `/login` to authenticate with your Claude subscription or Console account
* If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
@@ -1078,9 +1101,15 @@
OAuth token revoked · Please run /login
Please run /login · API Error: 401 OAuth token has expired ...
-**What to do:**
-
- * Run `/login` to sign in again
+In [non-interactive mode](</docs/en/headless>) (`-p`) and the [Agent SDK](</docs/en/agent-sdk/overview>), the messages read as follows, and the structured error code is `authentication_failed`:
+
+ Failed to authenticate: OAuth token revoked. Please log in again or contact your administrator.
+ Failed to authenticate. API Error: 401 OAuth token has expired ...
+
+Before v2.1.287, in non-interactive mode and the Agent SDK, the revoked message read `Your account does not have access to Claude. Please login again or contact your administrator.` **What to do:**
+
+ * Run `/login` at the Claude Code prompt to sign in again
+ * If your `-p` command or Agent SDK program uses a saved login, run `claude` in the same environment, complete `/login`, then run the command or program again. For automation that can’t sign in interactively, authenticate with [`ANTHROPIC_API_KEY`](</docs/en/env-vars>) or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If you authenticate with the `CLAUDE_CODE_OAUTH_TOKEN` environment variable, Claude Code keeps sending the value you set after a request fails with a 401, rather than switching to a stored login’s token. [`/status`](</docs/en/commands>) shows this credential as an `Auth token` row reading `CLAUDE_CODE_OAUTH_TOKEN`. Generate a fresh token with [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) and restart with it, or unset the variable and run `/login`. Before v2.1.225, Claude Code could replace the variable’s value mid-session with the short-lived access token from a stored login, and the session failed with 401 errors again once that token expired.
* For repeated prompts to log in across launches, see the system clock checks and macOS credential-storage recovery steps in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
@@ -1119,6 +1148,7 @@
This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
+ * If you sign in with your claude.ai account in another Claude Code window, see Not logged in for when this session starts using that login on its own.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
@@ -1216,19 +1246,19 @@
Not signed in to the Cloud gateway — run /login.
-Model requests fail with this message when the session has no gateway sign-in, for example because you haven’t run `/login` since the policy reached the machine. If the machine also holds an Anthropic-issued credential and the managed settings set `forceLoginMethod` or `forceLoginOrgUUID`, Claude Code exits at startup instead. That credential can be an `ANTHROPIC_API_KEY` or `ANTHROPIC_AUTH_TOKEN` variable, an `apiKeyHelper` setting, or an API key saved by an earlier Claude Console login. The message begins:
-
- Administrator policy requires a Cloud gateway sign-in on this machine; the
- Anthropic-issued credential configured here (ANTHROPIC_API_KEY,
- ANTHROPIC_AUTH_TOKEN, or apiKeyHelper) is not used.
-
-**What to do:**
-
- * Run `/login` and complete the sign-in on the **Cloud gateway** screen
- * For the startup message, remove the `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` setting you configured. To remove a saved Console API key, run `claude auth logout`, which also removes a saved claude.ai login. If you select a cloud provider with `CLAUDE_CODE_USE_*`, the session then starts with no sign-in. Otherwise start `claude` and run `/login`
+Model requests fail with this message when the session has no gateway sign-in, for example because you haven’t run `/login` since the policy reached the machine. If the machine also holds an Anthropic-issued credential and the managed settings set `forceLoginMethod` or `forceLoginOrgUUID`, Claude Code exits at startup instead. That credential can be an `ANTHROPIC_API_KEY` or `ANTHROPIC_AUTH_TOKEN` variable, an `apiKeyHelper` setting, or an API key saved by an earlier Claude Console login. The startup message names the credential the session is configured with, where it’s set, and the step that removes it. For example, with an `ANTHROPIC_API_KEY` variable set in your shell, it reads:
+
+ Administrator policy requires a Cloud gateway sign-in on this machine, but this session is configured with an API key from ANTHROPIC_API_KEY, which a gateway machine does not accept.
+
+ To continue: unset ANTHROPIC_API_KEY (or run in a shell without it), then run claude and sign in with /login.
+
+**What to do:**
+
+ * For `Not signed in to the Cloud gateway`, run `/login` and complete the sign-in on the **Cloud gateway** screen
+ * For the startup message, remove the credential by following the steps at the end of the message
* If you believe the machine shouldn’t require the gateway, ask the administrator who manages it to remove `forceLoginMethod` and `forceLoginGatewayUrl` from its managed settings
-On v2.1.265, a regression also showed the first message in some LLM-gateway and proxy configurations that authenticate with an API key, `apiKeyHelper`, or custom headers, even with no administrator requirement on the machine. Update to v2.1.266 or later. You don’t need to change your configuration. Before v2.1.261, on machines that set `forceLoginMethod` to `"gateway"`, Claude Code used a leftover saved login instead of failing model requests, and reported a configured environment credential with `This machine's managed settings require a first-party login` instead of the startup message. Before v2.1.265, a machine whose managed settings set only `forceLoginGatewayUrl` didn’t require the gateway sign-in, and Claude Code used a leftover credential there.
+Before v2.1.284, the startup message listed the possible credentials instead of naming the configured one. It began `Administrator policy requires a Cloud gateway sign-in on this machine; the Anthropic-issued credential configured here (ANTHROPIC_API_KEY, ANTHROPIC_AUTH_TOKEN, or apiKeyHelper) is not used.` If you see that wording and can’t tell which credential to remove, update to v2.1.284 or later and start `claude` again. On v2.1.265, a regression also showed the first message in some LLM-gateway and proxy configurations that authenticate with an API key, `apiKeyHelper`, or custom headers, even with no administrator requirement on the machine. Update to v2.1.266 or later. You don’t need to change your configuration. Before v2.1.261, on machines that set `forceLoginMethod` to `"gateway"`, Claude Code used a leftover saved login instead of failing model requests, and reported a configured environment credential with `This machine's managed settings require a first-party login` instead of the startup message.
###
@@ -1718,8 +1748,8 @@
You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
- * Open the routine for editing, or start a cloud session. Select the cloud icon showing your environment’s name, such as **Default** , to open the selector. Hover over your environment and click the settings icon.
- * In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * Open your environment for editing, either from the [routine’s form](</docs/en/routines#environments-and-network-access>) or from the [environment selector](</docs/en/cloud-environments#configure-your-environment>) where you start cloud sessions.
+ * In the **Edit cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -2009,7 +2039,7 @@
API Error: 400 ... Extra inputs are not permitted ... context_management
-Claude Code sends beta-only fields such as `context_management` and `effort` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
+Claude Code sends beta-only fields such as `context_management` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
* Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers the exact scope.
@@ -2041,7 +2071,7 @@
API Error: 400 ... tool_use.name: String should have at most 200 characters
-Claude Code cuts such a name to 200 characters when the response arrives and when it loads a saved conversation, so the call fails with an ordinary `No such tool available` tool error and the conversation continues without this API error. **What to do:**
+Claude Code cuts such a name to 200 characters when the response arrives and when it loads a saved conversation, so the call fails with a `No such tool available` tool error and the conversation continues without this API error. **What to do:**
* Run `claude update`, then resume the conversation. The updated version repairs the overlong name when it loads the transcript, so a conversation that was stuck works again.
@@ -2254,6 +2284,29 @@
+Advisor is less capable than the current main model
+
+Your [advisor model](</docs/en/advisor>) ranks below your session’s main model, so Claude Code keeps the selection but doesn’t attach the advisor to the main model’s requests.
+
+ Advisor set to Opus 4.8
+ Note: Opus 4.8 is less capable than the current main model (Sonnet 5.5), so the advisor will not activate. Choose a more capable advisor, or switch to a smaller main model.
+
+Other messages report the same condition:
+
+ * In an interactive session, a notification reads `Advisor will not activate on the main model (advisor is less capable); subagents may still use it and may use more tokens · /advisor`.
+ * At launch with the `--advisor` flag, a warning reads `"<advisor>" cannot advise "<main model>" (the advisor must be at least as capable as the main model). The advisor will not be used for the main model.` and the session starts anyway.
+
+**What to do:**
+
+ * Choose a higher-ranked advisor or a lower-ranked main model. [Choose an advisor model](</docs/en/advisor#choose-an-advisor-model>) shows the ranking and lists the accepted advisors for each main model.
+ * Leave the advisor set if you want [subagents](</docs/en/sub-agents>) whose model it can advise to keep using it
+
+Before v2.1.287, Claude Code ranked several pairings differently. It showed this note for a Sonnet 5.5 advisor with an Opus 4.7 or Opus 4.8 main model, a pairing it now accepts. It also attached some advisors that now produce this note, such as an Opus 4.8 advisor with a Sonnet 5.5 main model.
+
+###
+
+
+
thinking.type.enabled is not supported for this model
Your Claude Code version is older than the minimum for the selected model. The CLI sent a thinking configuration the model no longer accepts.
@@ -2485,6 +2538,20 @@
+Conflict between a system prompt flag and its file form
+
+You passed [`--append-subagent-system-prompt`](</docs/en/cli-reference#cli-flags>) together with `--append-subagent-system-prompt-file` in one `claude` invocation, so `claude` exits with code 1 instead of starting the session:
+
+ Error: Cannot use both --append-subagent-system-prompt and --append-subagent-system-prompt-file. Please use only one.
+
+Before v2.1.283, `claude` exited the same way when you passed `--system-prompt` with `--system-prompt-file`, or `--append-system-prompt` with `--append-system-prompt-file`, because those pairs conflicted instead of [combining](</docs/en/cli-reference#system-prompt-flags>). On those versions the message names the pair you combined. **What to do:**
+
+ * Keep one form of the flag and drop the other. To combine a fixed prompt file with per-run text, merge the text into the file before launching instead of passing both flags
+
+###
+
+
+
Invalid `--agents` configuration
The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway.
@@ -2733,6 +2800,21 @@
+Cannot add MCP server when managed settings allow only plugin servers
+
+You ran `claude mcp add` or `claude mcp add-json` while your organization’s managed settings set [`strictPluginOnlyCustomization`](</docs/en/settings-reference#strictpluginonlycustomization>) to `true` or to a list that includes `mcp`. With that setting, Claude Code doesn’t load MCP servers from `~/.claude.json` or `.mcp.json`, so the command exits with code 1 instead of saving a server that would never load:
+
+ Cannot add MCP server: your organization's managed settings allow only MCP servers that plugins provide. Install a plugin that provides this server, or ask your administrator to make it available.
+
+`claude mcp add-from-claude-desktop` reports each server you select as not imported, with this message as the reason. [`/import`](</docs/en/commands#all-commands>) reports this message for each MCP server it tries to add and still imports the other items it found. Before v2.1.284, these commands saved the server and reported success, and the server never loaded. **What to do:**
+
+ * Install a [plugin](</docs/en/plugins/install>) that provides the server
+ * Ask your administrator to distribute the server in a [plugin](</docs/en/plugins/org>), or to provide it through [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) if it’s a remote HTTP or SSE server
+
+###
+
+
+
Can’t read .mcp.json
A command that reads the project’s [`.mcp.json`](</docs/en/mcp#project-scope>), such as `claude mcp add` or `claude mcp add-json` with `--scope project`, or `claude mcp remove`, found that the file in your current directory isn’t a regular file or is larger than 2 MiB, so it exits with this error instead of reading the file.
@@ -2895,6 +2977,30 @@
* For interactive use, run `claude` in a real terminal: Windows Terminal or the PowerShell console rather than ISE, and your IDE’s integrated terminal rather than an output pane
* For one-shot use, pass the prompt: `claude -p "your question"`, or pipe it with `echo "your question" | claude -p`
+
+###
+
+
+
+Claude Code can’t read the keyboard here
+
+You ran `claude` without [`-p`](</docs/en/headless>), which starts an [interactive session](</docs/en/interactive-mode>), but its standard input isn’t a terminal. Something piped or redirected it, or the program that launched `claude` supplied its own input stream. An interactive session needs a terminal to read your keystrokes from, and what Claude Code does without one depends on your platform:
+
+ * **Windows** : Claude Code prints the message to stderr and exits with code 1 instead of starting the interface
+ * **macOS and Linux** : Claude Code reads your keystrokes from `/dev/tty` and starts the session, with any piped text as your first prompt. You see the message when `/dev/tty` can’t be opened, and its first line names `/dev/tty` in place of the Windows wording.
+
+On Windows the message reads:
+
+ Claude Code can't read the keyboard here: stdin is not a terminal (it is piped, redirected, or supplied by the program that launched claude), and on Windows it can't fall back to the console for input yet.
+ Run claude directly in Windows Terminal, PowerShell, or Command Prompt, without piping or redirecting its input.
+ To send text as a prompt and print the reply instead, add -p; it also works with --continue and --resume <session-id> (for example: type notes.md | claude -p --continue).
+
+**What to do:**
+
+ * To work interactively, run `claude` directly in a terminal, without piping or redirecting its input
+ * To get a reply without the interactive interface, for example from a script, add `-p` and give the prompt as an argument or on stdin, as in `claude -p "your question"` or `echo "your question" | claude -p`. The same works with `--continue` and `--resume <session-id>`.
+
+Before v2.1.287, Claude Code started the interface instead of printing this message, then either showed nothing on screen or failed with an error containing `Raw mode is not supported`. If you see `Raw mode is not supported` during `claude install` instead, see [`Raw mode is not supported` during install](</docs/en/troubleshoot-install#raw-mode-is-not-supported-during-install>).
###
@@ -3091,6 +3197,31 @@
+A GitHub organization policy is blocking Claude
+
+You ran a command at the Claude Code prompt that starts a cloud session, such as [`/autofix-pr`](</docs/en/claude-code-on-the-web#auto-fix-pull-requests>). Before it creates the session, Claude Code checks Claude’s access to the repository on GitHub, and GitHub refused because your GitHub organization has a policy that blocks Claude. Claude Code stops there and shows a message naming the policy. When an IP allow list is what blocks the access, the message reads:
+
+ Your GitHub organization has an IP allowlist that is blocking Claude. Add Claude's IP ranges to your GitHub allowlist.
+
+When single sign-on is what blocks it, the message reads:
+
+ Your GitHub organization requires single sign-on. Disconnect and reconnect GitHub on the Connectors page in Claude on the web, click Authorize next to your organization when GitHub asks, then try again.
+
+When a Microsoft Entra ID Conditional Access policy is what blocks it, the message reads:
+
+ Your GitHub organization's identity provider (Microsoft Entra ID) has a Conditional Access policy that is blocking Claude. Ask your GitHub Enterprise or Entra ID admin to allow Claude in that policy.
+
+**What to do:**
+
+ * **IP allow list** : ask an owner of your GitHub organization or enterprise to allow Anthropic’s outbound IP addresses. See [GitHub allow lists and firewalls](</docs/en/network-config#github-allow-lists-and-firewalls>) for the addresses and the GitHub settings to change.
+ * **Single sign-on** : disconnect GitHub at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>), then connect it again. When GitHub asks, click **Authorize** next to your organization so the new connection is authorized for its single sign-on.
+ * **Conditional Access policy** : ask your GitHub Enterprise or Microsoft Entra ID administrator to allow Claude in that policy
+ * After the change, run the command again
+
+###
+
+
+
Single sign-on authorization needed
You ran [`/install-github-app`](</docs/en/github-actions#quick-setup>) and chose a repository whose organization enforces SAML single sign-on. Before setup, Claude Code checks your access to the repository with the GitHub CLI, and GitHub refused that check because your `gh` token isn’t authorized for the organization yet. The wizard shows the warning with the steps to authorize:
@@ -3120,7 +3251,7 @@
Claude Code exits with code 1 after showing the message. The `/resume` picker inside a running session reports `Failed to resume conversation` in the conversation instead, and your current session keeps running. Before v2.1.216, a failed resume from the `claude --resume` picker stayed on the `Resuming conversation…` spinner indefinitely instead of showing this message. **What to do:**
* Run `claude --resume <session-id>` with the session ID from the message to retry
- * If every retry fails the same way, run `claude update` and resume again. Versions before v2.1.275 fail the resume when the saved transcript contains an entry they can’t read.
+ * On a version before v2.1.285, if the retry fails the same way, run `claude update` and resume again. Those versions fail the resume when the saved transcript contains an entry they can’t read.
* If the retry fails again, run `claude` to start a new session
###
@@ -3276,6 +3407,21 @@
* Add `local` to the session’s setting sources and switch again
* Set the [`outputStyle`](</docs/en/settings-reference#outputstyle>) key in a settings file the session does load, such as `.claude/settings.json` in the project or `~/.claude/settings.json`. In the TypeScript SDK, set `outputStyle` inside the inline `settings` object instead; see [Activate an output style](</docs/en/agent-sdk/modifying-system-prompts#activate-an-output-style>)
+###
+
+
+
+/recap only runs when you ask for it yourself
+
+The [`/recap`](</docs/en/interactive-mode#session-recap>) request didn’t come from your own input. It arrived in a message relayed into the session from a Slack, Teams, or [project](</docs/en/claude-projects>) thread, or in a prompt that a [routine](</docs/en/routines>) or another program sent. A relayed message gets the notice even when you wrote it yourself. Claude Code can’t tell that a relayed or automated message came from the person whose account runs the session, so it answers with this notice instead of a summary:
+
+ /recap only runs when you ask for it yourself in this session: from the terminal, the Claude app or claude.ai/code, or over Remote Control. A message relayed from Slack, Teams or a project thread, or sent by a routine or another program, can't request it.
+
+A `/recap` you pass to `claude -p`, or that your own [Agent SDK](</docs/en/agent-sdk/overview>) application sends to a session it launched, counts as your own input. **What to do:**
+
+ * Open the session yourself and run `/recap` there: in its terminal, in the [Desktop app](</docs/en/desktop>) or the [mobile app](</docs/en/mobile>), at [claude.ai/code](<https://claude.ai/code>), or over [Remote Control](</docs/en/remote-control>)
+ * If a routine or another program sent it, remove `/recap` from that prompt
+
##
@@ -3553,7 +3699,23 @@
Tool errors
-These errors come from Claude’s built-in tools. Claude corrects most tool errors on its own. When one needs a change from you, that error’s **What to do** list says what to change.
+These errors come from Claude’s tool calls. Claude corrects most tool errors on its own. When one needs a change from you, that error’s **What to do** list says what to change.
+
+###
+
+
+
+No such tool available
+
+Claude called a tool by a name that isn’t in the session’s tool list. Claude Code returns the error to Claude as the tool call’s result, and the turn continues. When Claude Code can tell why the tool is missing, it adds a sentence after the tool name that gives the reason or names the tool to call instead, as in the second line:
+
+ Error: No such tool available: <tool name>
+ Error: No such tool available: read. Tool names are case-sensitive: call Read instead.
+
+Right after you resume a session, an MCP server can still be on its first connection attempt when Claude calls one of its tools. Claude Code then [waits for the server](</docs/en/mcp#tool-availability>) and returns this error if the tool still isn’t available when the wait ends. Before v2.1.284, such a call failed at once instead of waiting. A call whose tool name Claude Code cut to 200 characters also fails with this error. **What to do:**
+
+ * If it happens once, you don’t need to do anything. Claude reads the error and the turn continues.
+ * If calls to an MCP server’s tools keep failing with this error, run `/mcp` in the session or `claude mcp list` in your shell to check the server’s [status](</docs/en/mcp#server-status>), and reconnect a failed server from `/mcp`. In the Agent SDK, see [Error handling](</docs/en/agent-sdk/mcp#error-handling>).
###
@@ -3875,6 +4037,28 @@
+Not published: that file is on a network share
+
+Claude tried to publish an [artifact](</docs/en/artifacts>) from a file at a path that names a network host:
+
+ * On Windows, a `\\server\share` path that isn’t under a mapped network drive you passed at launch with [`--add-dir`](</docs/en/cli-reference#cli-flags>)
+ * On macOS or Linux, an automount path such as `/net/<host>/page.html`
+
+Looking up such a path contacts the host it names, and on Windows that contact can send the host your credentials. Claude Code refuses to publish the file and doesn’t read it. The refusal appears in the Artifact tool result:
+
+ Not published: that file is on a network share. Publish a file from this session's folders instead.
+
+**What to do:**
+
+ * Nothing, if you don’t need that exact file: the message tells Claude to publish a file from the session’s own folders instead
+ * To publish that exact file, copy it into a folder on a local disk and ask again
+ * On Windows, to let Claude publish directly from the share, map it to a drive letter and pass the drive when you start Claude Code. In PowerShell, for example, run `net use Z: \\server\share` and then `claude --add-dir Z:\`. Claude can then publish files from that drive. Adding the drive mid-session with `/add-dir` isn’t enough.
+ * On macOS or Linux, mount the share at a directory such as one under `/mnt` or `/Volumes`, and publish from that path instead of the automount path
+
+###
+
+
+
Reading a local file from outside the connected folders in a Cowork session
In a [Cowork](<https://claude.com/docs/cowork/overview>) session running on your machine in the Claude Desktop app, Claude named a local file for an [artifact](</docs/en/artifacts>). Claude Code couldn’t confirm the file is a plain file inside the session’s connected folders: the path sits outside those folders, passes through a symbolic link, or is spelled in a way that can name a different file than it appears to. Reading such a file needs your approval, and in a session that can’t show you the approval card, such as one set to skip all approvals, Claude Code refuses the read. The refusal appears in the Artifact tool result; when the file couldn’t be examined at all, it names that failure instead:
@@ -3903,6 +4087,23 @@
* Usually nothing: the message points Claude at `curl` through the Bash tool, which can reach local and intranet servers
Before v2.1.268, WebFetch reported these URLs with a generic `Invalid URL` error.
+
+###
+
+
+
+WebFetch domain safety check failed
+
+Before fetching a URL, WebFetch sends the URL’s hostname to `api.anthropic.com` to check it against Anthropic’s [domain safety blocklist](</docs/en/data-usage#webfetch-domain-safety-check>). If the check can’t complete, WebFetch can’t confirm that the domain is safe, so it doesn’t fetch the page and the tool result carries one of these messages instead:
+
+ The safety check for domain example.com is rate-limited (too many domain checks from this network; the limit is shared and can stay exhausted for minutes). Do not retry WebFetch in a loop or sleep to wait it out; continue without this page and report that its safety check was rate-limited. A single later attempt is fine; if that is rate-limited too, stop.
+
+ Unable to verify if domain example.com is safe to fetch. This may be due to network restrictions or enterprise security policies blocking claude.ai.
+
+ * `rate-limited`: the check endpoint answered with HTTP `429`. The message tells Claude to continue without the page and to try again at most once later. Claude Code doesn’t cache a failed check, so a later fetch of that domain runs the check again. If sessions on your network hit this often, you can skip the check with [`skipWebFetchPreflight: true`](</docs/en/settings-reference#skipwebfetchpreflight>) in settings.
+ * `Unable to verify`: the check request failed, timed out, or got another error status. If your network blocks `api.anthropic.com`, allowlist that domain, or skip the check with [`skipWebFetchPreflight: true`](</docs/en/settings-reference#skipwebfetchpreflight>) in settings.
+
+Before v2.1.286, the rate-limited message read `The safety check for domain example.com is temporarily rate-limited (too many domain checks from this network). Retry after about a minute; retrying sooner will fail the same way.`. Before v2.1.285, a rate-limited check was reported with the `Unable to verify` message instead.
##
@@ -4224,7 +4425,7 @@
* **`The home directory is trusted one session at a time`** : the session’s directory is your home directory. Claude Code never saves trust for the home directory, so accepting the dialog there in an earlier session doesn’t count.
* **`<path> could not be resolved on disk`**: Claude Code couldn’t find the session’s directory on disk.
-**What to do:**
+Before v2.1.286, on Windows, this message could also appear in a directory you had already trusted, if its trust record was saved with the path in a different letter case. Update to v2.1.286 or later. **What to do:**
* Run `claude` in the directory the message names and accept the trust dialog, then run the command again
* For the home-directory message, run the command from a terminal in your home directory so the dialog can appear, or start the session from a project directory instead
@@ -4740,6 +4941,21 @@
+ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name
+
+You set [`ANTHROPIC_FOUNDRY_RESOURCE`](</docs/en/env-vars>) to something other than a bare [Microsoft Foundry](</docs/en/microsoft-foundry>) resource name, such as the endpoint URL or its host name. Claude Code refused the value before sending a request. The message appears in place of Claude’s reply, not as a startup warning:
+
+ API Error: ANTHROPIC_FOUNDRY_RESOURCE must be a Foundry resource name (2-64 letters, digits and hyphens, not starting or ending with a hyphen, such as my-resource), not a URL or host name. To use a full URL, set ANTHROPIC_FOUNDRY_BASE_URL instead.
+
+**What to do:**
+
+ * Set `ANTHROPIC_FOUNDRY_RESOURCE` to the resource name alone and restart Claude Code. For the endpoint `https://my-resource.services.ai.azure.com/anthropic`, the name is `my-resource`.
+ * To give the full endpoint URL instead, set [`ANTHROPIC_FOUNDRY_BASE_URL`](</docs/en/env-vars>) to the URL and remove `ANTHROPIC_FOUNDRY_RESOURCE`, then restart Claude Code. Claude Code accepts only one of the two variables.
+
+###
+
+
+
The 200K limit isn’t enforced
You set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>), which normally makes [auto-compaction](</docs/en/model-config#default-auto-compact-thresholds>) hold sessions on 1M-context models to a 200K window, but no compaction threshold caps this session at or below 200K, so the conversation can grow past it.
Show diff (299 lines)
--- a/errors.md
+++ b/errors.md
@@ -86,7 +86,9 @@
`rejected the credential from its headersHelper` / `rejected the Authorization header in its config`| Authentication
`MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate`| Authentication
`MCP server "<name>" requires re-authorization (token expired)`| Authentication
+`This server's URL is missing or not a valid URL, so sign-in can't start`| Authentication
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
+`Refusing to send credentials to non-https token endpoint` / `<short-name> from the MCP SDK for <server-url>`| Authentication
`Cloud gateway session expired — run /login to reconnect.`| Authentication
`Cloud gateway <url> no longer accepts this session`| Authentication
`Sign-in timed out while waiting for you to continue. Try again.`| Authentication
@@ -193,6 +195,8 @@
`Cannot add MCP server to scope: managed`| Command-line errors
`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
`Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes`| Command-line errors
+`MCP server "<name>" was not saved to` / `was not removed from`| Command-line errors
+`MCP server "<name>" may not have been saved` / `may not have been removed`| Command-line errors
`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`OAuth callback port <port> is already in use — another process may be holding it`| Command-line errors
@@ -308,7 +312,7 @@
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
-`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| Configuration warnings
+`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>)
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
@@ -317,9 +321,12 @@
`Remote managed settings failed to load (<cause>)`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
+`Your organization's managed settings allow Claude Code to use: <providers>`| Configuration warnings
+`Your organization's managed settings allow Claude Code to use no API provider at all`| Configuration warnings
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
+`Unable to read managed policy settings`| Configuration warnings
`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
@@ -1321,6 +1328,20 @@
+MCP server URL is missing or not a valid URL
+
+Claude Code refused to start an OAuth sign-in for a remote MCP server because the server’s configured `url` doesn’t parse as a URL. Unless Claude Code has a more specific configuration problem to report for the server, running [`claude mcp login <name>`](</docs/en/mcp#authenticate-from-the-command-line>) in your shell prints the refusal as:
+
+ Couldn't complete authentication for "<name>": This server's URL is missing or not a valid URL, so sign-in can't start. Fix the URL in its MCP config (or set the environment variable it uses) and try again.
+
+**What to do:**
+
+ * Set the entry’s `url` to the server’s real endpoint where the server is configured, or set the environment variable that its [`${VAR}` reference](</docs/en/mcp#environment-variable-expansion-in-mcp-json>) names, then run the sign-in again.
+
+###
+
+
+
Issuer mismatch in authorization response
During an [MCP OAuth sign-in](</docs/en/mcp#authenticate-with-remote-mcp-servers>), the authorization server redirected back to Claude Code with an `iss` parameter that doesn’t name the issuer that Claude Code expected from the server’s OAuth metadata. A wrong issuer at this step is how an authorization server mix-up attack looks, so Claude Code fails the sign-in instead of exchanging the authorization code. Claude Code shows the error in the `/mcp` server menu after the browser sign-in:
@@ -1334,6 +1355,21 @@
* To connect while the server is being fixed, start Claude Code with [`MCP_SDK_GENERATION=v1`](</docs/en/env-vars>), whose [runtime](</docs/en/mcp#mcp-client-runtimes>) doesn’t run this check. This removes a protection against mix-up attacks, so prefer the server-side fix
Before v2.1.232, Claude Code used the v2 runtime only in a gradual rollout or when you set `MCP_SDK_GENERATION=v2`.
+
+###
+
+
+
+Refusing to send credentials to non-https token endpoint
+
+On the [v2 runtime](</docs/en/mcp#mcp-client-runtimes>), Claude Code sends an [MCP OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>) token request only to a token endpoint served over HTTPS or at `localhost`, `127.0.0.1`, or `::1`. This message means the server’s token endpoint is neither, so Claude Code stopped before sending the request. That happens after the browser sign-in, so the browser step succeeds first, and again whenever Claude Code refreshes the server’s token. In its full form, the message comes from the MCP SDK and quotes the token endpoint it refused. In the debug log, it follows `Error during auth completion:` for a sign-in or `Token refresh failed:` for a refresh. In your shell, `claude mcp login <name>` prints it after `Couldn't complete authentication for "<name>":`, and in a session, `/mcp` shows it under the server’s menu:
+
+ Refusing to send credentials to non-https token endpoint 'http://192.168.1.50:8123/oauth/token'. OAuth token requests MUST use TLS (localhost / 127.0.0.1 / ::1 are exempt).
+
+Claude Code treats a server URL that has a query string or a long random-looking path segment as possibly secret. For such a server, it redacts the sign-in errors the MCP SDK raises before it shows or logs them. This error then reads as a short name that can change between releases, such as `io`, followed by `from the MCP SDK for` and the redacted server URL. Other errors from the MCP SDK take the same shape there. The redacted message can be this error only when the server’s token endpoint is plain `http://` at an address other than `localhost`, `127.0.0.1`, or `::1`. **What to do:**
+
+ * Serve that token endpoint over HTTPS, for example by putting the server behind a reverse proxy or tunnel that terminates TLS and configuring the server to advertise the `https://` address
+ * To connect without changing the server, start Claude Code with [`MCP_SDK_GENERATION=v1`](</docs/en/env-vars>), whose [runtime](</docs/en/mcp#mcp-client-runtimes>) doesn’t apply this rule and sends the token request over plain HTTP. That choice lasts until you exit and applies to every server. The v1 runtime also skips the issuer check, so prefer serving the endpoint over HTTPS
###
@@ -1684,7 +1720,7 @@
* Open the routine for editing, or start a cloud session. Select the cloud icon showing your environment’s name, such as **Default** , to open the selector. Hover over your environment and click the settings icon.
* In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
- * Click **Save changes**. The next run uses the updated allowlist.
+ * Click **Save changes**. The next run uses the updated allowlist. For a cloud session that’s already open, see [when a network access change reaches existing sessions](</docs/en/cloud-environments#network-access>).
See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
@@ -2711,13 +2747,42 @@
+MCP server was not saved or removed
+
+You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>). Both scopes are stored in `~/.claude.json`, and the change isn’t in that file when Claude Code reads it back after writing. The command exits with this error instead of its success line.
+
+ MCP server "example" was not saved to /home/user/.claude.json. If that file is read-only or protected by a sandbox, make it writable or run the command outside the sandbox, then add the server again.
+
+After a remove, the message reads `was not removed from` and ends with `then remove the server again`. For a `local`-scope server, the path is followed by the project directory the entry belongs to, as `(local scope for /path/to/project)`. Before v2.1.283, `claude mcp add`, `claude mcp add-json`, and `claude mcp remove` reported success even when the change didn’t reach the file. **What to do:**
+
+ * Make the file the message names writable, or run the command outside the sandbox, then run the same add or remove command again.
+
+###
+
+
+
+MCP server may not have been saved or removed
+
+You ran `claude mcp add`, `claude mcp add-json`, or `claude mcp remove` for a server in the `user` or `local` [scope](</docs/en/mcp#mcp-installation-scopes>), and Claude Code couldn’t read `~/.claude.json` back to confirm the change. The change may or may not be on disk. The text in parentheses is the error from that read.
+
+ MCP server "example" may not have been saved: /home/user/.claude.json could not be read to confirm the change (EACCES: permission denied, open '/home/user/.claude.json'). Run `claude mcp get example` to check, then add the server again if it is missing.
+
+After a remove, the message reads `may not have been removed` and ends with `then remove the server again if it is still listed`. Before v2.1.283, the commands reported success even when the change couldn’t be confirmed. **What to do:**
+
+ * Run `claude mcp get <name>` to check whether the change is on disk. For a `local`-scope server, run it from the project directory the server belongs to, since local scope is per project.
+ * If the server is missing after an add, or still listed after a remove, run the same add or remove command again.
+
+###
+
+
+
Server is Anthropic-hosted and doesn’t support local OAuth
You started a sign-in for an MCP server whose URL points at an Anthropic-hosted connector host that authenticates through a third-party identity provider. These hosts include `microsoft365.mcp.claude.com`, `gmail.mcp.claude.com`, and `gcal.mcp.claude.com`. Claude Code refuses to start its local OAuth flow for these hosts from both the `/mcp` panel and `claude mcp login`, because [their sign-in works only through claude.ai](</docs/en/mcp#use-mcp-servers-from-claude-ai>).
"gmail" is Anthropic-hosted and doesn't support local OAuth. Connect it via Settings → Connectors on claude.ai (requires `claude login`), then it'll be available here automatically.
-Claude Code matches these hosts by URL, so the message appears when a server you added with `claude mcp add` or in `.mcp.json` points at one of them. **What to do:**
+**What to do:**
* Remove your entry with `claude mcp remove <name>`, so it can’t hide the claude.ai connector at the same URL
* After removing it, connect the service at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>), while signed in to the account you use in Claude Code. Once connected, [the connector appears in Claude Code automatically](</docs/en/mcp#use-mcp-servers-from-claude-ai>) if your active authentication method is a claude.ai subscription login
@@ -3130,16 +3195,16 @@
Couldn’t open Claude Desktop
-You ran [`/desktop`](</docs/en/desktop#coming-from-the-cli>), or its alias `/app`, and the system command Claude Code uses to open Claude Desktop failed. The session stays in the terminal.
-
- Error: Couldn't open Claude Desktop (`open` exited 1: LSOpenURLsWithRole() failed for the URL claude://resume?session=<session-id> with error -10814). Open Claude Desktop and run /desktop again.
-
-**What to do:**
-
- * Open Claude Desktop yourself, then run `/desktop` again
- * To read that command’s full error output, turn on debug logging with `/debug`, run `/desktop` again, and check the debug log
-
-Before v2.1.275, the message was `Failed to open Claude Desktop. Please try opening it manually.` and didn’t say what failed.
+You ran [`/desktop`](</docs/en/desktop#coming-from-the-cli>) or its alias `/app` in a session, or [`claude --desktop`](</docs/en/cli-reference#cli-flags>) in your shell, and the system command Claude Code uses to open Claude Desktop failed. After `/desktop`, the session stays in the terminal; `claude --desktop` prints the message without the `Error:` prefix and exits with status 1. The text in parentheses names the command that failed, with its exit status and the first line of its error output when it produced them. On macOS that command is `open`, as in this example; on Windows it is `rundll32`:
+
+ Error: Couldn't open Claude Desktop (`open` exited 1: LSOpenURLsWithRole() failed for the URL claude://resume?session=<session-id> with error -10814). Open Claude Desktop and try again.
+
+**What to do:**
+
+ * Open Claude Desktop yourself, then run `/desktop` or `claude --desktop` again
+ * To read the failed command’s full error output, turn on debug logging with `/debug` and run `/desktop` again, or run `claude --desktop --debug-file <path>`, then check the debug log
+
+Before v2.1.285, the message ended `Open Claude Desktop and run /desktop again.` Before v2.1.275, it was `Failed to open Claude Desktop. Please try opening it manually.` and didn’t say what failed.
###
@@ -3364,7 +3429,7 @@
commands path escapes plugin directory: ./commands\deploy.md — its path contains a backslash, which is not resolved reliably on this platform
-Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Claude Code already rejected paths declared in `plugin.json` and the other component paths in a marketplace entry. Before v2.1.257, the check looked only at the path’s spelling, not at where a symlink leads. **What to do:**
+Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Before v2.1.257, the check looked only at the path’s spelling, not at where a symlink leads. **What to do:**
* Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
* If the path is a symlink to a file outside the plugin, replace the symlink with a copy of the file
@@ -3435,10 +3500,10 @@
Claude Code keeps the plugin marketplaces you’ve added in a registry file at `~/.claude/plugins/known_marketplaces.json`. A plugin command that needs the registry, such as `claude plugin install`, fails with one of two messages when Claude Code can’t use the file:
- * `Failed to load marketplace configuration`: the file isn’t valid JSON, or can’t be read. An empty file fails this way too.
+ * `Failed to load marketplace configuration`: the file exists but isn’t valid JSON or can’t be read. An empty file fails this way too.
* `Marketplace configuration file is corrupted`: the file is valid JSON but its contents don’t match the registry schema.
-A missing file isn’t a failure: Claude Code treats it as a registry with no marketplaces. With an empty file, `claude plugin install` reports:
+With an empty file, `claude plugin install` reports:
✘ Failed to install plugin "my-plugin": Failed to load marketplace configuration: JSON Parse error: Unexpected EOF
@@ -3995,7 +4060,7 @@
terminal host process died — press Enter to restart
-If you open the row before the check runs, the footer shows `This session's terminal host process died (the conversation is saved) — press Enter to restart it` and the row turns failed. From the shell, `claude attach <id>` restarts a session already marked failed for a dead host, and otherwise prints the cause and exits:
+From the shell, `claude attach <id>` restarts a session already marked failed for a dead host, and otherwise prints the cause and exits:
Couldn't attach to <id> — This session's terminal host process died (the conversation is saved) — run `claude attach <id>` again to restart it on a fresh host.
@@ -4342,25 +4407,6 @@
-Fullscreen renderer didn’t finish starting
-
-A previous [fullscreen](</docs/en/fullscreen>) session on this machine exited before it finished starting, so Claude Code starts this session on the classic renderer and prints one of these notices:
-
- Claude Code's fullscreen renderer didn't finish starting last time on this machine, so this launch is using the classic renderer. It will try fullscreen again next launch; /tui default keeps the classic renderer.
-
- Claude Code's fullscreen renderer has repeatedly failed to start on this machine, so it has been turned off here. Run /tui fullscreen to try it again (this also resets after an update).
-
-**What to do:**
-
- * Follow [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>). It says which notice you get, what Claude Code does in later sessions, and how to try fullscreen again or keep the classic renderer.
- * If the session that died printed an exit message, see Claude Code exited after an unrecoverable interface error for what it names.
-
-Before v2.1.236, Claude Code printed no notice and kept starting sessions in fullscreen rendering after a failed start.
-
-###
-
-
-
Claude Code exited after an unrecoverable interface error
Claude Code prints this message when it exits because its terminal interface hit an error it can’t recover from, in either renderer. The second sentence appears only when the error happened while the [fullscreen](</docs/en/fullscreen>) renderer was starting:
@@ -4497,6 +4543,25 @@
* If you administer the settings, add a model your users can run to `availableModels`, or narrow the `deniedModels` entries that block every fallback. [Block specific models or versions](</docs/en/model-config#block-specific-models-or-versions>) describes how the Default option steps down
* If you don’t administer them, send the message to your administrator. Your own settings files can’t widen a managed `availableModels` or `deniedModels` list
+
+###
+
+
+
+Managed settings don’t allow this API provider
+
+Your organization’s [managed settings](</docs/en/managed-settings>) set an [`allowedProviders`](</docs/en/settings-reference#allowedproviders>) list, and the session’s API provider isn’t on it or the session uses an endpoint that isn’t pinned the way that entry requires. Claude Code refuses at startup, before a login, or when the session next contacts the API. The message begins with the permitted providers:
+
+ Your organization's managed settings allow Claude Code to use: Anthropic API, Amazon Bedrock.
+
+When the list is empty, the message reads instead:
+
+ Your organization's managed settings allow Claude Code to use no API provider at all (allowedProviders is an empty list), so it cannot start on this machine.
+
+When every entry is unrecognized, the parenthetical reads `(allowedProviders lists only unrecognized entries)` instead. **What to do:**
+
+ * Follow the message’s `To continue:` steps
+ * If you administer the settings, the message’s lines starting `Admins:` name the entry to add or the value to pin, and the [`allowedProviders`](</docs/en/settings-reference#allowedproviders>) entry says which source’s `env` block can pin it
###
@@ -4542,6 +4607,27 @@
* If you administer the machine, fix the named document so it parses as a JSON object, or remove the file, profile, or registry value. An empty `managed-settings.json` counts as `{}` and doesn’t block launch.
* If you don’t, ask your administrator to fix the deployed document. Nothing in your own settings files causes or clears this error.
+
+###
+
+
+
+Unable to read managed policy settings
+
+Your organization deploys [managed settings](</docs/en/managed-settings>), and one of the deployed sources exists but couldn’t be read, for a reason such as an I/O error rather than the operating system denying the read. With no other admin source supplying a policy, Claude Code exits at startup rather than run without the policy the source may carry:
+
+ Unable to read managed policy settings.
+ This machine may require organization login enforcement, but the policy file failed to load.
+ Contact your administrator.
+
+ Detail: <source>: <reason>
+
+In the same state, sign-in flows, API requests from a session that is already running, and the [`claude gateway`](</docs/en/claude-apps-gateway>) server are refused with a variant of the first line that names [`allowedProviders`](</docs/en/settings-reference#allowedproviders>). A read that the operating system denied, such as on a root-only file, doesn’t produce this exit: [the session starts without that source’s policies](</docs/en/managed-settings#find-entries-claude-code-dropped>). For a source that can’t be parsed, Claude Code exits with a different message naming the source. **What to do:**
+
+ * If you administer the machine, fix the problem the `Detail:` line names so the deployed source can be read, or remove the source
+ * If you don’t, send the message to your administrator. Nothing in your own settings files causes or clears this error
+
+Before v2.1.285, only sessions signed in with claude.ai or Claude Console credentials exited with this message, and a read that the operating system denied produced it too.
###
@@ -4631,7 +4717,7 @@
* Fix the rule at the source the warning names in parentheses: a settings file path, or the `--allowed-tools` flag itself. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
* If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings, since you can’t clear it yourself.
-Claude Code doesn’t warn about deny and ask rules with the same shape: it refuses or prompts for the extra commands they match rather than approving them. It also doesn’t warn about rules whose subcommand comes before the first `*`, such as `Bash(git commit *)`, or rules in which no word other than an option follows the `*`, such as `Bash(git *)`, or about `:*` prefix rules such as `Bash(git:*)`. In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning.
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning.
###
@@ -4733,10 +4819,10 @@
Responses seem lower quality than usual
-If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code doesn’t silently change model versions. It can switch to a fallback model in three specific cases:
+If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code doesn’t silently change model versions. It can switch to a fallback model in these cases:
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
- * An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
+ * An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable, or your account [loses access to it mid-session](</docs/en/amazon-bedrock#when-a-model-is-disabled-mid-session>)
* [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, Opus 5.5, Sonnet 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
Show diff (330 lines)
--- a/errors.md
+++ b/errors.md
@@ -68,6 +68,7 @@
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`Failed to start OAuth callback server`| Authentication
`Claude login not accepted · Run /login, then try again`| Authentication
`Artifacts need a claude.ai login`| Authentication
`Not signed in to the Cloud gateway — run /login.`| Authentication
@@ -134,19 +135,21 @@
`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
`Unable to resize image`| Request errors
-`PDF too large` / `PDF is password protected`| Request errors
+`PDF too large` / `PDF is password protected` / `pdftoppm is not installed`| Request errors
`Extra inputs are not permitted`| Request errors
`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid` / `Property keys should match pattern`| Request errors
`tool_use.name: String should have at most 200 characters`| Request errors
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
`Model ... not found`| Request errors
+`Couldn't confirm model ... with the API`| Request errors
`API error: ... · model not changed`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
`Claude Code ... does not support this model; version ... or newer is required`| Request errors
`Claude Code ... is older than the minimum version required by your organization's policy`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
`Model ... is not available. Your organization restricts model selection.`| Request errors
+`Can't switch to the default model`| Request errors
`Model switch ... blocked by a PreModelSwitch hook`| Request errors
`couldn't save it as your default` / `couldn't confirm it was saved as your default`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
@@ -208,6 +211,7 @@
`Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected`| Command-line errors
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
+`Not uploading this working tree` with `the upload cannot follow that setting`| Command-line errors
`GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud`| Command-line errors
`Single sign-on authorization needed`| Command-line errors
`Failed to resume the conversation`| Command-line errors
@@ -241,6 +245,7 @@
`Plugin "<name>@synced" is required by your organization and can't be disabled here`| Plugin errors
`"<plugin>" was not uninstalled: it is still switched on in <file>`| Plugin errors
`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
+`Plugin "<plugin>" was not uninstalled: installed_plugins.json`| [Plugin troubleshooting](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>)
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
@@ -253,6 +258,7 @@
`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
+`Cross-session message was dropped at the recipient session's inbox`| Tool errors
`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
@@ -665,16 +671,16 @@
The prompt to confirm went unanswered
-If your account requires the [Fable usage-credits consent](</docs/en/model-config#fable-and-usage-credits>), Claude Code asks you to confirm before a Fable request bills usage credits. When nobody answers that consent prompt in a session that may have no one at its terminal, Claude Code closes the prompt and ends the turn with one of these messages:
+If your account requires the [Fable usage-credits consent](</docs/en/model-config#fable-and-usage-credits>), Claude Code asks you to confirm before a Fable request bills usage credits. When the consent prompt closes with nobody answering it, Claude Code ends the turn with one of these messages:
Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
-
- * At the terminal where the session runs, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
+The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), [agent team](</docs/en/agent-teams>) teammate sessions, and sessions that another application hosts through the Agent SDK. For when Claude Code closes the prompt, see [Fable and usage credits](</docs/en/model-config#fable-and-usage-credits>). **What to do:**
+
+ * Where the session runs, at the terminal or in the application hosting it, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
* Run `/model` to switch to a model that doesn’t bill usage credits
- * To give yourself more time to reach that terminal, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
+ * To give yourself more time, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
Before v2.1.236, this message didn’t appear: while a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
@@ -1150,6 +1156,21 @@
+Failed to start OAuth callback server
+
+When `/login`, `claude auth login`, or `claude setup-token` signs you in through the browser, Claude Code opens a listening port on `127.0.0.1` so your browser can return the sign-in result to it. This message means Claude Code couldn’t open that port, and the sign-in stops before a browser window or login URL appears:
+
+ Failed to start OAuth callback server: Failed to start server. Is port 0 in use?
+
+If your message ends with `Is port 0 in use?`, the attempt to listen on the IPv4 loopback address `127.0.0.1` failed outright. Because the failure happens before a login URL exists, the `Paste code here if prompted` flow isn’t available as a workaround. **What to do:**
+
+ * To sign in right away without the local listener: if you use a claude.ai subscription, run [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) on a machine where sign-in works and set the token it prints as `CLAUDE_CODE_OAUTH_TOKEN` on this machine. Otherwise set `ANTHROPIC_API_KEY` to a key from the [Claude Console](<https://platform.claude.com/settings/keys>). [Authentication precedence](</docs/en/authentication#authentication-precedence>) explains how Claude Code chooses between credentials.
+ * To use browser sign-in on this machine instead, Claude Code must be able to listen on `127.0.0.1`. If it runs inside a sandbox, check that the sandbox’s policy allows listening on local ports, then run `/login` again. If it should be able to and still fails, run `/feedback` so the report includes your environment details.
+
+###
+
+
+
Claude login not accepted
You tried to start a [cloud session](</docs/en/claude-code-on-the-web>), and the server refused to create it with a 401: it didn’t accept the Claude login this machine sent, usually because the login expired or was revoked. The first part of the line is the server’s own reason when it gives one. Otherwise the line reads:
@@ -1936,6 +1957,12 @@
* For oversized PDFs, ask Claude to read a page range with the Read tool instead of attaching the whole file, or extract text with a tool like `pdftotext` and reference the output file by path
* For protected or invalid PDFs, remove the password or re-export the file from its source application, then try again
+When Claude reads a page range from a PDF with the Read tool, the read can fail with a different message:
+
+ pdftoppm is not installed. Install poppler-utils (e.g. `brew install poppler` or `apt-get install poppler-utils`) to enable PDF page rendering.
+
+Page-range reads render pages with `pdftoppm`. Install poppler-utils with the command the message gives, or on other platforms a poppler build that puts `pdftoppm` on your `PATH`. See [Read tool behavior](</docs/en/tools-reference#read-tool-behavior>) for which PDFs are read by page range.
+
###
@@ -2010,16 +2037,16 @@
Model is not a recognized model id
-The model string you passed to a model switch isn’t a model alias, a model ID this Claude Code version knows, or an ID that starts with `claude-`. The usual causes are a typo in the ID, a display name such as `Sonnet 5` where the ID `claude-sonnet-5` is expected, or an alias that only newer Claude Code versions recognize. Claude Code rejects the switch immediately. Before v2.1.200, Claude Code saved the string and failed on the next request with There’s an issue with the selected model.
-
- Model "claud-sonnet-5" is not a recognized model id. Did you mean 'claude-sonnet-5'?
-
-The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. In a session that the [Desktop app](</docs/en/desktop>) starts for you, the no-match hint reads `Switch to a different model.` Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you, or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.260, the check didn’t cover Remote Control picks, so Claude Code applied the pick and the next request failed with There’s an issue with the selected model. **What to do:**
+The string you passed to a model switch isn’t one Claude Code can use as a model, so it refused the switch without sending a request and the session keeps its current model. You can get this error when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.200, Claude Code saved the string and failed on the next request with There’s an issue with the selected model.
+
+ Model "Sonnet5" is not a recognized model id. Did you mean 'claude-sonnet-5'?
+
+In this example an app sent the display name `Sonnet 5`, which the message repeats without its space. The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. In a session that the [Desktop app](</docs/en/desktop>) starts for you, the no-match hint reads `Switch to a different model.` When you switch through the Agent SDK or an app on the Anthropic API, only a string that can’t be a model ID gets this error, such as a display name or an empty string. When you pick a model from a Remote Control device, Claude Code checks the string locally. Any string that isn’t a model alias, a model Claude Code lists or you configured, or an ID that starts with `claude-` gets this error, a mistyped ID such as `claud-sonnet-5` included. Before v2.1.260, this check didn’t cover Remote Control picks, so an unrecognized string was applied and failed on the next request. **What to do:**
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
- * If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this local check even when the model is newer than your Claude Code version. The server can still require a minimum version for that model; see Claude Code does not support this model.
+ * If you used an alias that only a newer Claude Code version supports, run `claude update`, or pass the model’s full ID instead. The server can still require a minimum Claude Code version for that model; see Claude Code does not support this model.
* A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under [Setting your model](</docs/en/model-config#setting-your-model>).
- * The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
+ * On any provider other than the Anthropic API, or behind a gateway or custom `ANTHROPIC_BASE_URL`, only an empty string gets this error. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
###
@@ -2027,7 +2054,7 @@
Model not found
-You picked a model with `/model <name>` and Claude Code couldn’t confirm that a model with that name exists. When the name isn’t a [model alias](</docs/en/model-config#model-aliases>) or another spelling Claude Code accepts locally, `/model` verifies it with a minimal API request, and this error is usually your API endpoint’s answer. A name that can’t be a model ID at all, such as one containing spaces, gets the same message.
+You switched to a model by name and Claude Code couldn’t confirm that a model with that name exists. When the name isn’t a [model alias](</docs/en/model-config#model-aliases>) or another spelling Claude Code accepts locally, Claude Code verifies it with a minimal API request, and this error is usually your API endpoint’s answer. With `/model <name>`, a name that can’t be a model ID at all, such as one containing spaces, gets the same message.
Model 'claude-opus-9' not found
@@ -2035,7 +2062,23 @@
* Run `/model` with no argument and pick from the models available to your account, or use a [model alias](</docs/en/model-config#model-aliases>) such as `sonnet`, which resolves to a maintained default
* If you typed a full ID, check it against your provider’s model catalog. A newly launched model can be available on the Anthropic API before your provider or region offers it.
+ * In the Agent SDK, `setModel()` fails with this message and the session keeps running on its previous model. In the TypeScript SDK, call [`supportedModels()`](</docs/en/agent-sdk/typescript#query-object>) to list the models you can switch to.
* Before v2.1.265, `/model` also rejected the `opusplan[1m]` alias spelling with this error. On those versions, update Claude Code, or set the model in [settings](</docs/en/model-config#setting-your-model>) or with `--model` instead.
+
+###
+
+
+
+Couldn’t confirm model with the API
+
+You switched models through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or an app that runs the Claude Code CLI for you, such as the [Desktop app](</docs/en/desktop>), and the request that confirms the model ID with your API endpoint got no answer within five seconds. The session keeps its current model.
+
+ Couldn't confirm model "claude-sonnet-5" with the API. Try again, or run /model to see available models.
+
+In a session that the [Desktop app](</docs/en/desktop>) starts for you, the message ends at `Try again.` **What to do:**
+
+ * Switch to the model again
+ * If the switch keeps failing, check that Claude Code can reach your API endpoint; see Network and connection errors
###
@@ -2082,10 +2125,16 @@
API Error: 400 Claude Code 2.1.240 is older than the minimum version required by your organization's policy. Run 'claude update', or update the Claude desktop app, to continue.
-**What to do:**
-
- * Run `claude update`, or update the Claude desktop app, then start a new session
- * For the per-model wording, you can keep working in the current session by switching to another model with `/model`
+The version the API checks is the one reported by the Claude Code binary that made the request. **What to do:** Update that binary, then start a new session. Where the binary came from decides how, except in a [self-hosted environment](</docs/en/self-hosted-environments-deploy#pin-the-version>):
+
+The binary that made the request| How to update it
+---|---
+A Claude Code you installed| Run `claude update`
+The Claude desktop app| Update the app
+The binary the [VS Code extension](</docs/en/vs-code>) bundles| Update the extension
+The binary an Agent SDK package bundles| [Upgrade the SDK package](</docs/en/agent-sdk/hosting#runtime-dependencies>), then restart your application. In a [compiled single-file executable](</docs/en/agent-sdk/typescript#compile-to-a-single-executable>), rebuild it
+
+ * For the per-model wording, you can keep working in the current session by switching to another model: run `/model` in the CLI, call [`setModel()`](</docs/en/agent-sdk/typescript#query-object>) on the TypeScript SDK’s `Query` object in streaming input mode, or call [`set_model()`](</docs/en/agent-sdk/python#claudesdkclient>) on the Python SDK’s `ClaudeSDKClient`
* For the organization-policy wording, update before you continue
###
@@ -2103,6 +2152,30 @@
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
* If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, the `model` field of a settings file, or the `model` frontmatter of a [subagent](</docs/en/sub-agents#choose-a-model>), skill, or command, remove or update that value so the notice doesn’t recur
* If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
+
+###
+
+
+
+Can’t switch to the default model
+
+You picked the Default model, for example by selecting the Default row in the `/model` picker or typing `/model default`. Claude Code refused the switch, so the session keeps its current model.
+
+ Can't switch to the default model: your organization's managed settings block it (claude-opus-4-6) in "deniedModels", and none of the models they allow can be used as the default instead. Ask your administrator to update "deniedModels" or "availableModels".
+
+The wording after the colon names what blocked the switch:
+
+ * **`your organization's managed settings block it ... in "deniedModels"`** : a managed deny list blocks the model the Default option resolves to
+ * **`your organization allows only the models listed in "availableModels"`** : a managed [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist with [`availableModelsMatch`](</docs/en/settings-reference#availablemodelsmatch>) set to `"exact"` leaves out the model the Default option resolves to
+ * **`Claude Code couldn't read your organization's managed settings to check which models they allow`** : the [managed settings](</docs/en/managed-settings>) couldn’t be read, and Claude Code refuses the switch rather than apply it unchecked
+
+**What to do:**
+
+ * For the [`deniedModels`](</docs/en/settings-reference#deniedmodels>) and `availableModels` wordings, run `/model` and pick a model your organization allows by name
+ * Ask your administrator to update the managed setting the message names
+ * For the `couldn't read` wording, restart Claude Code; if it keeps happening, ask your administrator to check the managed settings
+
+If a session instead fails to start with a `Claude Code can't start` message under these managed settings, see Managed settings block the default model.
###
@@ -2361,7 +2434,7 @@
-Conflict between —bg and —print
+Conflict between `--bg` and `--print`
This message requires Claude Code v2.1.198 or later. You combined `--bg` with `-p` or `--print` in the same `claude` invocation. `--bg` starts a [background session](</docs/en/agent-view#from-your-shell>) that you later attach to with `claude agents`, while `--print` runs [non-interactively](</docs/en/headless>) and never starts the interactive session that `claude agents` attaches to. Before v2.1.198 this combination silently created a background job that could never be attached to.
@@ -2376,7 +2449,7 @@
-Invalid —agents configuration
+Invalid `--agents` configuration
The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway.
@@ -2402,7 +2475,7 @@
-Cloud sessions cannot be created from a —restricted session
+Cloud sessions cannot be created from a `--restricted` session
When you start a session with [`--restricted`](</docs/en/cli-reference#cli-flags>), Claude Code refuses to create [cloud sessions](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) from it, because the new session would run outside the restricted process and wouldn’t enforce restricted mode. Claude Code refuses on the client, before contacting the server, so no cloud session is created:
@@ -2434,7 +2507,7 @@
-The —json-schema value is not a valid JSON Schema
+The `--json-schema` value is not a valid JSON Schema
The schema you passed to [`--json-schema`](</docs/en/cli-reference#cli-flags>) in [non-interactive mode](</docs/en/headless#get-structured-output>) failed JSON Schema compilation, so `claude` exits with code 1 instead of running the prompt. Before v2.1.205, an invalid schema produced unstructured output with no error, and any schema that used the `format` keyword was treated as invalid.
@@ -2747,7 +2820,7 @@
-Input must be provided when using —print
+Input must be provided when using `--print`
Bare `claude` needs stdout to be a terminal to start the interactive UI. When stdout is redirected, or the console isn’t a real terminal, such as PowerShell ISE and some IDE output panes, `claude` runs [non-interactively](</docs/en/headless>) instead. That is the same mode as `claude -p`, which requires a prompt, so the message names `--print` even when you didn’t pass the flag. Passing `-p`/`--print` with no prompt and nothing piped on stdin produces the same error anywhere.
@@ -2922,6 +2995,20 @@
+The repository upload can’t follow a git setting
+
+You started a [cloud session that uploads your local repository](</docs/en/claude-code-on-the-web#send-local-repositories-without-github>), or an [ultrareview](</docs/en/ultrareview>) of a branch, and the upload can’t follow one of the git settings that decide which attribute rules apply to your files. If the upload went ahead and missed a rule, a file that git transforms before storing it, such as one a clean filter encrypts, could reach the cloud as it is on disk. Claude Code refuses the upload instead, and nothing is uploaded:
+
+ Not uploading this working tree: core.ignoreCase (which decides whether .gitattributes patterns match file names regardless of letter case) is set in <file>, and the upload cannot follow that setting, so a file git would change before storing it (to encrypt it, for example) could be uploaded as it is on disk. Move the core.ignoreCase line into this repository’s .git/config or directly into your ~/.gitconfig, then retry.
+
+The message names the setting and where it’s set, and ends with the fix for the case you hit. The same refusal appears for `core.attributesFile` and `attr.tree`, each with its own fix. The message can name a config file that your git configuration pulls in through an `include` or `includeIf` directive, even when that directive’s condition doesn’t apply to this repository. **What to do:**
+
+ * Apply the fix in the message’s final sentence
+
+###
+
+
+
GitHub isn’t connected to your Claude account
You started a [cloud session](</docs/en/claude-code-on-the-web>) from your local repository, for example with `/autofix-pr`. No GitHub account is connected to your Claude account, or the connection expired, so Claude Code refuses the launch:
@@ -3380,7 +3467,7 @@
Plugin was not uninstalled
-You ran [`claude plugin uninstall`](</docs/en/plugins/cli-reference#plugin-uninstall>), or chose **Uninstall** in the `/plugin` **Installed** tab, and the uninstall stopped with a message starting `"<plugin>" was not uninstalled:`. When Claude Code removed the plugin’s entry from `enabledPlugins` and read that scope’s settings files back, either the plugin was still switched on there, or a file that could switch it on couldn’t be read or checked. Deleting the plugin’s saved options, secrets, and data while a settings entry could switch it back on would lose them, so the uninstall stops instead: the plugin stays installed and nothing it saved is deleted.
+You ran [`claude plugin uninstall`](</docs/en/plugins/cli-reference#plugin-uninstall>), or chose **Uninstall** in the `/plugin` **Installed** tab, and the uninstall stopped with a message starting `"<plugin>" was not uninstalled:`. If the text after that colon starts with `installed_plugins.json` instead of naming a settings file, the cause is content in `installed_plugins.json` that this version of Claude Code can’t read. For that form, see [`installed_plugins.json` holds a record this version can’t read](</docs/en/plugins/troubleshooting#installed-plugins-json-holds-a-record-this-version-cannot-read>). When Claude Code removed the plugin’s entry from `enabledPlugins` and read that scope’s settings files back, either the plugin was still switched on there, or a file that could switch it on couldn’t be read or checked. Deleting the plugin’s saved options, secrets, and data while a settings entry could switch it back on would lose them, so the uninstall stops instead: the plugin stays installed and nothing it saved is deleted.
✘ Failed to uninstall plugin "formatter": "formatter" was not uninstalled: it is still switched on in /home/user/project/.claude/settings.local.json, although the settings change reported no error. It is still installed. Take it out of "enabledPlugins" in that file yourself, then uninstall it again.
@@ -3577,6 +3664,31 @@
* If you prompted the burst yourself, ask Claude to combine what’s left into a single message
Before v2.1.236, Claude Code reported these sends as sent. The receiving session dropped them unread.
+
+###
+
+
+
+Cross-session message was dropped at the recipient session’s inbox
+
+Claude sent a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, and that session’s inbox discarded it before Claude in that session read it. The line names the recipient’s address and, when the recipient gave a reason, adds the reason after a dash:
+
+ Cross-session message was dropped at the recipient session's inbox (recipient: uds:/tmp/cc-socks/13605.sock) and not delivered — its queue of undelivered peer messages was full. Claude was told not to resend right away.
+
+One line can cover several dropped messages. It then starts in the plural, for example `Cross-session messages (12) were dropped`. To find which session an address belongs to, compare it with the [`Peer address` row](</docs/en/cross-session-messaging#the-sessions-inbox-socket>) that `/status` shows in each session. After the dash, the line gives one or more of these reasons:
+
+ * `its queue of undelivered peer messages was full`: the recipient already held as many undelivered messages from other sessions as its queue allows
+ * `you sent faster than that session accepts`: the sending session’s messages arrived faster than the recipient accepts from one sender
+ * `it repeated your previous message`: the message was identical to one the sending session sent this recipient shortly before
+ * `a relay loop between sessions was cut`: the message continued a chain of sessions messaging each other, and the chain had passed through the recipient too many times or grown too long
+
+**What to do:**
+
+ * Assume the recipient never saw the dropped messages. Claude Code tells Claude the same, and tells it to include anything that still matters in one later message instead of resending right away
+ * If your sessions send each other frequent updates, ask Claude to send fewer, larger messages, such as one report when a session finishes its work
+ * For `a relay loop between sessions was cut`, type the next instruction into one of the sessions yourself. A message Claude sends in response to your own prompt begins a new chain
+
+Before v2.1.238, the sending session got no report when the recipient’s inbox discarded a message.
###
Show diff (526 lines)
--- a/errors.md
+++ b/errors.md
@@ -21,7 +21,7 @@
`Connection lost mid-response` / `Your computer went to sleep mid-response` / `The response stopped arriving`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
`Part of the response never arrived` / `The response stream was malformed`| Server errors
-`API Error: Content block not found` / `API Error: Content block already closed`| Server errors
+`API Error: Content block not found` / `API Error: Content block already closed` / `API Error: Stream event unreadable`| Server errors
`Connection lost before a response was produced` / `Your computer went to sleep before a response was produced` / `The response stalled before a response was produced`| Automatic retries
`Connection closed while thinking` / `Response stalled while thinking`| Automatic retries
`Connection lost while your computer was asleep`| Automatic retries
@@ -130,7 +130,6 @@
`all upstreams failed (N attempted)` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
`Claude Code may not be enabled for your organization` after a Claude apps gateway sign-in| [Claude apps gateway troubleshooting](</docs/en/claude-apps-gateway-deploy#troubleshooting>)
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
-`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
@@ -166,7 +165,7 @@
`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
`<model>'s safeguards flagged this message`| Request errors
-`Opus 5.5's safeguards flagged this session`| Request errors
+`<model>'s safeguards flagged this session`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
@@ -255,9 +254,6 @@
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
-`Refusing to send: connected endpoint is not the expected process` / `Refusing to send: connected endpoint identity could not be read`| Tool errors
-`Refusing to send: connected endpoint is not owned by this user` / `Refusing to send: connected endpoint owner could not be read`| Tool errors
-`Refusing to send: connected endpoint is a different process with the expected pid`| Tool errors
`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
`Refusing to write through symlink: <path>` / `Refusing to write into symlinked directory: <path>`| Tool errors
@@ -335,7 +331,7 @@
Automatic retries
-Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure; the lists below say which failures get the full budget, which get a smaller one, and which get none. Claude Code retries these failures:
+Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure. Claude Code retries these failures:
* Server errors, overloaded responses, and request timeouts that arrive before any of Claude’s response has streamed.
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
@@ -441,7 +437,6 @@
This can happen during periods of high load or when the model is generating a very large response. The default request timeout is 10 minutes. **What to do:**
* Retry the request
- * For long-running tasks, break the work into smaller prompts
* If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
* If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
@@ -463,7 +458,7 @@
Neither wait exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
* Send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
- * If it repeats, treat it as a network or proxy problem. A proxy that accepts the connection and never forwards the request produces this error on every attempt.
+ * If it repeats, treat it as a network or proxy problem.
* If a proxy or gateway on your network holds responses until they complete, raise `API_TIMEOUT_MS` so the retry waits longer. On Amazon Bedrock, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` as well.
* If the first attempt keeps timing out and the retry then succeeds, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` so the first attempt waits long enough too.
@@ -488,13 +483,13 @@
* `Connection lost mid-response`: the connection dropped. You also see this variant when a proxy or gateway ends the response body cleanly before the response has finished.
* `Your computer went to sleep mid-response`: Claude Code detected that your computer went to sleep while the response was streaming. Once your computer wakes, Claude Code treats the connection as broken and stops reading from it.
* `Part of the response never arrived`: a stream event was dropped between the API and Claude Code, so a later event referenced content that never arrived. Before v2.1.281, this case ended the turn with `API Error: Content block not found`.
- * `The response stream was malformed`: an event arrived for a content block that had already finished.
+ * `The response stream was malformed`: an event arrived for a content block that had already finished, or an event arrived damaged. A damaged event is one whose data isn’t valid JSON, whose content is missing, or whose content doesn’t match the event’s type. Before v2.1.284, the parser’s raw error, such as one beginning `API Error: JSON Parse error`, appeared instead when an event with invalid JSON arrived after Claude had completed its thinking, a block of text, or a tool call.
* `The response stopped arriving`: the connection stayed open but stopped delivering data, so the streaming idle watchdog aborted it. Before v2.1.222, Claude Code could also report this failure on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because it counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. When a dropped or duplicated stream event arrives before Claude has started any text or tool call, you don’t see this notice:
+Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. When a dropped, duplicated, or damaged stream event arrives before Claude has started any text or tool call, you don’t see this notice:
* If Claude had completed only its thinking, Claude Code re-issues the request. When the re-issued streams break the same way, the turn ends with `Part of the response never arrived and no response was produced. Try again.` or `The response stream was malformed and no response was produced. Try again.`
- * If nothing had completed, Claude Code re-sends the request without streaming instead. If you turned that fallback off with [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK`](</docs/en/env-vars>), the turn ends with `API Error: Content block not found` for a dropped event or `API Error: Content block already closed` for a duplicated one.
+ * If nothing had completed, Claude Code re-sends the request without streaming instead. If you turned that fallback off with [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK`](</docs/en/env-vars>), the turn ends with `API Error: Content block not found` for a dropped event or `API Error: Content block already closed` for a duplicated one. For a damaged event with the fallback off, the turn ends with `API Error: Stream event unreadable` or the parser’s raw error.
In four cases, Claude Code handles the failure without showing this notice right away:
@@ -521,7 +516,7 @@
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
-When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. Rate-limited, overloaded, and server errors are transient, and retrying works. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
+When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
@@ -534,7 +529,7 @@
**What to do:**
* Retry the action; this usually succeeds on the next attempt
- * Run `claude --debug` and repeat the action to see the underlying classifier response in the debug log
+ * Run `claude --debug` and repeat the action for details in the debug log
When a separate API safety check blocked the classifier request because of earlier conversation content:
@@ -655,7 +650,7 @@
API Error: Usage credits required for 1M context · run /usage-credits to turn them on (they take effect after you restart Claude Code), or /model to switch to standard context
-In a session the Claude Desktop app runs, the hint names no commands: it points at the claude.ai usage settings page, or on Team and Enterprise plans says to turn on usage credits at claude.ai/admin-settings/usage or to ask your admin. This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
+In a session the Claude Desktop app runs, the hint names no commands: it points at the claude.ai usage settings page, or on Team and Enterprise plans says to turn on usage credits at claude.ai/admin-settings/usage or to ask your admin. This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
* Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Once usage credits are on, restart Claude Code or start a new session, whichever the message says. Until then, the session stays at the standard context limit.
@@ -915,7 +910,7 @@
* Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
* If the message says `Update or unset`, you have no saved login to fall back to. Unset the key and run `/login`, or replace the key with one from an active Console organization.
* Run `/status` afterward to confirm the active credential is your subscription
- * If no environment variable is set and the error persists, the disabled organization is the one tied to your `/login`. Contact support or sign in with a different account.
+ * If no environment variable is set and the error persists, contact support or sign in with a different account.
###
@@ -976,7 +971,7 @@
Remote Control requires the Anthropic API
-The session isn’t talking to the Anthropic API directly, so there is no claude.ai backend for [Remote Control](</docs/en/remote-control>) to pair with.
+The session isn’t talking to the Anthropic API directly, which [Remote Control](</docs/en/remote-control>) requires.
Remote Control is only available when using Claude via api.anthropic.com. CLAUDE_CODE_USE_BEDROCK is set, so this session is using Amazon Bedrock — unset it (or run in a shell without it) to use Remote Control.
@@ -1073,7 +1068,6 @@
**What to do:**
* Run `/login` to sign in again
- * If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
* If you authenticate with the `CLAUDE_CODE_OAUTH_TOKEN` environment variable, Claude Code keeps sending the value you set after a request fails with a 401, rather than switching to a stored login’s token. [`/status`](</docs/en/commands>) shows this credential as an `Auth token` row reading `CLAUDE_CODE_OAUTH_TOKEN`. Generate a fresh token with [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) and restart with it, or unset the variable and run `/login`. Before v2.1.225, Claude Code could replace the variable’s value mid-session with the short-lived access token from a stored login, and the session failed with 401 errors again once that token expired.
* For repeated prompts to log in across launches, see the system clock checks and macOS credential-storage recovery steps in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
@@ -1101,7 +1095,7 @@
Login expired
-Claude Code tried to renew your saved claude.ai or Claude Console login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each model request stops locally with this message before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the model request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
+Claude Code tried to renew your saved claude.ai login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each model request stops locally with this message before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the model request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
Login expired · Please run /login
@@ -1235,7 +1229,7 @@
Anthropic profile login expired · Re-authenticate your Anthropic profile
Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile
-This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with `/login`’s claude.ai option, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. On a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login`, choose the Anthropic Console account, and sign in again to renew a profile that the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote. Claude Code replaces the expired credential in that profile. For a federation profile or one another tool created, `/login` doesn’t renew the credential. Which form you see depends on whether you selected the profile or Claude Code discovered it:
+This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. On a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login`, choose the Anthropic Console account, and sign in again to renew a profile that the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote. Claude Code replaces the expired credential in that profile. For a federation profile or one another tool created, `/login` doesn’t renew the credential. Which form you see depends on whether you selected the profile or Claude Code discovered it:
* When you set `ANTHROPIC_PROFILE` explicitly, the message ends with `Re-authenticate your Anthropic profile`.
* When Claude Code discovered the profile from your configuration directory, the message offers `/login`, because Claude Code gives a working `/login` precedence over the discovered profile and then authenticates with your claude.ai or Console account instead. Before v2.1.234, Claude Code showed the `Re-authenticate your Anthropic profile` form in this case too.
@@ -1253,7 +1247,7 @@
OAuth scope requirement
-The stored token predates a permission scope that a newer feature needs. You see this most often from `/usage` and the status line usage indicator:
+The stored token predates a permission scope that a newer feature needs:
OAuth token does not meet scope requirement: user:profile
@@ -1267,7 +1261,7 @@
claude.ai rejected the session token
-A [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) request failed because claude.ai rejected the token from your Claude Code login, usually a login that expired and couldn’t be refreshed. The rejected token is your login, not the connector’s own authorization in claude.ai, so authorizing the connector again doesn’t resolve it. In `/mcp`, the connector shows as `connected · session token rejected` and its detail view reads:
+A [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) request failed because claude.ai rejected the token from your Claude Code login. The rejected token is your login, not the connector’s own authorization in claude.ai, so authorizing the connector again doesn’t resolve it. In `/mcp`, the connector shows as `session token rejected` and its detail view reads:
claude.ai rejected the session token. Run /login, then reconnect.
@@ -1352,7 +1346,7 @@
* If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
* Refresh your AWS credentials in case an expired credential is the cause: run the [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) command named in the message when one is set, or refresh your SSO sign-in, access keys, API key, or proxy token yourself
* If your credentials are current, confirm the IAM permissions in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>) are attached to the identity you’re using and that the selected model is enabled for your account and region
- * Run `aws sts get-caller-identity` to confirm which identity your requests use; a stale `AWS_PROFILE` or default profile is a common cause of a permission mismatch
+ * Run `aws sts get-caller-identity` to confirm which identity your requests use
###
@@ -1439,7 +1433,7 @@
Common causes are a `credential_process` command in your AWS profile that waits for input it can’t receive, and a container or VM whose instance metadata service (IMDS) never answers the chain’s probe. Before v2.1.267, the message read `API Error: AWS default-chain credential resolve timed out`. Before v2.1.207, a stalled chain left the request waiting indefinitely instead of failing. **What to do:**
* Run `aws sts get-caller-identity` in the same shell with the same `AWS_PROFILE`. If it also hangs, fix the profile; a `credential_process` command that prompts interactively is a common cause.
- * Complete the sign-in step before starting Claude Code, for example `aws sso login --profile myprofile`, so the chain resolves from the local SSO cache instead of waiting on a browser flow
+ * Complete the sign-in step before starting Claude Code, for example `aws sso login --profile myprofile`
* If your chain runs an interactive sign-in that legitimately needs more than 60 seconds, such as SSO with MFA through a wrapper like `aws-vault`, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
###
@@ -1534,7 +1528,6 @@
No internet route — check your connection or VPN (EHOSTUNREACH)
Couldn't connect through your proxy (ERR_PROXY_TUNNEL) — the proxy refused the tunnel: check its credentials and that it allows this host
Connection dropped (ECONNRESET)
- fetch failed
Request timed out. Check your internet connection and proxy settings
A code Claude Code doesn’t recognize appears as `Unable to connect to API` followed by the code in parentheses. Some of these messages can show more than one code: `Connection refused` can show `ConnectionRefused` or `ECONNREFUSED`, for example, and `Can't reach the API server` can show `ENOTFOUND` or `FailedToOpenSocket`. Before v2.1.227, each of these coded messages read `Unable to connect to API` followed by the code, for example `Unable to connect to API (ECONNREFUSED)`. Common causes include no internet access, a VPN that blocks `api.anthropic.com`, or a required corporate proxy that is not configured. **What to do:**
@@ -1569,7 +1562,6 @@
* If the message names a proxy variable, check that its value points at the right proxy and ask your network team to allow HTTPS connections through it to the host in the message. See [Network configuration](</docs/en/network-config>).
* Work through the checks in Unable to connect to API. The `curl` test and firewall guidance there apply to this check too.
- * If your organization signs in through a [cloud gateway](</docs/en/claude-apps-gateway>) and this error appears on first run, update to Claude Code v2.1.247 or later.
* If your network is open and the failure persists, Claude Code may not be [available in your country](<https://www.anthropic.com/supported-countries>)
###
@@ -1603,7 +1595,7 @@
* Read the `Response:` clause to see which system answered. An HTML body, no Anthropic request id, or a named server such as `nginx` or `cloudflare` means that something between Claude Code and the API replied in its place
* If you route through an [LLM gateway](</docs/en/llm-gateway-connect#troubleshoot-gateway-errors>), test the route with a direct request and fix the hop that returns the non-API response
* On a network with a sign-in page, such as guest Wi-Fi, complete the sign-in in a browser, then retry
- * If only the non-streaming route through your gateway is broken, set [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK=1`](</docs/en/env-vars#variables>) so a request that fails mid-stream goes to the normal retry path instead of this fallback, except when the streaming endpoint itself returns `404`, where Claude Code still falls back
+ * If only the non-streaming route through your gateway is broken, set [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK=1`](</docs/en/env-vars#variables>) to turn off this fallback, except when the streaming endpoint itself returns `404`, where Claude Code still falls back
###
@@ -1761,7 +1753,7 @@
Couldn't share the transcript.
-The upload must fit an 8 MiB limit. On a long session, Claude Code progressively drops parts of the share, the last request’s model settings first, then the structured conversation and subagent transcripts, and shows this message only when no reduced version can be sent or a network or server error stops the upload. When Claude Code saves a local archive instead, the message means it couldn’t write the archive. **What to do:**
+The upload must fit an 8 MiB limit. On a long session, Claude Code progressively drops parts of the share, the last request’s model settings first, then the structured conversation and subagent transcripts, and shows this message when no reduced version can be sent or a network or server error stops the upload. When Claude Code saves a local archive instead, the message means it couldn’t write the archive. **What to do:**
* Run `/feedback` to send the transcript with a description of what happened. See Report an error if `/feedback` is unavailable in your environment
* If other requests are failing too, check your network connection and see Unable to connect to API
@@ -1842,7 +1834,6 @@
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
- * Subagents inherit every MCP tool definition from the parent session, which can fill their context window before the first turn. Disable MCP servers you are not using before spawning subagents.
* Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
@@ -1867,23 +1858,6 @@
* For more ways to reduce usage, see Prompt is too long
Before v2.1.216, `/context` showed usage above 100% with no warning line explaining what that meant or how to recover.
-
-###
-
-
-
-Error during compaction: Conversation too long
-
-`/compact` itself failed because there is not enough free context to hold the summary it produces.
-
- Error during compaction: Conversation too long. Press esc twice to go up a few messages and try again.
-
-This can happen when the window is already full at the moment auto-compact triggers, or when you run `/compact` after seeing `Prompt is too long`. In an interactive session, that error is the `Context limit reached` line. **What to do:**
-
- * Press Esc twice to open the message list and step back several turns. This drops the most recent messages from context. Then run `/compact` again.
- * If stepping back doesn’t free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
-
-This message and other `/compact` failures display in error styling. Before v2.1.216, they rendered in the same dim style as successful command output, so you could read a failed compaction as a success.
###
@@ -1971,7 +1945,6 @@
A proxy or LLM gateway between Claude Code and the API stripped the `anthropic-beta` request header, so the API rejected fields that depend on it.
API Error: 400 ... Extra inputs are not permitted ... context_management
- API Error: 400 ... Unexpected value(s) for the `anthropic-beta` header
Claude Code sends beta-only fields such as `context_management` and `effort` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
@@ -2028,7 +2001,6 @@
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
- * A newly launched model can be available on the Anthropic API before Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry offers it. If you pinned a new model ID on one of those providers and see this error, check your provider’s model catalog for availability in your region, and keep the previous version pinned until the new one appears there.
* Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
@@ -2181,9 +2153,9 @@
**What to do:**
- * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later. Opus 5.5 needs v2.1.280 or later
+ * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later. Opus 5.5 needs v2.1.280 or later. Sonnet 5.5 needs v2.1.284 or later
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
- * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later
+ * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later. Sonnet 5.5 needs TypeScript SDK v0.3.284 or later
###
@@ -2200,7 +2172,7 @@
* [Lower the effort level](</docs/en/model-config#set-the-effort-level>) to `high` or below.
* Turn thinking back on, for example by unsetting [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) or removing [`"alwaysThinkingEnabled": false`](</docs/en/settings-reference#alwaysthinkingenabled>) from your settings.
-Before v2.1.242, Claude Code showed the API’s own message: `API Error: 400 output_config.effort 'xhigh' is not supported when thinking is disabled on this model. Use effort 'high' or below, or enable thinking.` Before v2.1.251, Claude Code sent the request at the effort level you set, so Opus 5 rejected every request above `high` with thinking turned off. Claude Code now sends effort `high` instead to models it knows reject the combination, such as Opus 5, so on v2.1.251 or later this error reaches you only from a model Claude Code doesn’t know rejects it.
+Before v2.1.242, Claude Code showed the API’s own message: `API Error: 400 output_config.effort 'xhigh' is not supported when thinking is disabled on this model. Use effort 'high' or below, or enable thinking.` Before v2.1.251, Claude Code sent the request at the effort level you set, so Opus 5 rejected every request above `high` with thinking turned off. Claude Code now sends effort `high` instead to models it knows reject the combination, such as Opus 5.
###
@@ -2212,9 +2184,9 @@
API Error: 400 ... max_tokens must be greater than thinking.budget_tokens
-Claude Code adjusts these values automatically on the Anthropic API. You typically see this error on Amazon Bedrock or Google Cloud’s Agent Platform when [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) is set higher than the provider’s output limit, or when plan mode raises the thinking budget. **What to do:**
-
- * Lower `MAX_THINKING_TOKENS`, or raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
+**What to do:**
+
+ * Raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
* See [Extended thinking](</docs/en/model-config#extended-thinking>) for how the budget interacts with output length
###
@@ -2223,7 +2195,7 @@
Tool use or thinking block mismatch
-The conversation history reached the API in an inconsistent state, usually after a tool call was interrupted or a turn was edited mid-stream.
+The conversation history reached the API in an inconsistent state.
API Error: 400 due to tool use concurrency issues. Run /rewind to recover the conversation.
API Error: 400 orphaned tool_result in conversation history. Run /rewind to recover the conversation.
@@ -2276,10 +2248,10 @@
API Error: 400 messages.6: role 'system' must precede an 'assistant' message or end the array; ...
-Claude Code sends some of its reminder and attachment text as system messages inside the conversation. When the API refuses one’s position, Claude Code retries the request once with that text sent as ordinary user messages instead. The API’s sibling placement wordings, such as `use the top-level 'system' parameter for the initial system prompt`, get the same recovery. When the error does appear, the refused system message isn’t one Claude Code can remove. That usually means a proxy or [LLM gateway](</docs/en/llm-gateway>) between Claude Code and the API added a system message of its own or reordered the conversation. **What to do:**
-
+Claude Code sends some of its reminder and attachment text as system messages inside the conversation. When the API refuses one’s position, Claude Code retries the request once with that text sent as ordinary user messages instead. The API’s sibling placement wordings, such as `use the top-level 'system' parameter for the initial system prompt`, get the same recovery. When the error does appear, the refused system message isn’t one Claude Code can remove. That usually means a proxy or [LLM gateway](</docs/en/llm-gateway>) between Claude Code and the API added a system message of its own. **What to do:**
+
+ * If the error repeats on every turn behind a proxy or gateway configured through [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>), connect without the proxy to confirm the source, and report the error to whoever operates it
* Run `/clear` to start a fresh conversation. If the error returns there too, the cause is on the request path, not in the saved conversation.
- * If the error repeats on every turn behind a proxy or gateway configured through [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>), connect without the proxy to confirm the source, and report the error to whoever operates it
Before v2.1.280, Claude Code didn’t recognize this wording, so the error also appeared when the refused system message was one Claude Code itself sent, and every later turn of the conversation failed the same way.
@@ -2330,7 +2302,7 @@
API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5, which requires v2.1.280 or later, the message opens with `Opus 5.5's safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5 and Sonnet 5.5, the message opens with `<model>'s safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
@@ -2366,11 +2338,11 @@
The connection dropped while downloading the update
-The connection to the download server closed while `claude install`, `claude update`, or the [automatic updater](</docs/en/setup#auto-updates>) was fetching the Claude Code binary, and the retries didn’t recover. Claude Code retries the download when the connection drops, the transfer stalls, or the downloaded file fails its checksum, up to three attempts in total. A completed HTTP error, such as a 404, isn’t retried because the server already answered. Before v2.1.202, a single dropped connection failed the download immediately with the bare error `aborted` instead of retrying.
+The connection to the download server closed while `claude install` or `claude update` was fetching the Claude Code binary, and the retries didn’t recover. Claude Code retries the download when the connection drops, the transfer stalls, or the downloaded file fails its checksum, up to three attempts in total. A completed HTTP error, such as a 404, isn’t retried because the server already answered. Before v2.1.202, a single dropped connection failed the download immediately with the bare error `aborted` instead of retrying.
The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
-The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
+The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. A proxy or gateway can close a long transfer before it finishes, and the Claude Code binary is a large download. **What to do:**
* Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run. For the timed-out message, run it again from a faster or less throttled network.
* If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](</docs/en/troubleshoot-install#check-network-connectivity>).
@@ -2406,7 +2378,7 @@
Invalid —agents configuration
-The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway and left out the definitions it couldn’t load.
+The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway.
Error: Invalid --agents configuration:
<what failed>
@@ -2471,7 +2443,6 @@
The text after the second colon is the validator’s diagnostic and names the keyword or location that failed. Schemas that use the `format` keyword, such as `"format": "email"`, are valid: Claude Code accepts `format` as an annotation and doesn’t enforce it. Claude Code runs two checks before schema compilation: it rejects a value that isn’t parseable JSON with `Error: --json-schema is not valid JSON`, and valid JSON that isn’t an object with `Error: --json-schema must be a JSON object`. **What to do:**
* Fix the part of the schema the diagnostic names, then rerun the command
- * If the diagnostic is `schema too large`, reduce the schema’s nesting and `$ref` reuse
* See [Get structured output](</docs/en/headless#get-structured-output>) for a working schema and command
###
@@ -2480,7 +2451,7 @@
Settings file exceeds the 2MiB limit
-The file you passed to [`--settings`](</docs/en/cli-reference#cli-flags>) is larger than 2 MiB, so `claude` exits with code 1 at startup instead of loading it. A settings file is a small JSON document, so a file this large usually means the path points at the wrong file. Before v2.1.214, Claude Code read the file with no size check, and a multi-gigabyte file or a device file such as `/dev/zero` grew memory without bound.
+The file you passed to [`--settings`](</docs/en/cli-reference#cli-flags>) is larger than 2 MiB, so `claude` exits with code 1 at startup instead of loading it. Before v2.1.214, Claude Code read the file with no size check, and a multi-gigabyte file or a device file such as `/dev/zero` grew memory without bound.
Error: Settings file exceeds the 2MiB limit: /path/to/settings.json
@@ -2551,18 +2522,20 @@
Workspace not trusted when starting Remote Control
-You started [Remote Control](</docs/en/remote-control>) server mode with `claude remote-control` or its `claude rc` alias in a directory you haven’t trusted. The command doesn’t show the workspace trust dialog itself, so it exits with code 1 and names the fix:
+You started [Remote Control](</docs/en/remote-control>) server mode with `claude remote-control` or its `claude rc` alias in a directory you haven’t trusted, and the command couldn’t ask you whether to trust it. For example, the command’s standard input or standard output isn’t a terminal because one of them is redirected or piped. The command exits with code 1:
Error: Workspace not trusted. Please run `claude` in /Users/you/project first to review and accept the workspace trust dialog.
-In your home directory the message is different, because the workspace trust dialog never saves trust for the home directory, so accepting it there can’t satisfy this check. Before v2.1.214, the home directory showed the message above, whose advice can’t succeed there.
+Two variants that also begin with `Error: Workspace not trusted.` appear in a terminal too small to show what trusting the directory turns on, or one that didn’t report its size. Enlarge the window or switch to a normal terminal window, then run `claude rc` again. In your home directory the message is different, because the workspace trust dialog never saves trust for the home directory, so accepting it there can’t satisfy this check. Before v2.1.214, the home directory showed the message above, whose advice can’t succeed there.
Error: Workspace not trusted. /Users/you is your home directory, and for security home-directory trust is never saved, so running `claude` here first won't help. Run `claude rc` from a project directory instead (run `claude` there once to accept the trust dialog).
-**What to do:**
-
- * Run `claude` in the directory, accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run `claude remote-control` again
+If you answer `n` or press Enter at the [`Trust <directory>?` question](</docs/en/remote-control#requirements>), the command prints a `Remote Control did not start` message that names the directory and exits with code 1. Run `claude rc` again to answer `y`. **What to do:**
+
+ * Trust the directory from a terminal first: run `claude rc` there and answer `y`, or run `claude` there and accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run your original command again
* In your home directory, change to a project directory and start Remote Control there
+
+Before v2.1.284, the command never asked, even in a terminal.
###
@@ -2623,7 +2596,7 @@
Could not import a server from Claude Desktop
-Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import and none of the selected servers were added.
+Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import.
Could not import my server: Invalid name my server. Names can only contain letters, numbers, hyphens, and underscores.
@@ -2699,11 +2672,11 @@
MCP permission prompt tool not found
-The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call that needs approval, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
+The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
Error: MCP tool mcp__permissions__approve (passed via --permission-prompt-tool) not found. Available MCP tools: none
-The list after `Available MCP tools:` names the MCP tools that were connected when the wait ended. **What to do:**
+The list after `Available MCP tools:` names the MCP tools that were connected. **What to do:**
* Check that the server starts and stays connected: run `claude mcp list` in the same directory and confirm the server is listed as connected
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
@@ -3182,7 +3155,7 @@
Marketplace is registered from an untrusted source
-The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugins/marketplace-reference#marketplace-file>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, the name was checked only when the marketplace was added, so an entry registered before its name became reserved kept loading.
+The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugins/marketplace-reference#marketplace-file>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, an entry registered before its name became reserved kept loading.
Marketplace "claude-community" is registered from an untrusted source: The name 'claude-community' is reserved for official Anthropic marketplaces. Only repositories from 'github.com/anthropics/' can use this name. To fix it, remove the marketplace and re-add it from the official source.
@@ -3619,21 +3592,11 @@
* `reply target is a symlink`: a symbolic link sits at the target session’s socket path. Claude Code doesn’t deliver through it, because a link there could redirect the message to an endpoint the target session didn’t create.
* `cannot vet reply target`: Claude Code couldn’t inspect the target path at all, for example because reading it failed with a permission error.
- * `connected endpoint is not the expected process`: the process holding the socket isn’t the session the message was addressed to, so the address is stale or another process replaced the socket.
- * `connected endpoint identity could not be read`: Claude Code connected but couldn’t read which process holds the other end, so it couldn’t confirm the target. This can be transient.
- * `connected endpoint is not owned by this user`: the process holding the socket runs as a different user account, so it isn’t one of your sessions.
- * `connected endpoint owner could not be read`: Claude Code connected but couldn’t read which user account owns the other end, so it couldn’t confirm the endpoint is yours.
- * `connected endpoint is a different process with the expected pid`: the process id matches the one the message was addressed to, but Claude Code couldn’t confirm it’s the same process. Usually that session exited and the operating system reused its process id, so the address is stale.
**What to do:**
* Usually nothing: the checks keep a message from reaching an endpoint other than the session it was addressed to, and nothing was sent
- * Ask Claude to list your sessions again and resend; a refusal caused by a stale address clears once Claude sends to the current one
* If `reply target is a symlink` repeats for one session, check what created a link at that session’s socket path, shown in its `/status` under `Peer address`
- * For `connected endpoint identity could not be read`, resend; the condition can be transient
- * If `connected endpoint is not owned by this user` appears on a shared machine, the session at that address runs under another user’s account, so Claude can’t message it from yours
-
-Before v2.1.248, Claude Code didn’t check the endpoint’s owning user or process start time, so the refusals that name those checks don’t appear on earlier versions.
###
@@ -3778,13 +3741,13 @@
Commands refused in a background session
-Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message, and the session appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, the session didn’t appear under **Needs input** after one of these refusals. In v2.1.213 through v2.1.215, the commands still worked while a terminal was attached, and the refusal message told you to attach and run the command again. From v2.1.208 through v2.1.212, Claude Code refused them even while a terminal was attached, with a message such as `Can't open MCP settings in a background session`; on those versions, run the command from a regular `claude` session instead, or upgrade. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
+Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message. For `/install-github-app` and the `/mcp` settings list, the session also appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, the session didn’t appear under **Needs input** after `/install-github-app` or the `/mcp` settings list was refused. In v2.1.213 through v2.1.215, the commands still worked while a terminal was attached, and the refusal message told you to attach and run the command again. From v2.1.208 through v2.1.212, Claude Code refused them even while a terminal was attached, with a message such as `Can't open MCP settings in a background session`; on those versions, run the command from a regular `claude` session instead, or upgrade. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
Can't open MCP settings while no terminal is attached to this background session. This session now shows "needs input" in agent view — open it and run /mcp to manage servers, or use `/mcp enable|disable|reconnect <server>` to steer without the panel.
**What to do:**
- * Attach to the session from agent view, where it’s listed under **Needs input** , and run the command again
+ * Attach to the session from agent view and run the command again
* Or use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`, which work without attaching
###
@@ -3815,7 +3778,6 @@
A blocked command reports the same cause for its working directory and ends with `re-run the command from its local, plainly-spelled path`. Before v2.1.217, the guard compared path text only, so addressing a file inside the checkout through a UNC or `/net` path wasn’t blocked. **What to do:**
* Usually nothing: Claude retries with the local spelling the message asks for
- * If the file is on a network share rather than a local file spelled with a network path, it’s outside the session’s local workspace; edit it from a regular interactive session instead
###
@@ -4010,11 +3972,11 @@
Couldn't reach the background service (spawn background service: EUNKNOWN: unknown error, uv_spawn) — run 'claude daemon status'
-On some accounts the message says `daemon` in place of `background service`. On an npm installation, an `EUNKNOWN` that appears while `npm install -g @anthropic-ai/claude-code` is replacing the binary has the same cause as `EACCES` during a reinstall and clears when you retry after the install finishes. Claude Code starts the background service through PowerShell so the service survives closing the terminal, using PowerShell 7 when it’s installed and Windows PowerShell 5.1 otherwise. When neither PowerShell can run, Claude Code starts the service directly instead, so a policy that blocks only PowerShell doesn’t cause this error. If you see it while no npm install is running, the policy is blocking the Claude Code executable itself. Before v2.1.212, Claude Code used only Windows PowerShell 5.1 to start the service, so any machine where Group Policy blocked PowerShell 5.1 failed with `Couldn't start the session — EUNKNOWN: unknown error, uv_spawn`, even with PowerShell 7 installed. **What to do:**
+On some accounts the message says `daemon` in place of `background service`. On an npm installation, an `EUNKNOWN` that appears while `npm install -g @anthropic-ai/claude-code` is replacing the binary has the same cause as `EACCES` during a reinstall and clears when you retry after the install finishes. Claude Code starts the background service through PowerShell so the service survives closing the terminal, using PowerShell 7 when it’s installed and Windows PowerShell 5.1 otherwise. When neither PowerShell can run, Claude Code starts the service directly instead, so a policy that blocks only PowerShell doesn’t cause this error. Before v2.1.212, Claude Code used only Windows PowerShell 5.1 to start the service, so any machine where Group Policy blocked PowerShell 5.1 failed with `Couldn't start the session — EUNKNOWN: unknown error, uv_spawn`, even with PowerShell 7 installed. **What to do:**
* If the message reads `Couldn't start the session`, upgrade to v2.1.212 or later. On earlier versions you can also run `claude daemon run` in a separate terminal first, then start the background session again. That command runs the background service in the terminal’s foreground, so the service lasts only as long as that terminal stays open.
* If an npm install was replacing the binary, wait for it to finish, then start the background session again
- * If the error appears on v2.1.212 or later while no npm install is running, ask your Windows administrator to allow the Claude Code executable in the restriction policy
+ * If the error appears on v2.1.212 or later while no npm install is running, check with your Windows administrator whether a restriction policy blocks the Claude Code executable
* If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
###
@@ -4062,11 +4024,11 @@
Working directory no longer exists when starting a background session
-You tried to start a [background session](</docs/en/agent-view>) in a directory that doesn’t exist anymore. Claude Code doesn’t start the session, and the message names the missing directory:
+The directory you started a [background session](</docs/en/agent-view>) in was removed while the session was starting. Claude Code doesn’t start the session, and the message names the missing directory:
Couldn't start a background session (working directory no longer exists or is not accessible: /tmp/demo)
-Before v2.1.257, the session appeared to start and then showed in agent view as a failed row with the same reason. **What to do:**
+Before v2.1.257, the session appeared to start and then showed in agent view as a failed row with the same reason. Before v2.1.281, this message also appeared when the directory was already gone before you started the session. That case reports `could not be resolved on disk`. **What to do:**
* Recreate the directory the message names, or dispatch from a directory that exists, then try again
@@ -4175,7 +4137,7 @@
* Identify which files were skipped so you can handle each one with the steps below. The message gives only a count; the debug log at `~/.claude/debug/<session-id>.txt` names each skipped path as the restore runs, so turn on debug logging with `/debug` before your next restore. On macOS or Linux, you can instead find the links directly: `find . -type l` for symlinks and `find . -type f -links +1` for hard-linked files.
* If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
- * If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
+ * If you didn’t create the link, inspect the path before trusting its contents
###
@@ -4663,7 +4625,7 @@
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
- * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, Opus 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, Opus 5.5, Sonnet 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
Show diff (116 lines)
--- a/errors.md
+++ b/errors.md
@@ -225,6 +225,8 @@
`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
+`Claude Code refuses the marketplace name "<name>"`| Plugin errors
+`Marketplace name impersonates an official Anthropic/Claude marketplace`| Plugin errors
`Marketplace "<name>" is already added from a different source`| Plugin errors
`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
@@ -238,6 +240,8 @@
`Failed to load marketplace configuration`| Plugin errors
`Marketplace configuration file is corrupted`| Plugin errors
`Plugin "<name>@synced" is required by your organization and can't be disabled here`| Plugin errors
+`"<plugin>" was not uninstalled: it is still switched on in <file>`| Plugin errors
+`"<plugin>" was not uninstalled: <file> is there and could not be read`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`cannot contain null bytes (\0)`| Tool errors
@@ -257,6 +261,7 @@
`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
`Refusing to write through symlink: <path>` / `Refusing to write into symlinked directory: <path>`| Tool errors
+`Refusing to write <path>: where it leads on disk could not be determined` / `Refusing to read <path>: where it leads on disk could not be determined`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
@@ -1189,7 +1194,7 @@
Not signed in to the Cloud gateway — run /login.
-Model requests fail with this message when the session has no gateway sign-in, for example because you haven’t run `/login` since the policy reached the machine. If you also have an `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` credential configured and the managed settings set `forceLoginMethod`, Claude Code exits at startup instead with a message that begins:
+Model requests fail with this message when the session has no gateway sign-in, for example because you haven’t run `/login` since the policy reached the machine. If the machine also holds an Anthropic-issued credential and the managed settings set `forceLoginMethod` or `forceLoginOrgUUID`, Claude Code exits at startup instead. That credential can be an `ANTHROPIC_API_KEY` or `ANTHROPIC_AUTH_TOKEN` variable, an `apiKeyHelper` setting, or an API key saved by an earlier Claude Console login. The message begins:
Administrator policy requires a Cloud gateway sign-in on this machine; the
Anthropic-issued credential configured here (ANTHROPIC_API_KEY,
@@ -1198,7 +1203,7 @@
**What to do:**
* Run `/login` and complete the sign-in on the **Cloud gateway** screen
- * For the startup message, remove the `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` setting you configured, then start `claude` and run `/login`
+ * For the startup message, remove the `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` setting you configured. To remove a saved Console API key, run `claude auth logout`, which also removes a saved claude.ai login. If you select a cloud provider with `CLAUDE_CODE_USE_*`, the session then starts with no sign-in. Otherwise start `claude` and run `/login`
* If you believe the machine shouldn’t require the gateway, ask the administrator who manages it to remove `forceLoginMethod` and `forceLoginGatewayUrl` from its managed settings
On v2.1.265, a regression also showed the first message in some LLM-gateway and proxy configurations that authenticate with an API key, `apiKeyHelper`, or custom headers, even with no administrator requirement on the machine. Update to v2.1.266 or later. You don’t need to change your configuration. Before v2.1.261, on machines that set `forceLoginMethod` to `"gateway"`, Claude Code used a leftover saved login instead of failing model requests, and reported a configured environment credential with `This machine's managed settings require a first-party login` instead of the startup message. Before v2.1.265, a machine whose managed settings set only `forceLoginGatewayUrl` didn’t require the gateway sign-in, and Claude Code used a leftover credential there.
@@ -3210,6 +3215,22 @@
+Claude Code refuses the marketplace name
+
+A registered marketplace’s name [impersonates an official Anthropic marketplace](</docs/en/plugins/marketplace-reference#reserved-names>) under the rules that section lists. If a marketplace was registered under such a name before the check blocked it, the marketplace and the plugins installed from it stop loading, because Claude Code checks the name every time it reads the marketplace’s catalog. When the name imitates an official one, `claude plugin list` and the `/plugin` **Errors** tab report each affected plugin with a message that begins:
+
+ Claude Code refuses the marketplace name "anthropic-plugins-v2"
+
+For an imitating name, the marketplace’s own error reads `Claude Code refuses this marketplace's name: it looks like one of Anthropic's own` instead. `claude plugin marketplace add` refuses any impersonating name with `Marketplace name impersonates an official Anthropic/Claude marketplace`. Before v2.1.282, `claude plugin list` and `/plugin` reported the plugins of an imitating name as failed to load too, without naming the marketplace’s name as the cause. **What to do:**
+
+ * Run `claude plugin marketplace remove <name>`. This also uninstalls the plugins installed from the marketplace and deletes their saved data
+ * To keep the marketplace instead, wait until its maintainer renames it, then run `claude plugin marketplace update <name>`
+ * If you publish the marketplace, rename it in your `marketplace.json`; users then update the marketplace instead of removing it
+
+###
+
+
+
Marketplace is already added from a different source
You confirmed adding a marketplace through [`/plugin install <plugin> --marketplace <source>`](</docs/en/plugins/install#add-a-marketplace-and-install-in-one-command>), and the catalog Claude Code fetched from that source names itself the same as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
@@ -3379,6 +3400,27 @@
Claude Code saves nothing and the plugin stays enabled. When you try to disable a plugin that a required plugin depends on, Claude Code refuses the same way, with a message naming the required plugin that needs it. **What to do:**
* Ask an admin of your claude.ai organization to change the plugin’s required status on claude.ai
+
+###
+
+
+
+Plugin was not uninstalled
+
+You ran [`claude plugin uninstall`](</docs/en/plugins/cli-reference#plugin-uninstall>), or chose **Uninstall** in the `/plugin` **Installed** tab, and the uninstall stopped with a message starting `"<plugin>" was not uninstalled:`. When Claude Code removed the plugin’s entry from `enabledPlugins` and read that scope’s settings files back, either the plugin was still switched on there, or a file that could switch it on couldn’t be read or checked. Deleting the plugin’s saved options, secrets, and data while a settings entry could switch it back on would lose them, so the uninstall stops instead: the plugin stays installed and nothing it saved is deleted.
+
+ ✘ Failed to uninstall plugin "formatter": "formatter" was not uninstalled: it is still switched on in /home/user/project/.claude/settings.local.json, although the settings change reported no error. It is still installed. Take it out of "enabledPlugins" in that file yourself, then uninstall it again.
+
+The middle of the message names the file and the cause:
+
+ * `it is still switched on in <file>, although the settings change reported no error`: the settings write reported success but the entry is still there when the file is read back
+ * `it is still switched on in <file>, and the settings change failed (<error>)`: the file couldn’t be saved, for the reason in parentheses
+ * `<file> is there and could not be read`: the file exists but couldn’t be read as settings, for example because it isn’t valid JSON, so it may still enable the plugin
+ * `<file> (not read: it is on a network path or is a link to one, or could not be checked)`: Claude Code didn’t read the project or local settings file because the file, or the `.claude` folder that holds it, is a link that leads to a network location, or because it couldn’t examine that path
+
+`claude plugin uninstall` exits 1, and with `--json` the result carries `failureCode: "settings_still_on"`. `/plugin` shows the same message. **What to do:**
+
+ * Follow the last sentence of the message: repair or replace the settings file it names, or remove the plugin’s entry from `enabledPlugins` in that file yourself, then run the uninstall again
##
@@ -3607,7 +3649,8 @@
* `its symlink resolution changed after permission was checked`: a symlink along the path, or at a Grep or Glob search root, was replaced between the permission check and the operation. In a read refusal, the parenthesized phrase names which comparison failed.
* `its parent-directory symlink resolution changed after permission was checked`: a directory the write path passes through no longer resolves to the approved location
- * `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the approved write location itself, for example a `CLAUDE.md` that is a symlink to `AGENTS.md`; the message directs Claude to the link’s target
+ * `where it leads on disk could not be determined (a link on the way could not be examined, or the links do not resolve)`: Claude Code couldn’t follow the path to a final location on disk, for example because symlinks on it form a loop
+ * `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the requested write location itself, for example a `CLAUDE.md` that is a symlink to `AGENTS.md`; the message directs Claude to the link’s target
* `Refusing to write through symlink: <path>. Resolve the symlink and pass the real target path explicitly.`: the same condition caught when another writer opens the file, such as a write to a symlinked `.mcp.json`
* `Refusing to write into symlinked directory: <path>`: the directory that holds the file is itself a symbolic link, for example a project’s `.claude/` directory linked to another location
* `a path one of its Read deny rules is written through changed while the search was being prepared. Retry.`: a `Read` deny rule for the search names a path that passes through a symlink, and that link changed while Claude Code was preparing the search
@@ -3623,7 +3666,7 @@
* If a read refusal appears on macOS for a file that nothing is rewriting, such as a screenshot dragged into the prompt, upgrade to v2.1.273 or later
* For the ripgrep refusal, install ripgrep with your package manager so `rg` resolves to an absolute path on `PATH`, or keep searches under the working directory
-Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these, only the parent-directory, through-symlink, and symlinked-directory write refusals appear on earlier versions.
+Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these, only the parent-directory, through-symlink, and symlinked-directory write refusals appear on earlier versions. Before v2.1.280, the `where it leads on disk could not be determined` refusal didn’t appear.
###
Show diff (655 lines)
--- a/errors.md
+++ b/errors.md
@@ -14,11 +14,14 @@
---|---
`API Error: 500 Internal server error`| Server errors
`API Error: Repeated 529 Overloaded errors`| Server errors
+`Opus is experiencing high load` / `Fable is experiencing high load`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`API Error: No response from API`| Server errors
`Server error mid-response. The response above may be incomplete.`| Server errors
`Connection lost mid-response` / `Your computer went to sleep mid-response` / `The response stopped arriving`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
+`Part of the response never arrived` / `The response stream was malformed`| Server errors
+`API Error: Content block not found` / `API Error: Content block already closed`| Server errors
`Connection lost before a response was produced` / `Your computer went to sleep before a response was produced` / `The response stalled before a response was produced`| Automatic retries
`Connection closed while thinking` / `Response stalled while thinking`| Automatic retries
`Connection lost while your computer was asleep`| Automatic retries
@@ -39,6 +42,8 @@
`Could not update your spend limit`| Usage limits
`spend limit reached` / `spend limit unavailable`| Usage limits
`Not logged in · Please run /login`| Authentication
+`Couldn't save your login`| Authentication
+`Authentication required · Sign in again to continue`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`Your apiKeyHelper script is failing`| Authentication
@@ -59,6 +64,7 @@
`signed-in claude.ai account or organization changed on this machine`| Authentication
`Remote Control stopped — the app running this session is now signed in to a different Claude account`| Authentication
`Remote Control stopped — the app running this session is signed out of Claude`| Authentication
+`Couldn't verify your organization's policy for remote control`| [Troubleshoot Remote Control](</docs/en/remote-control#couldnt-verify-your-organizations-policy-for-remote-control>)
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
@@ -67,6 +73,8 @@
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
+`Could not refresh your login because another Claude Code process is refreshing it`| Authentication
+`Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh`| Authentication
`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
@@ -110,6 +118,7 @@
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
+`Couldn't send feedback`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
`Prompt is too long · this conversation is a single exchange` / `A single-exchange conversation cannot be compacted`| Request errors
@@ -129,13 +138,16 @@
`PDF too large` / `PDF is password protected`| Request errors
`Extra inputs are not permitted`| Request errors
`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid` / `Property keys should match pattern`| Request errors
+`tool_use.name: String should have at most 200 characters`| Request errors
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
`Model ... not found`| Request errors
+`API error: ... · model not changed`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
`Claude Code ... does not support this model; version ... or newer is required`| Request errors
`Claude Code ... is older than the minimum version required by your organization's policy`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
+`Model ... is not available. Your organization restricts model selection.`| Request errors
`Model switch ... blocked by a PreModelSwitch hook`| Request errors
`couldn't save it as your default` / `couldn't confirm it was saved as your default`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
@@ -145,9 +157,11 @@
`API Error: 400 due to tool use concurrency issues`| Request errors
`API Error: 400 orphaned tool_result in conversation history`| Request errors
`API Error: 400 duplicate tool_use ID in conversation history`| Request errors
+`Invalid data in redacted_thinking block`| Request errors
`[Unsupported tool content removed]`| Request errors
`role 'system' must precede an 'assistant' message`| Request errors
`Invalid encrypted_content in search_result block` / `Invalid encrypted_index in text block` / `Failed to decrypt web search result content`| Request errors
+`Invalid encrypted_stdout in encrypted_code_execution_result block`| Request errors
`server_tool_use.name: Input should be` on every turn of a resumed session| Request errors
`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
@@ -163,6 +177,8 @@
`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Invalid --agents configuration:`| Command-line errors
+`Error: --agents takes a JSON object, or a file path only with --print (-p)`| Command-line errors
+`Error: --agents file not found`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
`Temp directory <dir> ... Refusing to use it` / `ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
@@ -197,6 +213,7 @@
`Single sign-on authorization needed`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
+`Windows reported an error (EBADF) when Claude Code read this session's transcript file`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
`Couldn't open Claude Desktop`| Command-line errors
@@ -223,6 +240,8 @@
`Plugin "<name>@synced" is required by your organization and can't be disabled here`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
+`cannot contain null bytes (\0)`| Tool errors
+`Path contains null bytes`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`pkill: refusing to run`| Tool errors
@@ -242,6 +261,9 @@
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
`Command killed: its output file was replaced or could no longer be verified`| Tool errors
+`Your disk quota is full on the filesystem with Claude Code's temp directory <dir> (EDQUOT)`| Tool errors
+`The filesystem with Claude Code's temp directory <dir>, or your disk quota on it, is full (ENOSPC)`| Tool errors
+`Command output was lost: the temp filesystem at <dir> is full` / `is out of inodes`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
`Reading a local file from outside this session's connected folders, or through a link, needs the approval card`| Tool errors
@@ -269,6 +291,7 @@
`EACCES: permission denied, posix_spawn`| Background session errors
`exited before it became reachable`| Background session errors
`Couldn't start a background session (working directory no longer exists or is not accessible: ...)`| Background session errors
+`Workspace not trusted.` when starting or restarting a background session| Background session errors
`Claude Code is being updated by npm on this machine (still not runnable after 2 min, ...)`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
@@ -281,10 +304,12 @@
`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| Configuration warnings
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
+`Not loaded: rename <path>, then restart — its name uses "<name>", a name reserved for the skills synced from your claude.ai account`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
`Managed settings were not approved; exiting without applying them.`| Configuration warnings
+`Claude Code can't start: your organization's managed settings block the default model` / `Claude Code can't start: your organization allows only the models listed in "availableModels"`| Configuration warnings
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
@@ -376,7 +401,7 @@
API Error: 500 Internal server error. This is a server-side issue, usually temporary — try again in a moment. If it persists, check https://status.claude.com.
-The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
+The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. A 5xx from the API itself indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. When a proxy, load balancer, or gateway answers with an HTML error page, the message shows the status code and the page’s title, such as `API Error: 502 Bad Gateway`. For a page with no title, the message shows the status code and its standard name instead. Before v2.1.281, the status code was dropped when the page had a title, and the page’s raw markup was printed when it had none. **What to do:**
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
@@ -396,7 +421,7 @@
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for capacity notices
* Try again in a few minutes
- * Run `/model` and switch to a different model to keep working, since capacity is tracked per model. Claude Code prompts you to do this when one model is under particularly high load, for example `Opus is experiencing high load, please use /model to switch to Sonnet`.
+ * Run `/model` and switch to a different model to keep working, since capacity is tracked per model. Claude Code prompts you to do this when one model is under particularly high load, for example `Opus is experiencing high load, please use /model to switch to Sonnet`. On Fable models the message names Fable. In a session the Claude Desktop app runs, such as the Code tab or Cowork, the message reads `Opus is experiencing high load. Switch to Sonnet.` and you switch models with the app’s model picker.
###
@@ -451,13 +476,22 @@
API Error: Connection lost mid-response. The response above may be incomplete.
API Error: Your computer went to sleep mid-response. The response above may be incomplete.
API Error: The response stopped arriving. The response above may be incomplete.
+ API Error: Part of the response never arrived. The response above may be incomplete.
+ API Error: The response stream was malformed. The response above may be incomplete.
* `Server error mid-response`: a mid-stream overloaded or 5xx server error. This variant requires Claude Code v2.1.199 or later; before then that case discarded the partial output and reported the whole turn as an error.
- * `Connection lost mid-response`: the connection dropped.
+ * `Connection lost mid-response`: the connection dropped. You also see this variant when a proxy or gateway ends the response body cleanly before the response has finished.
* `Your computer went to sleep mid-response`: Claude Code detected that your computer went to sleep while the response was streaming. Once your computer wakes, Claude Code treats the connection as broken and stops reading from it.
+ * `Part of the response never arrived`: a stream event was dropped between the API and Claude Code, so a later event referenced content that never arrived. Before v2.1.281, this case ended the turn with `API Error: Content block not found`.
+ * `The response stream was malformed`: an event arrived for a content block that had already finished.
* `The response stopped arriving`: the connection stayed open but stopped delivering data, so the streaming idle watchdog aborted it. Before v2.1.222, Claude Code could also report this failure on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because it counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. In four cases, Claude Code handles the failure without showing this notice right away:
+Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. When a dropped or duplicated stream event arrives before Claude has started any text or tool call, you don’t see this notice:
+
+ * If Claude had completed only its thinking, Claude Code re-issues the request. When the re-issued streams break the same way, the turn ends with `Part of the response never arrived and no response was produced. Try again.` or `The response stream was malformed and no response was produced. Try again.`
+ * If nothing had completed, Claude Code re-sends the request without streaming instead. If you turned that fallback off with [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK`](</docs/en/env-vars>), the turn ends with `API Error: Content block not found` for a dropped event or `API Error: Content block already closed` for a duplicated one.
+
+In four cases, Claude Code handles the failure without showing this notice right away:
* Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
* When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
@@ -616,7 +650,7 @@
API Error: Usage credits required for 1M context · run /usage-credits to turn them on (they take effect after you restart Claude Code), or /model to switch to standard context
-This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
+In a session the Claude Desktop app runs, the hint names no commands: it points at the claude.ai usage settings page, or on Team and Enterprise plans says to turn on usage credits at claude.ai/admin-settings/usage or to ask your admin. This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
* Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Once usage credits are on, restart Claude Code or start a new session, whichever the message says. Until then, the session stays at the standard context limit.
@@ -669,7 +703,7 @@
API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check https://status.claude.com.
-The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. **What to do:**
+The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. When a proxy, load balancer, or gateway between Claude Code and the API answers with its own HTML 429 page, the text after the `·` is that page’s title when it has one, such as `Too Many Requests`. Before v2.1.281, the whole page’s markup was printed after the `·`. **What to do:**
* Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
* Check your provider console for the active limits and request a higher tier if needed
@@ -765,7 +799,7 @@
Not logged in · Please run /login
-**What to do:**
+In a session the Claude Desktop app runs, such as the Code tab or Cowork, the message reads `Authentication required · Sign in again to continue`, and you sign in again from the app. **What to do:**
* Run `/login` to authenticate with your Claude subscription or Console account
* If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
@@ -890,8 +924,9 @@
Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY to use your claude.ai account instead
Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY and run /login to sign in with your claude.ai account
Your organization has disabled API key authentication · Unset the apiKeyHelper setting and run /login to sign in with your claude.ai account
-
-Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone doesn’t help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
+ Your organization has disabled API key authentication · Sign in again with your claude.ai account
+
+The last form appears in a session the Claude Desktop app runs, such as the Code tab or Cowork, where you sign in again from the app. Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone doesn’t help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
* If the message names `ANTHROPIC_API_KEY`, unset it in the current shell and remove it from your shell profile or `.env` file, then relaunch `claude`
* If the message names `apiKeyHelper`, remove the [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting from your `settings.json`
@@ -1074,6 +1109,43 @@
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
+
+###
+
+
+
+Could not refresh your login because another Claude Code process is refreshing it
+
+This message doesn’t mean your login was rejected. Your saved claude.ai login had expired and needed renewing. Another Claude Code process on the same machine held the shared refresh lock, or exited and left it behind, and the refresh made no progress while this session waited. Claude Code stops the request before sending it:
+
+ Could not refresh your login because another Claude Code process is refreshing it (or exited mid-refresh) · Try again in a minute; if it keeps happening, close other Claude Code windows or sign in again with /login
+
+In [non-interactive mode](</docs/en/headless>) (`-p`) and the [Agent SDK](</docs/en/agent-sdk/overview>), the message reads as follows, and the structured error code is `server_error`:
+
+ Failed to refresh OAuth token: another Claude Code process is refreshing it or exited mid-refresh. This is usually transient; retry in a minute, and if it persists close other Claude Code processes or sign in again
+
+Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. **What to do:**
+
+ * Try again in a minute. If another process completes the refresh first, this session uses the renewed login.
+ * If the message keeps returning, close other Claude Code windows and processes, then retry.
+ * If it returns with no other Claude Code process running, run `/login`. Signing in again doesn’t wait on the refresh lock.
+
+###
+
+
+
+Couldn’t save your login
+
+You signed in with claude.ai, but Claude Code couldn’t save the login to its credential store, so the login didn’t complete. On macOS this can happen when the login keychain locks, for example on sleep or idle, after Claude Code has already read or saved credentials in it during the same session.
+
+ Couldn't save your login. If your Mac's keychain is locked, unlock it and log in again.
+ Couldn't save your login. Try logging in again.
+
+The first form appears on macOS and the second everywhere else. A transient credential-store failure, such as a timeout or an unreadable store, produces the same message. **What to do:**
+
+ * On macOS, unlock the login keychain, then run `/login` again
+ * On other platforms, run `/login` again
+ * If the login still doesn’t save, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for the keychain unlock command and other credential-storage recovery steps
###
@@ -1470,6 +1542,7 @@
If `curl` succeeds but Claude Code still fails, the cause is usually something between the runtime and the network rather than the network itself:
+ * Check whether `ANTHROPIC_BASE_URL` is set by running `echo $ANTHROPIC_BASE_URL`, or `echo $env:ANTHROPIC_BASE_URL` in PowerShell, and look for it in the `env` block of your [settings files](</docs/en/settings>). When it’s set, Claude Code sends model requests to that address instead of `api.anthropic.com`, so a leftover value pointing at a local proxy or gateway that’s no longer running produces `Connection refused` even though `curl` reaches the API. Remove it from your shell profile or settings and start Claude Code from a new terminal.
* On Linux and WSL, check `/etc/resolv.conf` for an unreachable nameserver. WSL in particular can inherit a broken resolver from the host.
* On macOS, a VPN client that was disconnected or uninstalled can leave a tunnel interface or routing rule behind. Check `ifconfig` for stale `utun` interfaces and remove the VPN’s network extension in System Settings.
* Docker Desktop and similar container runtimes can intercept outbound traffic. Quit them and retry to rule this out.
@@ -1656,7 +1729,7 @@
* Start a new session with `claude --remote-control` to create a new Remote Control session
* For other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
-If the server reports instead that the previous session is gone, you don’t see this message. Claude Code starts a new session in its place or shows [`Previous session is unavailable — run /remote-control to start a new one`](</docs/en/remote-control#previous-session-is-unavailable>), depending on [the conversation’s reconnection record](</docs/en/remote-control#resume-outcomes>). From v2.1.227 through v2.1.231, Claude Code showed a message that starts with `Remote Control could not resume the previous session under the current login` instead, and [earlier versions behaved differently again](</docs/en/remote-control#reconnect-history>).
+If the server reports instead that the previous session is gone, you don’t see this message. Claude Code starts a new session in its place or shows [`Previous session is unavailable — run /remote-control to start a new one`](</docs/en/remote-control#previous-session-is-unavailable>).
###
@@ -1687,6 +1760,29 @@
* Run `/feedback` to send the transcript with a description of what happened. See Report an error if `/feedback` is unavailable in your environment
* If other requests are failing too, check your network connection and see Unable to connect to API
+
+###
+
+
+
+Couldn’t send feedback
+
+You sent a report from the [`/feedback`, `/bug`, or `/share` dialog](</docs/en/commands#all-commands>) and the upload to Anthropic failed. The dialog keeps your text so you can retry.
+
+ Couldn't send feedback (couldn't reach the service). If it keeps failing, you can file at https://github.com/anthropics/claude-code/issues instead.
+
+The text after the prefix names what failed:
+
+ * **`: not signed in. Run /login, then retry.`** : the dialog uploads only when Claude Code found Anthropic credentials as it opened, and none were usable by the time you sent. For example, you signed out on this machine in the meantime, or your login could no longer be refreshed.
+ * **A parenthetical** : `(server returned <status>)` is the service’s response code; `(request timed out)` and `(couldn't reach the service)` are network failures. When Claude Code can’t name a reason, the parenthetical is absent.
+
+In the [feedback drafts queue](</docs/en/tools-reference#sendfeedback-tool-behavior>), the same failure ends with `The draft is still queued. Try again later.` instead, and the draft stays in the queue for another attempt. **What to do:**
+
+ * For the not-signed-in wording, run `/login` and send again
+ * Otherwise, send again; if other requests are failing too, check your network connection and see Unable to connect to API
+ * If it keeps failing, file the report at [github.com/anthropics/claude-code/issues](<https://github.com/anthropics/claude-code/issues>), as the message says
+
+Before v2.1.281, every send failed with this message once a Remote Control **Stop** or an urgent cross-session message had arrived while the dialog was open. On those versions, close the dialog, reopen it, and send again.
##
@@ -1893,6 +1989,22 @@
* If your Claude Code version is earlier than v2.1.216, run `claude update`.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
* If you maintain the server, fix the tool’s `input_schema`. The schema must be valid JSON Schema, and top-level property names must be 1 to 64 characters long and use only ASCII letters and digits, `_`, `.`, and `-`. See [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>).
+
+###
+
+
+
+tool_use.name over 200 characters
+
+A tool call in the conversation history carries a name longer than the 200 characters the API accepts in a request:
+
+ API Error: 400 ... tool_use.name: String should have at most 200 characters
+
+Claude Code cuts such a name to 200 characters when the response arrives and when it loads a saved conversation, so the call fails with an ordinary `No such tool available` tool error and the conversation continues without this API error. **What to do:**
+
+ * Run `claude update`, then resume the conversation. The updated version repairs the overlong name when it loads the transcript, so a conversation that was stuck works again.
+
+Before v2.1.281, the overlong name stayed in the history and the API rejected every request that re-sent the conversation, including `/compact` and `--resume`, so this error repeated and the conversation was stuck.
###
@@ -1925,7 +2037,7 @@
Model "claud-sonnet-5" is not a recognized model id. Did you mean 'claude-sonnet-5'?
-The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you, or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.260, the check didn’t cover Remote Control picks, so Claude Code applied the pick and the next request failed with There’s an issue with the selected model. **What to do:**
+The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. In a session that the [Desktop app](</docs/en/desktop>) starts for you, the no-match hint reads `Switch to a different model.` Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you, or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.260, the check didn’t cover Remote Control picks, so Claude Code applied the pick and the next request failed with There’s an issue with the selected model. **What to do:**
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
* If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this local check even when the model is newer than your Claude Code version. The server can still require a minimum version for that model; see Claude Code does not support this model.
@@ -1952,13 +2064,28 @@
+API error when checking the picked model
+
+You picked a model with `/model <name>`, or an app connected to the session requested the switch. The API refused the minimal request Claude Code sends to verify the model, for a reason that has no entry of its own, such as a rate limit or a server error. The session keeps its current model, and the message ends by saying so:
+
+ API error: 429 <the server's explanation> · model not changed
+
+The middle of the message is the HTTP status and the server’s own explanation. **What to do:**
+
+ * Act on the server’s explanation; for a rate limit or a 5xx status, wait and pick the model again
+ * The refusals with their own wording are covered by the surrounding entries, such as Model not found and Model is restricted by your organization’s settings
+
+###
+
+
+
Claude Opus is not available with the Claude Pro plan
Your active subscription plan does not include the model you selected.
Claude Opus is not available with the Claude Pro plan. If you have updated your subscription plan recently, run /logout and /login for the plan to take effect.
-**What to do:**
+In a session the Claude Desktop app runs, the message says to `sign out and sign in again` instead of naming the commands. **What to do:**
* Run `/model` and select a model your plan includes
* If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on claude.ai does not take effect in an existing session until you re-authenticate.
@@ -1990,11 +2117,11 @@
Model is restricted by your organization’s settings
-Your organization admin has disabled this model in the claude.ai admin console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model. The substitution notice can also appear mid-session after an admin disables the model a session is running on in the claude.ai admin console.
+Your organization admin has disabled this model in the claude.ai admin console, or managed settings exclude it through an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist or a [`deniedModels`](</docs/en/model-config#block-specific-models-or-versions>) list. The notice appears at startup when `--model`, `ANTHROPIC_MODEL`, or the `model` setting named the restricted model, and it names the model the session uses instead. If managed settings leave no permitted model for the session to use, see Managed settings block the default model. The substitution notice can also appear mid-session after an admin disables the model a session is running on in the claude.ai admin console.
Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
-A notice prefixed with an agent, skill, or command name means the restriction applied to that [subagent’s requested model](</docs/en/sub-agents#choose-a-model>): the subagent runs on the substituted model and your session’s model is unchanged. Before v2.1.223, Claude Code showed the notice only for subagents launched with the Agent tool. Claude Code treats a model family alias, one of `opus`, `sonnet`, `haiku`, or `fable`, as a request for that family rather than for its newest version. On the Anthropic API and on [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), a restricted family alias resolves to the newest version of the family that your organization and the `availableModels` allowlist permit, and the substitution notice names that version. Claude Code rejects `/model <alias>` only when every version of the family is restricted. Before v2.1.205, a family alias was substituted or rejected based on its newest version alone, even when an older version of the same family was allowed. **What to do:**
+Typing `/model <name>` for a restricted model is rejected and the session keeps its current model. For a model disabled in the admin console, the rejection reads `Model '<name>' is restricted by your organization's settings. Run /model to choose a different model.` For a model that managed settings exclude, it reads `Model '<name>' is not available. Your organization restricts model selection.` A notice prefixed with an agent, skill, or command name means the restriction applied to that [subagent’s requested model](</docs/en/sub-agents#choose-a-model>): the subagent runs on the substituted model and your session’s model is unchanged. Before v2.1.223, Claude Code showed the notice only for subagents launched with the Agent tool. Claude Code treats a model family alias, one of `opus`, `sonnet`, `haiku`, or `fable`, as a request for that family rather than for its newest version. On the Anthropic API and on [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), a restricted family alias resolves to the newest version of the family that your organization’s settings permit, and the substitution notice names that version. Claude Code rejects `/model <alias>` only when every version of the family is restricted. Before v2.1.205, a family alias was substituted or rejected based on its newest version alone, even when an older version of the same family was allowed. **What to do:**
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
* If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, the `model` field of a settings file, or the `model` frontmatter of a [subagent](</docs/en/sub-agents#choose-a-model>), skill, or command, remove or update that value so the notice doesn’t recur
@@ -2063,7 +2190,7 @@
API Error: Effort 'xhigh' isn't available with thinking turned off on this model · run /effort high to continue, or turn thinking back on (unset MAX_THINKING_TOKENS=0)
-**What to do:**
+The hint after the `·` varies by session: in a non-interactive session it reads `use --effort high (or the effortLevel setting)`, and in a session the Claude Desktop app runs it reads `you can lower effort to High`. **What to do:**
* [Lower the effort level](</docs/en/model-config#set-the-effort-level>) to `high` or below.
* Turn thinking back on, for example by unsetting [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) or removing [`"alwaysThinkingEnabled": false`](</docs/en/settings-reference#alwaysthinkingenabled>) from your settings.
@@ -2108,6 +2235,21 @@
+Invalid data in redacted_thinking block
+
+The API refused the request with a 400 because it couldn’t accept a `redacted_thinking` block that an earlier turn in the conversation history carries.
+
+ API Error: 400 ... Invalid `data` in `redacted_thinking` block
+
+Claude Code leaves the conversation’s earlier thinking out of the request and retries once, so the session continues without showing the error. Before v2.1.282, Claude Code kept the refused block, and every later turn failed with the same error. **What to do:**
+
+ * If you’re on v2.1.281 or earlier and every turn fails with this error, run `claude update` and resume the session
+ * If the error persists, run `/clear` to start a conversation that doesn’t carry the block
+
+###
+
+
+
Unsupported tool content removed
When Claude Code connects directly to the Anthropic API and loads or previews a saved session, it removes tool content the Anthropic API doesn’t accept and leaves this line where removed content sat between two thinking blocks:
@@ -2144,13 +2286,15 @@
The API refused the request with a 400 because the conversation history holds hosted web-search content it can’t decrypt. The wording names the field it can’t read:
- API Error: 400 messages.21.content.0: Invalid `encrypted_content` in `search_result` block
- API Error: 400 messages.21.content.3.citations.0: Invalid `encrypted_index` in `text` block
- API Error: 400 Failed to decrypt web search result content
-
-Results from the API’s hosted [web search tool](<https://platform.claude.com/docs/en/agents-and-tools/tool-use/web-search-tool>) carry encrypted fields that only the API can read. The API refuses a request that replays content it can’t decrypt, such as content produced for a different organization. Claude Code’s own [WebSearch tool](</docs/en/tools-reference#websearch-tool-behavior>) records search results as plain text, so these blocks usually reach a conversation through a proxy or [LLM gateway](</docs/en/llm-gateway>) that ran hosted web search itself. The refused blocks stay in the conversation history, so every later turn and `/compact` fail the same way. **What to do:**
-
- * Run `/clear` or start a new session; the new conversation doesn’t carry the refused blocks
+ API Error: 400 ... Invalid `encrypted_content` in `search_result` block
+ API Error: 400 ... Invalid `encrypted_index` in `text` block
+ API Error: 400 ... Failed to decrypt web search result content
+ API Error: 400 ... Invalid `encrypted_stdout` in `encrypted_code_execution_result` block
+
+Results from the API’s hosted [web search tool](<https://platform.claude.com/docs/en/agents-and-tools/tool-use/web-search-tool>) carry encrypted fields that only the API can read. The `encrypted_stdout` wording names the output of a hosted code execution program that read such results, which the API encrypts as well. The API refuses a request that replays content it can’t decrypt, such as content produced for a different organization. Claude Code’s own [WebSearch tool](</docs/en/tools-reference#websearch-tool-behavior>) records search results as plain text, so these blocks usually reach a conversation through a proxy or [LLM gateway](</docs/en/llm-gateway>) that ran hosted web search itself. For the three web search wordings, Claude Code leaves the search calls, results, and citations out of what it sends and retries the request once, so the session continues without showing the error. The `encrypted_stdout` wording has no such recovery, so that message still reaches you. Before v2.1.282, Claude Code kept the refused web search blocks too, and every later turn and `/compact` failed the same way. **What to do:**
+
+ * If you’re on v2.1.281 or earlier and every turn fails with one of the web search wordings, run `claude update` and resume the session
+ * If the error persists, or the message names `encrypted_stdout`, run `/rewind` to step back to a checkpoint before the turn that added the content, or run `/clear` to start a conversation that doesn’t carry it
* If you run Claude Code behind a proxy or gateway, report the error to whoever operates it
###
@@ -2159,7 +2303,7 @@
Usage Policy refusal
-The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID you can quote to support if you believe the refusal is incorrect.
+The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID and a Message ID you can quote to support if you believe the refusal is incorrect.
API Error: Opus 4.6 can't help with this. Start a new session to continue.
@@ -2257,18 +2401,23 @@
Invalid —agents configuration
-The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode`, `--resume`, or `--continue`, or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code doesn’t check the value and starts the session. Before v2.1.242, Claude Code started the session anyway and left out the definitions it couldn’t load.
+The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode` or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code ignores `--agents` entirely. With `--resume` or `--continue`, an inline JSON value isn’t checked and the session starts; a value read from a file is checked on every launch. Before v2.1.242, Claude Code started the session anyway and left out the definitions it couldn’t load.
Error: Invalid --agents configuration:
<what failed>
What follows the first line depends on how the value failed. Claude Code runs these checks in order and stops at the first one that fails. If your value has two kinds of problem, you see the second only after you fix the first:
- 1. When the value doesn’t parse as JSON, Claude Code prints one `invalid JSON:` line carrying the JSON parser’s own message
+ 1. When the value begins with `{` but doesn’t parse as JSON, or the contents of an `--agents` file don’t parse, Claude Code prints one `invalid JSON:` line carrying the JSON parser’s own message
2. When it parses but an agent definition doesn’t match the schema for [CLI-defined subagents](</docs/en/sub-agents#choose-the-subagent-scope>), Claude Code prints one line per problem
3. When an agent name starts with `-`, Claude Code prints `<name>: agent names must not start with '-'`
-When there are more than 20 problem lines, Claude Code prints the first 20 and replaces the rest with `…and N more`. **What to do:**
+When there are more than 20 problem lines, Claude Code prints the first 20 and replaces the rest with `…and N more`. With `--print`, `--agents` also accepts [the path to a JSON file](</docs/en/sub-agents#choose-the-subagent-scope>) in place of the inline object. Before v2.1.281, `--agents` accepted only inline JSON and treated a file path as invalid JSON. The file form has refusals of its own, printed in place of this message, including these:
+
+ * **`Error: --agents takes a JSON object, or a file path only with --print (-p)`** : Claude Code read the value as a file path in an interactive session. Pass the definitions as inline JSON, or add `-p` to read them from a file.
+ * **`Error: --agents file not found:<path>`**: no file exists at that path. A value that doesn’t begin with `{` and isn’t valid JSON is read as a path, so inline JSON that your shell mangled can fail this way too. Check the path or the quoting and run the command again.
+
+**What to do:**
* Fix each problem the message lists, then run the command again. See [the fields a CLI-defined subagent takes](</docs/en/sub-agents#choose-the-subagent-scope>).
@@ -2870,6 +3019,24 @@
+Windows reported an error (EBADF) when Claude Code read this session’s transcript file
+
+You resumed a session on Windows, its saved [transcript file](</docs/en/sessions#where-transcripts-are-stored>) opened normally, and reading it then failed with the system error EBADF. The system error doesn’t say why the read failed, so the message suggests likely causes and what to try:
+
+ Windows reported an error (EBADF) when Claude Code read this session's transcript file, although the file had opened normally. This can happen when other software intercepts file reads — security, encryption or endpoint-management tools, for example. If it keeps happening for this conversation, try excluding the folder that holds Claude Code's session transcripts from such software (the .claude folder in your user profile, unless the app or CLAUDE_CONFIG_DIR points Claude Code elsewhere), or adding Claude Code to its allowed applications, then resume again.
+
+The message follows the command’s own failure line, such as `Failed to resume session <session-id>`. A `claude --resume` or [`claude -p`](</docs/en/headless>) command exits with code 1 after showing it. After `/resume` inside a session, your current session keeps running. **What to do:**
+
+ * Exclude the folder that holds your session transcripts from software that scans or intercepts file reads, such as security, encryption, or endpoint-management tools. Transcripts live under `%USERPROFILE%\.claude\projects` by default, or under the directory [`CLAUDE_CONFIG_DIR`](</docs/en/env-vars>) names
+ * If you can’t add an exclusion, add Claude Code to that software’s allowed applications instead
+ * Resume the session again
+
+Before v2.1.282, the failure came with no explanation: `claude --resume <session-id>` ended at `Failed to resume session <session-id>`, and a `-p` run printed only the system error text, such as `Failed to resume session: EBADF: bad file descriptor, read`.
+
+###
+
+
+
Cannot switch renderers in this session
When you switch renderers, Claude Code restarts its process. You ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>) in a session Claude Code declines to restart, so it doesn’t switch and saves nothing. Which message you see tells you the cause:
@@ -3259,6 +3426,22 @@
* If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings-reference#permission-settings>)
* If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path to block the NotebookEdit tool too
+
+###
+
+
+
+Path cannot contain null bytes
+
+A file tool call’s path or pattern argument contained a null byte, which file systems and search tools can’t accept. Read, Write, Edit, NotebookEdit, Glob, and Grep check for this, and the message names the tool and the argument:
+
+ Read file_path cannot contain null bytes (\0). Remove the null byte and try again.
+
+The tool call fails, Claude sees the error, and the turn continues. **What to do:**
+
+ * Nothing on your side: the error is returned to Claude as the tool’s result, and the message itself tells Claude to remove the null byte and try again
+
+Before v2.1.281, a null byte in a Read, Write, Edit, or NotebookEdit path ended the whole turn with an error naming `Path contains null bytes`, and the tool never ran.
###
@@ -3467,6 +3650,28 @@
+Disk quota or temp filesystem is full
+
+Claude Code saves each Bash and PowerShell command’s output to a file under its temp directory. When a command exits with a nonzero code and no output at all, Claude Code checks whether the filesystem holding that file is out of space or inodes, or whether your disk quota on it is used up. If so, a diagnostic appears in the command’s result in place of the empty output:
+
+ Your disk quota is full on the filesystem with Claude Code's temp directory /private/tmp/claude-501/-Users-you-my-project/1f0e62dc-4b0a-4f5e-9c2d-8a7b6c5d4e3f/tasks (EDQUOT), so any output this command printed was lost, and it may have failed because it could not write. Delete files you no longer need there, or restart Claude Code with CLAUDE_CODE_TMPDIR set to a directory on another filesystem.
+
+The message names what ran out:
+
+ * `Your disk quota is full ... (EDQUOT)`: your own quota on that filesystem is used up. A quota can be full while the filesystem still shows free space
+ * `The filesystem with Claude Code's temp directory ..., or your disk quota on it, is full (ENOSPC)`: the filesystem, or your quota on it, has no space left
+ * `Command output was lost: the temp filesystem at ... is full` or `... is out of inodes`: the filesystem has almost no free space left, or is running out of inodes
+
+**What to do:**
+
+ * Delete files you no longer need on the filesystem that holds Claude Code’s temp directory. For `EDQUOT`, delete files that count against your own quota. For `out of inodes`, delete many files rather than a few large ones, since each file takes one inode whatever its size
+ * Or restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a directory on a filesystem with room
+ * Then have Claude run the command again. The output it printed was lost, not truncated
+
+###
+
+
+
The source file is not valid UTF-8 text
Claude tried to publish an [artifact](</docs/en/artifacts>) from a file whose bytes don’t decode as text, or whose text already contains the replacement character `U+FFFD`, so Claude Code refused the publish before uploading anything. The message appears in the Artifact tool result and names the first position to fix:
@@ -3814,13 +4019,34 @@
Working directory no longer exists when starting a background session
-You tried to start a [background session](</docs/en/agent-view>) in a directory that doesn’t exist anymore. This happens when you dispatch from agent view or run `/background` after the directory you’re working in was deleted or moved. It also happens when you attach to or restart a session whose process has exited and whose directory is gone, because the new process would start in that same directory. Claude Code doesn’t start the session, and the message names the missing directory:
+You tried to start a [background session](</docs/en/agent-view>) in a directory that doesn’t exist anymore. Claude Code doesn’t start the session, and the message names the missing directory:
Couldn't start a background session (working directory no longer exists or is not accessible: /tmp/demo)
Before v2.1.257, the session appeared to start and then showed in agent view as a failed row with the same reason. **What to do:**
* Recreate the directory the message names, or dispatch from a directory that exists, then try again
+
+###
+
+
+
+Workspace not trusted when dispatching a background session
+
+You started or restarted a [background session](</docs/en/agent-view>) in a directory you haven’t [trusted](</docs/en/permissions#project-allow-rules-and-workspace-trust>), and the workspace trust dialog couldn’t appear to ask you. Claude Code doesn’t start the session:
+
+ Workspace not trusted. Run `claude` in /path/to/project once and accept the trust prompt, then retry.
+
+From a terminal in the session’s own directory, the same command shows the trust dialog instead and starts the session once you accept. This message appears where no dialog can, such as in a script, or when you restart a session from a directory other than its own. Two variants name a different cause:
+
+ * **`The home directory is trusted one session at a time`** : the session’s directory is your home directory. Claude Code never saves trust for the home directory, so accepting the dialog there in an earlier session doesn’t count.
+ * **`<path> could not be resolved on disk`**: Claude Code couldn’t find the session’s directory on disk.
+
+**What to do:**
+
+ * Run `claude` in the directory the message names and accept the trust dialog, then run the command again
+ * For the home-directory message, run the command from a terminal in your home directory so the dialog can appear, or start the session from a project directory instead
+ * For the `could not be resolved on disk` message, recreate the directory, or start a new session from a directory that exists
##
@@ -4050,6 +4276,22 @@
+A skill, command, or workflow wasn’t loaded because its name is reserved
+
+A skill folder, a frontmatter `name`, a file or subfolder in `.claude/commands/`, or a [saved workflow](</docs/en/workflows#save-the-workflow-for-reuse>) uses the name `anthropic-skills` or a name that starts with `anthropic-skills:`. Claude Code [reserves that name for skills synced from claude.ai](</docs/en/skills#names-reserved-for-synced-skills>) and doesn’t load that item. Claude Code shows this warning as a startup notice in the conversation view rather than on stderr:
+
+ Not loaded: rename .claude/skills/anthropic-skills, then restart — its name uses "anthropic-skills", a name reserved for the skills synced from your claude.ai account
+
+The notice names what to change for the first item it refused: a folder or file to rename, a `name:` line to edit, or a workflow to rename. When more than one item was refused, the notice ends with a count such as `· 2 more`, and the [debug log](</docs/en/debug-your-config>) names each one. **What to do:**
+
+ * Rename the item the notice names, or edit the `name:` line it points to, then restart the session.
+
+Before v2.1.282, Claude Code loaded skills and commands with these names.
+
+###
+
+
+
Workspace has not been trusted
Claude Code found `permissions.allow` rules or `permissions.additionalDirectories` entries in the project’s `.claude/settings.json` or `.claude/settings.local.json` and didn’t apply them, because [allow rules from project settings require workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>). The count, the setting name, and the file named in the message vary with your configuration. `deny` and `ask` rules aren’t affected.
@@ -4092,7 +4334,7 @@
Remote managed settings failed to load
-Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them, so it shows this warning in interactive sessions. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`, and the rest of the line says which policy the session runs on:
+Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them or couldn’t apply what the server returned, so it shows this warning in interactive sessions. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`. The cause `no setting in the server response could be applied as written` means the server answered but none of the settings it returned passed [validation](</docs/en/server-managed-settings#invalid-entries-in-delivered-settings>). Before v2.1.282, this cause read `server returned invalid settings`. The rest of the line says which policy the session runs on:
* **Settings cached from an earlier successful fetch** : Claude Code runs the session on that cached policy, except the [withheld environment variables](</docs/en/server-managed-settings#fetch-and-caching-behavior>), and the line reads `using cached policy`.
* **No cache** : Claude Code runs the session without server-managed settings, and the line reads `no remote policy applied`.
@@ -4100,6 +4342,7 @@
**What to do:**
* Act on the cause the message names: for a network cause, check that this machine can reach `api.anthropic.com`; for an authentication cause, check your sign-in with `/status`
+ * For `no setting in the server response could be applied as written`, ask your administrator to correct the settings on the server
* Run `/status` or `claude doctor` for the full diagnostic
Before v2.1.248, Claude Code reported a failed settings fetch only in the debug log.
@@ -4118,6 +4361,25 @@
* Start Claude Code again and approve the dialog to continue under your organization’s settings. A declined dialog isn’t remembered, so it appears again at the next start.
* If you’re unsure about a setting the dialog lists, ask whoever maintains your organization’s managed settings before approving
+
+###
+
+
+
+Managed settings block the default model
+
+Your organization’s [managed settings](</docs/en/managed-settings>) block the model the Default option resolves to and every model it could step down to. A session that would start on the Default option exits at startup instead of running a blocked model. Which message you see depends on the setting that blocks it. When a [`deniedModels`](</docs/en/model-config#block-specific-models-or-versions>) list blocks it, the message reads:
+
+ Claude Code can't start: your organization's managed settings block the default model (claude-opus-5-5) in "deniedModels", and none of the models they allow can be used as the default instead. Ask your administrator to update "deniedModels" or "availableModels".
+
+When an `availableModels` list with [`availableModelsMatch`](</docs/en/settings-reference#availablemodelsmatch>) set to `"exact"` omits it, the message reads:
+
+ Claude Code can't start: your organization allows only the models listed in "availableModels", and none of them can be used as the default model (claude-opus-5-5 isn't listed). Ask your administrator to update "availableModels".
+
+**What to do:**
+
+ * If you administer the settings, add a model your users can run to `availableModels`, or narrow the `deniedModels` entries that block every fallback. [Block specific models or versions](</docs/en/model-config#block-specific-models-or-versions>) describes how the Default option steps down
+ * If you don’t administer them, send the message to your administrator. Your own settings files can’t widen a managed `availableModels` or `deniedModels` list
###
Show diff (290 lines)
--- a/errors.md
+++ b/errors.md
@@ -26,6 +26,8 @@
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
+`The server-side auto mode classifier gave no verdict`| Server errors
+`Auto mode is unavailable — the server returned no safety verdict for the last 10 responses`| Server errors
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit` / `You've hit your Opus limit` / `You've hit your Sonnet limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
@@ -144,6 +146,8 @@
`API Error: 400 orphaned tool_result in conversation history`| Request errors
`API Error: 400 duplicate tool_use ID in conversation history`| Request errors
`[Unsupported tool content removed]`| Request errors
+`role 'system' must precede an 'assistant' message`| Request errors
+`Invalid encrypted_content in search_result block` / `Invalid encrypted_index in text block` / `Failed to decrypt web search result content`| Request errors
`server_tool_use.name: Input should be` on every turn of a resumed session| Request errors
`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
@@ -161,6 +165,7 @@
`Error: Invalid --agents configuration:`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
+`Temp directory <dir> ... Refusing to use it` / `ENOSPC: no space left on device, mkdir '<dir>'`| Command-line errors
`couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
@@ -204,6 +209,7 @@
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Marketplace "<name>" is already added from a different source`| Plugin errors
+`"<name>" is another spelling of "<reserved>", a reserved marketplace name`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
@@ -526,6 +532,35 @@
+The server returned no safety verdict
+
+Under [server-side classifier review](</docs/en/permission-modes#server-side-classifier-review>), auto mode denies an action when the server gives no verdict for it. The denial names a category in parentheses when Claude Code can determine one, such as `(timed out)`:
+
+ The server-side auto mode classifier gave no verdict (timed out), so auto mode cannot determine the safety of <tool>.
+
+The rest of the message tells Claude whether one retry can help. Before some of these denials, Claude Code waits so that Claude’s next attempt doesn’t follow at once. During the wait in an interactive session, the spinner shows `Auto mode check unavailable` with a countdown, and pressing `Esc` interrupts the turn. After ten responses in a row with no verdict, auto mode stops the turn:
+
+ Auto mode is unavailable — the server returned no safety verdict for the last 10 responses, so Claude stopped. Send a message to try again, or switch out of auto mode.
+
+The stop message appears in a different place in each kind of session:
+
+ * In an interactive session, the message appears as a warning in the transcript and the turn ends
+ * In a [non-interactive](</docs/en/headless>) `-p` run, the run ends and reports an execution error. With the default text output, the message prints on stderr.
+ * When a [subagent](</docs/en/sub-agents>) hit the limit, the subagent stops before finishing, and Claude receives whatever it produced with a note that auto mode stopped it
+
+**What to do:**
+
+ * Send another message to have Claude try again. The count of responses starts over.
+ * If the stop repeats and your requests go through an [LLM gateway or proxy](</docs/en/llm-gateway>), check whether it cuts streaming responses short or rewrites them. [Server-side classifier review](</docs/en/permission-modes#server-side-classifier-review>) says which gateway behavior causes denials, and the [gateway compatibility guide](</docs/en/llm-gateway-protocol#feature-pass-through>) lists what to pass through unchanged.
+ * Set `CLAUDE_CODE_AUTO_MODE_SERVER=0` before you start Claude Code to use its own classifier requests instead. Before v2.1.281, Claude Code didn’t read the variable on a direct connection to the Anthropic API.
+ * To approve the actions yourself instead, [switch out of auto mode](</docs/en/permission-modes#switch-permission-modes>)
+
+Before v2.1.280, Claude Code denied each action from a response without a verdict immediately and never stopped the turn.
+
+###
+
+
+
Agent terminated early due to an API error
A [subagent](</docs/en/sub-agents>)’s API request failed terminally, for example because a usage limit was reached or retries for a server error ran out, so the subagent stopped before finishing its task. This message requires Claude Code v2.1.199 or later; before then the API error text was returned to Claude as if it were the subagent’s result.
@@ -2088,6 +2123,40 @@
+role ‘system’ must precede an ‘assistant’ message
+
+The API refused the request with a 400 because a system message sits at a position in the conversation it doesn’t accept:
+
+ API Error: 400 messages.6: role 'system' must precede an 'assistant' message or end the array; ...
+
+Claude Code sends some of its reminder and attachment text as system messages inside the conversation. When the API refuses one’s position, Claude Code retries the request once with that text sent as ordinary user messages instead. The API’s sibling placement wordings, such as `use the top-level 'system' parameter for the initial system prompt`, get the same recovery. When the error does appear, the refused system message isn’t one Claude Code can remove. That usually means a proxy or [LLM gateway](</docs/en/llm-gateway>) between Claude Code and the API added a system message of its own or reordered the conversation. **What to do:**
+
+ * Run `/clear` to start a fresh conversation. If the error returns there too, the cause is on the request path, not in the saved conversation.
+ * If the error repeats on every turn behind a proxy or gateway configured through [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>), connect without the proxy to confirm the source, and report the error to whoever operates it
+
+Before v2.1.280, Claude Code didn’t recognize this wording, so the error also appeared when the refused system message was one Claude Code itself sent, and every later turn of the conversation failed the same way.
+
+###
+
+
+
+Invalid encrypted_content in search_result block
+
+The API refused the request with a 400 because the conversation history holds hosted web-search content it can’t decrypt. The wording names the field it can’t read:
+
+ API Error: 400 messages.21.content.0: Invalid `encrypted_content` in `search_result` block
+ API Error: 400 messages.21.content.3.citations.0: Invalid `encrypted_index` in `text` block
+ API Error: 400 Failed to decrypt web search result content
+
+Results from the API’s hosted [web search tool](<https://platform.claude.com/docs/en/agents-and-tools/tool-use/web-search-tool>) carry encrypted fields that only the API can read. The API refuses a request that replays content it can’t decrypt, such as content produced for a different organization. Claude Code’s own [WebSearch tool](</docs/en/tools-reference#websearch-tool-behavior>) records search results as plain text, so these blocks usually reach a conversation through a proxy or [LLM gateway](</docs/en/llm-gateway>) that ran hosted web search itself. The refused blocks stay in the conversation history, so every later turn and `/compact` fail the same way. **What to do:**
+
+ * Run `/clear` or start a new session; the new conversation doesn’t carry the refused blocks
+ * If you run Claude Code behind a proxy or gateway, report the error to whoever operates it
+
+###
+
+
+
Usage Policy refusal
The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID you can quote to support if you believe the refusal is incorrect.
@@ -2286,6 +2355,29 @@
+Temp directory refused or cannot be created
+
+On macOS and Linux, Claude Code creates a private temp directory at startup, `claude-<uid>` under the system temp directory or the [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) override. When the directory can’t be created, or an entry already at that path fails the safety checks, Claude Code prints the failure to stderr and exits with code 1 rather than start the session:
+
+ ENOSPC: no space left on device, mkdir '/tmp/claude-501'
+
+ Temp directory /tmp/claude-501 is not a directory (may be an attacker-planted symlink). Refusing to use it. Set CLAUDE_CODE_TMPDIR to a directory you control, or ask an administrator to remove it.
+
+ Temp directory /tmp/claude-501 is owned by uid 502, expected 501. Refusing to use it — another user may have pre-created it. Set CLAUDE_CODE_TMPDIR to a directory you control, or ask an administrator to remove it.
+
+ Temp directory /tmp/claude-501 is not readable (its mode may have been altered, or a path component denies search). Refusing to use it — restore its permissions (chmod 0700) or remove it. Set CLAUDE_CODE_TMPDIR to a directory you control, or ask an administrator to remove it.
+
+**What to do:**
+
+ * For `ENOSPC`, free disk space on the volume that holds the temp directory
+ * For the `Refusing to use it` forms, remove the named entry itself, not what a link points to, and start Claude Code again; for the `owned by uid` form, only an administrator or that user can remove it
+ * For `is not readable`, run `chmod 0700` on the named directory, or remove it and start again
+ * In any of these cases, set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory you control and start Claude Code again, leaving the refused path alone
+
+###
+
+
+
Directory couldn’t be resolved to a real location
You ran `/add-dir` for a subdirectory of your working directory, and Claude Code couldn’t resolve the directory to its real location. You already have file access to a subdirectory of the working directory, so `/add-dir` only loads its skills, commands, and agents. Before loading them, Claude Code checks that the directory’s real location, with any symlinks resolved, is inside the working directory. When Claude Code can’t resolve that location, it loads nothing and shows this message:
@@ -2583,7 +2675,7 @@
* A typo, such as `/hepl` for `/help`. [How the command menu matches what you type](</docs/en/commands#how-the-command-menu-matches-what-you-type>) covers picking a close match before you submit
* A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them, such as `Cloud sessions are disabled by your organization's policy`
- * A command from a [plugin](</docs/en/plugins>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
+ * A command from a [plugin](</docs/en/plugins/overview>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
Claude Code answers an unmatched `/` name this way only in an interactive terminal session. In every other session, it sends the prompt to Claude as a normal message instead, with a note that the command didn’t run and a list of commands Claude can run in the session. Those sessions include:
@@ -2893,7 +2985,7 @@
Plugin errors
-These errors come from [plugin](</docs/en/plugins>) and [marketplace](</docs/en/plugin-marketplaces>) configuration. For plugin problems that don’t produce one of the messages on this page, such as a marketplace URL that doesn’t load or a plugin that installs but doesn’t appear, see [Plugin troubleshooting](</docs/en/discover-plugins#troubleshooting>).
+These errors come from [plugin](</docs/en/plugins/overview>) and [marketplace](</docs/en/plugins/overview>) configuration. For plugin problems that don’t produce one of the messages on this page, such as a marketplace URL that doesn’t load or a plugin that installs but doesn’t appear, see [Plugin troubleshooting](</docs/en/plugins/troubleshooting>).
###
@@ -2918,7 +3010,7 @@
Marketplace is registered from an untrusted source
-The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugin-marketplaces#marketplace-schema>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, the name was checked only when the marketplace was added, so an entry registered before its name became reserved kept loading.
+The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugins/marketplace-reference#marketplace-file>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, the name was checked only when the marketplace was added, so an entry registered before its name became reserved kept loading.
Marketplace "claude-community" is registered from an untrusted source: The name 'claude-community' is reserved for official Anthropic marketplaces. Only repositories from 'github.com/anthropics/' can use this name. To fix it, remove the marketplace and re-add it from the official source.
@@ -2926,7 +3018,26 @@
* If the marketplace is already registered, run `claude plugin marketplace remove <name>`, then add it again from the official `github.com/anthropics` repository
* If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
- * See the reserved name list under [Marketplace schema](</docs/en/plugin-marketplaces#marketplace-schema>)
+ * See the reserved name list under [Marketplace schema](</docs/en/plugins/marketplace-reference#marketplace-file>)
+
+###
+
+
+
+Marketplace name is another spelling of a reserved name
+
+The marketplace’s name isn’t itself a reserved name, but Claude Code treats it as another spelling of one. [Reserved names](</docs/en/plugins/marketplace-reference#reserved-name-spellings>) lists which spellings count as a reserved name. Claude Code refuses such a name when you add the marketplace:
+
+ Failed to add marketplace: "claude.code.plugins" is another spelling of "claude-code-plugins", a reserved marketplace name.
+
+When a marketplace is already registered under such a name, its entry stops loading, and `/plugin`, `claude plugin install`, and `claude plugin update` warn:
+
+ known_marketplaces.json has an entry named "claude.code.plugins", another spelling of the reserved marketplace name "claude-code-plugins", so it is ignored. Remove it with: claude plugin marketplace remove claude.code.plugins
+
+When the name would need shell quoting, the add-time refusal reads `This marketplace's name is another spelling of "<reserved>", a reserved marketplace name. It is not exactly the reserved name it appears to be.` **What to do:**
+
+ * Rename the marketplace to a name that doesn’t spell a reserved name and add it again
+ * For the ignored-entry warning, run the `claude plugin marketplace remove` command it gives, or remove the entry from `~/.claude/plugins/known_marketplaces.json`
###
@@ -2934,7 +3045,7 @@
Marketplace is already added from a different source
-You confirmed adding a marketplace through [`/plugin install <plugin> --marketplace <source>`](</docs/en/discover-plugins#add-a-marketplace-and-install-in-one-command>), and the catalog Claude Code fetched from that source names itself the same as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
+You confirmed adding a marketplace through [`/plugin install <plugin> --marketplace <source>`](</docs/en/plugins/install#add-a-marketplace-and-install-in-one-command>), and the catalog Claude Code fetched from that source names itself the same as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
Marketplace "acme-tools" is already added from a different source (github:acme/plugins). To use this source instead, remove that marketplace first with /plugin marketplace remove acme-tools.
@@ -2949,7 +3060,7 @@
Plugin command references user_config in a shell command
-A plugin hook, [monitor](</docs/en/plugins-reference#monitors>), or MCP [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) command references a `${user_config.KEY}` [plugin option](</docs/en/plugins-reference#user-configuration>), and the substituted string would be passed to a shell. A configured value containing `$(...)`, backticks, or `;` would run as code there, so Claude Code refuses to start the component instead of substituting the value. The check runs on the command template, so the error appears even when no value is configured yet. Before v2.1.207, the value was substituted into the shell command. The wording depends on which surface referenced the option. A shell-form hook reports:
+A plugin hook, [monitor](</docs/en/plugins/components#monitors>), or MCP [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) command references a `${user_config.KEY}` [plugin option](</docs/en/plugins/manifest-reference#user-configuration>), and the substituted string would be passed to a shell. A configured value containing `$(...)`, backticks, or `;` would run as code there, so Claude Code refuses to start the component instead of substituting the value. The check runs on the command template, so the error appears even when no value is configured yet. Before v2.1.207, the value was substituted into the shell command. The wording depends on which surface referenced the option. A shell-form hook reports:
Hook from plugin formatter@acme-tools references ${user_config.*} in a shell-form command. The substituted value would be re-parsed by the shell. Use exec form instead — {"command": "<executable>", "args": ["${user_config.KEY}", ...]} — or read $CLAUDE_PLUGIN_OPTION_<KEY> from the hook's environment. Command: ./scripts/notify.sh ${user_config.webhook_url}
@@ -2973,7 +3084,7 @@
Plugin archive integrity check failed
-The plugin’s marketplace entry uses an [`archive` source](</docs/en/plugin-marketplaces#zip-archives>) with a `sha256` pin, and the digest of the downloaded file doesn’t match the pin. Claude Code refuses the install, so nothing changes in the plugin cache. The mismatch has three possible causes:
+The plugin’s marketplace entry uses an [`archive` source](</docs/en/plugins/marketplace-reference#archive-plugin-source>) with a `sha256` pin, and the digest of the downloaded file doesn’t match the pin. Claude Code refuses the install, so nothing changes in the plugin cache. The mismatch has three possible causes:
* The file at the URL changed after the author computed the pin
* The author entered the wrong digest in the marketplace entry
@@ -2993,11 +3104,11 @@
Path escapes plugin directory
-A plugin component path, declared in the plugin’s `plugin.json` or in its [marketplace entry](</docs/en/plugin-marketplaces#plugin-entries>), resolves outside the plugin’s own directory. Claude Code drops that path and loads the rest of the plugin. The component name in the message, such as `commands` or `hooks`, names the field that declared the path.
+A plugin component path, declared in the plugin’s `plugin.json` or in its [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>), resolves outside the plugin’s own directory. Claude Code drops that path and loads the rest of the plugin. The component name in the message, such as `commands` or `hooks`, names the field that declared the path.
commands path escapes plugin directory: ./../shared.md
-In `claude plugin` command output, the same error reads `Path escapes plugin directory: ./../shared.md (commands)`. Claude Code rejects both a path that points outside the plugin as written, such as `../shared-utils`, and a symlink that leads outside the plugin and isn’t one the [marketplace symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>) allow. For a symlink, the message also says where the path resolves:
+In `claude plugin` command output, the same error reads `Path escapes plugin directory: ./../shared.md (commands)`. Claude Code rejects both a path that points outside the plugin as written, such as `../shared-utils`, and a symlink that leads outside the plugin and isn’t one the [marketplace symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>) allow. For a symlink, the message also says where the path resolves:
commands path escapes plugin directory: ./commands/deploy.md — it resolves to /home/user/shared/deploy.md, outside the plugin directory
@@ -3010,7 +3121,7 @@
* Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
* If the path is a symlink to a file outside the plugin, replace the symlink with a copy of the file
* If the message says the path contains a backslash, write the path with forward slashes, for example `./commands/deploy.md`
- * To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>)
+ * To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins/host-marketplace#share-files-within-a-marketplace-with-symlinks>)
###
@@ -3020,7 +3131,7 @@
Claude Code asked the operating system whether a plugin path exists and got an error other than “not found”, so it doesn’t load what the path names. How much of the plugin loads depends on which path failed:
- * One of a plugin’s [default component locations](</docs/en/plugins-reference#file-locations-reference>), such as the `skills/` folder, the `monitors/monitors.json` file, or a [`SKILL.md` at the plugin root](</docs/en/plugins-reference#skills>): the plugin’s other components still load
+ * One of a plugin’s [default component locations](</docs/en/plugins/manifest-reference#standard-layout>), such as the `skills/` folder, the `monitors/monitors.json` file, or a [`SKILL.md` at the plugin root](</docs/en/plugins/components#skills>): the plugin’s other components still load
* The plugin’s own directory: nothing from that plugin loads
You don’t see this error for a path that doesn’t exist at all. In `/plugin`, the error appears under the plugin and names the path and the code the operating system returned:
@@ -3048,12 +3159,12 @@
Marketplace entry path does not stay inside the marketplace directory
-The plugin’s [marketplace entry](</docs/en/plugin-marketplaces#plugin-entries>) declares a source path that Claude Code can’t resolve to a location inside the marketplace’s own directory, so the plugin doesn’t install or load. The refusal covers:
+The plugin’s [marketplace entry](</docs/en/plugins/marketplace-reference#plugin-entries>) declares a source path that Claude Code can’t resolve to a location inside the marketplace’s own directory, so the plugin doesn’t install or load. The refusal covers:
* An entry path that is absolute, climbs out of the marketplace with `..`, or is spelled like a network path
* On macOS and Linux, an entry path that contains a backslash anywhere after the leading `./`
* An entry in a marketplace fetched from a remote source, such as git or a URL, that reaches its target through a symlink resolving outside the marketplace directory
- * A relative entry in a marketplace added from a direct URL to its `marketplace.json`: Claude Code downloads only that file, so no local plugin files exist for the path to name. See [Plugins with relative paths fail in URL-based marketplaces](</docs/en/plugin-marketplaces#plugins-with-relative-paths-fail-in-url-based-marketplaces>)
+ * A relative entry in a marketplace added from a direct URL to its `marketplace.json`: Claude Code downloads only that file, so no local plugin files exist for the path to name. See [Plugins with relative paths fail in URL-based marketplaces](</docs/en/plugins/troubleshooting#plugins-with-relative-paths-fail-in-url-based-marketplaces>)
`claude plugin install` reports the refusal like this:
@@ -3066,7 +3177,7 @@
**What to do:**
* If you maintain the marketplace, write the entry’s `source` as a plain relative path with forward slashes, such as `./plugins/my-plugin`, and keep any symlink it crosses pointed inside the marketplace directory
- * If you added the marketplace from a direct URL, relative entries can’t resolve. Ask the marketplace author to use [another plugin source](</docs/en/plugin-marketplaces#plugin-sources>), or add the marketplace from its git repository instead
+ * If you added the marketplace from a direct URL, relative entries can’t resolve. Ask the marketplace author to use [another plugin source](</docs/en/plugins/marketplace-reference#plugin-sources>), or add the marketplace from its git repository instead
###
@@ -3094,7 +3205,7 @@
Plugin is required by your organization
-You ran `claude plugin disable`, or used the `/plugin` **Installed** tab, to turn off a [plugin synced from claude.ai](</docs/en/plugins-reference#synced-plugins>) that your organization marks as required:
+You ran `claude plugin disable`, or used the `/plugin` **Installed** tab, to turn off a [plugin synced from claude.ai](</docs/en/plugins/loading#synced-plugins>) that your organization marks as required:
Plugin "<name>@synced" is required by your organization and can't be disabled here. Contact your admin to change it.
--- a/errors.md
+++ b/errors.md
@@ -148,6 +148,7 @@
`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
`<model>'s safeguards flagged this message`| Request errors
+`Opus 5.5's safeguards flagged this session`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
@@ -2013,9 +2014,9 @@
**What to do:**
- * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later
+ * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later. Opus 5.5 needs v2.1.280 or later
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
- * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later
+ * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later. Opus 5.5 needs TypeScript SDK v0.3.280 or later
###
@@ -2111,7 +2112,7 @@
API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On Opus 5.5, which requires v2.1.280 or later, the message opens with `Opus 5.5's safeguards flagged this session` instead. When the flagged category has a fallback model available, Claude Code [switches models](</docs/en/model-config#automatic-model-fallback>) rather than showing this error. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
@@ -3050,6 +3051,7 @@
The plugin’s [marketplace entry](</docs/en/plugin-marketplaces#plugin-entries>) declares a source path that Claude Code can’t resolve to a location inside the marketplace’s own directory, so the plugin doesn’t install or load. The refusal covers:
* An entry path that is absolute, climbs out of the marketplace with `..`, or is spelled like a network path
+ * On macOS and Linux, an entry path that contains a backslash anywhere after the leading `./`
* An entry in a marketplace fetched from a remote source, such as git or a URL, that reaches its target through a symlink resolving outside the marketplace directory
* A relative entry in a marketplace added from a direct URL to its `marketplace.json`: Claude Code downloads only that file, so no local plugin files exist for the path to name. See [Plugins with relative paths fail in URL-based marketplaces](</docs/en/plugin-marketplaces#plugins-with-relative-paths-fail-in-url-based-marketplaces>)
@@ -3063,7 +3065,7 @@
**What to do:**
- * If you maintain the marketplace, write the entry’s `source` as a plain relative path such as `./plugins/my-plugin`, and keep any symlink it crosses pointed inside the marketplace directory
+ * If you maintain the marketplace, write the entry’s `source` as a plain relative path with forward slashes, such as `./plugins/my-plugin`, and keep any symlink it crosses pointed inside the marketplace directory
* If you added the marketplace from a direct URL, relative entries can’t resolve. Ask the marketplace author to use [another plugin source](</docs/en/plugin-marketplaces#plugin-sources>), or add the marketplace from its git repository instead
###
@@ -3128,7 +3130,7 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
- * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
+ * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `CronCreate`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
@@ -4245,7 +4247,7 @@
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
- * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, Opus 5.5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
Show diff (285 lines)
--- a/errors.md
+++ b/errors.md
@@ -61,6 +61,7 @@
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Claude login not accepted · Run /login, then try again`| Authentication
+`Artifacts need a claude.ai login`| Authentication
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
@@ -77,6 +78,7 @@
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
`Cloud gateway session expired — run /login to reconnect.`| Authentication
`Cloud gateway <url> no longer accepts this session`| Authentication
+`Sign-in timed out while waiting for you to continue. Try again.`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
`Google Cloud credentials expired or invalid`| Authentication
@@ -139,6 +141,8 @@
`effort '<level>' is not supported when thinking is disabled`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
+`API Error: 400 orphaned tool_result in conversation history`| Request errors
+`API Error: 400 duplicate tool_use ID in conversation history`| Request errors
`[Unsupported tool content removed]`| Request errors
`server_tool_use.name: Input should be` on every turn of a resumed session| Request errors
`<model> can't help with this. Start a new session to continue`| Request errors
@@ -189,6 +193,8 @@
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
+`Couldn't open Claude Desktop`| Command-line errors
+`Failed to open Claude Desktop. Please try opening it manually.`| Command-line errors
`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
`Skill usage reports are not available on this connection.`| Command-line errors
@@ -196,6 +202,7 @@
`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
+`Marketplace "<name>" is already added from a different source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
@@ -206,6 +213,7 @@
`Plugin source path refused`| Plugin errors
`Failed to load marketplace configuration`| Plugin errors
`Marketplace configuration file is corrupted`| Plugin errors
+`Plugin "<name>@synced" is required by your organization and can't be disabled here`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
@@ -236,6 +244,8 @@
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
`blocked because the path is network-shaped`| Background session errors
+`is isolated in the worktree <path>, but this command <reason>. Refusing to run it`| Background session errors
+`too complex to verify that it stays inside the worktree`| Background session errors
`This session has no saved transcript`| Background session errors
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
@@ -271,6 +281,7 @@
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
+`otelHeadersHelper failed; telemetry is not being exported. See /status: ...`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
@@ -572,7 +583,7 @@
This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
- * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Restart Claude Code once usage credits are on. Until you restart, the session stays at the standard context limit.
+ * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Once usage credits are on, restart Claude Code or start a new session, whichever the message says. Until then, the session stays at the standard context limit.
* If the error persists after `/model`, a 1M model ID may be set elsewhere. See [Setting your model](</docs/en/model-config#setting-your-model>) for the configuration locations to check in priority order.
* To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
@@ -781,7 +792,8 @@
* Run the command configured in `apiKeyHelper` directly in your shell to reproduce the failure
* If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
* Fix the command so it prints only the key to stdout, as a single token of printable ASCII up to 16,384 characters, and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
- * Run `/status` to confirm `apiKeyHelper` is the active credential source. Each time the command fails, its exit code and error output appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
+ * Run `/status` to see the failure and confirm `apiKeyHelper` is the active credential source. The `apiKeyHelper` row shows `Failing` with the last failure’s detail, such as the exit code and the command’s error output, and disappears after the next successful run. Before v2.1.274, `/status` showed only the credential source, not the failure.
+ * Each time the command fails, its exit code and error output also appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
###
@@ -1045,6 +1057,24 @@
+Artifacts need a claude.ai login
+
+Claude Code refused an [artifact](</docs/en/artifacts>) publish or read because the session has no claude.ai login it can use for artifacts. Every form of the message starts with the same words, followed by a remedy that depends on how your session authenticates. With no competing credential it reads:
+
+ Artifacts need a claude.ai login. Run /login and select "Claude account with subscription", then retry — the "Anthropic Console account" option does not provide claude.ai credentials.
+
+**What to do:**
+
+ * Run `/login` and select **Claude account with subscription**. The **Anthropic Console account** option doesn’t provide claude.ai credentials.
+ * When the message names a credential that takes precedence, such as `ANTHROPIC_API_KEY`, an `apiKeyHelper` setting, or a Console key saved by a previous `/login`, remove it the way the message says, then run `/login`
+ * When the message says this remote session authenticates through the machine that launched it, sign in to claude.ai on that machine, then reconnect the session
+ * When the message says the credential is injected by the session’s host environment, you can’t change it in that session; start a session that is signed in to claude.ai
+ * See [Availability](</docs/en/artifacts#availability>) for the other requirements artifacts have, such as plan, model provider, and organization policy
+
+###
+
+
+
Administrator policy requires a Cloud gateway sign-in
An administrator’s [managed settings](</docs/en/managed-settings>) on this machine set [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"` or set [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>). Unless you select a cloud provider through a variable such as `CLAUDE_CODE_USE_BEDROCK`, Claude Code then accepts only the [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in. You see one of two messages:
@@ -1337,6 +1367,20 @@
* Run `/login` in the session and complete the browser sign-in
* For a non-interactive launch, start `claude` in the same environment, run `/login`, then rerun your command
+
+###
+
+
+
+Sign-in timed out while waiting for you to continue
+
+During a [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in, the gateway named the account that signed in, and Claude Code asked you to confirm it before saving the credential. You left the confirmation open past the sign-in’s own expiry, and the gateway issued no refresh token that could renew it, so Claude Code stored nothing when you continued:
+
+ Sign-in timed out while waiting for you to continue. Try again.
+
+**What to do:**
+
+ * Run `/login` again and confirm the account before the sign-in expires
###
@@ -2014,10 +2058,12 @@
The conversation history reached the API in an inconsistent state, usually after a tool call was interrupted or a turn was edited mid-stream.
API Error: 400 due to tool use concurrency issues. Run /rewind to recover the conversation.
+ API Error: 400 orphaned tool_result in conversation history. Run /rewind to recover the conversation.
+ API Error: 400 duplicate tool_use ID in conversation history. Run /rewind to recover the conversation.
API Error: 400 ... unexpected `tool_use_id` found in `tool_result` blocks
API Error: 400 ... thinking blocks ... cannot be modified
-All three variants mean the same thing: the sequence of `tool_use`, `tool_result`, and `thinking` blocks in history no longer matches what the API expects. **What to do:**
+All variants mean the same thing: the sequence of `tool_use`, `tool_result`, and `thinking` blocks in history no longer matches what the API expects. **What to do:**
* If you are using Opus 4.7 or Opus 4.8, run `claude update` first. Versions before v2.1.156 can trigger this error during normal tool use, and `/rewind` doesn’t clear it.
* Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
@@ -2702,6 +2748,7 @@
Claude Code exits with code 1 after showing the message. The `/resume` picker inside a running session reports `Failed to resume conversation` in the conversation instead, and your current session keeps running. Before v2.1.216, a failed resume from the `claude --resume` picker stayed on the `Resuming conversation…` spinner indefinitely instead of showing this message. **What to do:**
* Run `claude --resume <session-id>` with the session ID from the message to retry
+ * If every retry fails the same way, run `claude update` and resume again. Versions before v2.1.275 fail the resume when the saved transcript contains an entry they can’t read.
* If the retry fails again, run `claude` to start a new session
###
@@ -2756,6 +2803,23 @@
+Couldn’t open Claude Desktop
+
+You ran [`/desktop`](</docs/en/desktop#coming-from-the-cli>), or its alias `/app`, and the system command Claude Code uses to open Claude Desktop failed. The session stays in the terminal.
+
+ Error: Couldn't open Claude Desktop (`open` exited 1: LSOpenURLsWithRole() failed for the URL claude://resume?session=<session-id> with error -10814). Open Claude Desktop and run /desktop again.
+
+**What to do:**
+
+ * Open Claude Desktop yourself, then run `/desktop` again
+ * To read that command’s full error output, turn on debug logging with `/debug`, run `/desktop` again, and check the debug log
+
+Before v2.1.275, the message was `Failed to open Claude Desktop. Please try opening it manually.` and didn’t say what failed.
+
+###
+
+
+
/terminal-setup left your Zed keymap unchanged
You ran [`/terminal-setup`](</docs/en/terminal-config#enter-multiline-prompts>) in Zed, and Claude Code couldn’t complete the update to your Zed `keymap.json`, so it left the file as it was. Each message names the path to your keymap and ends with the keybinding block to add yourself:
@@ -2867,6 +2931,21 @@
+Marketplace is already added from a different source
+
+You confirmed adding a marketplace through [`/plugin install <plugin> --marketplace <source>`](</docs/en/discover-plugins#add-a-marketplace-and-install-in-one-command>), and the catalog Claude Code fetched from that source names itself the same as a marketplace you already added from a different source. Claude Code keeps the existing marketplace instead of replacing it, and the plugin isn’t installed.
+
+ Marketplace "acme-tools" is already added from a different source (github:acme/plugins). To use this source instead, remove that marketplace first with /plugin marketplace remove acme-tools.
+
+**What to do:**
+
+ * If the marketplace you already added is the one you want, install from it by name: `/plugin install <plugin>@<name>`
+ * To switch to the new source, run `/plugin marketplace remove <name>`, then retry the install
+
+###
+
+
+
Plugin command references user_config in a shell command
A plugin hook, [monitor](</docs/en/plugins-reference#monitors>), or MCP [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) command references a `${user_config.KEY}` [plugin option](</docs/en/plugins-reference#user-configuration>), and the substituted string would be passed to a shell. A configured value containing `$(...)`, backticks, or `;` would run as code there, so Claude Code refuses to start the component instead of substituting the value. The check runs on the command template, so the error appears even when no value is configured yet. Before v2.1.207, the value was substituted into the shell command. The wording depends on which surface referenced the option. A shell-form hook reports:
@@ -3006,6 +3085,20 @@
* Open `~/.claude/plugins/known_marketplaces.json` and repair the JSON, or fix the entries the message names as not matching the registry schema
* If you can’t repair it, delete the file or replace its contents with `{}`, then re-add each marketplace with `claude plugin marketplace add <source>`. Claude Code re-registers the marketplaces your user or managed settings declare in [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>) the next time you start it in a folder you’ve trusted.
+
+###
+
+
+
+Plugin is required by your organization
+
+You ran `claude plugin disable`, or used the `/plugin` **Installed** tab, to turn off a [plugin synced from claude.ai](</docs/en/plugins-reference#synced-plugins>) that your organization marks as required:
+
+ Plugin "<name>@synced" is required by your organization and can't be disabled here. Contact your admin to change it.
+
+Claude Code saves nothing and the plugin stays enabled. When you try to disable a plugin that a required plugin depends on, Claude Code refuses the same way, with a message naming the required plugin that needs it. **What to do:**
+
+ * Ask an admin of your claude.ai organization to change the plugin’s required status on claude.ai
##
@@ -3367,6 +3460,27 @@
+Command blocked by the worktree isolation checks
+
+Claude ran a Bash or Monitor command in a [session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), and Claude Code refused it for one of two reasons:
+
+ * The command points git at the main checkout.
+ * Claude Code can’t verify from the command text that any git the command runs stays inside the worktree. A command that never names git can still be refused for this reason, because expanding a variable indirection such as `${!name}` or running a Bash function substitution such as `${ command; }` produces a value at runtime that can itself be a command.
+
+The middle of the message names what couldn’t be verified:
+
+ This session is isolated in the worktree /path/to/worktree, but this command evaluates ${!x@P} arithmetically inside a construct too complex to verify, which can run a command hidden in a variable's value. Refusing to run it — a worktree-isolated session's git operations must target its own worktree. Split it into plain, separate commands and run them from /path/to/worktree.
+
+**What to do:**
+
+ * Usually nothing: Claude reads the message and rewrites the command the way its final sentence asks
+ * If a command you asked for keeps being refused, spell the flagged value literally: replace the indirection or substitution with its value, and run git as its own plain command from inside the worktree
+ * To act on the main checkout on purpose, run the command yourself in a terminal outside the session
+
+###
+
+
+
This session has no saved transcript
You attached to a stopped [background session](</docs/en/agent-view>) that was backgrounded from another conversation with `←` or `/background` and stopped before its first response finished. Until that first response finishes, the conversation still lives only in the session it was backgrounded from, so `claude attach` refuses to start the stopped session rather than begin a blank conversation under the same session ID. The message ends with the `claude respawn` command for this session:
@@ -3692,7 +3806,7 @@
Failed to restore the code:
No files were restored: 1 file failed (backup missing, or the file could not be updated)
-Claude Code deletes a session’s backups in the [retention sweep](</docs/en/claude-directory#cleaned-up-automatically>), by default about 30 days after the session last saved one. If you resume a session after that, `/rewind` still lists its checkpoints, but rewinding to one of them can fail with this error. If the message also says `N paths were skipped for link safety`, see Restored the code, but skipped files for those paths. **What to do:**
+Claude Code deletes a session’s backups in the [retention sweep](</docs/en/claude-directory#cleaned-up-automatically>), by default about 30 days after the session last saved one. If you resume a session after that, `/rewind` still lists its checkpoints, but rewinding to one of them can fail with this error. If the message also says `N paths were skipped for link safety`, see Restored the code, but skipped files for those paths. When you fork a session, for example with [`--fork-session`](</docs/en/cli-reference#cli-flags>) or [`/branch`](</docs/en/sessions#branch-a-session>), Claude Code copies the original session’s backups into the fork. When Claude Code can’t copy a backup, for example because the disk is full, that backup is missing in the fork. Rewinding to a checkpoint that needs it can fail with this error. **What to do:**
* Undo the changes another way: ask Claude to reverse its edits, or restore the files from version control. When the backups are gone, running `/rewind` again fails the same way.
* If Claude Code couldn’t write or delete a file, fix what blocks the write, such as file permissions, then run `/rewind` again.
@@ -3936,6 +4050,24 @@
* If you administer the machine, fix the named document so it parses as a JSON object, or remove the file, profile, or registry value. An empty `managed-settings.json` counts as `{}` and doesn’t block launch.
* If you don’t, ask your administrator to fix the deployed document. Nothing in your own settings files causes or clears this error.
+
+###
+
+
+
+otelHeadersHelper failed
+
+Claude Code shows this warning as a notification in the terminal interface, once per interactive session, when the [`otelHeadersHelper`](</docs/en/settings-reference#otelheadershelper>) script fails or prints output that doesn’t meet the [script requirements](</docs/en/monitoring-usage#script-requirements>). While the script keeps failing, exports fail and your telemetry backend receives nothing from the session. The text after `See /status:` says what failed, such as the script’s exit code followed by its error output:
+
+ otelHeadersHelper failed; telemetry is not being exported. See /status: exited 1: token service unreachable
+
+**What to do:**
+
+ * Run `/status` to read the failure detail.
+ * Fix the script so it exits 0 within 30 seconds and prints a JSON object of string header values on stdout. See [script requirements](</docs/en/monitoring-usage#script-requirements>).
+ * If your organization deploys the script through [managed settings](</docs/en/managed-settings>), ask whoever maintains them to fix it.
+
+In [non-interactive mode](</docs/en/headless>) with `-p`, the same failure appears on stderr as `otelHeadersHelper failed (OpenTelemetry export headers unavailable): <error>` instead.
###
--- a/errors.md
+++ b/errors.md
@@ -222,6 +222,7 @@
`Refusing to send: connected endpoint is a different process with the expected pid`| Tool errors
`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
+`Refusing to write through symlink: <path>` / `Refusing to write into symlinked directory: <path>`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
@@ -1508,7 +1509,7 @@
HTTP 403
x-deny-reason: host_not_allowed
-You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:**
+You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:** These steps change one of your own environments. An [organization-shared environment](</docs/en/cloud-environments#organization-shared-environments>) opens read-only in the selector, so ask an Owner to change its network access from the **Cloud environments** page in [admin settings](<https://claude.ai/admin-settings>).
* Open the routine for editing, or start a cloud session. Select the cloud icon showing your environment’s name, such as **Default** , to open the selector. Hover over your environment and click the settings icon.
* In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
@@ -3213,11 +3214,13 @@
Refusing to read /path/to/file: its symlink resolution changed after permission was checked (a link on the way now leads somewhere the check did not see). If a link in the working directory is being rewritten concurrently, stop that and retry.
-The text after the path names the reason:
+Each refusal names its reason:
* `its symlink resolution changed after permission was checked`: a symlink along the path, or at a Grep or Glob search root, was replaced between the permission check and the operation. In a read refusal, the parenthesized phrase names which comparison failed.
* `its parent-directory symlink resolution changed after permission was checked`: a directory the write path passes through no longer resolves to the approved location
- * `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the approved write location itself
+ * `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the approved write location itself, for example a `CLAUDE.md` that is a symlink to `AGENTS.md`; the message directs Claude to the link’s target
+ * `Refusing to write through symlink: <path>. Resolve the symlink and pass the real target path explicitly.`: the same condition caught when another writer opens the file, such as a write to a symlinked `.mcp.json`
+ * `Refusing to write into symlinked directory: <path>`: the directory that holds the file is itself a symbolic link, for example a project’s `.claude/` directory linked to another location
* `a path one of its Read deny rules is written through changed while the search was being prepared. Retry.`: a `Read` deny rule for the search names a path that passes through a symlink, and that link changed while Claude Code was preparing the search
* `it could not be opened (EACCES) — it is unreadable, or is being replaced concurrently.`: the search root exists but couldn’t be opened; the parenthesized code is the operating system error
* `its permission check expired before it ran (too many concurrent file operations). Retry.`: Claude Code evicted the approval record under many simultaneous file operations before the tool used it; retrying runs a fresh permission check
@@ -3231,7 +3234,7 @@
* If a read refusal appears on macOS for a file that nothing is rewriting, such as a screenshot dragged into the prompt, upgrade to v2.1.273 or later
* For the ripgrep refusal, install ripgrep with your package manager so `rg` resolves to an absolute path on `PATH`, or keep searches under the working directory
-Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these refusals, only the parent-directory write refusal appears on earlier versions.
+Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these, only the parent-directory, through-symlink, and symlinked-directory write refusals appear on earlier versions.
###
Show diff (435 lines)
--- a/errors.md
+++ b/errors.md
@@ -60,6 +60,7 @@
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`Claude login not accepted · Run /login, then try again`| Authentication
`Not signed in to the Cloud gateway — run /login.`| Authentication
`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
@@ -69,18 +70,26 @@
`Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
+`MCP server "<name>" needs you to sign in again (run /mcp to re-authenticate)`| Authentication
+`rejected the credential from its headersHelper` / `rejected the Authorization header in its config`| Authentication
+`MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate`| Authentication
+`MCP server "<name>" requires re-authorization (token expired)`| Authentication
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
`Cloud gateway session expired — run /login to reconnect.`| Authentication
`Cloud gateway <url> no longer accepts this session`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
+`Google Cloud credentials expired or invalid`| Authentication
+`Google Cloud authentication failed`| Authentication
+`Microsoft Foundry authentication failed`| Authentication
+`Gateway refused the request`| Authentication
`Could not load AWS credentials` / `Could not load Google Cloud credentials`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
`Timed out after 60s waiting for AWS`| Authentication
`A request to AWS timed out. Check your network and proxy settings, then try again.`| Authentication
`Could not load the default credentials` on Google Cloud’s Agent Platform| Authentication
`Unable to connect to API`| Network
-`Connection refused —` / `Can't reach the API server —` / `No internet route —` / `Couldn't connect through your proxy` / `Connection dropped`, each ending with an error code in parentheses| Network
+`Connection refused —` / `Can't reach the API server —` / `No internet route —` / `Couldn't connect through your proxy` / `Connection dropped`, each with an error code in parentheses| Network
`Unable to connect to Anthropic services` during setup| Network
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
@@ -175,6 +184,7 @@
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
`GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud`| Command-line errors
+`Single sign-on authorization needed`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
@@ -182,6 +192,8 @@
`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
`Skill usage reports are not available on this connection.`| Command-line errors
+`Custom output styles can't be selected over Remote Control or from a relayed message`| Command-line errors
+`Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load`| Command-line errors
``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
@@ -208,7 +220,7 @@
`Refusing to send: connected endpoint is not the expected process` / `Refusing to send: connected endpoint identity could not be read`| Tool errors
`Refusing to send: connected endpoint is not owned by this user` / `Refusing to send: connected endpoint owner could not be read`| Tool errors
`Refusing to send: connected endpoint is a different process with the expected pid`| Tool errors
-`Refusing to read <path>: its symlink resolution changed after permission was checked` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
+`Refusing to read <path>: its symlink resolution changed after permission was checked (<reason>)` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
@@ -241,6 +253,7 @@
`Couldn't start a background session (working directory no longer exists or is not accessible: ...)`| Background session errors
`Claude Code is being updated by npm on this machine (still not runnable after 2 min, ...)`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
+`The connection to Claude Code ended before this message completed`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
@@ -1017,6 +1030,20 @@
+Claude login not accepted
+
+You tried to start a [cloud session](</docs/en/claude-code-on-the-web>), and the server refused to create it with a 401: it didn’t accept the Claude login this machine sent, usually because the login expired or was revoked. The first part of the line is the server’s own reason when it gives one. Otherwise the line reads:
+
+ Claude login not accepted · Run /login, then try again
+
+**What to do:**
+
+ * Run `/login`, complete the sign-in, then start the session again
+
+###
+
+
+
Administrator policy requires a Cloud gateway sign-in
An administrator’s [managed settings](</docs/en/managed-settings>) on this machine set [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"` or set [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>). Unless you select a cloud provider through a variable such as `CLAUDE_CODE_USE_BEDROCK`, Claude Code then accepts only the [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in. You see one of two messages:
@@ -1111,6 +1138,30 @@
+MCP server needs you to sign in again
+
+A remote [MCP server](</docs/en/mcp>) rejected the credential on a tool call mid-session, usually because a sign-in or token expired or because the token lacks a permission the tool needs. The tool call fails, and `/mcp` marks the server as [needing authentication](</docs/en/mcp#authenticate-with-remote-mcp-servers>). For a server you sign in to from Claude Code, including a claude.ai connector, the sign-in expired or was revoked:
+
+ MCP server "<name>" needs you to sign in again (run /mcp to re-authenticate)
+
+Run `/mcp`, select the server, and sign in again from its menu. For a server configured with a [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) script, Claude Code has already re-run the helper and retried the call once before showing this:
+
+ MCP server "<name>" rejected the credential from its headersHelper (check the helper and run /mcp to reconnect, or to authenticate if the server also uses OAuth)
+
+Check that the helper returns a credential the server accepts, then reconnect from `/mcp`, which runs the helper again. For a server with a static `Authorization` header in its configuration:
+
+ MCP server "<name>" rejected the Authorization header in its config (update it, then run /mcp to reconnect)
+
+Update the header value where the server is configured, then reconnect from `/mcp`. Before v2.1.273, the expired sign-in, `headersHelper`, and `Authorization` header cases all showed `MCP server "<name>" requires re-authorization (token expired)`. A server can also refuse a tool call with HTTP 403 `insufficient_scope` to ask you to authorize a scope, sometimes one your token already lists. The message names that scope:
+
+ MCP server "<name>" needs additional permissions (scope: "<scope>") — run /mcp to re-authenticate
+
+Run `/mcp`, select the server, and authenticate again from its menu. When the server’s configuration sets neither [`oauth.scopes`](</docs/en/mcp#restrict-oauth-scopes>) nor [`authServerMetadataUrl`](</docs/en/mcp#override-oauth-metadata-discovery>), Claude Code requests the scope the server named. With either setting, Claude Code requests that setting’s scopes instead. If you pinned `oauth.scopes`, add the missing scope to that list before you authenticate again. Before v2.1.274, this case showed the `needs you to sign in again` message, and before v2.1.273 it showed `requires re-authorization (token expired)` like the other cases.
+
+###
+
+
+
Issuer mismatch in authorization response
During an [MCP OAuth sign-in](</docs/en/mcp#authenticate-with-remote-mcp-servers>), the authorization server redirected back to Claude Code with an `iss` parameter that doesn’t name the issuer that Claude Code expected from the server’s OAuth metadata. A wrong issuer at this step is how an authorization server mix-up attack looks, so Claude Code fails the sign-in instead of exchanging the authorization code. Claude Code shows the error in the `/mcp` server menu after the browser sign-in:
@@ -1131,14 +1182,15 @@
AWS credentials expired or invalid
-This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS session token expired or was rejected, and the automatic refresh Claude Code already ran didn’t produce a credential the API accepts. It appears on a 401 from [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), which is how those providers report an expired security token. The action hint in the middle names the `awsAuthRefresh` command from your settings, so it varies. The stable part is the leading `AWS credentials expired or invalid`:
+Your AWS session token expired or was rejected. This message appears on a 401 from [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), which is how those providers report an expired security token. The action hint in the middle varies with your setup. The stable part is the leading `AWS credentials expired or invalid`:
AWS credentials expired or invalid · run /login and select "Claude Platform on AWS · refresh credentials", or run `aws sso login --profile myprofile` in another terminal · API Error: 401 ...
-Without `awsAuthRefresh` configured, the same 401 shows the generic `Please run /login` message instead, which can’t refresh AWS credentials. **What to do:**
-
- * Run the `awsAuthRefresh` command named in the message, such as `aws sso login --profile myprofile`, in another terminal and complete the browser sign-in, then retry
- * In an interactive session, run `/login`, choose **3rd-party platform** , then select **Claude Platform on AWS · refresh credentials** under **Using 3rd-party platforms** to run the same command without restarting Claude Code. See [Configure AWS credentials](</docs/en/claude-platform-on-aws#1-configure-aws-credentials>)
+Before v2.1.273, this message appeared only when `awsAuthRefresh` was configured. **What to do:**
+
+ * If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * If [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set, run the command named in the message, such as `aws sso login --profile myprofile`, in another terminal and complete the browser sign-in, then retry. Otherwise refresh the AWS credential you use yourself: your SSO sign-in, access keys, API key, or proxy token
+ * With `awsAuthRefresh` set in an interactive session, you can instead run `/login`, choose **3rd-party platform** , then select **Claude Platform on AWS · refresh credentials** under **Using 3rd-party platforms** to run the same command without restarting Claude Code. See [Configure AWS credentials](</docs/en/claude-platform-on-aws#1-configure-aws-credentials>)
* If the error repeats after the refresh command succeeds, confirm the identity is valid outside Claude Code with `aws sts get-caller-identity` in the same shell and profile
###
@@ -1147,15 +1199,72 @@
AWS authentication failed
-This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Claude Code can’t tell which cause you hit. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission or a model that isn’t enabled for your account. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Amazon Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
+Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission. Claude Code can’t tell those two causes apart. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Amazon Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
AWS authentication failed · run /login and select "Claude Platform on AWS · refresh credentials", or run `aws sso login --profile myprofile` in another terminal · if credentials are current, check AWS permissions and model access · API Error: 403 ...
-The action hint in the middle names the `awsAuthRefresh` command from your settings, so it varies. The stable part is the leading `AWS authentication failed`. **What to do:**
-
- * Run the `awsAuthRefresh` command named in the message, or `aws sso login`, in case an expired credential is the cause
+The action hint in the middle varies with your setup. The stable part is the leading `AWS authentication failed`. When the 403 is Amazon Bedrock’s answer that you don’t have access to the model with the specified model ID, the hint instead tells you to enable the model for your account and region in the Amazon Bedrock console. Before v2.1.273, this message appeared only when `awsAuthRefresh` was configured. **What to do:**
+
+ * If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * Refresh your AWS credentials in case an expired credential is the cause: run the [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) command named in the message when one is set, or refresh your SSO sign-in, access keys, API key, or proxy token yourself
* If your credentials are current, confirm the IAM permissions in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>) are attached to the identity you’re using and that the selected model is enabled for your account and region
* Run `aws sts get-caller-identity` to confirm which identity your requests use; a stale `AWS_PROFILE` or default profile is a common cause of a permission mismatch
+
+###
+
+
+
+Google Cloud credentials expired or invalid
+
+Your Google Cloud credentials for [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>) expired or were rejected: the request returned a 401, which is how Agent Platform reports credential expiry. The action hint in the middle varies with your setup. The stable part is the leading `Google Cloud credentials expired or invalid`:
+
+ Google Cloud credentials expired or invalid · refresh your Google Cloud credentials (application default sign-in, or the key file in GOOGLE_APPLICATION_CREDENTIALS) and retry · API Error: 401 ...
+
+**What to do:**
+
+ * If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * If you authenticate with application default credentials, run the [`gcpAuthRefresh`](</docs/en/google-vertex-ai#advanced-credential-configuration>) command named in the message, or `gcloud auth application-default login`, and complete the sign-in, then retry
+ * If you route through an [LLM gateway](</docs/en/llm-gateway>) with `CLAUDE_CODE_SKIP_VERTEX_AUTH` set, refresh the gateway token in `ANTHROPIC_AUTH_TOKEN` or `ANTHROPIC_CUSTOM_HEADERS`, then retry
+ * If you authenticate with a service account key file, confirm `GOOGLE_APPLICATION_CREDENTIALS` points at a valid key. See [Configure GCP credentials](</docs/en/google-vertex-ai#3-configure-gcp-credentials>)
+ * If the error repeats after a refresh, confirm the identity works outside Claude Code with `gcloud auth application-default print-access-token` in the same shell
+
+Before v2.1.273, a 401 from Agent Platform showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Google Cloud credentials.
+
+###
+
+
+
+Google Cloud authentication failed
+
+[Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>) returned a 403, which it uses for authorization denials rather than expired credentials. Usually the identity you authenticate with is missing an IAM permission, or the model isn’t enabled for your project. The action hint in the middle varies with your setup. The stable part is the leading `Google Cloud authentication failed`:
+
+ Google Cloud authentication failed · refresh your Google Cloud credentials (application default sign-in, or the key file in GOOGLE_APPLICATION_CREDENTIALS) and retry · if credentials are current, check GCP IAM permissions and Vertex AI model access · API Error: 403 ...
+
+**What to do:**
+
+ * If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * Confirm the roles in [IAM configuration](</docs/en/google-vertex-ai#iam-configuration>) are granted to the identity you authenticate with
+ * Confirm the model is enabled for your project. See [Request model access](</docs/en/google-vertex-ai#2-request-model-access>)
+
+Before v2.1.273, a 403 from Agent Platform showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Google Cloud credentials.
+
+###
+
+
+
+Microsoft Foundry authentication failed
+
+[Microsoft Foundry](</docs/en/microsoft-foundry>) returned a 401 or 403: the Azure credential on the request was rejected, or the identity behind it doesn’t have access to the Foundry resource. `/login` can’t mint Azure credentials. The action hint in the middle varies with your setup. The stable part is the leading `Microsoft Foundry authentication failed`:
+
+ Microsoft Foundry authentication failed · refresh your Foundry credential (ANTHROPIC_FOUNDRY_AUTH_TOKEN, ANTHROPIC_FOUNDRY_API_KEY, Azure sign-in for Entra, or your proxy token) and retry · if credentials are current, check access to the Foundry resource · API Error: 401 ...
+
+**What to do:**
+
+ * If the hint says credentials are managed by this environment, the app that launched Claude Code owns the credential and the other steps here don’t apply: retry, or contact your administrator
+ * Refresh the credential you configured in [Configure Azure credentials](</docs/en/microsoft-foundry#2-configure-azure-credentials>): rotate `ANTHROPIC_FOUNDRY_API_KEY`, mint a fresh `ANTHROPIC_FOUNDRY_AUTH_TOKEN`, or run `az login` so the default Microsoft Entra credential chain can sign in again
+ * If the credential is current, confirm the identity has access to the Foundry resource. See [Azure RBAC configuration](</docs/en/microsoft-foundry#azure-rbac-configuration>)
+
+Before v2.1.273, a 401 or 403 from Microsoft Foundry showed the generic `Please run /login` or `Failed to authenticate` message instead, which can’t refresh Azure credentials.
###
@@ -1227,6 +1336,23 @@
* Run `/login` in the session and complete the browser sign-in
* For a non-interactive launch, start `claude` in the same environment, run `/login`, then rerun your command
+
+###
+
+
+
+Gateway refused the request
+
+You’re signed in through a [Claude apps gateway](</docs/en/claude-apps-gateway>), and a request returned a 403: the gateway, or the upstream behind it, refused it. Signing in again doesn’t change a refusal, so the message points at your gateway administrator:
+
+ Gateway refused the request · signing in again won't change this — check with your gateway administrator · API Error: 403 ...
+
+**What to do:**
+
+ * Ask your gateway administrator to look up the request. The `API Error:` tail carries the refusal the gateway returned
+ * For administrators: an [access control rule](</docs/en/claude-apps-gateway-config#http-tuning>) on the gateway returns a 403 that the [audit log](</docs/en/claude-apps-gateway-deploy#logs>) records with its reason, and an upstream’s authorization denial passes through per [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
+
+Before v2.1.273, a 403 on a gateway session showed the generic `Please run /login` or `Failed to authenticate` message instead, and signing in again didn’t clear the refusal.
##
@@ -1248,7 +1374,7 @@
Connection refused — a firewall or proxy may be blocking it (ConnectionRefused)
Can't reach the API server — check your internet or DNS (ENOTFOUND)
No internet route — check your connection or VPN (EHOSTUNREACH)
- Couldn't connect through your proxy (ERR_PROXY_TUNNEL)
+ Couldn't connect through your proxy (ERR_PROXY_TUNNEL) — the proxy refused the tunnel: check its credentials and that it allows this host
Connection dropped (ECONNRESET)
fetch failed
Request timed out. Check your internet connection and proxy settings
@@ -1358,10 +1484,10 @@
A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Claude Code does not trust it.
- Unable to connect to API: SSL certificate verification failed. Check your proxy or corporate SSL certificates
- Unable to connect to API: Self-signed certificate detected. Check your proxy or corporate SSL certificates
-
-As of v2.1.199, a certificate validation failure isn’t retried, so this error appears on the first attempt instead of after the full retry budget. Earlier versions spent a few minutes retrying before showing it. Transient TLS conditions, such as a handshake timeout, still retry. During `/login` and the startup connectivity check, the same failure is reported with the OpenSSL code and the fix inline:
+ Unable to connect to API: SSL certificate verification failed (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). The certificate comes from an authority Claude Code doesn't trust, usually a TLS-inspecting corporate proxy or a gateway signed by a private CA: set NODE_EXTRA_CA_CERTS to that CA bundle, or add it to the system certificate store · see https://code.claude.com/docs/en/network-config
+ Unable to connect to API: Self-signed certificate detected (SELF_SIGNED_CERT_IN_CHAIN). The certificate comes from an authority Claude Code doesn't trust, usually a TLS-inspecting corporate proxy or a gateway signed by a private CA: set NODE_EXTRA_CA_CERTS to that CA bundle, or add it to the system certificate store · see https://code.claude.com/docs/en/network-config
+
+Before v2.1.273, both messages ended at `Check your proxy or corporate SSL certificates`, without the OpenSSL code or the `NODE_EXTRA_CA_CERTS` hint. As of v2.1.199, a certificate validation failure isn’t retried, so this error appears on the first attempt instead of after the full retry budget. Earlier versions spent a few minutes retrying before showing it. Transient TLS conditions, such as a handshake timeout, still retry. During `/login` and the startup connectivity check, the same failure produces a different message:
SSL certificate error (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). If you are behind a corporate proxy or TLS-intercepting firewall, set NODE_EXTRA_CA_CERTS to your CA bundle path, or ask IT to allowlist *.anthropic.com. Run `claude doctor` for details.
@@ -1511,7 +1637,12 @@
Prompt is too long · automatic compaction failed: <the underlying error>
-Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced `Prompt is too long` without the cause. A single-exchange conversation has no earlier turns to summarize. When automatic compaction would have run on one, Claude Code skips the attempt and explains what fills the request instead. When the API doesn’t report token counts in its error, the message reads:
+Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced `Prompt is too long` without the cause. When automatic compaction runs on this error, it normally summarizes your oldest exchanges and keeps the newest. As a last resort, Claude Code summarizes differently:
+
+ * When it can’t summarize any whole exchange, Claude Code keeps your newest prompt word for word and summarizes everything before it.
+ * In that case, when the conversation doesn’t end with your prompt, Claude Code summarizes the whole conversation instead.
+
+Claude Code skips this recovery when the content it would carry forward holds no model reply and less than about 1,000 tokens of your own text, such as a short retry sent after an oversized paste. Run `/clear` to start fresh. Before v2.1.269, compaction failed whenever it couldn’t summarize a whole exchange, so a session in that state hit this error again on every turn. A single-exchange conversation has no earlier turns to summarize. When automatic compaction would have run on one, Claude Code skips the attempt and explains what fills the request instead. When the API doesn’t report token counts in its error, the message reads:
Prompt is too long · this conversation is a single exchange and cannot be compacted — the request size comes mostly from system prompt, tool definitions, or attachments.
@@ -1525,7 +1656,7 @@
Before v2.1.162, Claude Code attempted the compaction anyway and surfaced the bare `Prompt is too long` when it failed. **What to do:**
- * In a multi-turn conversation, run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh. A single-exchange conversation can’t be compacted, so shrink the request instead
+ * Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh. If `/compact` answers `Not enough messages to compact.`, the conversation is a single exchange with nothing earlier to summarize, so the space is taken by that one prompt and what Claude Code sends with every request: run `/clear` and resend with less pasted text or smaller attachments, or reduce the tool definitions and memory files using the steps below
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
@@ -2396,7 +2527,7 @@
Unknown command
-You submitted a `/` name that doesn’t match any command in this session, so Claude Code reports the name instead of running anything:
+In an interactive terminal session, you submitted a `/` name that doesn’t match any command in this session, so Claude Code reports the name instead of running anything:
Unknown command: /hepl. Did you mean /help?
@@ -2406,7 +2537,15 @@
* A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them, such as `Cloud sessions are disabled by your organization's policy`
* A command from a [plugin](</docs/en/plugins>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
-Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
+Claude Code answers an unmatched `/` name this way only in an interactive terminal session. In every other session, it sends the prompt to Claude as a normal message instead, with a note that the command didn’t run and a list of commands Claude can run in the session. Those sessions include:
+
+ * `-p` runs
+ * [Agent SDK](</docs/en/agent-sdk/overview>) applications
+ * The Code tab of the [Desktop app](</docs/en/desktop>)
+ * The chat panel of the [VS Code extension](</docs/en/vs-code>)
+ * [Cloud sessions](</docs/en/claude-code-on-the-web>) and [routines](</docs/en/routines>)
+
+For a built-in command that can’t run in one of those sessions, Claude Code still answers that the command isn’t available instead of sending it to Claude. Before v2.1.274, only cloud sessions and routines sent an unmatched name to Claude. Before v2.1.273, they answered `Unknown command` too. Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
* Run the suggested name, or type `/` followed by part of the name to see what’s available in this session
* If Claude Code reports a documented command as unknown, check its row in the [commands reference](</docs/en/commands>) for the requirement it names
@@ -2528,6 +2667,25 @@
* Rerun the command a minute after connecting
Before v2.1.268, Claude Code reported this as a temporary failure of the Claude GitHub App check and suggested retrying or installing the app; neither connects a GitHub account.
+
+###
+
+
+
+Single sign-on authorization needed
+
+You ran [`/install-github-app`](</docs/en/github-actions#quick-setup>) and chose a repository whose organization enforces SAML single sign-on. Before setup, Claude Code checks your access to the repository with the GitHub CLI, and GitHub refused that check because your `gh` token isn’t authorized for the organization yet. The wizard shows the warning with the steps to authorize:
+
+ Single sign-on authorization needed
+ <owner>/<repo> belongs to an organization that enforces SAML single sign-on, and your GitHub CLI token isn't authorized for it yet.
+
+**What to do:**
+
+ * Re-authorize your GitHub CLI login with the `repo` and `workflow` scopes by running `gh auth refresh -h github.com -s repo,workflow`, and authorize the organization when GitHub prompts for single sign-on
+ * If you authenticate with a personal access token in `GH_TOKEN`, open [github.com/settings/tokens](<https://github.com/settings/tokens>), select **Configure SSO** on the token, and authorize the organization
+ * Run `/install-github-app` again
+
+Before v2.1.273, Claude Code showed the `Admin permissions required` warning for this condition instead.
###
@@ -2632,6 +2790,36 @@
**What to do:**
* Run `/skill-doctor` in the terminal on the machine where the session is running, or run `claude -p "/skill-doctor"` there
+
+###
+
+
+
+Custom output styles can’t be selected over Remote Control
+
+You ran [`/output-style`](</docs/en/output-styles#change-your-output-style>) from the mobile app or web via [Remote Control](</docs/en/remote-control>), or the command arrived in a message relayed into the session. Because such a turn may not come from the account owner, Claude Code lists and selects only [built-in styles](</docs/en/output-styles#built-in-output-styles>) on it, and adds this notice whenever the command lists the styles or doesn’t recognize the name you gave. A [custom style](</docs/en/output-styles#create-a-custom-output-style>) name gets the same reply as a name that doesn’t exist:
+
+ Custom output styles can't be selected over Remote Control or from a relayed message. Select one in the session itself, or pick a built-in style here.
+
+**What to do:**
+
+ * Pick a built-in style, for example `/output-style concise`
+ * To use a custom style, set [`outputStyle`](</docs/en/settings-reference#outputstyle>) in the project’s `.claude/settings.local.json`, or run `/output-style <style>` at the session’s own terminal if it has one
+
+###
+
+
+
+Output styles are saved to local settings which this session doesn’t load
+
+You tried to switch [output styles](</docs/en/output-styles>) with `/output-style <style>` or `/config outputStyle=<style>` in a session whose setting sources exclude `local`. Examples are an [Agent SDK](</docs/en/agent-sdk/typescript>) session whose [`settingSources`](</docs/en/agent-sdk/typescript#options>) leaves out `"local"` and a CLI session started with a [`--setting-sources`](</docs/en/cli-reference#cli-flags>) value that leaves out `local`. Both commands save the style to `.claude/settings.local.json`, a file such a session never reads back, so Claude Code refuses instead of writing a setting that would have no effect:
+
+ Output styles are saved to local settings (.claude/settings.local.json), which this session doesn't load, so the style can't be changed here.
+
+**What to do:**
+
+ * Add `local` to the session’s setting sources and switch again
+ * Set the [`outputStyle`](</docs/en/settings-reference#outputstyle>) key in a settings file the session does load, such as `.claude/settings.json` in the project or `~/.claude/settings.json`. In the TypeScript SDK, set `outputStyle` inside the inline `settings` object instead; see [Activate an output style](</docs/en/agent-sdk/modifying-system-prompts#activate-an-output-style>)
##
@@ -3023,11 +3211,11 @@
Claude Code checks a file path’s [permission rules](</docs/en/permissions#read-and-edit>), then confirms that resolution again when the tool opens the file or starts the search. When it can’t confirm that the path still leads to the location the check approved, Claude Code refuses the operation instead of following it. The refusal appears in the tool result:
- Refusing to read /path/to/file: its symlink resolution changed after permission was checked. If a link in the working directory is being rewritten concurrently, stop that and retry.
+ Refusing to read /path/to/file: its symlink resolution changed after permission was checked (a link on the way now leads somewhere the check did not see). If a link in the working directory is being rewritten concurrently, stop that and retry.
The text after the path names the reason:
- * `its symlink resolution changed after permission was checked`: a symlink along the path, or at a Grep or Glob search root, was replaced between the permission check and the operation
+ * `its symlink resolution changed after permission was checked`: a symlink along the path, or at a Grep or Glob search root, was replaced between the permission check and the operation. In a read refusal, the parenthesized phrase names which comparison failed.
* `its parent-directory symlink resolution changed after permission was checked`: a directory the write path passes through no longer resolves to the approved location
* `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the approved write location itself
* `a path one of its Read deny rules is written through changed while the search was being prepared. Retry.`: a `Read` deny rule for the search names a path that passes through a symlink, and that link changed while Claude Code was preparing the search
@@ -3040,6 +3228,7 @@
* Usually nothing: the refusal reaches Claude as the tool result, and the refused operation doesn’t run
* If a symlink refusal repeats on one path, find what keeps rewriting a link there, such as a build tool or file watcher, or ask Claude to use the file’s resolved path instead of the linked one
* If this refusal appears for every file while Claude Code runs on Windows inside an AppContainer or restricted-token sandbox, upgrade to v2.1.265 or later
+ * If a read refusal appears on macOS for a file that nothing is rewriting, such as a screenshot dragged into the prompt, upgrade to v2.1.273 or later
* For the ripgrep refusal, install ripgrep with your package manager so `rg` resolves to an absolute path on `PATH`, or keep searches under the working directory
Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these refusals, only the parent-directory write refusal appears on earlier versions.
@@ -3421,7 +3610,7 @@
Error: Claude Code process exited with code 1
-**What to do:**
+On Windows, the native build can exit with code `4294967295` right after a turn completes. When that exit lands at a turn boundary, with no message waiting and no background task running, the [VS Code extension](</docs/en/vs-code>) closes the session quietly instead of showing this error. Your next message resumes the conversation. Before v2.1.273, the extension showed the error for that exit at every turn boundary, even though nothing was lost. **What to do:**
* In VS Code, follow the **View output logs** link shown with the error to see the underlying failure
* In an Agent SDK application, catch the error around your message loop. The entries under [CLI process exit](</docs/en/agent-sdk/troubleshooting#cli-process-exit>) cover what your code receives in each SDK language.
@@ -3443,6 +3632,21 @@
* Open a new PowerShell window outside VS Code and run `where.exe claude`. If it doesn’t print a path, the CLI isn’t on your PATH: add its install directory by following [Verify your PATH](</docs/en/troubleshoot-install#verify-your-path>). If it prints a path, the entry comes from your PowerShell profile or from a PATH change VS Code hasn’t picked up yet; the next two steps cover those cases.
* Set the PATH entry as a user or system environment variable, not in your PowerShell profile. The extension doesn’t run your profile, so a PATH edit that lives only there never reaches it.
* Restart VS Code after changing PATH. The extension checks the PATH that VS Code captured at startup, so a PATH change takes effect only after a restart.
+
+###
+
+
+
+The connection to Claude Code ended before this message completed
+
+The [VS Code extension](</docs/en/vs-code>) sent your message to the `claude` process, and the connection ended without an error before the process acknowledged or finished it. The extension can’t tell whether the message was processed, so it asks you to send it again:
+
+ The connection to Claude Code ended before this message completed — it may not have been processed, so please send it again.
+
+**What to do:**
+
+ * Send the message again. The next message starts a fresh `claude` process that resumes the conversation.
+ * If it repeats, run `claude` in a terminal in the same project. A failure that keeps ending the process usually reproduces there with its real error message.
##
Show diff (296 lines)
--- a/errors.md
+++ b/errors.md
@@ -1,4 +1,4 @@
-This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). Except for Wrapper and IDE errors, which the launching program prints rather than Claude Code itself, these errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For other surface-specific issues, see the troubleshooting section on that surface’s page.
+This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). Except for Wrapper and IDE errors, which the launching program prints rather than Claude Code itself, these errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [cloud sessions](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For other surface-specific issues, see the troubleshooting section on that surface’s page.
Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
@@ -141,6 +141,8 @@
`Download timed out: exceeded the total deadline`| Installation errors
`--bg and --print conflict`| Command-line errors
`Cloud sessions cannot be created from a --restricted session`| Command-line errors
+`Cloud sessions are disabled by your organization's policy`| Command-line errors
+`Couldn't verify your organization's policy for cloud sessions`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Invalid --agents configuration:`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
@@ -157,6 +159,7 @@
`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`OAuth callback port <port> is already in use — another process may be holding it`| Command-line errors
+`No available ports for OAuth redirect`| Command-line errors
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
@@ -171,6 +174,7 @@
`Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected`| Command-line errors
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
+`GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
@@ -197,6 +201,7 @@
`pkill: refusing to run`| Tool errors
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
+`Its agent definition was not restored: the folder its definition file came from is not trusted`| Tool errors
`Message too large for cross-session delivery`| Tool errors
`Too many messages to this session just now`| Tool errors
`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
@@ -211,6 +216,9 @@
`Command killed: its output file was replaced or could no longer be verified`| Tool errors
`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
`the source file has the replacement character U+FFFD`| Tool errors
+`Reading a local file from outside this session's connected folders, or through a link, needs the approval card`| Tool errors
+`cannot read file_path (...) — the file could not be examined, and no one can answer the approval card`| Tool errors
+`WebFetch cannot fetch localhost or other hostnames without a dot`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -219,6 +227,7 @@
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
+`kept <id> — its worktree is still at <path>`| Background session errors
`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
@@ -544,14 +553,16 @@
The selected model uses the 1M-token extended context window, and your plan only includes it through usage credits.
- API Error: Usage credits required for 1M context · run /usage-credits to turn them on, or /model to switch to standard context
+ API Error: Usage credits required for 1M context · run /usage-credits to turn them on (they take effect after you restart Claude Code), or /model to switch to standard context
This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
- * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise
+ * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise. Restart Claude Code once usage credits are on. Until you restart, the session stays at the standard context limit.
* If the error persists after `/model`, a 1M model ID may be set elsewhere. See [Setting your model](</docs/en/model-config#setting-your-model>) for the configuration locations to check in priority order.
* To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
+
+Before v2.1.268, the message ended with `run /usage-credits to turn them on, or /model to switch to standard context` and didn’t mention restarting.
###
@@ -1738,7 +1749,7 @@
**What to do:**
* Run `/model` and select a model your plan includes
- * If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on the web does not take effect in an existing session until you re-authenticate.
+ * If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on claude.ai does not take effect in an existing session until you re-authenticate.
* See [claude.com/pricing](<https://claude.com/pricing>) for which models each plan includes
###
@@ -1767,7 +1778,7 @@
Model is restricted by your organization’s settings
-Your organization admin has disabled this model in the claude.ai admin console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model.
+Your organization admin has disabled this model in the claude.ai admin console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model. The substitution notice can also appear mid-session after an admin disables the model a session is running on in the claude.ai admin console.
Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
@@ -2019,7 +2030,7 @@
Cloud sessions cannot be created from a —restricted session
-When you start a session with [`--restricted`](</docs/en/cli-reference#cli-flags>), Claude Code refuses to create [cloud sessions](</docs/en/claude-code-on-the-web#from-terminal-to-web>) from it, because the new session would run outside the restricted process and wouldn’t enforce restricted mode. Claude Code refuses on the client, before contacting the server, so no cloud session is created:
+When you start a session with [`--restricted`](</docs/en/cli-reference#cli-flags>), Claude Code refuses to create [cloud sessions](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) from it, because the new session would run outside the restricted process and wouldn’t enforce restricted mode. Claude Code refuses on the client, before contacting the server, so no cloud session is created:
Cloud sessions cannot be created from a --restricted session: they would not enforce it.
@@ -2029,6 +2040,21 @@
* If you control how the session was launched, start a new `claude` session without `--restricted` and create the cloud session from there
Before v2.1.248, Claude Code had no `--restricted` flag; earlier versions reject the flag itself with an unknown-option error.
+
+###
+
+
+
+Cloud sessions are disabled by your organization’s policy
+
+Your organization’s `allow_remote_sessions` policy is off, so [cloud sessions](</docs/en/claude-code-on-the-web>) and the commands that use them aren’t available:
+
+ Cloud sessions are disabled by your organization's policy. Contact your organization admin to enable them.
+
+The message appears when you [create a cloud session from the terminal](</docs/en/claude-code-on-the-web#from-terminal-to-cloud>) and when you submit a command that needs cloud sessions, such as `/teleport`, `/remote-env`, or `/web-setup`. Before v2.1.268, submitting one of those commands returned `Unknown command` instead. This is a server-side organization policy, so it can’t be overridden from local settings, environment variables, or CLI flags. If Claude Code hasn’t loaded your organization’s policy yet or can’t fetch it, those commands answer `Couldn't verify your organization's policy for cloud sessions. Check your network connection, then restart Claude Code and try again.` instead. **What to do:**
+
+ * Ask an [Owner](</docs/en/server-managed-settings#access-control>) in your organization to enable cloud sessions in the Claude Code admin settings at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
+ * If the message says it couldn’t verify the policy, check your network connection, then restart Claude Code and try again
###
@@ -2272,6 +2298,21 @@
* Run the command from the message to find the process holding the port, and stop it or wait for it to finish
* If another program needs that port permanently, register a different redirect URI with the server and set its port with `MCP_OAUTH_CALLBACK_PORT` or `--callback-port`, whichever you use
+ * Then start the sign-in again, for example by selecting the server in `/mcp`
+
+###
+
+
+
+No available ports for OAuth redirect
+
+When you sign in to a remote MCP server with [OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>), Claude Code starts a local listener to receive the sign-in callback. The sign-in fails with this message when Claude Code can’t bind a local port for it. Something on the machine is preventing it from listening on `127.0.0.1`, for example security software or a sandbox policy that denies local listeners.
+
+ No available ports for OAuth redirect
+
+Before v2.1.268, Claude Code didn’t fall back to an operating-system-assigned port, so the message also appeared when only its self-picked ports couldn’t be bound. That can happen on Windows hosts where Hyper-V reserves port ranges that cover the ports Claude Code picks from. **What to do:**
+
+ * Check whether security software or a sandbox policy blocks processes from listening on `127.0.0.1`, and allow Claude Code to bind a local port
* Then start the sign-in again, for example by selecting the server in `/mcp`
###
@@ -2287,9 +2328,15 @@
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
-The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>). A failed injected command aborts that skill’s invocation. Two sibling strings fire before the command runs at all:
-
- * `Shell command permission check failed for pattern "..."`: the command’s permission check returned something other than allow. Injected commands never prompt, so the invocation aborts without asking you. Pre-approve commands that no rule matches with [`allowed-tools`](</docs/en/skills#pre-approve-tools-for-a-skill>). A matching ask or deny rule still aborts the invocation regardless of `allowed-tools`
+The message may quote `git log` or a different `git diff` instead. Git creates `origin/HEAD` only when the remote advertises a default branch and your fetch refspec covers it, which a full `git clone` of a remote with commits does. The ref is missing in these setups:
+
+ * A single-branch or CI checkout, which fetches too narrow a refspec
+ * A remote whose server-side HEAD points at a branch nobody pushed
+ * A repository with no `origin` remote, or one you never fetched
+
+Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>), and a failed injected command aborts that skill’s invocation. Two sibling strings fire before the command runs at all:
+
+ * `Shell command permission check failed for pattern "..."`: the command’s permission check didn’t allow it. [Permission checks on injected commands](</docs/en/skills#permission-checks-on-injected-commands>) covers which results abort in each permission mode and how to pre-approve a command with `allowed-tools`
* `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
**What to do:**
@@ -2356,7 +2403,7 @@
Claude Code suggests the closest command name or alias that the menu lists in this session. When nothing is close, the message ends after the name. The cause is usually one of the following:
* A typo, such as `/hepl` for `/help`. [How the command menu matches what you type](</docs/en/commands#how-the-command-menu-matches-what-you-type>) covers picking a close match before you submit
- * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them
+ * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them, such as `Cloud sessions are disabled by your organization's policy`
* A command from a [plugin](</docs/en/plugins>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
@@ -2464,6 +2511,23 @@
* If retries keep failing, the start of the message names what stopped the upload. When that cause is something you can fix, fix it so the session can start from your local repository instead
Before v2.1.251, Claude Code ended the message with `Please set up GitHub on https://claude.ai/code` even when the GitHub check failed only transiently, and setup advice can’t clear a transient failure.
+
+###
+
+
+
+GitHub isn’t connected to your Claude account
+
+You started a [cloud session](</docs/en/claude-code-on-the-web>) from your local repository, for example with `/autofix-pr`. No GitHub account is connected to your Claude account, or the connection expired, so Claude Code refuses the launch:
+
+ GitHub isn't connected to your Claude account, so this repository can't be cloned in the cloud. Run /web-setup to connect with your GitHub CLI login, or connect on the web at https://claude.ai/connect-github
+
+When you create a routine with [`/schedule`](</docs/en/routines>), the same message appears as a setup note that names the repository; the note doesn’t block creating the routine. **What to do:**
+
+ * Run `/web-setup` to connect your GitHub CLI login to your Claude account, or connect an account at [claude.ai/connect-github](<https://claude.ai/connect-github>). See [GitHub authentication options](</docs/en/claude-code-on-the-web#github-authentication-options>) for how the two differ.
+ * Rerun the command a minute after connecting
+
+Before v2.1.268, Claude Code reported this as a temporary failure of the Claude GitHub App check and suggested retrying or installing the app; neither connects a GitHub account.
###
@@ -2687,7 +2751,7 @@
Claude Code asked the operating system whether a plugin path exists and got an error other than “not found”, so it doesn’t load what the path names. How much of the plugin loads depends on which path failed:
- * One of a plugin’s [default component folders](</docs/en/plugins-reference#file-locations-reference>), such as `skills/` or `commands/`: the plugin’s other components still load
+ * One of a plugin’s [default component locations](</docs/en/plugins-reference#file-locations-reference>), such as the `skills/` folder, the `monitors/monitors.json` file, or a [`SKILL.md` at the plugin root](</docs/en/plugins-reference#skills>): the plugin’s other components still load
* The plugin’s own directory: nothing from that plugin loads
You don’t see this error for a path that doesn’t exist at all. In `/plugin`, the error appears under the plugin and names the path and the code the operating system returned:
@@ -2871,6 +2935,21 @@
* Ask the sender to resend the message; contention for the inbox lock is transient and clears on retry
* Check free disk space, and check that `~/.claude/teams` and the files under it are writable by your user
+
+###
+
+
+
+Teammate’s agent definition was not restored
+
+Claude messaged a stopped [agent team](</docs/en/agent-teams>) teammate, and Claude Code brought it back without re-applying the [subagent definition](</docs/en/agent-teams#use-subagent-definitions-for-teammates>) it was spawned from, because its definition file came from a folder with no saved trust. The notice follows the resume report in the sending agent’s tool result:
+
+ Its agent definition was not restored: the folder its definition file came from is not trusted (source: projectSettings), so the teammate is running with the team-essential tools and no custom instructions. To restore it, the user needs to run Claude Code in that folder once and accept the trust dialog (the --debug log names the folder); do not change trust settings on the user's behalf.
+
+The check applies to a definition in the `.claude/agents/` directory of the project or of an `--add-dir` directory, and accepting the trust dialog for a parent folder doesn’t satisfy it. **What to do:**
+
+ * Run `claude` in the folder the [debug log](</docs/en/debug-your-config>) names and accept the trust dialog. The definition is re-applied the next time Claude Code brings the teammate back; you don’t need to restart the lead session
+ * Or set the `hasTrustDialogAccepted` entry to `true` in `~/.claude.json`, using the exact `projects["<path>"]` key the debug log prints
###
@@ -3006,6 +3085,39 @@
Before v2.1.267, Claude Code uploaded such a file without checking it, and the server refused the publish instead.
+###
+
+
+
+Reading a local file from outside the connected folders in a Cowork session
+
+In a [Cowork](<https://claude.com/docs/cowork/overview>) session running on your machine in the Claude Desktop app, Claude named a local file for an [artifact](</docs/en/artifacts>). Claude Code couldn’t confirm the file is a plain file inside the session’s connected folders: the path sits outside those folders, passes through a symbolic link, or is spelled in a way that can name a different file than it appears to. Reading such a file needs your approval, and in a session that can’t show you the approval card, such as one set to skip all approvals, Claude Code refuses the read. The refusal appears in the Artifact tool result; when the file couldn’t be examined at all, it names that failure instead:
+
+ Reading a local file from outside this session's connected folders, or through a link, needs the approval card, and no one can answer it in this Cowork session. Use a plain file inside the connected folders; do not retry this file in this session.
+
+ cannot read file_path (ENOENT) — the file could not be examined, and no one can answer the approval card in this Cowork session. Check that the file exists as a plain file inside the connected folders, then retry with that path.
+
+**What to do:**
+
+ * Usually nothing: the message tells Claude to use a plain file inside the connected folders instead
+ * To put that exact file in the artifact, copy it into one of the session’s connected folders as a regular file, not a symlink, and ask again
+
+###
+
+
+
+WebFetch cannot fetch localhost
+
+Claude called [WebFetch](</docs/en/tools-reference#webfetch-tool-behavior>) with a URL whose hostname has no dot, such as `http://localhost:3000` or a bare intranet name like `http://wiki/`. WebFetch refuses these URLs before making any request:
+
+ WebFetch cannot fetch localhost or other hostnames without a dot. To reach a local server, use Bash with curl instead.
+
+**What to do:**
+
+ * Usually nothing: the message points Claude at `curl` through the Bash tool, which can reach local and intranet servers
+
+Before v2.1.268, WebFetch reported these URLs with a generic `Invalid URL` error.
+
##
@@ -3120,17 +3232,17 @@
You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits unseen. `claude rm` names the branch and the unpushed commits, and says how to proceed:
- kept 7c5dcf5d — 2 unpushed commits on claude/fix-login (a1b2c3d Fix login flow, … and 1 more)
- worktree: /home/you/project/.claude/worktrees/fix-login
- push them, or discard the worktree and its commits: claude rm 7c5dcf5d --discard-unpushed a1b2c3d000000000000000000000000000000000@0123456789abcdef0123456789abcdef
-
-When Claude Code can’t summarize the commits, the message reads `worktree has commits that are not pushed anywhere` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
+ kept 7c5dcf5d — its worktree is still at “/home/you/project/.claude/worktrees/fix-login”
+ 2 unpushed commits on “claude/fix-login”: a1b2c3d “Fix login flow” and 1 more. They exist on no remote, so deleting the worktree would lose them.
+ push them and run 'claude rm 7c5dcf5d' again, or discard the worktree and its commits: claude rm 7c5dcf5d --discard-unpushed a1b2c3d000000000000000000000000000000000@0123456789abcdef0123456789abcdef
+
+When Claude Code can’t summarize the commits, the detail line reads `The worktree has unpushed commits` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
* To keep the commits, push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
* To discard the commits, run the `claude rm <id> --discard-unpushed` command the message printed, or press `Ctrl+X` twice on the session’s row in agent view again. This removes the session and the worktree along with its branch, the unpushed commits, and any uncommitted changes. If the worktree has gained a commit since the refusal, Claude Code keeps it again and shows the updated state
* When the message says the worktree is also recorded by another finished session, deleting again doesn’t discard it: push the commits, then delete the session again
-Before v2.1.260, the message didn’t name the branch or the commits, and deleting again was refused the same way: deleting the session without pushing meant removing the worktree yourself with `git worktree remove --force <path>`, then running `claude rm <id>` again. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
+Before v2.1.268, `claude rm` put the commit summary on the `kept` line itself. When `claude rm` couldn’t summarize the commits, the `kept` line read `worktree has commits that are not pushed anywhere` in place of the summary. Before v2.1.260, the message didn’t name the branch or the commits, and deleting again was refused the same way: deleting the session without pushing meant removing the worktree yourself with `git worktree remove --force <path>`, then running `claude rm <id>` again. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
###
--- a/errors.md
+++ b/errors.md
@@ -313,7 +313,7 @@
Variable| Default| Effect
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
-[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once on a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
+[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once when a standard-speed request gets a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. For fast mode requests, see [Handle rate limits](</docs/en/fast-mode#handle-rate-limits>). On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
@@ -871,6 +871,7 @@
* A `CLAUDE_CODE_USE_*` provider variable, such as `CLAUDE_CODE_USE_BEDROCK` for [Amazon Bedrock](</docs/en/amazon-bedrock>) or `CLAUDE_CODE_USE_VERTEX` for [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>)
* [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) pointing at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai; before v2.1.196, a custom base URL didn’t block Remote Control
+ * `ANTHROPIC_UNIX_SOCKET` set, so the session sends its requests through a local socket rather than to `api.anthropic.com`
* An enterprise [cloud gateway](</docs/en/claude-apps-gateway>) sign-in made through `/login`, which doesn’t support Remote Control and has no variable to unset
**What to do:**
@@ -954,8 +955,7 @@
Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
OAuth token revoked · Please run /login
- OAuth token has expired · Please run /login
- API Error: 401 ... authentication_error
+ Please run /login · API Error: 401 OAuth token has expired ...
**What to do:**
@@ -996,7 +996,7 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
+This is not the same state as OAuth token revoked or expired. Those messages report a rejection the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
@@ -1302,7 +1302,7 @@
* A `Response:` clause with the content type, the kind of body, such as `body is an HTML page` or `empty body`, its size in bytes, and whether the response carried an Anthropic request id. When the response names a recognizable server, such as `nginx` or `cloudflare`, or carries intermediary headers, such as `cf-ray` or `via`, the clause lists those too.
* A sentence naming the failed streaming request’s id and the failure that triggered the retry. When a stream had opened before the failure, it also reports how many stream events arrived and, if any did, how long the stream had been silent when the attempt failed.
-Before v2.1.234, the message ended after `intercepting the request`. **What to do:**
+Before v2.1.234, the message ended after `intercepting the request`. Before v2.1.271, a reply that carried a valid API message under a non-JSON content type such as `text/plain` also ended the turn with this error. Some LLM gateways use that content type for the non-streaming reply. **What to do:**
* Read the `Response:` clause to see which system answered. An HTML body, no Anthropic request id, or a named server such as `nginx` or `cloudflare` means that something between Claude Code and the API replied in its place
* If you route through an [LLM gateway](</docs/en/llm-gateway-connect#troubleshoot-gateway-errors>), test the route with a direct request and fix the hop that returns the non-API response
@@ -1533,7 +1533,7 @@
Context exceeds the 200k-token limit by 94k tokens — run /compact or /clear to continue.
-When the limit you exceeded is a compaction window smaller than the model’s context window, such as the 200K boundary on 1M-context models, the warning reads differently. Requests still succeed past a compaction window; run the named command to bring usage back under it.
+When the limit you exceeded is a compaction window, such as the 200K boundary on 1M-context models, the warning reads differently. A compaction window can sit below the model’s context window, so requests past it can still succeed.
Context is 94k tokens past the 200k-token compaction window — run /compact to reduce usage.
Show diff (120 lines)
--- a/errors.md
+++ b/errors.md
@@ -33,6 +33,7 @@
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
+`You've hit your monthly spend limit` / `You've hit your individual spend limit` / `You've hit your org's monthly spend limit` / `You've hit your channel's monthly spend limit` / `You've hit your team's shared budget` / `You've hit your individual usage limit`| Usage limits
`Could not update your spend limit`| Usage limits
`spend limit reached` / `spend limit unavailable`| Usage limits
`Not logged in · Please run /login`| Authentication
@@ -177,6 +178,7 @@
`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
`Skill usage reports are not available on this connection.`| Command-line errors
+``plugin eval` is currently in early access` / ``plugin eval` is currently unavailable`| Plugin errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -532,7 +534,7 @@
* Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
-To watch your remaining allowance before you hit the limit, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
+Before a window runs out, Claude Code can warn you that you’ve used most of it, with a message such as `You've used 85% of your session limit · resets 3:45pm`. To watch your remaining allowance continuously, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
###
@@ -601,6 +603,28 @@
* Check your provider console for the active limits and request a higher tier if needed
* For Anthropic API keys, see the [rate limits reference](<https://platform.claude.com/docs/en/api/rate-limits>) for how tiers work and how to set per-workspace caps
* Reduce concurrency: lower [`CLAUDE_CODE_MAX_TOOL_USE_CONCURRENCY`](</docs/en/env-vars>), avoid running many parallel subagents, or switch to a smaller model with `/model` for high-volume scripted runs
+
+###
+
+
+
+You’ve hit your monthly spend limit
+
+Your plan’s included usage can’t cover this request, and the [usage credits](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) that would otherwise pay for it have reached a spend limit. That happens when one of your plan’s usage windows has run out, or when the request is one that only usage credits pay for, such as a request to a model that [bills to usage credits](</docs/en/model-config#fable-and-usage-credits>). The message names whose limit blocked you. The text after the `·` says how to get that limit increased, and varies with your plan and whether you manage billing:
+
+ You've hit your monthly spend limit · raise it at claude.ai/settings/usage
+ You've hit your individual spend limit · ask your admin for a higher limit
+ You've hit your org's monthly spend limit · visit claude.ai/admin-settings/usage to raise it
+ You've hit your team's shared budget · ask your admin to raise it at claude.ai/admin-settings/usage
+ You've hit your channel's monthly spend limit · an org owner or channel manager can raise it in the channel's Claude settings
+
+`team's shared budget` is a pooled budget an admin assigned to a group you belong to; the message doesn’t name the group. `channel's monthly spend limit` is the budget of the one Slack channel the session runs in, so your organization may still have budget outside it. When one of your plan’s windows is what ran out, the message also says when that window resets, for example `· your session limit resets 3:45pm`, and access returns then without anyone raising the limit. On organizations with usage-based billing, the message says `usage limit` in place of `spend limit`, as in `You've hit your individual usage limit`. Before v2.1.239, the message didn’t name the plan window’s reset time. Before v2.1.268, a group’s pooled budget produced the `individual spend limit` message instead of `team's shared budget`. If you connect through a Claude apps gateway and see lowercase `spend limit reached`, that is your gateway operator’s cap instead; see Spend limit reached. **What to do:**
+
+ * On Pro and Max, increase your monthly spend limit in [**Settings > Usage**](<https://claude.ai/settings/usage>) on claude.ai, or run `/usage-credits`
+ * On Team and Enterprise, increase the limit in [**Admin settings > Usage**](<https://claude.ai/admin-settings/usage>) if you manage billing, or ask an admin to. `/usage-credits` sends that request to your admin for you
+ * For a channel’s limit, ask an org owner or the channel’s manager to raise it on claude.ai. See [Per-channel limits](<https://claude.com/docs/claude-tag/admins/set-spend-limit#per-channel-limits>) in the Claude Tag documentation
+ * If the message names a reset time for your plan’s window, you can wait for it instead
+ * Run `/usage` to see your plan’s windows and when each resets
###
@@ -1951,7 +1975,7 @@
Command-line errors
-These errors come from the `claude` command line and its subcommands, from a command name you submit at the prompt, and from commands such as `/security-review` that gather context by running shell commands before their prompt runs. So do errors from `/tui`, which relaunches the CLI.
+These errors come from the `claude` command line and its subcommands, from a command name you submit at the prompt, and from commands such as `/security-review` that gather context by running shell commands before their prompt runs. They also come from `/tui`, which relaunches the CLI.
###
@@ -2047,10 +2071,11 @@
The current directory no longer exists (it was deleted or moved). Start Claude Code from an existing directory.
error: The current working directory was deleted, so that command didn't work. Please cd into a different directory and try again.
-The cause and the fix are the same for both forms. When Claude Code can’t read the working directory for a different reason, such as a permissions change, the message names the error code instead: `Can't read the current directory (EACCES). Start Claude Code from a different directory.` **What to do:**
+The cause and the fix are the same for both forms. When Claude Code can’t read the working directory for a different reason, such as a permissions change, the message names the error code instead: `Can't read the current directory (EACCES). Start Claude Code from a different directory.` On macOS, `EPERM` for a directory in `~/Desktop`, `~/Documents`, `~/Downloads`, or iCloud Drive usually means macOS is blocking your terminal app from that folder. Other commands that read that folder fail the same way: `ls` there reports `Operation not permitted`, even with `sudo`. **What to do:**
* Change to a directory that exists, such as your home or project directory, then run `claude` again
* If the directory was recreated at the same path, your shell still holds the deleted one. Run `cd "$PWD"` or leave and re-enter the directory, then run `claude` again
+ * For `EPERM` on macOS, quit your terminal app with Cmd+Q, open it again, return to that folder, and run `claude`. If `ls` in that folder still fails, open **System Settings > Privacy & Security > Files and Folders**, turn on the folder for your terminal app, then reopen the terminal
###
@@ -2118,7 +2143,7 @@
Claude Code turns `claude import` on through a feature flag it fetches from Anthropic and caches on disk. This message means the cached value is off. The cause is usually one of the following:
* You haven’t started a session since installing, so Claude Code hasn’t fetched the flag yet. The first `claude import` can print this even when the feature is available to you.
- * You use Claude Code through Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or Claude Platform on AWS. Claude Code doesn’t fetch feature flags on these providers, so `claude import` stays unavailable.
+ * You use Claude Code through Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or Claude Platform on AWS, or through a [Claude apps gateway](</docs/en/claude-apps-gateway#availability-and-limitations>). Claude Code doesn’t fetch feature flags in these sessions, so `claude import` stays unavailable.
* You set `DISABLE_TELEMETRY`, `DO_NOT_TRACK`, `DISABLE_GROWTHBOOK`, or [`CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`](</docs/en/env-vars>), which turn off feature-flag fetching, so `claude import` stays unavailable.
**What to do:**
@@ -2556,6 +2581,23 @@
+plugin eval is currently in early access
+
+You ran [`claude plugin eval`](</docs/en/plugin-evals>) or `claude plugin eval init` and it exited 1 with one of these messages before doing anything:
+
+ `plugin eval` is currently in early access
+
+ `plugin eval` is currently unavailable
+
+The first message means your build is older than v2.1.269, the first version where the command is generally available. The second means Anthropic has switched the command off server-side; nothing on your machine turns it back on. **What to do:**
+
+ * Run `claude --version`, then `claude update`, and run the command again in a fresh session. See the [requirements for plugin evals](</docs/en/plugin-evals#requirements>)
+ * If you see the second message on a current build, try again later after another `claude update`
+
+###
+
+
+
Marketplace is registered from an untrusted source
The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugin-marketplaces#marketplace-schema>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, the name was checked only when the marketplace was added, so an entry registered before its name became reserved kept loading.
@@ -2681,7 +2723,7 @@
`claude plugin install` reports the refusal like this:
- Cannot install my-plugin@my-marketplace: its marketplace entry path does not stay inside the marketplace directory (an absolute, climbing, network-shaped or link-traversing entry, an entry of a fetched marketplace that resolves outside its tree — or a relative entry in a url-catalog marketplace, which has no local directory)
+ Cannot install my-plugin@my-marketplace: its marketplace entry path does not stay inside the marketplace directory (an absolute, climbing, network-shaped, backslash-containing or link-traversing entry, an entry of a fetched marketplace that resolves or opens outside its tree — or a relative entry in a url-catalog marketplace, which has no local directory)
When an already-installed plugin’s entry fails the same check, `claude plugin list` shows the plugin as `failed to load` with:
Show diff (101 lines)
--- a/errors.md
+++ b/errors.md
@@ -207,6 +207,8 @@
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
`Command killed: its output file was replaced or could no longer be verified`| Tool errors
+`the source file is not valid UTF-8 text` / `the source file is not valid UTF-16 text`| Tool errors
+`the source file has the replacement character U+FFFD`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -225,6 +227,7 @@
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`EACCES: permission denied, posix_spawn`| Background session errors
`exited before it became reachable`| Background session errors
+`Couldn't start a background session (working directory no longer exists or is not accessible: ...)`| Background session errors
`Claude Code is being updated by npm on this machine (still not runnable after 2 min, ...)`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
@@ -1584,11 +1587,15 @@
Unable to resize image — dimensions exceed the 2000x2000px limit and image processing failed. Please resize the image to reduce its pixel dimensions.
Unable to resize image (… raw, … base64). The image exceeds the … API limit and compression failed. Please resize the image manually or use a smaller image.
Unable to resize image — could not verify image dimensions are within the 2000x2000px API limit.
-
-Claude Code normally resizes large images automatically. These errors mean the native image processor failed to load or returned an error, so the image couldn’t be resized to fit within API limits. **What to do:**
-
- * If the message asks you to convert the image, convert it to PNG, JPEG, GIF, or WebP and attach it again. Claude Code can verify dimensions for these formats without the image processor.
+ Unable to resize image — it is a CMYK JPEG, which Claude Code cannot decode, and at …px it is over the 2000x2000px limit, so it cannot be sent. Re-save it as an RGB PNG or JPEG and try again.
+ Unable to resize image — it is an animated WebP whose first frame Claude Code cannot decode, and at …px it is over the 2000x2000px limit, so it cannot be sent. Save its first frame as a PNG or JPEG and try again.
+ Unable to resize image — its pixels could not be decoded (the file may be damaged, or use an encoding Claude Code cannot read), and it is over the … API limit (… raw, … base64), so it cannot be sent. Re-save it as a PNG or JPEG and try again.
+
+Claude Code normally resizes large images automatically. These errors mean the image couldn’t be decoded or resized to fit within the API limits. **What to do:**
+
+ * If the message asks you to convert the image, convert it to PNG, JPEG, GIF, or WebP and attach it again. Claude Code can verify dimensions for these formats from the file header, without decoding the image.
* If the message reports a dimension or size limit, resize or recompress the image below that limit before attaching.
+ * If the message names a cause, such as a CMYK JPEG, an animated WebP, or a possibly damaged file, re-save the image in the format the message suggests and attach it again.
###
@@ -2390,11 +2397,11 @@
You ran `/code-review ultra <PR#>` or `claude ultrareview <PR#>`, and before creating the cloud session Claude Code asks the server whether [the GitHub account connected to your Claude account](</docs/en/ultrareview#review-a-pull-request>) can reach the PR’s repository. No account is connected, or the connection expired, so the cloud clone would fail and Claude Code refuses the launch. Claude Code doesn’t spend a free run or bill usage credits for a refused launch.
- Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected (or the connection expired). To fix: run /web-setup to reuse your GitHub CLI login, or connect an account at https://claude.ai/code/onboarding?step=alt-auth — then re-run /code-review ultra 1234 (allow a minute after connecting).
+ Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected (or the connection expired). To fix: run /web-setup to reuse your GitHub CLI login, or connect an account at https://claude.ai/connect-github — then re-run /code-review ultra 1234 (allow a minute after connecting).
When [`/web-setup`](</docs/en/web-quickstart#connect-from-your-terminal>) isn’t available in your session, the message names only the claude.ai link. **What to do:**
- * Run `/web-setup` to connect your GitHub CLI login to your Claude account, or connect an account at [claude.ai/code/onboarding](<https://claude.ai/code/onboarding?step=alt-auth>)
+ * Run `/web-setup` to connect your GitHub CLI login to your Claude account, or connect an account at [claude.ai/connect-github](<https://claude.ai/connect-github>)
* Rerun the review a minute after connecting
Before v2.1.248, Claude Code didn’t check this before launch.
@@ -2937,6 +2944,26 @@
* Or check your project’s directory under the Claude Code temp directory, `/private/tmp/claude-501/-Users-you-my-project` in the example message. If that path is a symbolic link, or a directory that shouldn’t be there, remove the link or directory itself rather than the link’s target, and restart Claude Code
* If the refusal repeats, a process is replacing, linking, or removing entries under Claude Code’s temp directory while the session runs. Set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory nothing else manages and restart
+###
+
+
+
+The source file is not valid UTF-8 text
+
+Claude tried to publish an [artifact](</docs/en/artifacts>) from a file whose bytes don’t decode as text, or whose text already contains the replacement character `U+FFFD`, so Claude Code refused the publish before uploading anything. The message appears in the Artifact tool result and names the first position to fix:
+
+ file_path: the source file is not valid UTF-8 text (first invalid byte at line 12, column 40). It may be saved in another encoding or contain binary data. Rewrite it as UTF-8, then publish again. Nothing was published.
+
+ file_path: the source file has the replacement character U+FFFD at line 12, column 40, usually left where an earlier edit or paste lost a character. Replace it with the intended text (in HTML, write an intended U+FFFD as �), then publish again. Nothing was published.
+
+Claude Code decodes the file as UTF-8, or as UTF-16 when it starts with a little-endian UTF-16 byte-order mark. When such a UTF-16 file doesn’t decode, the first message names `UTF-16` and still tells you to rewrite the file as UTF-8. When more positions follow the named one, the message adds a count such as `(+2 more)` after the position. **What to do:**
+
+ * Usually nothing: Claude rewrites the file and publishes again
+ * If the file is one you wrote or exported, save it again as UTF-8, and replace each `U+FFFD` with the character an earlier edit, paste, or conversion lost
+ * To show an intentional `U+FFFD` on the page, write it as `�` in the HTML instead of the literal character
+
+Before v2.1.267, Claude Code uploaded such a file without checking it, and the server refused the publish instead.
+
##
@@ -3207,6 +3234,20 @@
* If the message quotes a line, fix what it names, then open the session or dispatch again. The next attempt starts the service again
* Run `claude daemon status` to check whether a service is running now
+
+###
+
+
+
+Working directory no longer exists when starting a background session
+
+You tried to start a [background session](</docs/en/agent-view>) in a directory that doesn’t exist anymore. This happens when you dispatch from agent view or run `/background` after the directory you’re working in was deleted or moved. It also happens when you attach to or restart a session whose process has exited and whose directory is gone, because the new process would start in that same directory. Claude Code doesn’t start the session, and the message names the missing directory:
+
+ Couldn't start a background session (working directory no longer exists or is not accessible: /tmp/demo)
+
+Before v2.1.257, the session appeared to start and then showed in agent view as a failed row with the same reason. **What to do:**
+
+ * Recreate the directory the message names, or dispatch from a directory that exists, then try again
##
Show diff (752 lines)
--- a/errors.md
+++ b/errors.md
@@ -59,6 +59,8 @@
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
+`Not signed in to the Cloud gateway — run /login.`| Authentication
+`Administrator policy requires a Cloud gateway sign-in on this machine`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
@@ -67,10 +69,15 @@
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
`Issuer mismatch in authorization response (RFC 9207)`| Authentication
+`Cloud gateway session expired — run /login to reconnect.`| Authentication
+`Cloud gateway <url> no longer accepts this session`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
+`Could not load AWS credentials` / `Could not load Google Cloud credentials`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
-`Could not load the default credentials` on Google Cloud’s Agent Platform| Automatic retries
+`Timed out after 60s waiting for AWS`| Authentication
+`A request to AWS timed out. Check your network and proxy settings, then try again.`| Authentication
+`Could not load the default credentials` on Google Cloud’s Agent Platform| Authentication
`Unable to connect to API`| Network
`Connection refused —` / `Can't reach the API server —` / `No internet route —` / `Couldn't connect through your proxy` / `Connection dropped`, each ending with an error code in parentheses| Network
`Unable to connect to Anthropic services` during setup| Network
@@ -81,6 +88,7 @@
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
+`unable to get local issuer certificate`| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`proxy refused the connection`| Network
`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
@@ -97,6 +105,7 @@
`upstream rejected the request` / `request too large for this upstream` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
`upstream rate limit exceeded` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
`all upstreams failed (N attempted)` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
+`Claude Code may not be enabled for your organization` after a Claude apps gateway sign-in| [Claude apps gateway troubleshooting](</docs/en/claude-apps-gateway-deploy#troubleshooting>)
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -105,12 +114,16 @@
`Unable to resize image`| Request errors
`PDF too large` / `PDF is password protected`| Request errors
`Extra inputs are not permitted`| Request errors
-`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid`| Request errors
+`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid` / `Property keys should match pattern`| Request errors
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
+`Model ... not found`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
`Claude Code ... does not support this model; version ... or newer is required`| Request errors
+`Claude Code ... is older than the minimum version required by your organization's policy`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
+`Model switch ... blocked by a PreModelSwitch hook`| Request errors
+`couldn't save it as your default` / `couldn't confirm it was saved as your default`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
`effort '<level>' is not supported when thinking is disabled`| Request errors
@@ -131,20 +144,25 @@
`Error: Invalid --agents configuration:`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
+`couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
+`Cannot add MCP server to scope: managed`| Command-line errors
`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
+`Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes`| Command-line errors
`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
+`OAuth callback port <port> is already in use — another process may be holding it`| Command-line errors
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Error: Input contained only whitespace`| Command-line errors
`Blank prompt — the message was only whitespace, so nothing was sent to the model.`| Command-line errors
+`Error: stream-json input carried over 256M characters with no newline`| Command-line errors
`Unknown command: /<name>`, with or without a `Did you mean` suggestion| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
@@ -165,6 +183,9 @@
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`Plugin archive integrity check failed`| Plugin errors
`path escapes plugin directory`| Plugin errors
+`path could not be checked`| Plugin errors
+`its marketplace entry path does not stay inside the marketplace directory`| Plugin errors
+`Plugin source path refused`| Plugin errors
`Failed to load marketplace configuration`| Plugin errors
`Marketplace configuration file is corrupted`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
@@ -185,6 +206,7 @@
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`task output swap refused (tasks dir moved or linked)`| Tool errors
+`Command killed: its output file was replaced or could no longer be verified`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -193,6 +215,7 @@
`Can't open — this session is running in another terminal`| Background session errors
`This conversation is already open in another running Claude session`| Background session errors
`This session's saved conversation is no longer on disk`| Background session errors
+`kept <id> — <n> unpushed commits on <branch>`| Background session errors
`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
`Session isn't responding` / `Press enter again to restart this session — it isn't responding`| Background session errors
@@ -202,6 +225,7 @@
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`EACCES: permission denied, posix_spawn`| Background session errors
`exited before it became reachable`| Background session errors
+`Claude Code is being updated by npm on this machine (still not runnable after 2 min, ...)`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings and errors
@@ -215,6 +239,7 @@
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
+`Managed settings were not approved; exiting without applying them.`| Configuration warnings
`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
@@ -225,6 +250,7 @@
`... has a wildcard before the rest of the command`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
`[claude-code:unrecognized_model]`| Configuration warnings
+`Stale sandbox mask files left by a killed session`| Configuration warnings
Responses seem lower quality than usual| Response quality
##
@@ -245,7 +271,7 @@
* A request rejected because the input plus `max_tokens` exceeds the context limit. Re-sending it unchanged would fail the same way, so Claude Code retries with a reduced `max_tokens`, and stops retrying and compacts instead in two cases:
* When no reduction can fit, for example when the conversation itself nearly fills the context window.
* When a retry can’t shrink `max_tokens` any further. Before v2.1.218, Claude Code could re-send a reduced request that still didn’t fit, such as when the extended thinking budget exceeded the remaining context, until the retry budget ran out.
- * An expired or missing Google Cloud credential on [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), which surfaces as an error such as `Could not load the default credentials`. Claude Code discards its cached credentials and retries up to two times, running your [`gcpAuthRefresh`](</docs/en/google-vertex-ai#advanced-credential-configuration>) command if you configured one, then reports the error so you can re-authenticate right away. [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>) covers re-authenticating. Before v2.1.228, Claude Code retried a failing credential through the full retry budget before showing the error.
+ * An expired or missing Google Cloud credential on [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), or AWS credentials that fail to load on your machine. Claude Code discards its cached credentials and retries up to two times, then reports the error so you can re-authenticate right away, as described under Could not load AWS or Google Cloud credentials. Before v2.1.228, Claude Code retried a failing Google Cloud credential through the full retry budget before showing the error.
* A `401` or `403` from the Anthropic API, directly or through an [LLM gateway](</docs/en/llm-gateway>), while an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script supplies the credential. Claude Code re-runs the script and retries with its fresh output, within the full retry budget. When the script itself fails on the re-run, Claude Code shows Your apiKeyHelper script is failing instead.
Before v2.1.227, `Connection lost before a response was produced` read `Connection closed while thinking, before producing a response` and `The response stalled before a response was produced` read `Response stalled while thinking, before producing a response`. Claude Code doesn’t retry these failures:
@@ -533,7 +559,7 @@
Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.255, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
+The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.257, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
* At the terminal where the session runs, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
* Run `/model` to switch to a model that doesn’t bill usage credits
@@ -698,7 +724,7 @@
Your apiKeyHelper script is failing · This usually means you need to re-authenticate with your provider · Run /status to see the script's error output
-Claude Code re-runs the script and retries the request up to two more times before showing this message, so the failure surfaces within three attempts. Before v2.1.208, Claude Code spent the full retry budget resending the request with the placeholder credential and then reported a generic `401` authentication error instead of the script failure. Running `/login` doesn’t help here: the helper’s output [takes precedence](</docs/en/authentication#authentication-precedence>) over a saved login for as long as the setting is present. **What to do:**
+In [non-interactive mode](</docs/en/headless>), stderr also carries the specific reason, prefixed with `apiKeyHelper failed:`. Claude Code re-runs the script and retries the request up to two more times before showing this message, so the failure surfaces within three attempts. Before v2.1.208, Claude Code spent the full retry budget resending the request with the placeholder credential and then reported a generic `401` authentication error instead of the script failure. Running `/login` doesn’t help here: the helper’s output [takes precedence](</docs/en/authentication#authentication-precedence>) over a saved login for as long as the setting is present. **What to do:**
* Run the command configured in `apiKeyHelper` directly in your shell to reproduce the failure
* If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
@@ -924,7 +950,7 @@
**What to do:**
- * If `/status` shows an `API key` row, an approved [`ANTHROPIC_API_KEY`](</docs/en/authentication#authentication-precedence>) is the active credential and takes precedence over your login, so `/login` doesn’t replace it. Rotate the key in the Claude Console, or fall back to your subscription by running `unset ANTHROPIC_API_KEY`, or in PowerShell `Remove-Item Env:ANTHROPIC_API_KEY`.
+ * If `/status` shows an `API key` row that isn’t marked as not in use, an approved [`ANTHROPIC_API_KEY`](</docs/en/authentication#authentication-precedence>) is the active credential and takes precedence over your login, so `/login` doesn’t replace it. Rotate the key in the Claude Console, or fall back to your subscription by running `unset ANTHROPIC_API_KEY`, or in PowerShell `Remove-Item Env:ANTHROPIC_API_KEY`.
* If `/status` shows only your login, run `/login` once. If the credential was revoked, a fresh login replaces it.
* If the same message returns for the same login account, the account or organization is no longer active. Check the account and organization that `/status` reports, and ask your organization admin to restore access.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
@@ -948,6 +974,30 @@
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
+
+###
+
+
+
+Administrator policy requires a Cloud gateway sign-in
+
+An administrator’s [managed settings](</docs/en/managed-settings>) on this machine set [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"` or set [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>). Unless you select a cloud provider through a variable such as `CLAUDE_CODE_USE_BEDROCK`, Claude Code then accepts only the [Claude apps gateway](</docs/en/claude-apps-gateway>) sign-in. You see one of two messages:
+
+ Not signed in to the Cloud gateway — run /login.
+
+Model requests fail with this message when the session has no gateway sign-in, for example because you haven’t run `/login` since the policy reached the machine. If you also have an `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` credential configured and the managed settings set `forceLoginMethod`, Claude Code exits at startup instead with a message that begins:
+
+ Administrator policy requires a Cloud gateway sign-in on this machine; the
+ Anthropic-issued credential configured here (ANTHROPIC_API_KEY,
+ ANTHROPIC_AUTH_TOKEN, or apiKeyHelper) is not used.
+
+**What to do:**
+
+ * Run `/login` and complete the sign-in on the **Cloud gateway** screen
+ * For the startup message, remove the `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, or `apiKeyHelper` setting you configured, then start `claude` and run `/login`
+ * If you believe the machine shouldn’t require the gateway, ask the administrator who manages it to remove `forceLoginMethod` and `forceLoginGatewayUrl` from its managed settings
+
+On v2.1.265, a regression also showed the first message in some LLM-gateway and proxy configurations that authenticate with an API key, `apiKeyHelper`, or custom headers, even with no administrator requirement on the machine. Update to v2.1.266 or later. You don’t need to change your configuration. Before v2.1.261, on machines that set `forceLoginMethod` to `"gateway"`, Claude Code used a leftover saved login instead of failing model requests, and reported a configured environment credential with `This machine's managed settings require a first-party login` instead of the startup message. Before v2.1.265, a machine whose managed settings set only `forceLoginGatewayUrl` didn’t require the gateway sign-in, and Claude Code used a leftover credential there.
###
@@ -1073,17 +1123,72 @@
+Could not load AWS or Google Cloud credentials
+
+Claude Code couldn’t obtain usable credentials from the AWS credential provider chain or from your Google application default credentials on the machine it runs on, so no request reached your cloud provider. Claude Code clears its cached credentials and retries twice before showing this message. The detail after the `·` names the specific cause, such as an expired SSO session, missing application default credentials reported as `Could not load the default credentials`, or a revoked sign-in reported as `invalid_grant`:
+
+ API Error: Could not load AWS credentials · Could not load credentials from any providers. Check or refresh your AWS credentials and try again.
+ API Error: Could not load Google Cloud credentials · invalid_grant. Check or refresh your Google Cloud credentials and try again.
+
+In [non-interactive mode](</docs/en/headless>) with `-p` and in the [Agent SDK](</docs/en/agent-sdk/overview>), the structured error code is `cloud_credential_error`. Before v2.1.267, the message showed only the detail text after `API Error:`, and the structured code was `server_error` or `unknown`. **What to do:**
+
+ * Run your provider’s sign-in command, such as `aws sso login --profile myprofile` or `gcloud auth application-default login`, then retry. [Bedrock, Agent Platform, or Foundry credentials not loading](</docs/en/troubleshoot-install#bedrock-agent-platform-or-foundry-credentials-not-loading>) shows how to confirm the credentials outside Claude Code
+ * If the detail reads `AWS default-chain credential resolve timed out`, the chain hung rather than failed, so follow AWS default-chain credential resolve timed out instead
+
+###
+
+
+
AWS default-chain credential resolve timed out
-The AWS default credential provider chain didn’t produce credentials within 60 seconds, so Claude Code stopped the resolve and failed the request. The failure is local credential resolution: the request never reached [Amazon Bedrock](</docs/en/amazon-bedrock>), [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>). Claude Code clears its [credential cache](</docs/en/amazon-bedrock#credential-caching-and-resolution-timeout>) and retries before this error surfaces, so by the time you see it the chain has stalled on repeated attempts.
-
- API Error: AWS default-chain credential resolve timed out
-
-Common causes are a `credential_process` command in your AWS profile that waits for input it can’t receive, and a container or VM whose instance metadata service (IMDS) never answers the chain’s probe. Before v2.1.207, a stalled chain left the request waiting indefinitely instead of failing with this message. **What to do:**
+The AWS default credential provider chain didn’t produce credentials within 60 seconds, so Claude Code stopped the resolve and failed the request. This timeout is one cause of Could not load AWS or Google Cloud credentials. The failure is local credential resolution: the request never reached [Amazon Bedrock](</docs/en/amazon-bedrock>), [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>). Claude Code clears its [credential cache](</docs/en/amazon-bedrock#credential-caching-and-resolution-timeout>) and retries before this error surfaces, so by the time you see it the chain has stalled on repeated attempts.
+
+ API Error: Could not load AWS credentials · AWS default-chain credential resolve timed out. Check or refresh your AWS credentials and try again.
+
+Common causes are a `credential_process` command in your AWS profile that waits for input it can’t receive, and a container or VM whose instance metadata service (IMDS) never answers the chain’s probe. Before v2.1.267, the message read `API Error: AWS default-chain credential resolve timed out`. Before v2.1.207, a stalled chain left the request waiting indefinitely instead of failing. **What to do:**
* Run `aws sts get-caller-identity` in the same shell with the same `AWS_PROFILE`. If it also hangs, fix the profile; a `credential_process` command that prompts interactively is a common cause.
* Complete the sign-in step before starting Claude Code, for example `aws sso login --profile myprofile`, so the chain resolves from the local SSO cache instead of waiting on a browser flow
* If your chain runs an interactive sign-in that legitimately needs more than 60 seconds, such as SSO with MFA through a wrapper like `aws-vault`, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
+
+###
+
+
+
+Bedrock setup verification timed out waiting for AWS
+
+A call to AWS during the [Bedrock setup wizard](</docs/en/amazon-bedrock#sign-in-with-bedrock>)’s credential verification, such as the credential lookup or the identity check, didn’t finish within the 60-second limit. The wizard stops waiting and fails the verification step:
+
+ Timed out after 60s waiting for AWS. Check your network and proxy settings; if a credential helper needs longer to prompt you, raise CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS.
+
+The number reflects your limit: 60 seconds by default, or the value you set in [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>). Common causes are a network or proxy that stalls requests to AWS, including the SSO token refresh, and a credential helper still waiting for input you can’t see. Raise the limit only when the helper legitimately needs more time. A single stalled request to AWS can also fail on its own per-request timeout, which shows a shorter message on the same step:
+
+ A request to AWS timed out. Check your network and proxy settings, then try again.
+
+When the same timeouts occur on the model pin step, the wizard marks a model as `unreachable` instead of showing either message. **What to do:**
+
+ * Run `aws sts get-caller-identity` in the same shell. If it also hangs, the stall is outside Claude Code, in your network, your proxy, or the credential helper in your AWS profile; fix that first.
+ * Complete any interactive sign-in before opening the wizard, for example `aws sso login --profile myprofile`
+ * If a credential helper in your AWS profile legitimately needs longer than 60 seconds to prompt you, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
+
+###
+
+
+
+Cloud gateway session expired
+
+You signed in through a [Claude apps gateway](</docs/en/claude-apps-gateway>), and the gateway session saved on this machine has expired and couldn’t be renewed, or the gateway no longer accepts it, for example after the gateway’s [JWT secret is replaced](</docs/en/claude-apps-gateway-deploy#jwt-secret-rotation>). If you see this line when you start `claude` interactively, the session has opened signed out of the gateway:
+
+ Cloud gateway session expired — run /login to reconnect.
+
+The same line can appear mid-session when the gateway credential expires and Claude Code can’t renew it. In a [non-interactive](</docs/en/headless>) run, a background or other unattended session, or a `claude` subcommand other than `claude auth`, Claude Code exits with this message instead when the gateway no longer accepts the session:
+
+ Cloud gateway <url> no longer accepts this session. Start `claude` and sign in again with /login.
+
+**What to do:**
+
+ * Run `/login` in the session and complete the browser sign-in
+ * For a non-interactive launch, start `claude` in the same environment, run `/login`, then rerun your command
##
@@ -1222,7 +1327,7 @@
SSL certificate error (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). If you are behind a corporate proxy or TLS-intercepting firewall, set NODE_EXTRA_CA_CERTS to your CA bundle path, or ask IT to allowlist *.anthropic.com. Run `claude doctor` for details.
-**What to do:**
+On [Amazon Bedrock](</docs/en/amazon-bedrock>), the requests Claude Code itself sends to AWS, such as the STS and SSO role-credential calls, model discovery, and the setup wizard’s checks, depend on the same certificate configuration. See [Certificate errors behind a TLS-inspecting proxy](</docs/en/amazon-bedrock#certificate-errors-behind-a-tls-inspecting-proxy>). **What to do:**
* Export your organization’s CA bundle and point Claude Code at it with `NODE_EXTRA_CA_CERTS=/path/to/ca-bundle.pem`
* See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
@@ -1527,8 +1632,9 @@
A tool in the request declared an `input_schema` that fails the API’s JSON Schema validation, so the API rejected the whole request. The number after `tools.` is the failing tool’s position in the request’s tool list, not a name you can look up.
API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid
-
-Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a [deployment where flag fetching is off](</docs/en/env-vars#features-that-need-feature-flag-fetching>), or on a machine whose flags have never arrived, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`. Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though the top-level property-name check still applies. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
+ API Error: 400 ... tools.N.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'
+
+The first form means the schema isn’t valid JSON Schema draft 2020-12. The second means a top-level property name doesn’t match the pattern the message quotes. Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a [deployment where flag fetching is off](</docs/en/env-vars#features-that-need-feature-flag-fetching>), or on a machine whose flags have never arrived, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`. Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though the top-level property-name check still applies. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
* If your Claude Code version is earlier than v2.1.216, run `claude update`.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
@@ -1565,7 +1671,7 @@
Model "claud-sonnet-5" is not a recognized model id. Did you mean 'claude-sonnet-5'?
-The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you. **What to do:**
+The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method, by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you, or when you pick a model from a device connected through [Remote Control](</docs/en/remote-control>). Before v2.1.260, the check didn’t cover Remote Control picks, so Claude Code applied the pick and the next request failed with There’s an issue with the selected model. **What to do:**
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
* If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this local check even when the model is newer than your Claude Code version. The server can still require a minimum version for that model; see Claude Code does not support this model.
@@ -1576,6 +1682,22 @@
+Model not found
+
+You picked a model with `/model <name>` and Claude Code couldn’t confirm that a model with that name exists. When the name isn’t a [model alias](</docs/en/model-config#model-aliases>) or another spelling Claude Code accepts locally, `/model` verifies it with a minimal API request, and this error is usually your API endpoint’s answer. A name that can’t be a model ID at all, such as one containing spaces, gets the same message.
+
+ Model 'claude-opus-9' not found
+
+On providers with provider-specific model IDs, the message may add a `Try '...' instead` suggestion that names your provider’s ID for a fallback model. **What to do:**
+
+ * Run `/model` with no argument and pick from the models available to your account, or use a [model alias](</docs/en/model-config#model-aliases>) such as `sonnet`, which resolves to a maintained default
+ * If you typed a full ID, check it against your provider’s model catalog. A newly launched model can be available on the Anthropic API before your provider or region offers it.
+ * Before v2.1.265, `/model` also rejected the `opusplan[1m]` alias spelling with this error. On those versions, update Claude Code, or set the model in [settings](</docs/en/model-config#setting-your-model>) or with `--model` instead.
+
+###
+
+
+
Claude Opus is not available with the Claude Pro plan
Your active subscription plan does not include the model you selected.
@@ -1594,14 +1716,19 @@
Claude Code does not support this model
-The model you selected requires a newer Claude Code version than the one making the request. The server checks this per model.
+The API refused the request with a 400 because your Claude Code version is below a required minimum. Either the model you selected requires a newer version, which the server checks per model, or your organization’s policy requires one. The 400 carries the error code `claude_code_version_too_old`, and the message says which minimum applies.
API Error: 400 Claude Code 2.1.219 does not support this model; version 2.1.255 or newer is required. Run 'claude update', or update the Claude desktop app, then try again.
-**What to do:**
-
- * Run `claude update`, or update the Claude desktop app, then start a new session on the model
- * To keep working in the current session, switch to another model with `/model`
+The organization-policy wording reads:
+
+ API Error: 400 Claude Code 2.1.240 is older than the minimum version required by your organization's policy. Run 'claude update', or update the Claude desktop app, to continue.
+
+**What to do:**
+
+ * Run `claude update`, or update the Claude desktop app, then start a new session
+ * For the per-model wording, you can keep working in the current session by switching to another model with `/model`
+ * For the organization-policy wording, update before you continue
###
@@ -1618,6 +1745,43 @@
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
* If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, the `model` field of a settings file, or the `model` frontmatter of a [subagent](</docs/en/sub-agents#choose-a-model>), skill, or command, remove or update that value so the notice doesn’t recur
* If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
+
+###
+
+
+
+Model switch was blocked by a PreModelSwitch hook
+
+A [PreModelSwitch hook](</docs/en/hooks#premodelswitch>) didn’t approve the model switch you or a client requested, so the session keeps its current model. When the switch came from an [Agent SDK](</docs/en/agent-sdk/overview>) host or [Remote Control](</docs/en/remote-control>) rather than a command you typed, the message reads `Model switch blocked by a PreModelSwitch hook` without naming the target model.
+
+ Model switch to Opus 4.6 was blocked by a PreModelSwitch hook: Opus 4.6 is retired for this project. Use a newer model.
+
+The reason after the colon says what refused the switch:
+
+ * **A reason a hook wrote** : a PreModelSwitch hook supplied that reason when it [denied the switch or asked for confirmation](</docs/en/hooks#premodelswitch-decision-control>). Address what it asks, or pick a model your hooks allow.
+ * **`PreModelSwitch hook<name> did not respond before its timeout`**: a hook that doesn’t answer before its [timeout](</docs/en/hooks#timeouts>) blocks the switch. Fix the hanging command or raise that hook’s `timeout`, then switch again.
+ * **`confirmation required, and this session cannot ask`** : a hook answered `ask` without a reason, and a control request has no way to show the confirmation prompt. A `/model` command in a [`-p` run](</docs/en/headless>) reports the same condition with `(run /model interactively to confirm)` after the reason. Make the switch from an interactive session, or change the hook’s decision for this model.
+ * **`so organization-managed PreModelSwitch hooks could not be checked`** : Claude Code couldn’t tell which PreModelSwitch hooks your organization’s [managed plugins](</docs/en/settings-reference#enabledplugins>) deliver, for example because a managed plugin failed to load. One of those hooks might block the switch, so Claude Code refuses rather than apply the switch unchecked. The start of the reason names what failed. Claude Code re-checks on every switch attempt, so a failure that has since cleared stops blocking; if it keeps failing, run `claude --debug` and switch again to capture the details, then fix the plugin or ask your admin to fix it.
+ * **`a PreModelSwitch hook failed before answering`** or **`PreModelSwitch hooks were cancelled (the control stream closed) before answering`** : the hook run ended without a verdict, and Claude Code doesn’t treat that as approval. Run `claude --debug` to see what failed, then switch again.
+
+Before v2.1.260, the managed-plugin refusal read `plugin hooks could not be loaded, so PreModelSwitch hooks could not be checked; see the debug log`. Claude Code retried the plugin load once and then refused later switches in the session, even when your organization managed no plugins. Restart the session to run the plugin load again on those versions.
+
+###
+
+
+
+Couldn’t save it as your default
+
+You picked a model to save as your default, for example with `/model <name>` or `Enter` in the `/model` picker, and Claude Code couldn’t write the pick to your user settings file, `~/.claude/settings.json`. The switch itself applied, so the current session runs on the model you picked, but your default is unchanged and the next session starts on the old value.
+
+ Set model to Fable 5.1 for this session only · couldn't save it as your default: ~/.claude/settings.json can't be written (EROFS)
+
+The reason after the file path says what failed:
+
+ * **`can't be written (<code>)`**: the write failed with the operating system error code in parentheses, such as `EROFS` when the file, or the file it links to, sits on a filesystem that refuses writes. Make the file writable and switch again. If another tool generates the file, set the `model` key in that tool instead; see [A change you made in Claude Code is lost in new sessions](</docs/en/settings#a-change-you-made-in-claude-code-is-lost-in-new-sessions>).
+ * **`isn't valid JSON`** : the file on disk doesn’t parse, and Claude Code leaves it untouched rather than overwrite content it can’t read back. Fix the syntax error, then switch again; see [Fix a broken settings file](</docs/en/settings#fix-a-broken-settings-file>).
+
+A notice ending `couldn't confirm it was saved as your default (~/.claude/settings.json is still being written)` means the write hadn’t finished after three seconds. It continues in the background, so the default may still be saved; check which model your next session starts on, or run `/model <name>` again. Before v2.1.265, the notice said the model was `saved as your default for new sessions` even when the write failed.
###
@@ -1874,11 +2038,29 @@
You started `claude` from a directory that was deleted or moved after your shell entered it, for example a worktree or temp directory another shell removed. Claude Code can’t read its working directory, so it exits with code 1 before starting the session, in interactive and [non-interactive](</docs/en/headless>) mode alike. Before v2.1.239, Claude Code crashed with minified bundle source and a raw `ENOENT ... uv_cwd` stack on stderr instead of this message.
The current directory no longer exists (it was deleted or moved). Start Claude Code from an existing directory.
-
-When Claude Code can’t read the working directory for a different reason, such as a permissions change, the message names the error code instead: `Can't read the current directory (EACCES). Start Claude Code from a different directory.` **What to do:**
+ error: The current working directory was deleted, so that command didn't work. Please cd into a different directory and try again.
+
+The cause and the fix are the same for both forms. When Claude Code can’t read the working directory for a different reason, such as a permissions change, the message names the error code instead: `Can't read the current directory (EACCES). Start Claude Code from a different directory.` **What to do:**
* Change to a directory that exists, such as your home or project directory, then run `claude` again
* If the directory was recreated at the same path, your shell still holds the deleted one. Run `cd "$PWD"` or leave and re-enter the directory, then run `claude` again
+
+###
+
+
+
+Directory couldn’t be resolved to a real location
+
+You ran `/add-dir` for a subdirectory of your working directory, and Claude Code couldn’t resolve the directory to its real location. You already have file access to a subdirectory of the working directory, so `/add-dir` only loads its skills, commands, and agents. Before loading them, Claude Code checks that the directory’s real location, with any symlinks resolved, is inside the working directory. When Claude Code can’t resolve that location, it loads nothing and shows this message:
+
+ packages/app couldn't be resolved to a real location, so its skills, commands, and agents weren't loaded. Check that it is a directory inside the working directory and try again.
+
+**What to do:**
+
+ * Check that the path names a real directory inside the working directory, then run `/add-dir` again
+ * The message doesn’t change your file access; it only reports that the directory’s `.claude/` content wasn’t loaded
+
+Before v2.1.261, this message also appeared for every `/add-dir <subdirectory>` when the working directory was on a `/net/<host>` automount, where Claude Code declines to resolve paths by design; the directory was fine and retrying couldn’t help.
###
@@ -1971,6 +2153,35 @@
+Cannot add MCP server to the managed scope
+
+You ran `claude mcp add` or `claude mcp add-json` with `--scope managed`. That scope holds the servers your organization provides through the [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) managed setting. Claude Code reads them from managed settings only, so the command can’t write a server to that scope.
+
+ Cannot add MCP server to scope: managed
+
+**What to do:**
+
+ * Add the server to a scope you can write: `local`, `user`, or `project`. Without `--scope`, the command uses `local`. See [MCP installation scopes](</docs/en/mcp#mcp-installation-scopes>)
+ * To provide the server to every user in your organization, add it to [`managedMcpServers`](</docs/en/settings-reference#managedmcpservers>) in the managed settings you deploy
+
+###
+
+
+
+Can’t read .mcp.json
+
+A command that reads the project’s [`.mcp.json`](</docs/en/mcp#project-scope>), such as `claude mcp add` or `claude mcp add-json` with `--scope project`, or `claude mcp remove`, found that the file in your current directory isn’t a regular file or is larger than 2 MiB, so it exits with this error instead of reading the file.
+
+ Can't read .mcp.json: it isn't a regular file or is larger than 2097152 bytes. Fix or remove it, then run the command again.
+
+Before v2.1.257, a FIFO at `.mcp.json` left the command waiting forever with no output, and a symlink to a device file such as `/dev/zero` grew memory until the process was killed. **What to do:**
+
+ * Check what sits at `.mcp.json` in your current directory. Replace it with an ordinary JSON file in the [project-scope format](</docs/en/mcp#project-scope>), or delete it, then run the command again.
+
+###
+
+
+
Server is Anthropic-hosted and doesn’t support local OAuth
You started a sign-in for an MCP server whose URL points at an Anthropic-hosted connector host that authenticates through a third-party identity provider. These hosts include `microsoft365.mcp.claude.com`, `gmail.mcp.claude.com`, and `gcal.mcp.claude.com`. Claude Code refuses to start its local OAuth flow for these hosts from both the `/mcp` panel and `claude mcp login`, because [their sign-in works only through claude.ai](</docs/en/mcp#use-mcp-servers-from-claude-ai>).
@@ -2014,6 +2225,22 @@
* Check that the server starts and stays connected: run `claude mcp list` in the same directory and confirm the server is listed as connected
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
* If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
+
+###
+
+
+
+OAuth callback port is already in use
+
+When you sign in to a remote MCP server with OAuth, Claude Code starts a local listener to receive the sign-in callback. If the port that listener needs is held by another process, the sign-in fails with this message. This mostly happens with a [fixed callback port](</docs/en/mcp#use-a-fixed-oauth-callback-port>) set through the [`MCP_OAUTH_CALLBACK_PORT`](</docs/en/env-vars>) variable or `--callback-port`, since without one Claude Code picks an available port.
+
+ OAuth callback port <port> is already in use — another process may be holding it. Run `lsof -ti:<port> -sTCP:LISTEN` to find it.
+
+On Windows, the suggested command is `netstat -ano | findstr :<port>` instead. **What to do:**
+
+ * Run the command from the message to find the process holding the port, and stop it or wait for it to finish
+ * If another program needs that port permanently, register a different redirect URI with the server and set its port with `MCP_OAUTH_CALLBACK_PORT` or `--callback-port`, whichever you use
+ * Then start the sign-in again, for example by selecting the server in `/mcp`
###
@@ -2073,6 +2300,21 @@
+stream-json input carried over 256M characters with no newline
+
+Your program sent more than 268,435,456 characters on stdin without a newline to a `claude -p --input-format stream-json` run, so Claude Code prints this error to stderr and exits with code 1 instead of buffering more input. The message states that budget as `256M`. Before v2.1.257, Claude Code buffered such input without limit, growing memory until the process crashed or was killed.
+
+ Error: stream-json input carried over 256M characters with no newline. Each stream-json message must be a single newline-terminated JSON line: either the producer is not newline-terminating its messages, or one message exceeded this budget.
+
+Input this long without a newline usually means the producer isn’t a stream-json producer at all, such as a binary file or plain log output piped in by accident. A single message over the budget fails the same check. **What to do:**
+
+ * Check what’s piped to stdin. With [`--input-format stream-json`](</docs/en/cli-reference#cli-flags>), every message must be one newline-terminated JSON line
+ * To send plain text instead, drop `--input-format stream-json`; `claude -p` reads a plain-text prompt from stdin by default
+
+###
+
+
+
Unknown command
You submitted a `/` name that doesn’t match any command in this session, so Claude Code reports the name instead of running anything:
@@ -2313,9 +2555,9 @@
Marketplace "claude-community" is registered from an untrusted source: The name 'claude-community' is reserved for official Anthropic marketplaces. Only repositories from 'github.com/anthropics/' can use this name. To fix it, remove the marketplace and re-add it from the official source.
-**What to do:**
-
- * Run `claude plugin marketplace remove <name>`, then add the marketplace again from the official `github.com/anthropics` repository
+For a marketplace whose source isn’t a GitHub repository or a Git URL, such as a local directory, the middle sentence reads `can only be used with GitHub sources from the 'anthropics' organization` instead. `claude plugin marketplace add` runs the same check, and refuses a reserved name with `Failed to add marketplace:` followed by the same reserved-name sentence. **What to do:**
+
+ * If the marketplace is already registered, run `claude plugin marketplace remove <name>`, then add it again from the official `github.com/anthropics` repository
* If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
* See the reserved name list under [Marketplace schema](</docs/en/plugin-marketplaces#marketplace-schema>)
@@ -2377,11 +2619,71 @@
commands path escapes plugin directory: ./commands/deploy.md — it resolves to /home/user/shared/deploy.md, outside the plugin directory
+On macOS and Linux, Claude Code also rejects a component path that contains a backslash anywhere in it, even when the path stays inside the plugin. A plugin whose component paths use Windows-style separators loads on Windows and triggers this rejection on the other platforms:
+
+ commands path escapes plugin directory: ./commands\deploy.md — its path contains a backslash, which is not resolved reliably on this platform
+
Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Claude Code already rejected paths declared in `plugin.json` and the other component paths in a marketplace entry. Before v2.1.257, the check looked only at the path’s spelling, not at where a symlink leads. **What to do:**
* Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
* If the path is a symlink to a file outside the plugin, replace the symlink with a copy of the file
+ * If the message says the path contains a backslash, write the path with forward slashes, for example `./commands/deploy.md`
* To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>)
+
+###
+
+
+
+Path could not be checked
+
+Claude Code asked the operating system whether a plugin path exists and got an error other than “not found”, so it doesn’t load what the path names. How much of the plugin loads depends on which path failed:
+
+ * One of a plugin’s [default component folders](</docs/en/plugins-reference#file-locations-reference>), such as `skills/` or `commands/`: the plugin’s other components still load
+ * The plugin’s own directory: nothing from that plugin loads
+
+You don’t see this error for a path that doesn’t exist at all. In `/plugin`, the error appears under the plugin and names the path and the code the operating system returned:
+
+ skills path could not be checked: /home/user/my-plugin/skills (ELOOP)
+
+In `claude plugin list`, the same error reads `Path not found: /home/user/my-plugin/skills (skills, ELOOP)`. Causes that produce this error include:
+
+ * `ELOOP`: a symlink in the path points at itself or forms a loop
+ * `EIO` or `ESTALE`: the path is on a network mount that is broken or stale
+ * `EACCES`: one of the directories above the path denies you permission to traverse it
+
+**What to do:**
+
+ * Replace a symlink that points at itself with a real folder, or delete it
+ * If the path is on a network mount, remount the share
+ * If the code is `EACCES`, restore your execute permission on the directories above the path
+ * Run `/reload-plugins` after fixing the path, or restart Claude Code, to load the plugin or component
+
+Before v2.1.265, Claude Code treated a default component folder it couldn’t check as absent and loaded the plugin without that component, with no error.
+
+###
+
+
+
+Marketplace entry path does not stay inside the marketplace directory
+
+The plugin’s [marketplace entry](</docs/en/plugin-marketplaces#plugin-entries>) declares a source path that Claude Code can’t resolve to a location inside the marketplace’s own directory, so the plugin doesn’t install or load. The refusal covers:
+
+ * An entry path that is absolute, climbs out of the marketplace with `..`, or is spelled like a network path
+ * An entry in a marketplace fetched from a remote source, such as git or a URL, that reaches its target through a symlink resolving outside the marketplace directory
+ * A relative entry in a marketplace added from a direct URL to its `marketplace.json`: Claude Code downloads only that file, so no local plugin files exist for the path to name. See [Plugins with relative paths fail in URL-based marketplaces](</docs/en/plugin-marketplaces#plugins-with-relative-paths-fail-in-url-based-marketplaces>)
+
+`claude plugin install` reports the refusal like this:
+
+ Cannot install my-plugin@my-marketplace: its marketplace entry path does not stay inside the marketplace directory (an absolute, climbing, network-shaped or link-traversing entry, an entry of a fetched marketplace that resolves outside its tree — or a relative entry in a url-catalog marketplace, which has no local directory)
+
+When an already-installed plugin’s entry fails the same check, `claude plugin list` shows the plugin as `failed to load` with:
+
+ Plugin source path refused: ./my-plugin does not stay inside its marketplace directory. Check that the marketplace entry has a plain relative path.
+
+**What to do:**
+
+ * If you maintain the marketplace, write the entry’s `source` as a plain relative path such as `./plugins/my-plugin`, and keep any symlink it crosses pointed inside the marketplace directory
+ * If you added the marketplace from a direct URL, relative entries can’t resolve. Ask the marketplace author to use [another plugin source](</docs/en/plugin-marketplaces#plugin-sources>), or add the marketplace from its git repository instead
###
@@ -2609,6 +2911,7 @@
* Usually nothing: the refusal reaches Claude as the tool result, and the refused operation doesn’t run
* If a symlink refusal repeats on one path, find what keeps rewriting a link there, such as a build tool or file watcher, or ask Claude to use the file’s resolved path instead of the linked one
+ * If this refusal appears for every file while Claude Code runs on Windows inside an AppContainer or restricted-token sandbox, upgrade to v2.1.265 or later
* For the ripgrep refusal, install ripgrep with your package manager so `rg` resolves to an absolute path on `PATH`, or keep searches under the working directory
Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these refusals, only the parent-directory write refusal appears on earlier versions.
@@ -2619,15 +2922,20 @@
Task output swap refused
-Claude Code saves each Bash command’s output to a file under its temp directory. This message means a directory on that file’s path is a symbolic link or has been moved, so Claude Code refused to run the command rather than write its output through that path. The message appears in the Bash tool result:
+Claude Code saves each Bash command’s output to a file under its temp directory. Every time it opens one of these files, it checks that the path still leads to the file it created, with no symbolic link, extra hard link, or moved directory redirecting it. This message means that check failed, so Claude Code refused the operation rather than write or read output through that path. The message appears in the Bash tool result:
task output swap refused (tasks dir moved or linked): /private/tmp/claude-501/-Users-you-my-project/1f0e62dc-4b0a-4f5e-9c2d-8a7b6c5d4e3f/tasks/b7k2f9m3q.output. To recover: restart Claude Code with CLAUDE_CODE_TMPDIR set to a fresh directory; or, if /private/tmp/claude-501/-Users-you-my-project is a stray directory or a symbolic link that should not be there, remove that entry itself (not what it points to) and restart.
+
+The parenthesized text names the check that failed. Reasons such as `output symlink was re-pointed`, `output file identity changed`, and `not a regular file` all report the same condition: something at or along the output path is no longer the file Claude Code created. Only some reasons carry a `To recover:` sentence. If the check fails while a command is still running, Claude Code stops the command, and its result reports:
+
+ Command killed: its output file was replaced or could no longer be verified
**What to do:**
* Upgrade to v2.1.260 or later. Earlier versions sometimes showed this message when no link or moved directory was present
* Restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a fresh directory
* Or check your project’s directory under the Claude Code temp directory, `/private/tmp/claude-501/-Users-you-my-project` in the example message. If that path is a symbolic link, or a directory that shouldn’t be there, remove the link or directory itself rather than the link’s target, and restart Claude Code
+ * If the refusal repeats, a process is replacing, linking, or removing entries under Claude Code’s temp directory while the session runs. Set [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) to a directory nothing else manages and restart
##
@@ -2741,18 +3049,19 @@
Worktree has commits that are not pushed anywhere
-You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits. `claude rm` prints the kept path and the reason:
-
- kept 7c5dcf5d — worktree has commits that are not pushed anywhere
- worktree kept at /home/you/project/.claude/worktrees/fix-login
- resolve that (commit/push, or remove the worktree), then run 'claude rm 7c5dcf5d' again
-
-When you delete from [agent view](</docs/en/agent-view>) with a `Ctrl+X` double-press, you consent to discarding uncommitted changes, but not to discarding commits, so Claude Code refuses there too. After a refused delete, the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
-
- * Push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
- * To delete the session without pushing or merging the commits, first note the branch that `git worktree list` shows for the path the message names. Remove the worktree yourself with `git worktree remove --force <path>`, as described in [Clean up subagent and background-session worktrees](</docs/en/worktrees#clean-up-subagent-and-background-session-worktrees>), then run `claude rm <id>` again. Neither step deletes that branch, so the commits stay on it until you run `git branch -D <branch>`.
-
-Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
+You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits unseen. `claude rm` names the branch and the unpushed commits, and says how to proceed:
+
+ kept 7c5dcf5d — 2 unpushed commits on claude/fix-login (a1b2c3d Fix login flow, … and 1 more)
+ worktree: /home/you/project/.claude/worktrees/fix-login
+ push them, or discard the worktree and its commits: claude rm 7c5dcf5d --discard-unpushed a1b2c3d000000000000000000000000000000000@0123456789abcdef0123456789abcdef
+
+When Claude Code can’t summarize the commits, the message reads `worktree has commits that are not pushed anywhere` instead. In [agent view](</docs/en/agent-view>), the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
+
+ * To keep the commits, push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
+ * To discard the commits, run the `claude rm <id> --discard-unpushed` command the message printed, or press `Ctrl+X` twice on the session’s row in agent view again. This removes the session and the worktree along with its branch, the unpushed commits, and any uncommitted changes. If the worktree has gained a commit since the refusal, Claude Code keeps it again and shows the updated state
+ * When the message says the worktree is also recorded by another finished session, deleting again doesn’t discard it: push the commits, then delete the session again
+
+Before v2.1.260, the message didn’t name the branch or the commits, and deleting again was refused the same way: deleting the session without pushing meant removing the worktree yourself with `git worktree remove --force <path>`, then running `claude rm <id>` again. Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
###
@@ -2817,7 +3126,7 @@
Session agent no longer available
-You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
+You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools, so the agent’s tool restrictions no longer apply:
This session was running agent 'code-reviewer', which is no longer available (no agent by that name in /home/you/project). Continuing with the default tools and system prompt — the agent's tool restrictions no longer apply. To restore it, re-create the agent, or resume with an explicit --agent <name>.
@@ -2870,9 +3179,13 @@
Couldn't start the background service — spawn background service: EACCES: permission denied, posix_spawn '/usr/local/lib/node_modules/@anthropic-ai/claude-code/bin/claude'
-When you start a session with `/background` or `claude --bg`, the same reason appears inside `Couldn't reach the background service (...)`. During the same reinstall window the error can name another code instead, such as `ENOENT` or `ENOEXEC`, or `EUNKNOWN` or `EPERM` on Windows; an `EUNKNOWN` that persists across retries has a different cause. On an npm installation, Claude Code waits up to ten seconds for the reinstall to finish and retries on its own, so you see the error only when the binary stays unrunnable for longer, such as while npm is still downloading the package. Before v2.1.246, Claude Code failed at once. **What to do:**
-
- * Wait a few seconds, then open the session or dispatch again.
+When you start a session with `/background` or `claude --bg`, the same reason appears inside `Couldn't reach the background service (...)`. During the same reinstall window the error can name another code instead, such as `ENOENT` or `ENOEXEC`, or `EUNKNOWN` or `EPERM` on Windows; an `EUNKNOWN` that persists across retries has a different cause. On an npm installation, Claude Code waits for the reinstall to finish and retries on its own: up to ten seconds, and up to two minutes while an npm install of Claude Code is visibly still running on the machine, which covers another Claude Code process downloading an update. When the install outlasts that wait, the failure names the update instead of the bare error code:
+
+ Claude Code is being updated by npm on this machine (still not runnable after 2 min, EACCES) — try again when the update finishes
+
+Before v2.1.257, the wait stopped at ten seconds in every case, so this error appeared while another Claude Code process was still downloading an update. Before v2.1.246, Claude Code failed at once, without waiting. **What to do:**
+
+ * Wait a few seconds, then open the session or dispatch again. When the message says Claude Code is being updated, retry after the update finishes.
* If the error persists while no npm install is running, your user can’t run the installed binary. Check its permissions and its directory’s, or reinstall Claude Code.
###
@@ -2885,7 +3198,12 @@
Couldn't reach the background service (background service exited before it became reachable (exit code N): <the service's first error line>) — run 'claude daemon status'
-When you open a session from [agent view](</docs/en/agent-view>), the same reason follows `Couldn't start the background service —`. When the service printed nothing before exiting, the message says `nothing on stderr` instead. Claude Code reports the failure with the service’s error line. Before v2.1.246, the failure surfaced only after a 45-second wait, as `background service did not become reachable within 45s`, without the service’s error line. **What to do:**
+When you open a session from [agent view](</docs/en/agent-view>), the same reason follows `Couldn't start the background service —`. When the service printed nothing before exiting, the message says `nothing on stderr` instead. Claude Code reports the failure with the service’s error line. Before v2.1.246, the failure surfaced only after a 45-second wait, as `background service did not become reachable within 45s`, without the service’s error line. Two quoted reasons have known causes:
+
+ * `Error: claude native binary not installed.`: an npm install was replacing the Claude Code binary at that moment, so the service ran npm’s placeholder instead. Retry after the install finishes; if the line persists with no install running, [complete the npm install](</docs/en/troubleshoot-install#native-binary-not-found-after-npm-install>). Before v2.1.257, a macOS npm self-update produced this failure on every start during the install window.
+ * `nothing on stderr` with exit code 1, on every start, on Windows: `daemon.lock` names a process that Claude Code can neither signal nor prove is gone, so each new service concludes another one holds the lock and exits. A lock whose writer Claude Code can prove is gone is replaced on its own and doesn’t produce this failure. When the failure repeats on every start, delete `~/.claude/daemon.lock`, then open the session or dispatch again. Before v2.1.257, such a lock blocked every start until you deleted the file.
+
+**What to do:**
* If the message quotes a line, fix what it names, then open the session or dispatch again. The next attempt starts the service again
* Run `claude daemon status` to check whether a service is running now
@@ -3156,6 +3474,21 @@
* Run `/status` or `claude doctor` for the full diagnostic
Before v2.1.248, Claude Code reported a failed settings fetch only in the debug log.
+
+###
+
+
+
+Managed settings were not approved
+
+Your organization’s [server-managed settings](</docs/en/server-managed-settings>) include settings that need your approval, and you declined the [security approval dialog](</docs/en/server-managed-settings#security-approval-dialogs>), so Claude Code exits without applying them:
+
+ Managed settings were not approved; exiting without applying them.
+
+**What to do:**
+
+ * Start Claude Code again and approve the dialog to continue under your organization’s settings. A declined dialog isn’t remembered, so it appears again at the next start.
+ * If you’re unsure about a setting the dialog lists, ask whoever maintains your organization’s managed settings before approving
###
@@ -3350,6 +3683,24 @@
Before v2.1.233, Claude Code wrote no line when it sent a request for a model ID it didn’t recognize.
+###
+
+
+
+Stale sandbox mask files left by a killed session
+
+`claude doctor` prints this warning in its diagnostics, and `/status` lists the same line. It appears on Linux and WSL2 when [sandboxing](</docs/en/sandboxing>) is enabled with filesystem isolation on. While a sandboxed command runs, the sandbox holds a write denial on a file that doesn’t exist yet by creating a 0-byte read-only placeholder there, and removes it afterward. A session killed before that cleanup runs, for example by SIGKILL, leaves the placeholders behind. Later sessions bind them read-only again on every start, so a settings write such as saving “Yes, and don’t ask again” fails where one sits.
+
+ - Stale sandbox mask files left by a killed session: /home/you/project/.claude/settings.local.json
+ Fix: Remove each with `rm <path>` while no other Claude Code session is running in that project — a 0-byte read-only file where a settings file belongs makes "Yes, and don't ask again" fail to save, and the sandbox binds it read-only again on every start
+
+**What to do:**
+
+ * Quit any other Claude Code session running in that project, then delete each listed file with `rm`. The warning names up to three files and counts the rest, so rerun `claude doctor` after deleting until the warning no longer appears. A placeholder that another session’s sandbox is still using is a live part of that session’s write protection
+ * If a permission choice you saved with “Yes, and don’t ask again” didn’t stick, save it again after deleting the placeholder
+
+Before v2.1.257, `claude doctor` didn’t flag these files; earlier versions leave the same placeholders behind when a session is killed.
+
##
Show diff (284 lines)
--- a/errors.md
+++ b/errors.md
@@ -158,6 +158,7 @@
`Cannot switch renderers while work is running in the background`| Command-line errors
`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
+`Skill usage reports are not available on this connection.`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -183,6 +184,7 @@
`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
+`task output swap refused (tasks dir moved or linked)`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -202,7 +204,8 @@
`exited before it became reachable`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
-`Restored the code, but skipped N files`| Rewind warnings
+`Restored the code, but skipped N files`| Rewind warnings and errors
+`No files were restored: N files failed (backup missing, or the file could not be updated)`| Rewind warnings and errors
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
@@ -210,11 +213,14 @@
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`is a network path, which cannot be added as a working directory`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
+`MCP server <name> is blocked by enterprise managed policy`| Configuration warnings
`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
`Managed settings drop-in directory could not be read`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
+`Invalid permission rule "..." was skipped: Malformed Tool(content) rule`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
`... has a wildcard before the rest of the command`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
@@ -277,7 +283,7 @@
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once on a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
-[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also bounds the first-byte deadline.
+[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also caps how long Claude Code waits for response headers, described in No response from API.
[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
##
@@ -343,23 +349,23 @@
No response from API
-Claude Code sent a streaming request and the API returned no response headers within the deadline for the first byte, so Claude Code aborted the request instead of waiting for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default. Claude Code sends the request again at most once per model request, within the retry budget, and ends the turn with this message when that attempt goes unanswered too. When you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), the one-retry cap doesn’t apply and Claude Code retries under the budget described in Tune retry behavior.
-
- API Error: No response from API
-
-Claude Code picks the deadline from the first of these that applies:
-
- * [`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>), when you set it to 1 or more: Claude Code uses that value, clamped to between 10 seconds and 30 minutes, and adds one second for every 32KB of request body. Claude Code ignores 0 and lower.
- * [`API_TIMEOUT_MS`](</docs/en/env-vars>), when you set it above the byte-level watchdog timeout, 180 seconds on the Anthropic API and 300 seconds elsewhere: Claude Code uses one second less than the value you set.
- * Otherwise, Claude Code uses the byte-level watchdog timeout, and adds one second for every 32KB of request body.
-
-Whichever case applies, the deadline never exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. See [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>) for the variables that change the watchdog timeout and the connections the deadline runs on. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
+Claude Code sent a streaming request and the API returned no response headers within the deadline for the first byte, so Claude Code aborted the request instead of waiting for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default. Claude Code sends the request again at most once, if the retry budget allows. When the retry goes unanswered too, the turn ends with this message, which shows how long each attempt waited. When you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), the one-retry cap doesn’t apply and Claude Code retries under the budget described in Tune retry behavior.
+
+ API Error: No response from API (waited 3m, then 10m on the retry). If a proxy or gateway on your network holds responses until they complete, raise API_TIMEOUT_MS or CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS to wait longer.
+
+Claude Code sets the first attempt’s wait for response headers and the retry’s wait separately:
+
+ * **First attempt** : [`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>) when you set it to 1 or more, clamped to between 10 seconds and 30 minutes. Otherwise Claude Code uses the byte-level watchdog timeout listed in [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>), so the variables that change that timeout change this wait too. Either way, Claude Code adds one second for every 32KB of request body.
+ * **Retry** : one second less than `API_TIMEOUT_MS`, just under 10 minutes by default, so that the retry can outlast a proxy or gateway that holds the response until generation completes. On Amazon Bedrock, the retry uses the same deadline as the first attempt, and the message shows one duration instead of two.
+
+Neither wait exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
* Send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
* If it repeats, treat it as a network or proxy problem. A proxy that accepts the connection and never forwards the request produces this error on every attempt.
- * On a slow network, set `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` to the deadline you want, or set `API_TIMEOUT_MS` above the watchdog timeout.
-
-Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request.
+ * If a proxy or gateway on your network holds responses until they complete, raise `API_TIMEOUT_MS` so the retry waits longer. On Amazon Bedrock, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` as well.
+ * If the first attempt keeps timing out and the retry then succeeds, raise `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` so the first attempt waits long enough too.
+
+Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request. Before v2.1.261, the retry waited the same deadline as the first attempt and the message showed no durations.
###
@@ -2275,6 +2281,20 @@
Before v2.1.247, `/terminal-setup` couldn’t parse a Zed keymap that used `//` comments or trailing commas, and it replaced the entire file with only its own binding while reporting the binding as installed. To restore a keymap an earlier version replaced, use the `.bak` backup file described under [Enter multiline prompts](</docs/en/terminal-config#enter-multiline-prompts>).
+###
+
+
+
+Skill usage reports are not available on this connection
+
+You ran [`/skill-doctor`](</docs/en/skills#find-unused-skills>) over [Remote Control](</docs/en/remote-control>), from your phone or browser. Claude Code doesn’t send the skill usage report over Remote Control and replies with this message instead:
+
+ Skill usage reports are not available on this connection.
+
+**What to do:**
+
+ * Run `/skill-doctor` in the terminal on the machine where the session is running, or run `claude -p "/skill-doctor"` there
+
##
@@ -2353,9 +2373,14 @@
commands path escapes plugin directory: ./../shared.md
-In `claude plugin` command output, the same error reads `Path escapes plugin directory: ./../shared.md (commands)`. Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Claude Code already rejected paths declared in `plugin.json` and the other component paths in a marketplace entry. **What to do:**
+In `claude plugin` command output, the same error reads `Path escapes plugin directory: ./../shared.md (commands)`. Claude Code rejects both a path that points outside the plugin as written, such as `../shared-utils`, and a symlink that leads outside the plugin and isn’t one the [marketplace symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>) allow. For a symlink, the message also says where the path resolves:
+
+ commands path escapes plugin directory: ./commands/deploy.md — it resolves to /home/user/shared/deploy.md, outside the plugin directory
+
+Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Claude Code already rejected paths declared in `plugin.json` and the other component paths in a marketplace entry. Before v2.1.257, the check looked only at the path’s spelling, not at where a symlink leads. **What to do:**
* Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
+ * If the path is a symlink to a file outside the plugin, replace the symlink with a copy of the file
* To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>)
###
@@ -2384,7 +2409,7 @@
Tool errors
-These errors come from Claude’s built-in tools. Claude corrects most tool errors on its own; the first two below need a change from you, because they come from a subagent definition or a permission rule you control.
+These errors come from Claude’s built-in tools. Claude corrects most tool errors on its own. When one needs a change from you, that error’s **What to do** list says what to change.
###
@@ -2588,6 +2613,22 @@
Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these refusals, only the parent-directory write refusal appears on earlier versions.
+###
+
+
+
+Task output swap refused
+
+Claude Code saves each Bash command’s output to a file under its temp directory. This message means a directory on that file’s path is a symbolic link or has been moved, so Claude Code refused to run the command rather than write its output through that path. The message appears in the Bash tool result:
+
+ task output swap refused (tasks dir moved or linked): /private/tmp/claude-501/-Users-you-my-project/1f0e62dc-4b0a-4f5e-9c2d-8a7b6c5d4e3f/tasks/b7k2f9m3q.output. To recover: restart Claude Code with CLAUDE_CODE_TMPDIR set to a fresh directory; or, if /private/tmp/claude-501/-Users-you-my-project is a stray directory or a symbolic link that should not be there, remove that entry itself (not what it points to) and restart.
+
+**What to do:**
+
+ * Upgrade to v2.1.260 or later. Earlier versions sometimes showed this message when no link or moved directory was present
+ * Restart Claude Code with [`CLAUDE_CODE_TMPDIR`](</docs/en/env-vars>) set to a fresh directory
+ * Or check your project’s directory under the Claude Code temp directory, `/private/tmp/claude-501/-Users-you-my-project` in the example message. If that path is a symbolic link, or a directory that shouldn’t be there, remove the link or directory itself rather than the link’s target, and restart Claude Code
+
##
@@ -2894,9 +2935,9 @@
-Rewind warnings
-
-This warning comes from a [`/rewind`](</docs/en/checkpointing>) code restore. It reports paths the restore refused to touch; the restore completed for every other tracked file.
+Rewind warnings and errors
+
+These messages come from a [`/rewind`](</docs/en/checkpointing>) code restore. `Restored the code, but skipped N files` is a warning that Claude Code skipped some paths. `No files were restored` is an error that means it restored nothing.
###
@@ -2920,6 +2961,25 @@
* If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
* If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
+###
+
+
+
+No files were restored
+
+Claude Code shows this message when you restore code with [`/rewind`](</docs/en/checkpointing>) and it can’t restore any of the files in that checkpoint. For each file, either the backup Claude Code saved before editing it is missing, or Claude Code couldn’t write to or delete the file.
+
+ Failed to restore the code:
+ No files were restored: 1 file failed (backup missing, or the file could not be updated)
+
+Claude Code deletes a session’s backups in the [retention sweep](</docs/en/claude-directory#cleaned-up-automatically>), by default about 30 days after the session last saved one. If you resume a session after that, `/rewind` still lists its checkpoints, but rewinding to one of them can fail with this error. If the message also says `N paths were skipped for link safety`, see Restored the code, but skipped files for those paths. **What to do:**
+
+ * Undo the changes another way: ask Claude to reverse its edits, or restore the files from version control. When the backups are gone, running `/rewind` again fails the same way.
+ * If Claude Code couldn’t write or delete a file, fix what blocks the write, such as file permissions, then run `/rewind` again.
+ * To keep backups longer in future sessions, raise [`cleanupPeriodDays`](</docs/en/settings-reference#cleanupperioddays>).
+
+Before v2.1.260, Claude Code silently skipped files whose backups were missing, and the rewind appeared to succeed.
+
##
@@ -3059,6 +3119,30 @@
+Working directory is a network path
+
+Claude Code doesn’t add network paths as working directories. Looking up a network path can contact the host it names, and on Windows that contact can send the host your credentials, so Claude Code refuses the path without looking it up. You see this message when you run `/add-dir` with such a path, or as a warning at startup. When it appears at startup, Claude Code starts without that directory.
+
+ \\server\share is a network path, which cannot be added as a working directory. On Windows, map the share to a drive letter and pass it at launch with --add-dir (a drive letter added mid-session does not yet carry remote-read trust).
+
+Paths that Claude Code refuses this way include:
+
+ * UNC shares such as `\\server\share`
+ * Automount paths such as `/net/<host>`, unless you launched Claude Code from a directory under that host’s automount
+ * Local paths that reach a network location through a symbolic link or junction
+
+Mapped drive letters and `\\wsl$` paths don’t count as network paths. **What to do:**
+
+ * On Windows, map the share to a drive letter, for example with `net use Z: \\server\share`, and pass the drive at launch with `claude --add-dir Z:\`.
+ * On macOS or Linux, mount the share at a local path and add that path instead.
+ * If the path is in `permissions.additionalDirectories`, remove it from the settings file that lists it.
+
+Before v2.1.257, Claude Code accepted a reachable network path as a working directory.
+
+###
+
+
+
Remote managed settings failed to load
Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them, so it shows this warning in interactive sessions. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`, and the rest of the line says which policy the session runs on:
@@ -3072,6 +3156,30 @@
* Run `/status` or `claude doctor` for the full diagnostic
Before v2.1.248, Claude Code reported a failed settings fetch only in the debug log.
+
+###
+
+
+
+MCP server is blocked by enterprise managed policy
+
+You selected **Reconnect** on a server in `/mcp`, or turned a disabled server back on there, and a setting that [restricts MCP servers](</docs/en/managed-mcp>) blocks that server. Claude Code refuses to connect it and shows:
+
+ MCP server <name> is blocked by enterprise managed policy
+
+Any of these settings can produce the message:
+
+ * A [`deniedMcpServers`](</docs/en/managed-mcp#policy-based-control-with-allowlists-and-denylists>) entry that matches the server, including one in your own `~/.claude/settings.json` or the project’s `.claude/settings.json`
+ * An [`allowedMcpServers`](</docs/en/managed-mcp#policy-based-control-with-allowlists-and-denylists>) list that the server doesn’t match
+ * [`strictPluginOnlyCustomization`](</docs/en/settings-reference#strictpluginonlycustomization>) with `mcp` locked, which blocks servers configured in `~/.claude.json` and `.mcp.json`
+ * [`disableClaudeAiConnectors`](</docs/en/mcp#disable-claude-ai-connectors>), when the server is a claude.ai connector
+
+**What to do:**
+
+ * Check your own user and project settings files for one of these settings and change or remove it
+ * If none of your own settings explains the block, ask your administrator which managed setting blocks the server
+
+Before v2.1.257, **Reconnect** and re-enable in `/mcp` could connect a server that a mid-session policy update blocked.
###
@@ -3109,6 +3217,23 @@
* Run `claude` in the folder the message names, accept the trust dialog, then run your `-p` or SDK command again
* Set the `hasTrustDialogAccepted` entry in `~/.claude.json` yourself, using the exact `projects` key the message prints
* If you started the session in your home directory, work from a project directory you have trusted. When you accept the trust dialog in your home directory, Claude Code holds that trust for the current session only.
+
+###
+
+
+
+Malformed Tool(content) rule
+
+A [permission rule](</docs/en/permissions#permission-rule-syntax>) in one of your settings files doesn’t have the shape `Tool` or `Tool(content)`, for example because text follows the closing parenthesis or one of the parentheses is missing. Claude Code skips the rule and lists it in the invalid-settings dialog when an interactive session starts, and in [`claude doctor`](</docs/en/debug-your-config#check-resolved-settings>) output:
+
+ Invalid permission rule "Bash(ls) x" was skipped: Malformed Tool(content) rule. Rules take the form Tool or Tool(content) and must end at the closing ")"; parentheses inside the content are literal
+
+**What to do:**
+
+ * In the settings file listed with the message, rewrite the rule so it ends at its closing parenthesis, for example `Bash(ls *)` in place of `Bash(ls) x`
+ * Leave parentheses inside the content as they are. They’re literal, so a rule such as `Edit(./Finance (2024)/**)` is valid without escaping
+
+Before v2.1.260, Claude Code reported a rule with unmatched parentheses as `Mismatched parentheses`.
###
--- a/errors.md
+++ b/errors.md
@@ -211,6 +211,8 @@
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`Remote managed settings failed to load (<cause>)`| Configuration warnings
+`Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.`| Configuration warnings
+`Managed settings drop-in directory could not be read`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
@@ -258,7 +260,7 @@
While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. After the abort, what you see depends on how far the response had got:
* Before Claude has completed a block of text or a tool call, or started one after finishing its thinking, Claude Code retries the request or ends the turn with an error. Automatic retries says which stalls it retries and how many times.
- * After Claude has completed a block of text or a tool call, or started one after finishing its thinking, but before Claude has finished the response, Claude Code keeps what Claude completed, continues the turn from any tool calls Claude finished, and shows The response above may be incomplete. In a non-interactive session, Claude Code may first prompt Claude to continue the response; that entry says when it does and when you still see the notice there.
+ * After Claude has completed a block of text or a tool call, or started one after finishing its thinking, but before Claude has finished the response, Claude Code keeps what Claude completed, continues the turn from any tool calls Claude finished, and shows The response above may be incomplete. In a non-interactive session, and for a subagent’s response in any session, Claude Code may first prompt Claude to continue the response; that entry says when it does and when you still see the notice there.
* After Claude finished the response, Claude Code ends the turn normally.
The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
@@ -377,11 +379,12 @@
* `Your computer went to sleep mid-response`: Claude Code detected that your computer went to sleep while the response was streaming. Once your computer wakes, Claude Code treats the connection as broken and stops reading from it.
* `The response stopped arriving`: the connection stayed open but stopped delivering data, so the streaming idle watchdog aborted it. Before v2.1.222, Claude Code could also report this failure on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because it counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. In three cases, Claude Code handles the failure without showing this notice right away:
+Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. In four cases, Claude Code handles the failure without showing this notice right away:
* Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
* When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
* In a [non-interactive session](</docs/en/headless>), such as a `-p` run, an [Agent SDK](</docs/en/agent-sdk/overview>) run, or a [cloud session](</docs/en/claude-code-on-the-web>), you don’t have to send `continue` yourself when the cut-off response is in the main conversation and contains text but no tool calls: Claude Code keeps the partial output and prompts Claude to continue from where it stopped, up to three times in a row. You see this notice for such a response only once Claude Code has used up those continuations. Before v2.1.246, Claude Code ended a non-interactive turn with this notice on the first cut-off.
+ * In a [subagent](</docs/en/sub-agents#api-errors-in-subagents>), whether the session is interactive or not: when its cut-off response contains text but no tool calls, Claude Code prompts the subagent to continue. The notice becomes the subagent’s last message only once those continuations are used up. Before v2.1.257, a subagent showed this notice on the first cut-off.
**What to do:**
@@ -3074,6 +3077,27 @@
+Managed settings document could not be parsed
+
+Your organization deploys [managed settings](</docs/en/managed-settings>), and one of the deployed documents is present but can’t be parsed as a JSON object, so Claude Code exits with code 1 at startup instead of running without the policy the document carries. The line names the failed source before the message:
+
+ /Library/Application Support/ClaudeCode/managed-settings.json: Managed settings document could not be parsed as a JSON object; none of its settings are in effect. Fix or remove it.
+
+The source is one of:
+
+ * The path of the `managed-settings.json` file or a drop-in file under `managed-settings.d`
+ * The macOS managed preferences profile, `per-user managed preferences` or `device-level managed preferences`
+ * The Windows registry value, `Registry: HKLM\SOFTWARE\Policies\ClaudeCode\Settings`
+
+[Find entries Claude Code dropped](</docs/en/managed-settings#find-entries-claude-code-dropped>) lists what makes each source unparseable. Claude Code refuses to start even when another admin source delivers a valid policy. You see this error in interactive sessions, `claude -p`, Agent SDK sessions, [background sessions](</docs/en/agent-view>), and most subcommands, `claude doctor` included. The refusal fails closed on purpose: settings in a document Claude Code can’t parse can’t be enforced, and starting anyway would run sessions without the organization’s controls. A schema problem in a parseable document doesn’t produce this error. [Find entries Claude Code dropped](</docs/en/managed-settings#find-entries-claude-code-dropped>) covers what Claude Code does with one. When a `managed-settings.d/` directory exists but can’t be listed, Claude Code reports `Managed settings drop-in directory could not be read:` followed by the underlying error instead. [Find entries Claude Code dropped](</docs/en/managed-settings#find-entries-claude-code-dropped>) covers when a read failure exits at startup. **What to do:**
+
+ * If you administer the machine, fix the named document so it parses as a JSON object, or remove the file, profile, or registry value. An empty `managed-settings.json` counts as `{}` and doesn’t block launch.
+ * If you don’t, ask your administrator to fix the deployed document. Nothing in your own settings files causes or clears this error.
+
+###
+
+
+
headersHelper not run
Claude Code connected an MCP server with its static `headers` alone and skipped the server’s [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>), because the helper is a shell command and the folder has no saved trust. A folder gets saved trust when you set its entry in `~/.claude.json` by hand or, outside your home directory, when you accept the trust dialog for it in an interactive session. See [Trust a folder before its headersHelper runs](</docs/en/mcp#trust-a-folder-before-its-headershelper-runs>) for which servers this check applies to. Claude Code writes this line in [non-interactive mode](</docs/en/headless>) only, once per server. In an interactive session it writes the same refusal to the debug log instead.
--- a/errors.md
+++ b/errors.md
@@ -109,6 +109,7 @@
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
+`Claude Code ... does not support this model; version ... or newer is required`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
@@ -518,12 +519,12 @@
The prompt to confirm went unanswered
-On plans where Fable 5 usage [bills to usage credits](</docs/en/model-config#fable-5-and-usage-credits>), Claude Code asks you to confirm before a request bills them. When nobody answers that consent prompt in a session that may have no one at its terminal, Claude Code closes the prompt and ends the turn with one of these messages:
-
- Fable 5 limit reached · continuing on Fable 5 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
- Fable 5 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-
-This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
+If your account requires the [Fable usage-credits consent](</docs/en/model-config#fable-and-usage-credits>), Claude Code asks you to confirm before a Fable request bills usage credits. When nobody answers that consent prompt in a session that may have no one at its terminal, Claude Code closes the prompt and ends the turn with one of these messages:
+
+ Fable limit reached · continuing on Fable 5.1 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
+ Fable 5.1 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
+
+The messages name the session’s Fable model, so on Fable 5 they read `continuing on Fable 5` and `Fable 5 now uses usage credits`. Before v2.1.255, the first message began `Fable 5 limit reached`. This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
* At the terminal where the session runs, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
* Run `/model` to switch to a model that doesn’t bill usage credits
@@ -1558,7 +1559,7 @@
The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you. **What to do:**
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
- * If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this check even when the model is newer than your Claude Code version, so upgrading isn’t needed for those.
+ * If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this local check even when the model is newer than your Claude Code version. The server can still require a minimum version for that model; see Claude Code does not support this model.
* A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under [Setting your model](</docs/en/model-config#setting-your-model>).
* The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
@@ -1577,6 +1578,21 @@
* Run `/model` and select a model your plan includes
* If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on the web does not take effect in an existing session until you re-authenticate.
* See [claude.com/pricing](<https://claude.com/pricing>) for which models each plan includes
+
+###
+
+
+
+Claude Code does not support this model
+
+The model you selected requires a newer Claude Code version than the one making the request. The server checks this per model.
+
+ API Error: 400 Claude Code 2.1.219 does not support this model; version 2.1.255 or newer is required. Run 'claude update', or update the Claude desktop app, then try again.
+
+**What to do:**
+
+ * Run `claude update`, or update the Claude desktop app, then start a new session on the model
+ * To keep working in the current session, switch to another model with `/model`
###
@@ -3195,7 +3211,7 @@
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
- * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5 and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5.1, Fable 5, and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
--- a/errors.md
+++ b/errors.md
@@ -60,6 +60,8 @@
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
+`Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
+`Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
`Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
@@ -506,7 +508,7 @@
This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
- * Run `/usage-credits` to turn on metered billing for the 1M variant on Pro and Max, or to request it from your admin on Team and Enterprise
+ * Where the message names `/usage-credits`, run it to turn on metered billing for the 1M variant on Pro and Max, or to request usage credits from your admin on Team and Enterprise
* If the error persists after `/model`, a 1M model ID may be set elsewhere. See [Setting your model](</docs/en/model-config#setting-your-model>) for the configuration locations to check in priority order.
* To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
@@ -923,7 +925,7 @@
Login expired
-Claude Code tried to renew your saved claude.ai or Claude Console login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each request stops locally before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
+Claude Code tried to renew your saved claude.ai or Claude Console login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each model request stops locally with this message before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the model request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
Login expired · Please run /login
@@ -931,11 +933,27 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
+This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. When the renewal fails because the account itself is suspended rather than the login being stale, Claude Code shows Your account is on hold instead. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
* If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
+
+###
+
+
+
+Your account is on hold
+
+The Claude account behind your login has been suspended. Claude Code shows the first message when it tries to renew your saved login and learns of the hold, and the second when a sign-in you complete in the browser reports it:
+
+ Your account is on hold and can't use Claude Code. View details or appeal: https://claude.ai/restricted
+ Your account is on hold and can't sign in to Claude Code. View details or appeal: https://claude.ai/restricted
+
+Signing in again with the same account doesn’t clear the message, because the hold is on the account rather than the login. In [non-interactive mode](</docs/en/headless>) (`-p`) and the [Agent SDK](</docs/en/agent-sdk/overview>), the structured error code is `account_on_hold`. Before v2.1.235, Claude Code reported a held account as Login expired · Please run /login, whose recovery steps can’t clear a hold. **What to do:**
+
+ * Open the link in the message to view the hold’s details or appeal it
+ * If you have another Claude account or an API key that isn’t affected by the hold, you can keep working while the hold is resolved: run `/login` with that account, or set the key with `ANTHROPIC_API_KEY`
###
@@ -3066,11 +3084,11 @@
* Replace `Write(path)`, `NotebookEdit(path)`, and legacy `MultiEdit(path)` rules with `Edit(path)`. `Edit` rules cover all file-editing tools.
* Except in `--allowedTools`, where Claude Code accepts a `Glob` rule without warning, replace `Glob(path)` rules with `Read(path)`.
- * Fix the rule at the source the warning names in parentheses: a settings file path, or the flag itself for `--allowed-tools` and `--disallowed-tools`. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value; fix the JSON you pass to that flag.
+ * Fix the rule at the source the warning names in parentheses: a settings file path, or the flag itself for `--allowed-tools` and `--disallowed-tools`. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
* Leave bare tool-name rules such as `Write` or `Glob` alone. Claude Code matches them at the [tool level](</docs/en/permissions#match-all-uses-of-a-tool>) and doesn’t warn about them.
- * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings; you can’t clear it yourself.
-
-In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean; run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.210, Claude Code accepted these rules without a warning.
+ * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings, since you can’t clear it yourself.
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.210, Claude Code accepted these rules without a warning.
###
Show diff (109 lines)
--- a/errors.md
+++ b/errors.md
@@ -235,6 +235,7 @@
* When no reduction can fit, for example when the conversation itself nearly fills the context window.
* When a retry can’t shrink `max_tokens` any further. Before v2.1.218, Claude Code could re-send a reduced request that still didn’t fit, such as when the extended thinking budget exceeded the remaining context, until the retry budget ran out.
* An expired or missing Google Cloud credential on [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), which surfaces as an error such as `Could not load the default credentials`. Claude Code discards its cached credentials and retries up to two times, running your [`gcpAuthRefresh`](</docs/en/google-vertex-ai#advanced-credential-configuration>) command if you configured one, then reports the error so you can re-authenticate right away. [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>) covers re-authenticating. Before v2.1.228, Claude Code retried a failing credential through the full retry budget before showing the error.
+ * A `401` or `403` from the Anthropic API, directly or through an [LLM gateway](</docs/en/llm-gateway>), while an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script supplies the credential. Claude Code re-runs the script and retries with its fresh output, within the full retry budget. When the script itself fails on the re-run, Claude Code shows Your apiKeyHelper script is failing instead.
Before v2.1.227, `Connection lost before a response was produced` read `Connection closed while thinking, before producing a response` and `The response stalled before a response was produced` read `Response stalled while thinking, before producing a response`. Claude Code doesn’t retry these failures:
@@ -634,7 +635,7 @@
* For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script that fetches a key at startup
* See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential Claude Code uses when several are present
-If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
+If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock checks and macOS credential-storage recovery steps.
###
@@ -896,7 +897,7 @@
* Run `/login` to sign in again
* If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
* If you authenticate with the `CLAUDE_CODE_OAUTH_TOKEN` environment variable, Claude Code keeps sending the value you set after a request fails with a 401, rather than switching to a stored login’s token. [`/status`](</docs/en/commands>) shows this credential as an `Auth token` row reading `CLAUDE_CODE_OAUTH_TOKEN`. Generate a fresh token with [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) and restart with it, or unset the variable and run `/login`. Before v2.1.225, Claude Code could replace the variable’s value mid-session with the short-lived access token from a stored login, and the session failed with 401 errors again once that token expired.
- * For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
+ * For repeated prompts to log in across launches, see the system clock checks and macOS credential-storage recovery steps in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
###
@@ -947,14 +948,14 @@
Anthropic profile login expired · Re-authenticate your Anthropic profile
Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile
-This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable or that Claude Code discovers as the active profile in your Anthropic configuration directory. Sessions that authenticate with `/login`, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. Running `/login` doesn’t renew the profile credential. Which form you see depends on whether you selected the profile or Claude Code discovered it, and tells you whether a working login can take over instead:
-
- * When you set `ANTHROPIC_PROFILE` explicitly, the message ends with `Re-authenticate your Anthropic profile`. Claude Code gives the profile precedence over a saved login, so signing in doesn’t stop the error.
+This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable, that Claude Code discovers as the active profile in your Anthropic configuration directory, or that Claude Code wrote when you [signed in without an API key](</docs/en/authentication#sign-in-without-an-api-key>). Sessions that authenticate with `/login`’s claude.ai option, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. On a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login`, choose the Anthropic Console account, and sign in again to renew a profile that the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote. Claude Code replaces the expired credential in that profile. For a federation profile or one another tool created, `/login` doesn’t renew the credential. Which form you see depends on whether you selected the profile or Claude Code discovered it:
+
+ * When you set `ANTHROPIC_PROFILE` explicitly, the message ends with `Re-authenticate your Anthropic profile`.
* When Claude Code discovered the profile from your configuration directory, the message offers `/login`, because Claude Code gives a working `/login` precedence over the discovered profile and then authenticates with your claude.ai or Console account instead. Before v2.1.234, Claude Code showed the `Re-authenticate your Anthropic profile` form in this case too.
**What to do:**
- * Sign in to the profile again with the tool that created it, then retry
+ * Sign in to the profile again, then retry: on a machine that [offers the keyless sign-in](</docs/en/authentication#sign-in-without-an-api-key>), run `/login` and choose the Anthropic Console account for a profile the keyless Console sign-in or the Claude Platform CLI’s `ant auth login` wrote; for other profiles, use the tool that created them
* If an administrator provisioned the profile’s credential, ask them to issue a new one
* Run `/status` to confirm the active credential source and profile name
* To stop using the profile, unset `ANTHROPIC_PROFILE` if you set it, then authenticate another way, such as `/login` or `ANTHROPIC_API_KEY`
@@ -1169,14 +1170,14 @@
Bedrock streaming response has an unexpected content-type
-A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`, and Claude Code rejects a successful streaming response that reports a different content-type instead of decoding a body it can’t read. The request isn’t retried.
+A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`. Rather than decode a body it can’t read, Claude Code rejects a successful streaming response that reports a different content-type. Claude Code doesn’t retry the request.
Bedrock streaming response has content-type "text/event-stream"; expected "application/vnd.amazon.eventstream". A gateway or proxy between Claude Code and Bedrock is likely transforming the response body — Bedrock's binary event-stream format must be passed through unmodified. Set CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1 to suppress this check while the gateway is being fixed.
Before v2.1.208, the same misconfiguration surfaced as `API Error: Truncated event message received` after the whole response had been buffered. **What to do:**
* Configure the gateway to pass the `InvokeModelWithResponseStream` response body and its `Content-Type` header through unmodified. An intermediary that re-emits the stream as server-sent events is a common cause.
- * If the gateway rewrites only the header and passes the binary body through intact, set [`CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1`](</docs/en/env-vars>) to skip the check until the gateway is fixed. See [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>).
+ * Setting [`CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1`](</docs/en/env-vars>) hides this error, but Claude Code doesn’t decode a binary body under a rewritten header, so those requests fall back to a slower non-streaming path. See [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>).
###
@@ -1499,7 +1500,7 @@
API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid
-Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a deployment that doesn’t receive the remote configuration that enables the exclusion, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`: Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though it still excludes one with an invalid top-level property name. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
+Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a [deployment where flag fetching is off](</docs/en/env-vars#features-that-need-feature-flag-fetching>), or on a machine whose flags have never arrived, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`. Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though the top-level property-name check still applies. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
* If your Claude Code version is earlier than v2.1.216, run `claude update`.
* Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
@@ -1667,7 +1668,7 @@
Send feedback with /feedback or learn more: https://www.anthropic.com/legal/aup
-The message names the model that declined, or `Claude` when no model is recorded. In [non-interactive mode](</docs/en/headless>) (`-p`), the final line reads `Learn more:` followed by the link, without the `/feedback` mention. The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), this message also covers requests the model’s safety measures flagged as a cybersecurity topic. See Safety measures flagged a cybersecurity topic. Before v2.1.219, the message read `Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.` **What to do:**
+The message names the model that declined, or `Claude` when no model is recorded. The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), this message also covers requests the model’s safety measures flagged as a cybersecurity topic. See Safety measures flagged a cybersecurity topic. Before v2.1.219, the message read `Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.` **What to do:**
* Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
* If you can’t identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
@@ -1683,12 +1684,7 @@
API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
-The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. What you see depends on your provider and mode:
-
- * On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead.
- * In [non-interactive mode](</docs/en/headless>), the final sentence reads `Learn more:` followed by the link, without the `/feedback` mention.
-
-The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead. The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
@@ -2043,10 +2039,10 @@
Claude Code suggests the closest command name or alias that the menu lists in this session. When nothing is close, the message ends after the name. The cause is usually one of the following:
* A typo, such as `/hepl` for `/help`. [How the command menu matches what you type](</docs/en/commands#how-the-command-menu-matches-what-you-type>) covers picking a close match before you submit
- * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases
+ * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases. Some commands answer with their own message when your organization’s policy disables them
* A command from a [plugin](</docs/en/plugins>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
-Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
+Claude Code doesn’t treat every prompt that starts with `/` as a command. It sends the prompt to Claude as a normal message when the first word after the `/` starts with punctuation, such as the `/--` that opens a Lean doc comment, or is a path such as `/var/log/syslog`. Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
* Run the suggested name, or type `/` followed by part of the name to see what’s available in this session
* If Claude Code reports a documented command as unknown, check its row in the [commands reference](</docs/en/commands>) for the requirement it names
Show diff (356 lines)
--- a/errors.md
+++ b/errors.md
@@ -15,6 +15,7 @@
`API Error: 500 Internal server error`| Server errors
`API Error: Repeated 529 Overloaded errors`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
+`API Error: No response from API`| Server errors
`Server error mid-response. The response above may be incomplete.`| Server errors
`Connection lost mid-response` / `Your computer went to sleep mid-response` / `The response stopped arriving`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
@@ -108,6 +109,8 @@
`Claude Opus is not available with the Claude Pro plan`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
+`Effort '<level>' isn't available with thinking turned off on this model`| Request errors
+`effort '<level>' is not supported when thinking is disabled`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
`[Unsupported tool content removed]`| Request errors
@@ -120,14 +123,18 @@
`The connection dropped while downloading the update`| Installation errors
`Download timed out: exceeded the total deadline`| Installation errors
`--bg and --print conflict`| Command-line errors
+`Cloud sessions cannot be created from a --restricted session`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
+`Error: Invalid --agents configuration:`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
+``<flag>` before `remote-control` is not carried over to the sessions Remote Control starts`| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
+`Server rejected the Authorization header minted by the configured headersHelper`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
@@ -141,6 +148,7 @@
`Your checkout has no branches (detached HEAD only)`| Command-line errors
`Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected`| Command-line errors
`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
+`The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
@@ -152,6 +160,7 @@
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`Plugin archive integrity check failed`| Plugin errors
+`path escapes plugin directory`| Plugin errors
`Failed to load marketplace configuration`| Plugin errors
`Marketplace configuration file is corrupted`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
@@ -167,6 +176,10 @@
`Refusing to send: connected endpoint is not the expected process` / `Refusing to send: connected endpoint identity could not be read`| Tool errors
`Refusing to send: connected endpoint is not owned by this user` / `Refusing to send: connected endpoint owner could not be read`| Tool errors
`Refusing to send: connected endpoint is a different process with the expected pid`| Tool errors
+`Refusing to read <path>: its symlink resolution changed after permission was checked` / `Refusing to search <path>: its symlink resolution changed after permission was checked`| Tool errors
+`Refusing to write <path>: its parent-directory symlink resolution changed after permission was checked` / `Refusing to write <path>: it is a symbolic link. Write to the link's target path instead`| Tool errors
+`Refusing to search <path>: a path one of its Read deny rules is written through changed while the search was being prepared` / `Refusing to search <path>: it could not be opened`| Tool errors
+`its permission check expired before it ran (too many concurrent file operations)` / `ripgrep was found only by name on PATH`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -194,6 +207,7 @@
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`Remote managed settings failed to load (<cause>)`| Configuration warnings
`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
@@ -213,7 +227,8 @@
* Server errors, overloaded responses, and request timeouts that arrive before any of Claude’s response has streamed.
* Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
* A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
- * A stalled response stream, when none of the response has arrived yet or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
+ * A stalled response stream, when the response headers have arrived but none of Claude’s response has arrived, or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
+ * A streaming request the API never answers with response headers, on a connection where the [first-byte deadline runs](</docs/en/network-config#streaming-idle-watchdogs>): Claude Code aborts it at the deadline and re-sends it at most once per model request, within the retry budget, then ends the turn with No response from API if that attempt goes unanswered too. On other connections, the request waits out `API_TIMEOUT_MS`. When you set `CLAUDE_CODE_RETRY_WATCHDOG`, the one-retry cap doesn’t apply.
* Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
* When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
* A request rejected because the input plus `max_tokens` exceeds the context limit. Re-sending it unchanged would fail the same way, so Claude Code retries with a reduced `max_tokens`, and stops retrying and compacts instead in two cases:
@@ -256,7 +271,8 @@
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once on a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
-[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies.
+[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies. It also bounds the first-byte deadline.
+[`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>)| unset| Deadline in milliseconds for the first response byte of a streaming request. Requires Claude Code v2.1.242 or later. For how Claude Code picks the deadline when this is unset, see No response from API.
##
@@ -314,6 +330,30 @@
* For long-running tasks, break the work into smaller prompts
* If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
* If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
+
+###
+
+
+
+No response from API
+
+Claude Code sent a streaming request and the API returned no response headers within the deadline for the first byte, so Claude Code aborted the request instead of waiting for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default. Claude Code sends the request again at most once per model request, within the retry budget, and ends the turn with this message when that attempt goes unanswered too. When you set [`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>), the one-retry cap doesn’t apply and Claude Code retries under the budget described in Tune retry behavior.
+
+ API Error: No response from API
+
+Claude Code picks the deadline from the first of these that applies:
+
+ * [`CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS`](</docs/en/env-vars>), when you set it to 1 or more: Claude Code uses that value, clamped to between 10 seconds and 30 minutes, and adds one second for every 32KB of request body. Claude Code ignores 0 and lower.
+ * [`API_TIMEOUT_MS`](</docs/en/env-vars>), when you set it above the byte-level watchdog timeout, 180 seconds on the Anthropic API and 300 seconds elsewhere: Claude Code uses one second less than the value you set.
+ * Otherwise, Claude Code uses the byte-level watchdog timeout, and adds one second for every 32KB of request body.
+
+Whichever case applies, the deadline never exceeds one second less than a positive `API_TIMEOUT_MS`, and a positive `API_TIMEOUT_MS` under 11 seconds turns the deadline off. See [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>) for the variables that change the watchdog timeout and the connections the deadline runs on. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead of this deadline. **What to do:**
+
+ * Send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
+ * If it repeats, treat it as a network or proxy problem. A proxy that accepts the connection and never forwards the request produces this error on every attempt.
+ * On a slow network, set `CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS` to the deadline you want, or set `API_TIMEOUT_MS` above the watchdog timeout.
+
+Before v2.1.242, Claude Code waited for the full `API_TIMEOUT_MS` request timeout, 10 minutes by default, before failing an unanswered streaming request.
###
@@ -1555,6 +1595,23 @@
+Effort isn’t available with thinking turned off
+
+You turned [extended thinking](</docs/en/model-config#extended-thinking>) off and ran at an [effort level](</docs/en/model-config#adjust-effort-level>) above `high`. The model doesn’t accept that combination, so the API rejected the request.
+
+ API Error: Effort 'xhigh' isn't available with thinking turned off on this model · run /effort high to continue, or turn thinking back on (unset MAX_THINKING_TOKENS=0)
+
+**What to do:**
+
+ * [Lower the effort level](</docs/en/model-config#set-the-effort-level>) to `high` or below.
+ * Turn thinking back on, for example by unsetting [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) or removing [`"alwaysThinkingEnabled": false`](</docs/en/settings-reference#alwaysthinkingenabled>) from your settings.
+
+Before v2.1.242, Claude Code showed the API’s own message: `API Error: 400 output_config.effort 'xhigh' is not supported when thinking is disabled on this model. Use effort 'high' or below, or enable thinking.` Before v2.1.251, Claude Code sent the request at the effort level you set, so Opus 5 rejected every request above `high` with thinking turned off. Claude Code now sends effort `high` instead to models it knows reject the combination, such as Opus 5, so on v2.1.251 or later this error reaches you only from a model Claude Code doesn’t know rejects it.
+
+###
+
+
+
Thinking budget exceeds output limit
The configured extended thinking budget exceeds the maximum response length, so there is no room left for the actual answer.
@@ -1705,6 +1762,44 @@
+Invalid —agents configuration
+
+The value you passed to `--agents` is invalid, so `claude` exits with code 1 instead of starting the session. When you pass `--safe-mode`, `--resume`, or `--continue`, or set [`CLAUDE_CODE_SAFE_MODE`](</docs/en/env-vars#variables>), Claude Code doesn’t check the value and starts the session. Before v2.1.242, Claude Code started the session anyway and left out the definitions it couldn’t load.
+
+ Error: Invalid --agents configuration:
+ <what failed>
+
+What follows the first line depends on how the value failed. Claude Code runs these checks in order and stops at the first one that fails. If your value has two kinds of problem, you see the second only after you fix the first:
+
+ 1. When the value doesn’t parse as JSON, Claude Code prints one `invalid JSON:` line carrying the JSON parser’s own message
+ 2. When it parses but an agent definition doesn’t match the schema for [CLI-defined subagents](</docs/en/sub-agents#choose-the-subagent-scope>), Claude Code prints one line per problem
+ 3. When an agent name starts with `-`, Claude Code prints `<name>: agent names must not start with '-'`
+
+When there are more than 20 problem lines, Claude Code prints the first 20 and replaces the rest with `…and N more`. **What to do:**
+
+ * Fix each problem the message lists, then run the command again. See [the fields a CLI-defined subagent takes](</docs/en/sub-agents#choose-the-subagent-scope>).
+
+###
+
+
+
+Cloud sessions cannot be created from a —restricted session
+
+When you start a session with [`--restricted`](</docs/en/cli-reference#cli-flags>), Claude Code refuses to create [cloud sessions](</docs/en/claude-code-on-the-web#from-terminal-to-web>) from it, because the new session would run outside the restricted process and wouldn’t enforce restricted mode. Claude Code refuses on the client, before contacting the server, so no cloud session is created:
+
+ Cloud sessions cannot be created from a --restricted session: they would not enforce it.
+
+**What to do:**
+
+ * Run the task locally in the restricted session
+ * If you control how the session was launched, start a new `claude` session without `--restricted` and create the cloud session from there
+
+Before v2.1.248, Claude Code had no `--restricted` flag; earlier versions reject the flag itself with an unknown-option error.
+
+###
+
+
+
The —json-schema value is not a valid JSON Schema
The schema you passed to [`--json-schema`](</docs/en/cli-reference#cli-flags>) in [non-interactive mode](</docs/en/headless#get-structured-output>) failed JSON Schema compilation, so `claude` exits with code 1 instead of running the prompt. Before v2.1.205, an invalid schema produced unstructured output with no error, and any schema that used the `format` keyword was treated as invalid.
@@ -1769,6 +1864,23 @@
+Not carried over to the sessions Remote Control starts
+
+You started [Remote Control](</docs/en/remote-control>) with a global `claude` flag before the `remote-control` verb, one that would restrict or configure the sessions Remote Control starts, such as `--settings`, `--setting-sources`, `--permission-mode`, `--disallowed-tools`, or `--mcp-config`. A flag placed before the verb never reaches those sessions. Claude Code refuses to start instead, naming the flag:
+
+ Error: `--settings` before `remote-control` is not carried over to the sessions Remote Control starts, so Remote Control refuses to start rather than drop it — remove it, and give Remote Control's own options after the verb (see `claude remote-control --help`).
+
+Claude Code doesn’t refuse global flags that are harmless to drop, such as `--verbose`, `--model`, or a wrapper-injected `--session-id` or `--plugin-dir`: it ignores them and Remote Control starts. Claude Code also refuses to start for a global flag it doesn’t yet recognize as harmless, so a flag added in a newer release can appear in this message until a later release marks it harmless. **What to do:**
+
+ * Remove the flag from before the verb and pass [Remote Control’s own options](</docs/en/remote-control#start-a-remote-control-session>) after it; `claude remote-control --help` lists them
+ * When the refused flag is `--permission-mode`, run `claude remote-control --permission-mode <mode>` to set the permission mode for the sessions Remote Control starts
+
+Before v2.1.248, `claude remote-control` didn’t accept its own flags when a global flag came first, and the command failed with an `unknown option` error.
+
+###
+
+
+
claude import is not yet available in this build
You ran [`claude import`](</docs/en/cli-reference#cli-commands>), and Claude Code found the import flow turned off, so the command exits with code 1 instead of starting the import. Before v2.1.222, a build with the import flow off treated `import` as a prompt and started an interactive session instead of printing this message.
@@ -1830,6 +1942,23 @@
* Remove your entry with `claude mcp remove <name>`, so it can’t hide the claude.ai connector at the same URL
* After removing it, connect the service at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>), while signed in to the account you use in Claude Code. Once connected, [the connector appears in Claude Code automatically](</docs/en/mcp#use-mcp-servers-from-claude-ai>) if your active authentication method is a claude.ai subscription login
+
+###
+
+
+
+Server rejected the Authorization header minted by the configured headersHelper
+
+An MCP server whose [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) supplies the `Authorization` header answered the connection with HTTP 401 or 403, so Claude Code reports the connection as failed. Because the helper supplies the `Authorization` header, Claude Code [doesn’t fall back to OAuth](</docs/en/mcp#authenticate-with-remote-mcp-servers>) for the server:
+
+ Server rejected the Authorization header minted by the configured headersHelper (HTTP 401). Check that the helper command returns a valid credential for this MCP endpoint — OAuth fallback is disabled when the helper supplies Authorization.
+
+Claude Code re-runs the helper on each connection attempt, so a retry after a transient rejection, such as a token-rotation race, can succeed with a fresh credential. **What to do:**
+
+ * Run the `headersHelper` command yourself the way Claude Code runs it: from the [directory Claude Code runs it in](</docs/en/mcp#where-the-helper-runs>), with the [environment variables Claude Code sets for it](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>), and without the [credential variables Claude Code removes](</docs/en/mcp#which-variables-a-helper-can-read>) for a server from a project `.mcp.json`, a plugin, or a project agent file. Check that it prints an `Authorization` value the server’s endpoint accepts
+ * After fixing the helper or its credential source, select the server in `/mcp` and choose **Reconnect**
+
+Before v2.1.248, Claude Code ran OAuth discovery for a server whose helper supplied the `Authorization` header. That discovery could fail with `Incompatible auth server: does not support dynamic client registration` instead of reporting the rejected credential.
###
@@ -2010,6 +2139,23 @@
+The GitHub App preflight failed transiently
+
+You started a [cloud session](</docs/en/claude-code-on-the-web>) from a local repository, and two steps failed together. Claude Code couldn’t build or upload the bundle of your repository. Before the upload, it checked whether the cloud service can clone the repository from GitHub, and rather than a definite answer, that check ended in an error that a retry could clear, such as a network error, a timeout, or a temporary server error. The full message starts with what stopped the bundle, for example `Could not upload repo bundle (<error>)`, and ends with the preflight sentence:
+
+ Could not upload repo bundle (<error>). The GitHub App preflight failed transiently (network or service hiccup) — retry in a moment to start from GitHub instead
+
+**What to do:**
+
+ * Rerun the command after a moment. When the GitHub check passes, Claude Code can start the session from a GitHub clone, so the failed upload no longer blocks the launch
+ * If retries keep failing, the start of the message names what stopped the upload. When that cause is something you can fix, fix it so the session can start from your local repository instead
+
+Before v2.1.251, Claude Code ended the message with `Please set up GitHub on https://claude.ai/code` even when the GitHub check failed only transiently, and setup advice can’t clear a transient failure.
+
+###
+
+
+
Failed to resume the conversation
Claude Code couldn’t read or process the saved transcript for the session you selected from the [`claude --resume` picker](</docs/en/sessions#use-the-session-picker>), so it ends the process rather than continue in a partially loaded state. The message includes the command to retry:
@@ -2163,6 +2309,21 @@
* If you publish the plugin, recompute the digest of the exact file the URL serves, for example with `shasum -a 256 my-plugin.zip`, or `Get-FileHash -Algorithm SHA256 my-plugin.zip` in PowerShell, and update the `sha256` in the marketplace entry
* If you install the plugin, run `/plugin marketplace update <name>` to refresh the catalog in case the entry was corrected, then retry the install
* If the digests still disagree after a refresh, ask the marketplace owner which file they pinned before installing
+
+###
+
+
+
+Path escapes plugin directory
+
+A plugin component path, declared in the plugin’s `plugin.json` or in its [marketplace entry](</docs/en/plugin-marketplaces#plugin-entries>), resolves outside the plugin’s own directory. Claude Code drops that path and loads the rest of the plugin. The component name in the message, such as `commands` or `hooks`, names the field that declared the path.
+
+ commands path escapes plugin directory: ./../shared.md
+
+In `claude plugin` command output, the same error reads `Path escapes plugin directory: ./../shared.md (commands)`. Before v2.1.251, Claude Code loaded a `commands` path declared in a marketplace entry even when it pointed outside the plugin directory. Claude Code already rejected paths declared in `plugin.json` and the other component paths in a marketplace entry. **What to do:**
+
+ * Move the referenced file inside the plugin directory and point the path at it with a `./` relative path
+ * To share files with other plugins in the same marketplace, link them with a symlink inside the plugin directory, following the [symlink rules](</docs/en/plugins-reference#share-files-within-a-marketplace-with-symlinks>)
###
@@ -2366,6 +2527,34 @@
Before v2.1.248, Claude Code didn’t check the endpoint’s owning user or process start time, so the refusals that name those checks don’t appear on earlier versions.
+###
+
+
+
+Refusing to read, write, or search a path
+
+Claude Code checks a file path’s [permission rules](</docs/en/permissions#read-and-edit>), then confirms that resolution again when the tool opens the file or starts the search. When it can’t confirm that the path still leads to the location the check approved, Claude Code refuses the operation instead of following it. The refusal appears in the tool result:
+
+ Refusing to read /path/to/file: its symlink resolution changed after permission was checked. If a link in the working directory is being rewritten concurrently, stop that and retry.
+
+The text after the path names the reason:
+
+ * `its symlink resolution changed after permission was checked`: a symlink along the path, or at a Grep or Glob search root, was replaced between the permission check and the operation
+ * `its parent-directory symlink resolution changed after permission was checked`: a directory the write path passes through no longer resolves to the approved location
+ * `it is a symbolic link. Write to the link's target path instead`: a symbolic link sits at the approved write location itself
+ * `a path one of its Read deny rules is written through changed while the search was being prepared. Retry.`: a `Read` deny rule for the search names a path that passes through a symlink, and that link changed while Claude Code was preparing the search
+ * `it could not be opened (EACCES) — it is unreadable, or is being replaced concurrently.`: the search root exists but couldn’t be opened; the parenthesized code is the operating system error
+ * `its permission check expired before it ran (too many concurrent file operations). Retry.`: Claude Code evicted the approval record under many simultaneous file operations before the tool used it; retrying runs a fresh permission check
+ * `ripgrep was found only by name on PATH, and a search outside the working directory cannot apply your Read deny rules in that configuration`: Claude Code couldn’t resolve the `rg` binary to an absolute path, so it refuses searches outside the working directory rather than run one your deny rules don’t cover
+
+**What to do:**
+
+ * Usually nothing: the refusal reaches Claude as the tool result, and the refused operation doesn’t run
+ * If a symlink refusal repeats on one path, find what keeps rewriting a link there, such as a build tool or file watcher, or ask Claude to use the file’s resolved path instead of the linked one
+ * For the ripgrep refusal, install ripgrep with your package manager so `rg` resolves to an absolute path on `PATH`, or keep searches under the working directory
+
+Before v2.1.251, Claude Code re-checked a path’s resolution only for file writes, so a link replaced after the permission check could redirect a read or search to a different location without a message. Of these refusals, only the parent-directory write refusal appears on earlier versions.
+
##
@@ -2417,7 +2606,7 @@
A blocked command reports the same cause for its working directory and ends with `re-run the command from its local, plainly-spelled path`. Before v2.1.217, the guard compared path text only, so addressing a file inside the checkout through a UNC or `/net` path wasn’t blocked. **What to do:**
* Usually nothing: Claude retries with the local spelling the message asks for
- * If the file genuinely lives on a network share, it’s outside the session’s local workspace; edit it from a regular interactive session instead
+ * If the file is on a network share rather than a local file spelled with a network path, it’s outside the session’s local workspace; edit it from a regular interactive session instead
###
@@ -2832,6 +3021,24 @@
* Run `claude` in the directory and accept the trust dialog. [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>) says which folder that acceptance covers.
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
* If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
+
+###
+
+
+
+Remote managed settings failed to load
+
+Your session is eligible for [server-managed settings](</docs/en/server-managed-settings>), but Claude Code couldn’t fetch them, so it shows this warning in interactive sessions. The parenthesized cause names what failed, such as `network error`, `request timed out`, or `authentication rejected (401)`, and the rest of the line says which policy the session runs on:
+
+ * **Settings cached from an earlier successful fetch** : Claude Code runs the session on that cached policy, except the [withheld environment variables](</docs/en/server-managed-settings#fetch-and-caching-behavior>), and the line reads `using cached policy`.
+ * **No cache** : Claude Code runs the session without server-managed settings, and the line reads `no remote policy applied`.
+
+**What to do:**
+
+ * Act on the cause the message names: for a network cause, check that this machine can reach `api.anthropic.com`; for an authentication cause, check your sign-in with `/status`
+ * Run `/status` or `claude doctor` for the full diagnostic
+
+Before v2.1.248, Claude Code reported a failed settings fetch only in the debug log.
###
Show diff (466 lines)
--- a/errors.md
+++ b/errors.md
@@ -85,10 +85,9 @@
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
-`Couldn't show context usage: the remote sent a reply this version can't display`| Network
-`The remote session sent a reply this version can't display`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
+`Prompt is too long · this conversation is a single exchange` / `A single-exchange conversation cannot be compacted`| Request errors
`Context limit reached · /compact or /clear to continue`| Request errors
`Context limit reached · /clear to continue`| Request errors
`capability_rejected: prompt_too_long` on a Claude apps gateway session| Request errors
@@ -103,6 +102,7 @@
`Unable to resize image`| Request errors
`PDF too large` / `PDF is password protected`| Request errors
`Extra inputs are not permitted`| Request errors
+`API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid`| Request errors
`There's an issue with the selected model`| Request errors
`Model ... is not a recognized model id`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
@@ -139,6 +139,8 @@
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
`Your checkout has no branches (detached HEAD only)`| Command-line errors
+`Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected`| Command-line errors
+`Your connected GitHub account can't see <owner>/<repo>`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
@@ -150,6 +152,8 @@
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`Plugin archive integrity check failed`| Plugin errors
+`Failed to load marketplace configuration`| Plugin errors
+`Marketplace configuration file is corrupted`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
@@ -161,16 +165,25 @@
`Too many messages to this session just now`| Tool errors
`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
`Refusing to send: connected endpoint is not the expected process` / `Refusing to send: connected endpoint identity could not be read`| Tool errors
+`Refusing to send: connected endpoint is not owned by this user` / `Refusing to send: connected endpoint owner could not be read`| Tool errors
+`Refusing to send: connected endpoint is a different process with the expected pid`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
`blocked because the path is network-shaped`| Background session errors
`This session has no saved transcript`| Background session errors
+`Can't open — this session is running in another terminal`| Background session errors
+`This conversation is already open in another running Claude session`| Background session errors
+`This session's saved conversation is no longer on disk`| Background session errors
+`kept <id> — worktree has commits that are not pushed anywhere`| Background session errors
`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
`Session isn't responding` / `Press enter again to restart this session — it isn't responding`| Background session errors
+`Session <id> was stopped while the respawn was in flight`| Background session errors
`This session was running agent '<name>', which is no longer available`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
+`EACCES: permission denied, posix_spawn`| Background session errors
+`exited before it became reachable`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings
@@ -179,7 +192,9 @@
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| Configuration warnings
`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
+`Agent descriptions are over the 15.0k-token limit`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`"crossSessionInbound" must be one of "accept", "hold", "refuse"`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
`... has a wildcard before the rest of the command`| Configuration warnings
@@ -587,7 +602,7 @@
Could not resolve authentication method
-The session reached the API client without any credential. This appears in [background sessions](</docs/en/agent-view>), cloud sessions, and Agent SDK contexts where the interactive login check doesn’t run before the first request.
+The session reached the API client without any credential. [Background sessions](</docs/en/agent-view>) and cloud sessions show this message when the worker starts without a credential. Interactive, `-p`, and Agent SDK runs report the same condition as Not logged in and write this string only to their debug log, so if you found it there, follow that entry instead.
Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
@@ -1053,10 +1068,11 @@
Connection to api.anthropic.com timed out after 10 seconds
A proxy is configured via HTTPS_PROXY. Check that it allows connections to the host above.
-Claude Code sends the check through the same [proxy configuration](</docs/en/network-config>) as API requests and gives each probe 10 seconds. When the failed probe went through a proxy, the message names the environment variable that configured it, such as `HTTPS_PROXY`. Before v2.1.222, the check used a different proxy transport with no timeout: behind a proxy URL with the `https://` scheme, it could stall on `Checking connectivity...` indefinitely and then fail even though API requests through the same proxy succeed. **What to do:**
+Claude Code sends the check through the same [proxy configuration](</docs/en/network-config>) as API requests and gives each probe 10 seconds. When the failed probe went through a proxy, the message names the environment variable that configured it, such as `HTTPS_PROXY`. Before v2.1.222, the check used a different proxy transport with no timeout: behind a proxy URL with the `https://` scheme, it could stall on `Checking connectivity...` indefinitely and then fail even though API requests through the same proxy succeed. Claude Code skips this check when a [managed settings file, MDM policy, or policy helper](</docs/en/managed-settings>) sets [`forceLoginMethod`](</docs/en/settings-reference#forceloginmethod>) to `"gateway"`, or sets [`forceLoginGatewayUrl`](</docs/en/settings-reference#forcelogingatewayurl>) without `forceLoginMethod`. With either configuration, Claude Code opens the sign-in step on the **Cloud gateway** screen rather than an Anthropic sign-in method. Claude Code also skips the check when a managed settings source on the machine exists but can’t be read, since that source may hold the gateway configuration. Before v2.1.247, Claude Code ran the check under this configuration too, and exited with this error when Anthropic’s endpoints were unreachable. **What to do:**
* If the message names a proxy variable, check that its value points at the right proxy and ask your network team to allow HTTPS connections through it to the host in the message. See [Network configuration](</docs/en/network-config>).
* Work through the checks in Unable to connect to API. The `curl` test and firewall guidance there apply to this check too.
+ * If your organization signs in through a [cloud gateway](</docs/en/claude-apps-gateway>) and this error appears on first run, update to Claude Code v2.1.247 or later.
* If your network is open and the failure persists, Claude Code may not be [available in your country](<https://www.anthropic.com/supported-countries>)
###
@@ -1242,23 +1258,6 @@
-The remote sent a reply this version can’t display
-
-`/context` shows this line in a terminal [attached to a cloud session](</docs/en/claude-code-on-the-web#send-follow-ups-from-the-cli>):
-
- Couldn't show context usage: the remote sent a reply this version can't display
-
-While your terminal is attached, `/context` and `/btw` ask the cloud session for their answer. Sometimes the answer arrives in a form your terminal’s Claude Code can’t render. The usual cause is a version difference between the two. `/context` then shows the line above instead of the usage breakdown. `/btw` shows `The remote session sent a reply this version can't display` instead of its answer. The cloud session keeps running, and other commands still work. **What to do:**
-
- * Update Claude Code with `claude update`, reattach, and rerun the command
- * If the line still appears, run `/feedback` and name the command
-
-Before v2.1.235, this case showed a raw JavaScript error instead, such as `undefined is not an object`.
-
-###
-
-
-
Couldn’t share the transcript
After you agree to share your session transcript from a survey prompt, such as the [session quality survey](</docs/en/data-usage#session-quality-surveys>), Claude Code uploads it to Anthropic, or saves a local archive instead on third-party providers, on [Claude apps gateway](</docs/en/claude-apps-gateway>) sessions, and when no Anthropic credentials are available. This message means the share didn’t complete.
@@ -1296,13 +1295,25 @@
Context limit reached · /compact or /clear to continue · auto-compact is off · /config to turn it on
-The **Auto-compact** toggle in `/config` writes `autoCompactEnabled` to user settings. The hint appears only when a `/config` change would take effect. For example, it doesn’t appear when [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>) or [`DISABLE_COMPACT`](</docs/en/env-vars>) turned auto-compact off. It also doesn’t appear when a higher-precedence scope, such as project or managed settings, set `autoCompactEnabled` to `false`. Nor does it appear in a terminal attached to a cloud session, where the cloud session owns auto-compact. Before v2.1.235, the line carried no auto-compact hint. Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. A [Claude apps gateway](</docs/en/claude-apps-gateway-config#upstream-error-messages>) reports this condition as `capability_rejected: prompt_too_long` when a cloud upstream rejects the request in the provider’s own error shape. Claude Code treats the token the same as `Prompt is too long`. Before v2.1.228, Claude Code didn’t recognize the token, so auto-compact didn’t trigger on it. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
+The **Auto-compact** toggle in `/config` writes `autoCompactEnabled` to user settings. The hint appears only when a `/config` change would take effect. For example, it doesn’t appear when [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>) or [`DISABLE_COMPACT`](</docs/en/env-vars>) turned auto-compact off. It also doesn’t appear when a higher-precedence scope, such as project or managed settings, set `autoCompactEnabled` to `false`. Before v2.1.235, the line carried no auto-compact hint. Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. A [Claude apps gateway](</docs/en/claude-apps-gateway-config#upstream-error-messages>) reports this condition as `capability_rejected: prompt_too_long` when a cloud upstream rejects the request in the provider’s own error shape. Claude Code treats the token the same as `Prompt is too long`. Before v2.1.228, Claude Code didn’t recognize the token, so auto-compact didn’t trigger on it. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
Prompt is too long · automatic compaction failed: <the underlying error>
-Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced `Prompt is too long` without the cause. **What to do:**
-
- * Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
+Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced `Prompt is too long` without the cause. A single-exchange conversation has no earlier turns to summarize. When automatic compaction would have run on one, Claude Code skips the attempt and explains what fills the request instead. When the API doesn’t report token counts in its error, the message reads:
+
+ Prompt is too long · this conversation is a single exchange and cannot be compacted — the request size comes mostly from system prompt, tool definitions, or attachments.
+
+When the API reports token counts in its error, Claude Code compares them with its own estimate of the conversation’s size to tell which is most of the request: the conversation’s own content, or the system prompt, tool definitions, and attachment content that Claude Code sends with it. When the conversation’s own content is most of the request, the message reads:
+
+ Prompt is too long · the request is ~<request tokens> tokens (limit <limit>) and this conversation's own content is most of it. A single-exchange conversation cannot be compacted; start with less content (smaller files or pasted text).
+
+When most of the request is outside the conversation, the message reads:
+
+ Prompt is too long · the request is ~<request tokens> tokens (limit <limit>) but this conversation is only ~<conversation tokens> tokens — the rest is system prompt, tool definitions, and attachment content. A single-exchange conversation cannot be compacted; reduce attached files/tools or start with less context.
+
+Before v2.1.162, Claude Code attempted the compaction anyway and surfaced the bare `Prompt is too long` when it failed. **What to do:**
+
+ * In a multi-turn conversation, run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh. A single-exchange conversation can’t be compacted, so shrink the request instead
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
@@ -1327,7 +1338,7 @@
Both forms name `/clear` instead of `/compact` when you have set [`DISABLE_COMPACT`](</docs/en/env-vars>). **What to do:**
- * Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
+ * In a multi-turn conversation, run `/compact` to summarize earlier turns and free space. To start fresh instead, run `/clear`
* For more ways to reduce usage, see Prompt is too long
Before v2.1.216, `/context` showed usage above 100% with no warning line explaining what that meant or how to recover.
@@ -1437,6 +1448,22 @@
* Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers the exact scope.
+
+###
+
+
+
+Tool input schema is invalid
+
+A tool in the request declared an `input_schema` that fails the API’s JSON Schema validation, so the API rejected the whole request. The number after `tools.` is the failing tool’s position in the request’s tool list, not a name you can look up.
+
+ API Error: 400 ... tools.N.custom.input_schema: JSON schema is invalid
+
+Claude Code [excludes MCP tools whose input schema would fail this validation](</docs/en/mcp#tools-with-invalid-input-schemas>) when it loads a server’s tools, so requests normally never include one. On a deployment that doesn’t receive the remote configuration that enables the exclusion, Claude Code records in the server’s log which tool would be rejected but sends it anyway, so this error can still occur. The error can also occur for a tool whose schema declares a JSON Schema dialect other than draft 2020-12 in `$schema`: Claude Code doesn’t check those schemas against the JSON Schema meta-schema, though it still excludes one with an invalid top-level property name. Before v2.1.216, no deployment ran the exclusion checks. **What to do:**
+
+ * If your Claude Code version is earlier than v2.1.216, run `claude update`.
+ * Remove or [disable](</docs/en/mcp#disable-a-server-without-removing-it>) the MCP server that declares the invalid schema. The error names the tool only by position. On v2.1.216 or later, check each server’s log for a line naming a tool whose input schema would be rejected. If no log names one, disable servers one at a time.
+ * If you maintain the server, fix the tool’s `input_schema`. The schema must be valid JSON Schema, and top-level property names must be 1 to 64 characters long and use only ASCII letters and digits, `_`, `.`, and `-`. See [Tools with invalid input schemas](</docs/en/mcp#tools-with-invalid-input-schemas>).
###
@@ -1949,6 +1976,40 @@
+No GitHub account is connected to your Claude account
+
+You ran `/code-review ultra <PR#>` or `claude ultrareview <PR#>`, and before creating the cloud session Claude Code asks the server whether [the GitHub account connected to your Claude account](</docs/en/ultrareview#review-a-pull-request>) can reach the PR’s repository. No account is connected, or the connection expired, so the cloud clone would fail and Claude Code refuses the launch. Claude Code doesn’t spend a free run or bill usage credits for a refused launch.
+
+ Ultrareview clones <owner>/<repo> in the cloud with the GitHub account connected to your Claude account, and none is connected (or the connection expired). To fix: run /web-setup to reuse your GitHub CLI login, or connect an account at https://claude.ai/code/onboarding?step=alt-auth — then re-run /code-review ultra 1234 (allow a minute after connecting).
+
+When [`/web-setup`](</docs/en/web-quickstart#connect-from-your-terminal>) isn’t available in your session, the message names only the claude.ai link. **What to do:**
+
+ * Run `/web-setup` to connect your GitHub CLI login to your Claude account, or connect an account at [claude.ai/code/onboarding](<https://claude.ai/code/onboarding?step=alt-auth>)
+ * Rerun the review a minute after connecting
+
+Before v2.1.248, Claude Code didn’t check this before launch.
+
+###
+
+
+
+Your connected GitHub account can’t see the repository
+
+You ran `/code-review ultra <PR#>` or `claude ultrareview <PR#>`, and [the GitHub account connected to your Claude account](</docs/en/ultrareview#review-a-pull-request>) can’t read the PR’s repository, so the cloud clone would fail and Claude Code refuses the launch. Claude Code doesn’t spend a free run or bill usage credits for a refused launch.
+
+ Your connected GitHub account can't see <owner>/<repo> — usually the Claude GitHub app isn't installed on <owner> or wasn't granted this repo (web-connected accounts need it for private repos), or a different GitHub account is connected. To fix: run /web-setup to reuse your GitHub CLI login, or install the app at https://github.com/apps/claude/installations/new — then re-run /code-review ultra 1234.
+
+When [`/web-setup`](</docs/en/web-quickstart#connect-from-your-terminal>) isn’t available in your session, the message names only the app install. **What to do:**
+
+ * If your local `gh` CLI can read the repository, run `/web-setup` to connect that login to your Claude account
+ * Rerun the review after the change
+
+Before v2.1.248, Claude Code didn’t check this before launch.
+
+###
+
+
+
Failed to resume the conversation
Claude Code couldn’t read or process the saved transcript for the session you selected from the [`claude --resume` picker](</docs/en/sessions#use-the-session-picker>), so it ends the process rather than continue in a partially loaded state. The message includes the command to retry:
@@ -2102,6 +2163,26 @@
* If you publish the plugin, recompute the digest of the exact file the URL serves, for example with `shasum -a 256 my-plugin.zip`, or `Get-FileHash -Algorithm SHA256 my-plugin.zip` in PowerShell, and update the `sha256` in the marketplace entry
* If you install the plugin, run `/plugin marketplace update <name>` to refresh the catalog in case the entry was corrected, then retry the install
* If the digests still disagree after a refresh, ask the marketplace owner which file they pinned before installing
+
+###
+
+
+
+Failed to load marketplace configuration
+
+Claude Code keeps the plugin marketplaces you’ve added in a registry file at `~/.claude/plugins/known_marketplaces.json`. A plugin command that needs the registry, such as `claude plugin install`, fails with one of two messages when Claude Code can’t use the file:
+
+ * `Failed to load marketplace configuration`: the file isn’t valid JSON, or can’t be read. An empty file fails this way too.
+ * `Marketplace configuration file is corrupted`: the file is valid JSON but its contents don’t match the registry schema.
+
+A missing file isn’t a failure: Claude Code treats it as a registry with no marketplaces. With an empty file, `claude plugin install` reports:
+
+ ✘ Failed to install plugin "my-plugin": Failed to load marketplace configuration: JSON Parse error: Unexpected EOF
+
+Before v2.1.246, `claude plugin install` didn’t report this failure. **What to do:**
+
+ * Open `~/.claude/plugins/known_marketplaces.json` and repair the JSON, or fix the entries the message names as not matching the registry schema
+ * If you can’t repair it, delete the file or replace its contents with `{}`, then re-add each marketplace with `claude plugin marketplace add <source>`. Claude Code re-registers the marketplaces your user or managed settings declare in [`extraKnownMarketplaces`](</docs/en/settings-reference#extraknownmarketplaces>) the next time you start it in a folder you’ve trusted.
##
@@ -2271,6 +2352,9 @@
* `cannot vet reply target`: Claude Code couldn’t inspect the target path at all, for example because reading it failed with a permission error.
* `connected endpoint is not the expected process`: the process holding the socket isn’t the session the message was addressed to, so the address is stale or another process replaced the socket.
* `connected endpoint identity could not be read`: Claude Code connected but couldn’t read which process holds the other end, so it couldn’t confirm the target. This can be transient.
+ * `connected endpoint is not owned by this user`: the process holding the socket runs as a different user account, so it isn’t one of your sessions.
+ * `connected endpoint owner could not be read`: Claude Code connected but couldn’t read which user account owns the other end, so it couldn’t confirm the endpoint is yours.
+ * `connected endpoint is a different process with the expected pid`: the process id matches the one the message was addressed to, but Claude Code couldn’t confirm it’s the same process. Usually that session exited and the operating system reused its process id, so the address is stale.
**What to do:**
@@ -2278,6 +2362,9 @@
* Ask Claude to list your sessions again and resend; a refusal caused by a stale address clears once Claude sends to the current one
* If `reply target is a symlink` repeats for one session, check what created a link at that session’s socket path, shown in its `/status` under `Peer address`
* For `connected endpoint identity could not be read`, resend; the condition can be transient
+ * If `connected endpoint is not owned by this user` appears on a shared machine, the session at that address runs under another user’s account, so Claude can’t message it from yours
+
+Before v2.1.248, Claude Code didn’t check the endpoint’s owning user or process start time, so the refusals that name those checks don’t appear on earlier versions.
##
@@ -2352,6 +2439,62 @@
+This session is running in another terminal
+
+You opened a stopped session’s row in [agent view](</docs/en/agent-view>), and its saved conversation is already open in another live Claude Code process on this machine, so Claude Code refuses to start a second process that would write to the same transcript. Which message you see depends on [what holds the conversation](</docs/en/agent-view#opening-a-session-says-the-conversation-is-already-open>):
+
+ Can't open — this session is running in another terminal
+ This conversation is already open in another running Claude session — use that one, or close it and try again
+
+ * **`running in another terminal`** : a terminal holds the conversation, for example one where you resumed it with `claude --resume` or `/resume`. The row also shows `Open in a terminal`.
+ * **`already open in another running Claude session`** : another non-interactive Claude Code process holds it, for example a [background session](</docs/en/agent-view#the-supervisor-process>) process for the same conversation that hasn’t exited yet.
+
+Claude Code saves a reply you typed when opening the row and sends it as the session’s next prompt when the session next starts. **What to do:**
+
+ * Continue the conversation in the process that has it open, or exit that process and open the row again
+
+Before v2.1.248, only the `already open in another running Claude session` refusal existed: a conversation resumed in a terminal didn’t count as open, and opening the row started a second Claude Code process writing to the same conversation.
+
+###
+
+
+
+This session’s saved conversation is no longer on disk
+
+You opened a [background session](</docs/en/agent-view>) that ended while the background service was off, and [transcript cleanup](</docs/en/settings-reference#cleanupperioddays>) has since removed its saved conversation, for example after the machine was off for weeks. Opening such a row normally [resumes its saved conversation](</docs/en/agent-view#sessions-show-as-failed-after-shutdown>). With nothing left to resume, Claude Code refuses rather than re-run the session’s original prompt without asking:
+
+ This session's saved conversation is no longer on disk (it ended while the background service was off, and old transcripts are cleaned up), so there is nothing to resume. `claude rm 7c5dcf5d` deletes the row; `claude respawn 7c5dcf5d` runs its original prompt again instead.
+
+`claude attach <id>` prints this text. In agent view, the footer is shorter and ends with `ctrl+x deletes the row`. **What to do:**
+
+ * Run `claude rm <id>` to delete the row. When one of the [kept cases](</docs/en/agent-view#what-deleting-a-session-removes>) applies, `claude rm` keeps the row and the worktree instead and names the reason
+ * To run the session’s original prompt again as a fresh conversation, run `claude respawn <id>`
+
+Before v2.1.248, opening such a row re-ran the session’s original prompt instead of refusing, pulling a weeks-old task back into the foreground.
+
+###
+
+
+
+Worktree has commits that are not pushed anywhere
+
+You tried to delete a [background session](</docs/en/agent-view#what-deleting-a-session-removes>) whose worktree holds commits Claude Code can’t confirm are saved elsewhere. Claude Code keeps the worktree and the session row rather than destroy the commits. `claude rm` prints the kept path and the reason:
+
+ kept 7c5dcf5d — worktree has commits that are not pushed anywhere
+ worktree kept at /home/you/project/.claude/worktrees/fix-login
+ resolve that (commit/push, or remove the worktree), then run 'claude rm 7c5dcf5d' again
+
+When you delete from [agent view](</docs/en/agent-view>) with a `Ctrl+X` double-press, you consent to discarding uncommitted changes, but not to discarding commits, so Claude Code refuses there too. After a refused delete, the session’s row shows `not deleted` with the same reason. Commits on a remote don’t block the delete. Neither do commits on the local copy of your `origin` remote’s default branch, as long as that branch is checked out in your main checkout, the repository directory itself rather than a worktree. **What to do:**
+
+ * Push the worktree’s branch, or merge it into the default branch checked out in your main checkout, then delete the session again
+ * To delete the session without pushing or merging the commits, first note the branch that `git worktree list` shows for the path the message names. Remove the worktree yourself with `git worktree remove --force <path>`, as described in [Clean up subagent and background-session worktrees](</docs/en/worktrees#clean-up-subagent-and-background-session-worktrees>), then run `claude rm <id>` again. Neither step deletes that branch, so the commits stay on it until you run `git branch -D <branch>`.
+
+Before v2.1.248, the default branch checked out in your main checkout didn’t count: a branch you had already merged there still triggered this refusal until its commits reached a remote.
+
+###
+
+
+
Terminal host process died
Each [background session’s](</docs/en/agent-view>) terminal runs in a host process under the background service, and that process died while the service still held its connection, so the session couldn’t be reached. On Linux and WSL, the background service checks each host process every few seconds, marks the session failed when the process has exited but its connection to the service never closed, and shows the reason on its row in [agent view](</docs/en/agent-view#read-session-state>):
@@ -2394,6 +2537,21 @@
+Session was stopped while the respawn was in flight
+
+You opened a [background session](</docs/en/agent-view>) whose process wasn’t running, and while Claude Code was restarting it, another Claude Code process stopped it, for example `claude stop` in another terminal. Claude Code keeps the session stopped:
+
+ Session <id> was stopped while the respawn was in flight
+
+Opening a session you just dispatched, while its process is still starting, waits for the process instead. Before v2.1.246, opening it at that moment could stop it and show this message. **What to do:**
+
+ * If you didn’t stop the session, open its row again in agent view or run `claude respawn <id>` to restart it
+ * If you stopped it yourself, nothing remains to do: the session stays stopped
+
+###
+
+
+
Session agent no longer available
You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
@@ -2432,12 +2590,43 @@
Couldn't reach the background service (spawn background service: EUNKNOWN: unknown error, uv_spawn) — run 'claude daemon status'
-On some accounts the message says `daemon` in place of `background service`. Claude Code starts the background service through PowerShell so the service survives closing the terminal, using PowerShell 7 when it’s installed and Windows PowerShell 5.1 otherwise. When neither PowerShell can run, Claude Code starts the service directly instead, so a policy that blocks only PowerShell doesn’t cause this error. If you see it, the policy is blocking the Claude Code executable itself. Before v2.1.212, Claude Code used only Windows PowerShell 5.1 to start the service, so any machine where Group Policy blocked PowerShell 5.1 failed with `Couldn't start the session — EUNKNOWN: unknown error, uv_spawn`, even with PowerShell 7 installed. **What to do:**
+On some accounts the message says `daemon` in place of `background service`. On an npm installation, an `EUNKNOWN` that appears while `npm install -g @anthropic-ai/claude-code` is replacing the binary has the same cause as `EACCES` during a reinstall and clears when you retry after the install finishes. Claude Code starts the background service through PowerShell so the service survives closing the terminal, using PowerShell 7 when it’s installed and Windows PowerShell 5.1 otherwise. When neither PowerShell can run, Claude Code starts the service directly instead, so a policy that blocks only PowerShell doesn’t cause this error. If you see it while no npm install is running, the policy is blocking the Claude Code executable itself. Before v2.1.212, Claude Code used only Windows PowerShell 5.1 to start the service, so any machine where Group Policy blocked PowerShell 5.1 failed with `Couldn't start the session — EUNKNOWN: unknown error, uv_spawn`, even with PowerShell 7 installed. **What to do:**
* If the message reads `Couldn't start the session`, upgrade to v2.1.212 or later. On earlier versions you can also run `claude daemon run` in a separate terminal first, then start the background session again. That command runs the background service in the terminal’s foreground, so the service lasts only as long as that terminal stays open.
- * If the error appears on v2.1.212 or later, ask your Windows administrator to allow the Claude Code executable in the restriction policy
+ * If an npm install was replacing the binary, wait for it to finish, then start the background session again
+ * If the error appears on v2.1.212 or later while no npm install is running, ask your Windows administrator to allow the Claude Code executable in the restriction policy
* If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
+###
+
+
+
+EACCES when starting a background session
+
+Claude Code couldn’t run its own binary to start the [background service](</docs/en/agent-view#the-supervisor-process>) that hosts background sessions. On an npm installation, this usually means `npm install -g @anthropic-ai/claude-code` was replacing the binary at that moment, whether you ran it or the [auto-updater](</docs/en/setup#auto-updates>) did. The error appears when you open a session from [agent view](</docs/en/agent-view>):
+
+ Couldn't start the background service — spawn background service: EACCES: permission denied, posix_spawn '/usr/local/lib/node_modules/@anthropic-ai/claude-code/bin/claude'
+
+When you start a session with `/background` or `claude --bg`, the same reason appears inside `Couldn't reach the background service (...)`. During the same reinstall window the error can name another code instead, such as `ENOENT` or `ENOEXEC`, or `EUNKNOWN` or `EPERM` on Windows; an `EUNKNOWN` that persists across retries has a different cause. On an npm installation, Claude Code waits up to ten seconds for the reinstall to finish and retries on its own, so you see the error only when the binary stays unrunnable for longer, such as while npm is still downloading the package. Before v2.1.246, Claude Code failed at once. **What to do:**
+
+ * Wait a few seconds, then open the session or dispatch again.
+ * If the error persists while no npm install is running, your user can’t run the installed binary. Check its permissions and its directory’s, or reinstall Claude Code.
+
+###
+
+
+
+Background service exited before it became reachable
+
+The process Claude Code started as the [background service](</docs/en/agent-view#the-supervisor-process>) exited before it accepted connections, so Claude Code couldn’t open your session. When the service printed an error before exiting, the reason in parentheses gives the exit code or signal and the first line the service printed, which names what stopped it:
+
+ Couldn't reach the background service (background service exited before it became reachable (exit code N): <the service's first error line>) — run 'claude daemon status'
+
+When you open a session from [agent view](</docs/en/agent-view>), the same reason follows `Couldn't start the background service —`. When the service printed nothing before exiting, the message says `nothing on stderr` instead. Claude Code reports the failure with the service’s error line. Before v2.1.246, the failure surfaced only after a 45-second wait, as `background service did not become reachable within 45s`, without the service’s error line. **What to do:**
+
+ * If the message quotes a line, fix what it names, then open the session or dispatch again. The next attempt starts the service again
+ * Run `claude daemon status` to check whether a service is running now
+
##
@@ -2459,6 +2648,7 @@
**What to do:**
* In VS Code, follow the **View output logs** link shown with the error to see the underlying failure
+ * In an Agent SDK application, catch the error around your message loop. The entries under [CLI process exit](</docs/en/agent-sdk/troubleshooting#cli-process-exit>) cover what your code receives in each SDK language.
* Run `claude` in a terminal in the same project. The failure usually reproduces there with its real error message, which you can then look up on this page.
* Run `claude doctor` in a terminal to check the installation and configuration
@@ -2574,7 +2764,7 @@
Configuration warnings
-Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup. Two exceptions: it writes the unrecognized-model diagnostic line at request time, and the unrecoverable interface error message as it exits.
+Claude Code writes most of these messages to stderr, not into the conversation, and writes most of them at startup. An entry says so when its message appears somewhere else, such as in the debug log or as a startup notice in the conversation view, or at another time, such as the unrecognized-model diagnostic line at request time.
###
@@ -2611,6 +2801,21 @@
* If the message names the fullscreen renderer, [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>) says what the next launch does, which depends on how you turned fullscreen on, and how to try fullscreen again or keep the classic renderer.
Before v2.1.236, Claude Code exited without printing a message after this kind of error.
+
+###
+
+
+
+Agent descriptions are over the 15.0k-token limit
+
+Claude Code shows this warning as a startup notice in the conversation view rather than on stderr. The combined descriptions of your [subagents](</docs/en/sub-agents>), except the built-in ones, exceed 15,000 tokens as Claude Code estimates them. Each agent counts its name plus its `description` frontmatter. Claude Code loads every agent whether or not the total is over the limit, so the warning doesn’t change what loads.
+
+ Agent descriptions are over the 15.0k-token limit (~16.2k tokens) · ask Claude to trim agent descriptions in .claude/agents/
+
+**What to do:**
+
+ * Shorten the `description` frontmatter of your agent files, or ask Claude to trim them for you.
+ * Remove agent files you no longer use.
###
@@ -2687,6 +2892,23 @@
+crossSessionInbound must be one of accept, hold, refuse
+
+A settings file sets [`crossSessionInbound`](</docs/en/settings-reference#crosssessioninbound>) to a value Claude Code doesn’t recognize, such as the typo `"reject"`. The warning’s second sentence depends on which file holds the value; in a user, project, local, or `--settings` file it reads:
+
+ "crossSessionInbound" must be one of "accept", "hold", "refuse"; received "reject". This value was ignored; while it is present, cross-session messages are held for your approval instead of being delivered. Set it to one of the values above.
+
+In [managed settings](</docs/en/managed-settings>), Claude Code treats the unrecognized value as `refuse`, the most restrictive value, and the warning says cross-session messages are turned away until an administrator fixes it. For how the hold combines with values in your other settings files, see [`crossSessionInbound`](</docs/en/settings-reference#crosssessioninbound>). **What to do:**
+
+ * Set the key to `"accept"`, `"hold"`, or `"refuse"`, or remove it
+ * When the warning names managed settings, ask the administrator to fix the value
+
+Before v2.1.248, Claude Code ignored an unrecognized value without warning.
+
+###
+
+
+
The 200K limit isn’t enforced
You set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>), which normally makes [auto-compaction](</docs/en/model-config#default-auto-compact-thresholds>) hold sessions on 1M-context models to a 200K window, but no compaction threshold caps this session at or below 200K, so the conversation can grow past it.
Show diff (301 lines)
--- a/errors.md
+++ b/errors.md
@@ -81,6 +81,7 @@
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`proxy refused the connection`| Network
`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
+`The cloud environments service returned an empty response` / `The cloud environments service returned a response in an unexpected format`| Network
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
@@ -109,6 +110,8 @@
`thinking.type.enabled is not supported for this model`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
+`[Unsupported tool content removed]`| Request errors
+`server_tool_use.name: Input should be` on every turn of a resumed session| Request errors
`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
`<model>'s safeguards flagged this message`| Request errors
@@ -124,6 +127,7 @@
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
+`is Anthropic-hosted and doesn't support local OAuth`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
@@ -139,6 +143,8 @@
`No conversation found with session ID: <session-id>`| Command-line errors
`Cannot switch renderers in this session`| Command-line errors
`Cannot switch renderers while work is running in the background`| Command-line errors
+`Couldn't read your Zed keymap` / `Couldn't back up your Zed keymap` / `Couldn't update your Zed keymap`| Command-line errors
+`Your Zed keymap isn't a readable list of keybindings`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -160,6 +166,8 @@
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
`blocked because the path is network-shaped`| Background session errors
`This session has no saved transcript`| Background session errors
+`terminal host process died — press Enter to restart` / `This session's terminal host process died`| Background session errors
+`Session isn't responding` / `Press enter again to restart this session — it isn't responding`| Background session errors
`This session was running agent '<name>', which is no longer available`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
@@ -169,6 +177,8 @@
`Transcript writes are failing (...)`| Session saving warnings
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
+`Claude Code's fullscreen renderer didn't finish starting last time on this machine` / `Claude Code's fullscreen renderer has repeatedly failed to start on this machine`| Configuration warnings
+`Claude Code exited after an unrecoverable interface error (...)`| Configuration warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
@@ -199,7 +209,7 @@
Before v2.1.227, `Connection lost before a response was produced` read `Connection closed while thinking, before producing a response` and `The response stalled before a response was produced` read `Response stalled while thinking, before producing a response`. Claude Code doesn’t retry these failures:
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
- * A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code doesn’t re-run the request, because that could execute the same tool calls twice. It keeps what Claude completed, runs any tool calls Claude finished, and continues the turn from their results. For what you see in an interactive session and in a non-interactive one, read The response above may be incomplete. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
* A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
@@ -211,7 +221,13 @@
What you see while Claude Code retries or waits
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. After the abort, Claude Code retries the request, ends the turn with an error when the failure isn’t retryable or retries run out, shows The response above may be incomplete and continues the turn from the results of any tool calls Claude completed, or ends the turn normally when Claude had already finished the response before the stall. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. After the abort, what you see depends on how far the response had got:
+
+ * Before Claude has completed a block of text or a tool call, or started one after finishing its thinking, Claude Code retries the request or ends the turn with an error. Automatic retries says which stalls it retries and how many times.
+ * After Claude has completed a block of text or a tool call, or started one after finishing its thinking, but before Claude has finished the response, Claude Code keeps what Claude completed, continues the turn from any tool calls Claude finished, and shows The response above may be incomplete. In a non-interactive session, Claude Code may first prompt Claude to continue the response; that entry says when it does and when you still see the notice there.
+ * After Claude finished the response, Claude Code ends the turn normally.
+
+The banner clears on its own once data resumes or a retry succeeds. If it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
###
@@ -302,10 +318,11 @@
* `Your computer went to sleep mid-response`: Claude Code detected that your computer went to sleep while the response was streaming. Once your computer wakes, Claude Code treats the connection as broken and stops reading from it.
* `The response stopped arriving`: the connection stayed open but stopped delivering data, so the streaming idle watchdog aborted it. Before v2.1.222, Claude Code could also report this failure on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because it counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. When one of these failures lands at another point in the turn, Claude Code handles it without this notice:
+Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. In three cases, Claude Code handles the failure without showing this notice right away:
* Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
* When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
+ * In a [non-interactive session](</docs/en/headless>), such as a `-p` run, an [Agent SDK](</docs/en/agent-sdk/overview>) run, or a [cloud session](</docs/en/claude-code-on-the-web>), you don’t have to send `continue` yourself when the cut-off response is in the main conversation and contains text but no tool calls: Claude Code keeps the partial output and prompts Claude to continue from where it stopped, up to three times in a row. You see this notice for such a response only once Claude Code has used up those continuations. Before v2.1.246, Claude Code ended a non-interactive turn with this notice on the first cut-off.
**What to do:**
@@ -313,7 +330,7 @@
* In [non-interactive mode](</docs/en/headless>) (`-p`):
* With the default text output, Claude Code prints the last completed block of text it still holds from earlier in the turn, followed by this message. When it holds none, Claude Code prints this message alone, for example because Claude Code compacted the conversation mid-turn and cleared that text. Before v2.1.219, Claude Code printed only this message in `-p` text output and dropped the response it had already produced.
* With `--output-format json` or `stream-json`, Claude Code reports this message in the `result` field.
- * To continue the turn, resume the session and send `continue` as described in [Continue conversations](</docs/en/headless#continue-conversations>).
+ * To continue the turn once the connection is stable, resume the session and send `continue` as described in [Continue conversations](</docs/en/headless#continue-conversations>).
###
@@ -1167,9 +1184,28 @@
**What to do:**
* Check the address and credentials in the proxy variable, as [Proxy configuration](</docs/en/network-config#proxy-configuration>) describes, then run `curl -x http://proxy.example.com:8080 -I https://api.anthropic.com` from the shell you start Claude Code in, using your own proxy URL. On Windows PowerShell, run `curl.exe`. If this probe fails the same way, fix the proxy setup first. If it succeeds, the refusal is specific to the artifact host.
- * If your network lets Claude Code reach the artifact host directly, add `.claudeusercontent.com` to [`NO_PROXY`](</docs/en/network-config#environment-variables>).
+ * If your network lets Claude Code reach the artifact host directly, add `.frame.claudeusercontent.com` to [`NO_PROXY`](</docs/en/network-config#environment-variables>). Keep the entry that narrow: a broader `.claudeusercontent.com` entry also bypasses the proxy for `bridge.claudeusercontent.com`, which organizations with [IP allowlisting](</docs/en/network-config#organization-ip-allowlists-and-proxy-egress>) need to keep on the proxy.
Before v2.1.238, Claude Code reported a refused tunnel as a generic network error.
+
+###
+
+
+
+The cloud environments service returned an empty or unexpected response
+
+Claude Code requests your [cloud environments](</docs/en/cloud-environments>) list at several points, such as when you create a cloud session from the CLI or run [`/remote-env`](</docs/en/cloud-environments#select-an-environment-from-the-cli>). When it can’t read the server’s answer, it shows one of these messages:
+
+ The cloud environments service returned an empty response (HTTP 200 with no body). This is usually temporary — try again in a moment.
+ The cloud environments service returned a response in an unexpected format (HTTP 200 with a non-JSON body). This is usually temporary — try again in a moment.
+ The cloud environments service returned a response in an unexpected format (HTTP 200 without a usable environments list). This is usually temporary — try again in a moment.
+
+The server accepted the request but answered with a body that isn’t the environments list: empty, not JSON, or JSON without the list. This usually accompanies a service-side disruption and clears on its own. Depending on the surface that requested the list, Claude Code may add a prefix, such as `couldn't list environments:` in the `/remote-env` dialog. **What to do:**
+
+ * Retry the action. Claude Code requests the list again each time
+ * If the message keeps appearing, check [status.claude.com](<https://status.claude.com>) for active incidents
+
+Before v2.1.236, Claude Code showed a raw JavaScript TypeError instead of these messages.
###
@@ -1524,6 +1560,21 @@
+Unsupported tool content removed
+
+When Claude Code connects directly to the Anthropic API and loads or previews a saved session, it removes tool content the Anthropic API doesn’t accept and leaves this line where removed content sat between two thinking blocks:
+
+ [Unsupported tool content removed]
+
+Such content reaches a session file when something other than the Anthropic API answered in the API’s format, typically a third-party proxy set through [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) that translates another provider’s tool calls. Claude Code removes it only when the session connects directly to the Anthropic API, and loads the saved history as it is when the session runs through a proxy or on another provider. Before v2.1.246, Claude Code sent the tool use and its result back to the API, and every turn of the resumed session failed with a 400 error such as `messages.1.content.0.server_tool_use.name: Input should be 'web_search', 'web_fetch', ...`. **What to do:**
+
+ * None needed when you see the placeholder line. The session continues without the removed content.
+ * If every turn of a resumed session fails with the 400 error instead, run `claude update` and resume the session again. Versions before v2.1.246 don’t remove the content.
+
+###
+
+
+
Usage Policy refusal
The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID you can quote to support if you believe the refusal is incorrect.
@@ -1742,6 +1793,21 @@
+Server is Anthropic-hosted and doesn’t support local OAuth
+
+You started a sign-in for an MCP server whose URL points at an Anthropic-hosted connector host that authenticates through a third-party identity provider. These hosts include `microsoft365.mcp.claude.com`, `gmail.mcp.claude.com`, and `gcal.mcp.claude.com`. Claude Code refuses to start its local OAuth flow for these hosts from both the `/mcp` panel and `claude mcp login`, because [their sign-in works only through claude.ai](</docs/en/mcp#use-mcp-servers-from-claude-ai>).
+
+ "gmail" is Anthropic-hosted and doesn't support local OAuth. Connect it via Settings → Connectors on claude.ai (requires `claude login`), then it'll be available here automatically.
+
+Claude Code matches these hosts by URL, so the message appears when a server you added with `claude mcp add` or in `.mcp.json` points at one of them. **What to do:**
+
+ * Remove your entry with `claude mcp remove <name>`, so it can’t hide the claude.ai connector at the same URL
+ * After removing it, connect the service at [claude.ai/customize/connectors](<https://claude.ai/customize/connectors>), while signed in to the account you use in Claude Code. Once connected, [the connector appears in Claude Code automatically](</docs/en/mcp#use-mcp-servers-from-claude-ai>) if your active authentication method is a claude.ai subscription login
+
+###
+
+
+
MCP permission prompt tool not found
The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call that needs approval, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
@@ -1942,6 +2008,32 @@
**What to do:**
* In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings-reference#tui>) there
+
+###
+
+
+
+/terminal-setup left your Zed keymap unchanged
+
+You ran [`/terminal-setup`](</docs/en/terminal-config#enter-multiline-prompts>) in Zed, and Claude Code couldn’t complete the update to your Zed `keymap.json`, so it left the file as it was. Each message names the path to your keymap and ends with the keybinding block to add yourself:
+
+ Couldn't update your Zed keymap, so it was left unchanged.
+ To add the binding yourself, add this block to the keymap array in <path to keymap.json>:
+ { "context": "Terminal", "bindings": { "shift-enter": ["terminal::SendText", "\u001b\r"] } }
+
+The first line of the message names the cause:
+
+ * `Couldn't read your Zed keymap, so it was left unchanged.`: Claude Code couldn’t read the file, for example because of file permissions
+ * `Your Zed keymap isn't a readable list of keybindings, so it was left unchanged.`: the file read fine but doesn’t parse as an array of keybinding blocks, even with `//` comments and trailing commas allowed
+ * `Couldn't back up your Zed keymap; not modifying it.`: Claude Code couldn’t copy the file to a `.bak` backup beside it, so it changed nothing
+ * `Couldn't update your Zed keymap, so it was left unchanged.`: the merged result didn’t verify as a valid keymap carrying the binding, so Claude Code discarded it instead of writing. A keybinding block with a duplicated key can cause this
+
+**What to do:**
+
+ * Copy the block from the message into the top-level array in your `keymap.json` at the path the message names
+ * For `isn't a readable list of keybindings`, fix the syntax error, or make the file’s top-level value an array, then run `/terminal-setup` again
+
+Before v2.1.247, `/terminal-setup` couldn’t parse a Zed keymap that used `//` comments or trailing commas, and it replaced the entire file with only its own binding while reporting the binding as installed. To restore a keymap an earlier version replaced, use the `.bak` backup file described under [Enter multiline prompts](</docs/en/terminal-config#enter-multiline-prompts>).
##
@@ -2260,6 +2352,48 @@
+Terminal host process died
+
+Each [background session’s](</docs/en/agent-view>) terminal runs in a host process under the background service, and that process died while the service still held its connection, so the session couldn’t be reached. On Linux and WSL, the background service checks each host process every few seconds, marks the session failed when the process has exited but its connection to the service never closed, and shows the reason on its row in [agent view](</docs/en/agent-view#read-session-state>):
+
+ terminal host process died — press Enter to restart
+
+If you open the row before the check runs, the footer shows `This session's terminal host process died (the conversation is saved) — press Enter to restart it` and the row turns failed. From the shell, `claude attach <id>` restarts a session already marked failed for a dead host, and otherwise prints the cause and exits:
+
+ Couldn't attach to <id> — This session's terminal host process died (the conversation is saved) — run `claude attach <id>` again to restart it on a fresh host.
+
+The conversation is saved either way. A row running a [shell command](</docs/en/agent-view#run-a-shell-command>) instead shows `terminal host process died — its output is gone; the command was not run again`, and `claude attach` prints `This command's terminal host process died — its output is gone and the command was not run again`. Claude Code never reruns the command for you. **What to do:**
+
+ * In agent view, press `Enter` on the failed row; the session restarts on a fresh host process and the conversation resumes
+ * From the shell, run `claude attach <id>` again. Claude Code prints `Session <id>'s terminal host died — restarting it on a fresh one…` and reopens the session
+ * You can’t restart a shell-command row this way; dispatch the command again to rerun it
+
+Before v2.1.247, a dead host process could pass every liveness check the background service ran, so opening the session showed `opening… · esc to cancel` indefinitely and `claude attach <id>` waited without reporting an error.
+
+###
+
+
+
+Session isn’t responding
+
+You opened a [background session](</docs/en/agent-view>) and the background service accepted the open, but no output arrived for about ten seconds, so Claude Code concludes that the process relaying the session’s terminal can’t deliver output, and ends the attempt instead of waiting. In agent view, Claude Code offers a restart in the footer:
+
+ Press enter again to restart this session — it isn't responding (its conversation is saved and resumes).
+
+From the shell, `claude attach <id>` prints the cause and exits:
+
+ Couldn't attach to <id> — Session isn't responding — `claude stop <id>`, then `claude attach <id>` restarts it (the conversation is saved).
+
+Claude Code never restarts a row running a [shell command](</docs/en/agent-view#run-a-shell-command>) for you, because a restart would run the command again. **What to do:**
+
+ * In agent view, press `Enter` on the same row again. Claude Code stops the unresponsive process and restarts the session, and the conversation resumes. Nothing is stopped without that second press
+ * From the shell, run `claude stop <id>`, then `claude attach <id>`
+ * For a shell-command row, press `Ctrl+X` in agent view or run `claude stop <id>` to stop it; dispatch the command again to rerun it
+
+###
+
+
+
Session agent no longer available
You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
@@ -2440,7 +2574,43 @@
Configuration warnings
-Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup and writes the unrecognized-model diagnostic line at request time.
+Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup. Two exceptions: it writes the unrecognized-model diagnostic line at request time, and the unrecoverable interface error message as it exits.
+
+###
+
+
+
+Fullscreen renderer didn’t finish starting
+
+A previous [fullscreen](</docs/en/fullscreen>) session on this machine exited before it finished starting, so Claude Code starts this session on the classic renderer and prints one of these notices:
+
+ Claude Code's fullscreen renderer didn't finish starting last time on this machine, so this launch is using the classic renderer. It will try fullscreen again next launch; /tui default keeps the classic renderer.
+
+ Claude Code's fullscreen renderer has repeatedly failed to start on this machine, so it has been turned off here. Run /tui fullscreen to try it again (this also resets after an update).
+
+**What to do:**
+
+ * Follow [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>). It says which notice you get, what Claude Code does in later sessions, and how to try fullscreen again or keep the classic renderer.
+ * If the session that died printed an exit message, see Claude Code exited after an unrecoverable interface error for what it names.
+
+Before v2.1.236, Claude Code printed no notice and kept starting sessions in fullscreen rendering after a failed start.
+
+###
+
+
+
+Claude Code exited after an unrecoverable interface error
+
+Claude Code prints this message when it exits because its terminal interface hit an error it can’t recover from, in either renderer. The second sentence appears only when the error happened while the [fullscreen](</docs/en/fullscreen>) renderer was starting:
+
+ Claude Code exited after an unrecoverable interface error (<error>). It happened while the fullscreen renderer was starting, so the next launch will use the classic renderer (CLAUDE_CODE_DISABLE_ALTERNATE_SCREEN=1 forces that any time).
+
+**What to do:**
+
+ * Start Claude Code again. To pick the conversation back up, run `claude --resume` in the same directory.
+ * If the message names the fullscreen renderer, [Fullscreen rendering](</docs/en/fullscreen#fullscreen-renderer-didnt-finish-starting>) says what the next launch does, which depends on how you turned fullscreen on, and how to try fullscreen again or keep the classic renderer.
+
+Before v2.1.236, Claude Code exited without printing a message after this kind of error.
###
--- a/errors.md
+++ b/errors.md
@@ -74,6 +74,7 @@
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`API returned an empty or malformed response`| Network
+`Streaming response ended before any complete data was received`| Network
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
@@ -171,6 +172,7 @@
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
+`... has a wildcard before the rest of the command`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
`[claude-code:unrecognized_model]`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -1077,6 +1079,21 @@
+Streaming response ended before any complete data was received
+
+A streaming response from your model provider completed without delivering any usable data, so Claude Code re-sent the request without streaming to finish the turn. Claude Code shows the warning once per session, in interactive sessions only. Before v2.1.239, Claude Code silently retried without streaming.
+
+ Streaming response ended before any complete data was received. Retrying without streaming. If this keeps happening, check any proxy or gateway between Claude Code and your model provider.
+
+Claude Code sends each affected request twice: the empty streaming attempt and the retry. The usual cause is a proxy or gateway that consumes or transforms the streaming response body on its way back. **What to do:**
+
+ * Configure any proxy or gateway between Claude Code and your model provider to pass streaming response bodies and their headers through unmodified
+ * On [Amazon Bedrock](</docs/en/amazon-bedrock>), see [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>) for the header and body requirements
+
+###
+
+
+
Bedrock streaming response has an unexpected content-type
A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`, and Claude Code rejects a successful streaming response that reports a different content-type instead of decoding a body it can’t read. The request isn’t retried.
@@ -2423,7 +2440,7 @@
Configuration warnings
-Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup, reporting configuration it read but didn’t apply, and writes the unrecognized-model diagnostic line at request time.
+Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup and writes the unrecognized-model diagnostic line at request time.
###
@@ -2481,6 +2498,25 @@
+Has a wildcard before the rest of the command
+
+Claude Code found a `Bash` allow rule whose `*` comes before a later word that determines which command it is, such as `Bash(git * main)` or `Bash(git -C * status *)`, in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in an `--allowedTools` or `--settings` flag value. The `*` matches any text, including options inserted at that position: `Bash(git * main)` also approves `git -c core.fsmonitor=<script> diff main`, where `-c` makes git run a program the command names. [Wildcard patterns](</docs/en/permissions#wildcard-patterns>) shows the matching rules. The warning exists so you can narrow a rule whose wildcard is broader than you intended. Claude Code keeps the rule and changes nothing about how it matches; the warning names the rule and its source in parentheses:
+
+ Permission allow rule (.claude/settings.json): Bash(git -C * status *) has a wildcard before the rest of the command, so it also matches any options inserted at that position and approves them without a prompt. For git, options such as -c and --exec-path can run arbitrary commands. Replace that * with the exact value you mean, or only use * after the subcommand (for example Bash(git status *)).
+
+**What to do:**
+
+ * Replace the `*` before the subcommand with the exact value you mean: `Bash(git checkout main)` in place of `Bash(git * main)`.
+ * Move every `*` after the subcommand: `Bash(git status *)` in place of `Bash(git -C * status *)`. Write one rule per subcommand you want to allow.
+ * Fix the rule at the source the warning names in parentheses: a settings file path, or the `--allowed-tools` flag itself. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value. Fix the JSON you pass to that flag.
+ * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings, since you can’t clear it yourself.
+
+Claude Code doesn’t warn about deny and ask rules with the same shape: it refuses or prompts for the extra commands they match rather than approving them. It also doesn’t warn about rules whose subcommand comes before the first `*`, such as `Bash(git commit *)`, or rules in which no word other than an option follows the `*`, such as `Bash(git *)`, or about `:*` prefix rules such as `Bash(git:*)`. In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean. Run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.246, Claude Code accepted these rules without a warning.
+
+###
+
+
+
The 200K limit isn’t enforced
You set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>), which normally makes [auto-compaction](</docs/en/model-config#default-auto-compact-thresholds>) hold sessions on 1M-context models to a 200K window, but no compaction threshold caps this session at or below 200K, so the conversation can grow past it.
--- a/errors.md
+++ b/errors.md
@@ -26,7 +26,7 @@
`Auto mode classifier transcript exceeded context window`| Server errors
`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
`Agent terminated early due to an API error`| Server errors
-`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
+`You've hit your session limit` / `You've hit your weekly limit` / `You've hit your Opus limit` / `You've hit your Sonnet limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
`the prompt to confirm went unanswered — nothing was sent`| Usage limits
`Server is temporarily limiting requests`| Usage limits
@@ -201,6 +201,7 @@
* A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
* A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
+ * A request that your organization’s policy check denied, which surfaces as an `API Error:` line carrying the denial message. Your organization’s administrators set up the check with [Inference hooks](<https://platform.claude.com/docs/en/manage-claude/inference-hooks>), a Claude Enterprise feature, and the message ends with the instructions they configured, or by default tells you to contact them. Claude Code doesn’t re-send the denied request to the same model or to a [fallback model](</docs/en/model-config#fallback-model-chains>), because the denial is about the request’s content rather than the model. Before v2.1.239, Claude Code could re-send a denied request, without streaming or on a configured fallback model, before showing you the denial.
###
@@ -404,12 +405,13 @@
You've hit your session limit · resets 3:45pm
You've hit your weekly limit · resets Mon 12:00am
You've hit your Opus limit · resets 3:45pm
-
-Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus limit applies only to Opus requests, so switching to another model with `/model` keeps you working. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
+ You've hit your Sonnet limit · resets 3:45pm
+
+Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus and Sonnet limits each apply only to requests to that model family, so switching to a model outside the family with `/model` keeps you working. In an interactive session signed in with a claude.ai subscription, Claude Code can also wait in the open session and continue the interrupted task shortly after the reset. While it waits, a line at the bottom of the session reads `Usage limit reached · continuing automatically at 3:45pm · esc to cancel`. Press `Esc` at an empty prompt to cancel the wait. See [Wait for a usage limit to reset](</docs/en/interactive-mode#wait-for-a-usage-limit-to-reset>) for what you see, how to start or cancel a wait, and how to turn automatic continue off. Before v2.1.234, Claude Code didn’t offer this wait. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
* Wait for the reset time shown in the error
- * In the Code tab of the [Desktop app](</docs/en/desktop>), the session-limit card shows an **Auto-continue when limits reset** checkbox. The weekly-limit card doesn’t offer it. When it’s checked, the Desktop app retries the interrupted turn after the reset and shows the retry time on the card. Uncheck it to turn this off for your account.
- * For the Opus limit, run `/model` and switch to another model to keep working
+ * In the Code tab of the [Desktop app](</docs/en/desktop>), the session-limit card offers an **Auto-continue when limits reset** checkbox. The weekly-limit card doesn’t. When it’s checked, the Desktop app retries the interrupted turn after the reset and shows the retry time on the card. The Desktop checkbox and the CLI’s **Continue automatically at usage limit** setting in `/config` are separate, so turn each off on its own.
+ * For the Opus or Sonnet limit, run `/model` and switch to a model outside that family to keep working. Each model has its own prompt cache, so the next request re-reads the whole conversation with no cache hits; see [Switching models](</docs/en/prompt-caching#switching-models>)
* Run `/usage` to see your plan limits and when they reset
* Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
@@ -1095,7 +1097,7 @@
A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Claude Code does not trust it.
Unable to connect to API: SSL certificate verification failed. Check your proxy or corporate SSL certificates
- Unable to connect to API: Self-signed certificate detected
+ Unable to connect to API: Self-signed certificate detected. Check your proxy or corporate SSL certificates
As of v2.1.199, a certificate validation failure isn’t retried, so this error appears on the first attempt instead of after the full retry budget. Earlier versions spent a few minutes retrying before showing it. Transient TLS conditions, such as a handshake timeout, still retry. During `/login` and the startup connectivity check, the same failure is reported with the OpenSSL code and the fix inline:
--- a/errors.md
+++ b/errors.md
@@ -63,6 +63,7 @@
`Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
+`Issuer mismatch in authorization response (RFC 9207)`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
@@ -117,6 +118,7 @@
`--bg and --print conflict`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
+`The current directory no longer exists (it was deleted or moved)` / `Can't read the current directory`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
``claude import` is not yet available in this build`| Command-line errors
`Could not read Claude Code config`| Command-line errors
@@ -916,6 +918,24 @@
+Issuer mismatch in authorization response
+
+During an [MCP OAuth sign-in](</docs/en/mcp#authenticate-with-remote-mcp-servers>), the authorization server redirected back to Claude Code with an `iss` parameter that doesn’t name the issuer that Claude Code expected from the server’s OAuth metadata. A wrong issuer at this step is how an authorization server mix-up attack looks, so Claude Code fails the sign-in instead of exchanging the authorization code. Claude Code shows the error in the `/mcp` server menu after the browser sign-in:
+
+ Issuer mismatch in authorization response (RFC 9207): expected "https://auth.example.com", received "https://other.example.com"
+
+`expected` is the issuer from the server’s OAuth metadata, and `received` is the `iss` value the redirect carried. A sign-in whose redirect carries no `iss` parameter passes the check, unless the server’s metadata sets `authorization_response_iss_parameter_supported`, in which case Claude Code fails the sign-in. **What to do:**
+
+ * Try the sign-in again from `/mcp`
+ * If the error repeats, report it to the server operator. The fix is server-side: the authorization server must return the same issuer in the `iss` parameter that it advertises in its metadata
+ * To connect while the server is being fixed, start Claude Code with [`MCP_SDK_GENERATION=v1`](</docs/en/env-vars>), whose [runtime](</docs/en/mcp#mcp-client-runtimes>) doesn’t run this check. This removes a protection against mix-up attacks, so prefer the server-side fix
+
+Before v2.1.232, Claude Code used the v2 runtime only in a gradual rollout or when you set `MCP_SDK_GENERATION=v2`.
+
+###
+
+
+
AWS credentials expired or invalid
This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS session token expired or was rejected, and the automatic refresh Claude Code already ran didn’t produce a credential the API accepts. It appears on a 401 from [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), which is how those providers report an expired security token. The action hint in the middle names the `awsAuthRefresh` command from your settings, so it varies. The stable part is the leading `AWS credentials expired or invalid`:
@@ -1618,6 +1638,21 @@
+The current directory no longer exists
+
+You started `claude` from a directory that was deleted or moved after your shell entered it, for example a worktree or temp directory another shell removed. Claude Code can’t read its working directory, so it exits with code 1 before starting the session, in interactive and [non-interactive](</docs/en/headless>) mode alike. Before v2.1.239, Claude Code crashed with minified bundle source and a raw `ENOENT ... uv_cwd` stack on stderr instead of this message.
+
+ The current directory no longer exists (it was deleted or moved). Start Claude Code from an existing directory.
+
+When Claude Code can’t read the working directory for a different reason, such as a permissions change, the message names the error code instead: `Can't read the current directory (EACCES). Start Claude Code from a different directory.` **What to do:**
+
+ * Change to a directory that exists, such as your home or project directory, then run `claude` again
+ * If the directory was recreated at the same path, your shell still holds the deleted one. Run `cd "$PWD"` or leave and re-enter the directory, then run `claude` again
+
+###
+
+
+
Workspace not trusted when starting Remote Control
You started [Remote Control](</docs/en/remote-control>) server mode with `claude remote-control` or its `claude rc` alias in a directory you haven’t trusted. The command doesn’t show the workspace trust dialog itself, so it exits with code 1 and names the fix:
Show diff (248 lines)
--- a/errors.md
+++ b/errors.md
@@ -72,6 +72,7 @@
`Unable to connect to Anthropic services` during setup| Network
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
+`API returned an empty or malformed response`| Network
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
@@ -87,6 +88,10 @@
`Prompt is too long · automatic compaction failed:`| Request errors
`Context limit reached · /compact or /clear to continue`| Request errors
`Context limit reached · /clear to continue`| Request errors
+`capability_rejected: prompt_too_long` on a Claude apps gateway session| Request errors
+`upstream rejected the request` / `request too large for this upstream` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
+`upstream rate limit exceeded` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
+`all upstreams failed (N attempted)` on a Claude apps gateway session| [Upstream error messages](</docs/en/claude-apps-gateway-config#upstream-error-messages>)
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -123,6 +128,7 @@
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Error: Input contained only whitespace`| Command-line errors
`Blank prompt — the message was only whitespace, so nothing was sent to the model.`| Command-line errors
+`Unknown command: /<name>`, with or without a `Did you mean` suggestion| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
`Your checkout has no branches (detached HEAD only)`| Command-line errors
@@ -192,6 +198,7 @@
* A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
* A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
+ * A non-streaming retry of a failed streaming request that gets a success status but no Claude API message in the body. Claude Code ends the turn with that error.
###
@@ -212,7 +219,7 @@
Variable| Default| Effect
---|---|---
[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
-[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. As of v2.1.199 it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
+[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. Claude Code fails at once on a `429` that reports a spend limit or exhausted usage credits, even one from a gateway spend cap that resets on a schedule. Before v2.1.239, the watchdog retried these indefinitely. On v2.1.199 or later it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies.
##
@@ -435,11 +442,11 @@
Fable 5 limit reached · continuing on Fable 5 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
Fable 5 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
-This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings#available-settings>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, so answer before it passes. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
+This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, and a new prompt still closes the consent prompt, so answer before either happens. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
* At the terminal where the session runs, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
* Run `/model` to switch to a model that doesn’t bill usage credits
- * To give yourself more time to reach that terminal, set [`dialogExpiry`](</docs/en/settings#available-settings>) to a longer value or `"never"`
+ * To give yourself more time to reach that terminal, set [`dialogExpiry`](</docs/en/settings-reference#dialogexpiry>) to a longer value or `"never"`
Before v2.1.236, this message didn’t appear: while a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
@@ -546,7 +553,7 @@
* Run `/login` to authenticate with your Claude subscription or Console account
* If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
- * For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings#available-settings>) script that fetches a key at startup
+ * For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script that fetches a key at startup
* See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential Claude Code uses when several are present
If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
@@ -583,7 +590,7 @@
* Check for typos and confirm the key has not been revoked in the [Console](<https://platform.claude.com/settings/keys>)
* In the same shell, run `env | grep ANTHROPIC`, or in PowerShell `Get-ChildItem Env:ANTHROPIC*`. Tools like direnv, dotenv shell plugins, and IDE terminals can load a stale key from a `.env` file in your project without you setting it explicitly.
* Unset `ANTHROPIC_API_KEY` and run `/login` to use subscription auth instead
- * If the key comes from an [`apiKeyHelper`](</docs/en/settings#available-settings>) script, run the script directly to confirm it prints a valid key on stdout
+ * If the key comes from an [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script, run the script directly to confirm it prints a valid key on stdout
* Run `/status` to confirm which credential source Claude Code is actually using
###
@@ -592,7 +599,7 @@
Your apiKeyHelper script is failing
-Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings#available-settings>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. The `Authentication` panel in the terminal shows which of these happened:
+Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. The `Authentication` panel in the terminal shows which of these happened:
* The command exited with an error or timed out
* The command printed nothing to stdout
@@ -625,7 +632,7 @@
* `Invalid ANTHROPIC_CUSTOM_HEADERS`: a header name or value you set in [`ANTHROPIC_CUSTOM_HEADERS`](</docs/en/env-vars>). The description counts which `Name: Value` pair is at fault, such as `distinct header 2 of 3 parsed from ANTHROPIC_CUSTOM_HEADERS`, without repeating the name or value, since you chose both.
* `Invalid request header from the environment`: a value Claude Code copies into a request header from another environment variable, such as `CLAUDE_AGENT_SDK_CLIENT_APP`. The description names the variable to fix.
-Claude Code reports a bad `ANTHROPIC_API_KEY` caught by this check as Invalid API key, with the same trailing description. It reports a bad saved `/login` credential as Not logged in instead; run `/login` to save a fresh one. An [`apiKeyHelper`](</docs/en/settings#available-settings>) script’s output never reaches this check: Claude Code validates it when the script runs, and output an HTTP header can’t carry fails with Your apiKeyHelper script is failing. After the second `·`, the message describes the problem, as in this full example:
+Claude Code reports a bad `ANTHROPIC_API_KEY` caught by this check as Invalid API key, with the same trailing description. It reports a bad saved `/login` credential as Not logged in instead; run `/login` to save a fresh one. An [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) script’s output never reaches this check: Claude Code validates it when the script runs, and output an HTTP header can’t carry fails with Your apiKeyHelper script is failing. After the second `·`, the message describes the problem, as in this full example:
Invalid auth token · Fix external auth token · Invalid Authorization header value from ANTHROPIC_AUTH_TOKEN: it contains a line break at character 41 (120 characters on 2 lines).
@@ -670,7 +677,7 @@
Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone doesn’t help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
* If the message names `ANTHROPIC_API_KEY`, unset it in the current shell and remove it from your shell profile or `.env` file, then relaunch `claude`
- * If the message names `apiKeyHelper`, remove the [`apiKeyHelper`](</docs/en/settings#available-settings>) setting from your `settings.json`
+ * If the message names `apiKeyHelper`, remove the [`apiKeyHelper`](</docs/en/settings-reference#apikeyhelper>) setting from your `settings.json`
* Run `/login` to sign in with your claude.ai account
* Run `/status` afterward to confirm the active credential is your subscription rather than an API key
* If you need API key authentication for automation, ask your organization admin to re-enable it in the Console
@@ -725,7 +732,7 @@
**What to do:**
* Unset the variable the message names, such as `CLAUDE_CODE_USE_BEDROCK` or `ANTHROPIC_BASE_URL`, and restart the session, or start Remote Control from a session that talks to the Anthropic API directly
- * If the variable isn’t set in your shell, check the `env` key in your [settings files](</docs/en/settings#settings-files>), which applies environment variables to every session
+ * If the variable isn’t set in your shell, check the `env` key in your [settings files](</docs/en/settings#where-settings-live>), which applies environment variables to every session
* For this and the other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
###
@@ -1026,6 +1033,28 @@
+API returned an empty or malformed response
+
+Claude Code shows this error when its non-streaming retry of a failed streaming request gets an HTTP success status but the body isn’t a Claude API message: commonly an HTML error or sign-in page, an empty body, or JSON in another format. A proxy, gateway, or network sign-in page answering in the API’s place is the usual source. Claude Code doesn’t retry the request, and the turn ends with this error.
+
+ API returned an empty or malformed response (HTTP 200) — check for a proxy or gateway intercepting the request.
+
+After that opening, the message reports what came back and which request failed:
+
+ * A `Response:` clause with the content type, the kind of body, such as `body is an HTML page` or `empty body`, its size in bytes, and whether the response carried an Anthropic request id. When the response names a recognizable server, such as `nginx` or `cloudflare`, or carries intermediary headers, such as `cf-ray` or `via`, the clause lists those too.
+ * A sentence naming the failed streaming request’s id and the failure that triggered the retry. When a stream had opened before the failure, it also reports how many stream events arrived and, if any did, how long the stream had been silent when the attempt failed.
+
+Before v2.1.234, the message ended after `intercepting the request`. **What to do:**
+
+ * Read the `Response:` clause to see which system answered. An HTML body, no Anthropic request id, or a named server such as `nginx` or `cloudflare` means that something between Claude Code and the API replied in its place
+ * If you route through an [LLM gateway](</docs/en/llm-gateway-connect#troubleshoot-gateway-errors>), test the route with a direct request and fix the hop that returns the non-API response
+ * On a network with a sign-in page, such as guest Wi-Fi, complete the sign-in in a browser, then retry
+ * If only the non-streaming route through your gateway is broken, set [`CLAUDE_CODE_DISABLE_NONSTREAMING_FALLBACK=1`](</docs/en/env-vars#variables>) so a request that fails mid-stream goes to the normal retry path instead of this fallback, except when the streaming endpoint itself returns `404`, where Claude Code still falls back
+
+###
+
+
+
Bedrock streaming response has an unexpected content-type
A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`, and Claude Code rejects a successful streaming response that reports a different content-type instead of decoding a body it can’t read. The request isn’t retried.
@@ -1188,11 +1217,11 @@
Context limit reached · /compact or /clear to continue
-The line names only `/clear` when [`DISABLE_COMPACT`](</docs/en/env-vars>) is set. Longer forms of the error, such as the compaction-failed form below, keep the `Prompt is too long ·` wording. In `-p` output and the transcript, the text stays `Prompt is too long`. When you turned auto-compact off in your [user settings](</docs/en/settings#available-settings>), the line also says so:
+The line names only `/clear` when [`DISABLE_COMPACT`](</docs/en/env-vars>) is set. Longer forms of the error, such as the compaction-failed form below, keep the `Prompt is too long ·` wording. In `-p` output and the transcript, the text stays `Prompt is too long`. When you turned auto-compact off in your [user settings](</docs/en/settings-reference#autocompactenabled>), the line also says so:
Context limit reached · /compact or /clear to continue · auto-compact is off · /config to turn it on
-The **Auto-compact** toggle in `/config` writes `autoCompactEnabled` to user settings. The hint appears only when a `/config` change would take effect. For example, it doesn’t appear when [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>) or [`DISABLE_COMPACT`](</docs/en/env-vars>) turned auto-compact off. It also doesn’t appear when a higher-precedence scope, such as project or managed settings, set `autoCompactEnabled` to `false`. Nor does it appear in a terminal attached to a cloud session, where the cloud session owns auto-compact. Before v2.1.235, the line carried no auto-compact hint. Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
+The **Auto-compact** toggle in `/config` writes `autoCompactEnabled` to user settings. The hint appears only when a `/config` change would take effect. For example, it doesn’t appear when [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>) or [`DISABLE_COMPACT`](</docs/en/env-vars>) turned auto-compact off. It also doesn’t appear when a higher-precedence scope, such as project or managed settings, set `autoCompactEnabled` to `false`. Nor does it appear in a terminal attached to a cloud session, where the cloud session owns auto-compact. Before v2.1.235, the line carried no auto-compact hint. Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. A [Claude apps gateway](</docs/en/claude-apps-gateway-config#upstream-error-messages>) reports this condition as `capability_rejected: prompt_too_long` when a cloud upstream rejects the request in the provider’s own error shape. Claude Code treats the token the same as `Prompt is too long`. Before v2.1.228, Claude Code didn’t recognize the token, so auto-compact didn’t trigger on it. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
Prompt is too long · automatic compaction failed: <the underlying error>
@@ -1538,7 +1567,7 @@
Command-line errors
-These errors come from the `claude` command line, its subcommands, and commands such as `/security-review` that gather context by running shell commands before their prompt runs. So do errors from `/tui`, which relaunches the CLI.
+These errors come from the `claude` command line and its subcommands, from a command name you submit at the prompt, and from commands such as `/security-review` that gather context by running shell commands before their prompt runs. So do errors from `/tui`, which relaunches the CLI.
###
@@ -1623,7 +1652,7 @@
**What to do:**
* On a fresh installation, start `claude`, wait for the session to load, exit, and run `claude import` again
- * Where feature-flag fetching stays off, set the configuration up yourself: add MCP servers with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>), and create the [`CLAUDE.md` files](</docs/en/memory#how-claude-md-files-load>), [skills and commands](</docs/en/skills#where-skills-live>), and [subagents](</docs/en/sub-agents#choose-the-subagent-scope>) you want to carry over. The message also names `~/.claude/settings.json`. Of the configuration `claude import` carries, that file holds only the [permission mode](</docs/en/settings#permission-settings>); Claude Code doesn’t read MCP servers from it.
+ * Where feature-flag fetching stays off, set the configuration up yourself: add MCP servers with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>), and create the [`CLAUDE.md` files](</docs/en/memory#how-claude-md-files-load>), [skills and commands](</docs/en/skills#where-skills-live>), and [subagents](</docs/en/sub-agents#choose-the-subagent-scope>) you want to carry over. The message also names `~/.claude/settings.json`. Of the configuration `claude import` carries, that file holds only the [permission mode](</docs/en/settings-reference#permission-settings>); Claude Code doesn’t read MCP servers from it.
###
@@ -1729,6 +1758,27 @@
+Unknown command
+
+You submitted a `/` name that doesn’t match any command in this session, so Claude Code reports the name instead of running anything:
+
+ Unknown command: /hepl. Did you mean /help?
+
+Claude Code suggests the closest command name or alias that the menu lists in this session. When nothing is close, the message ends after the name. The cause is usually one of the following:
+
+ * A typo, such as `/hepl` for `/help`. [How the command menu matches what you type](</docs/en/commands#how-the-command-menu-matches-what-you-type>) covers picking a close match before you submit
+ * A command that exists but isn’t available in this session because a requirement isn’t met, such as your platform, plan, or authentication method. The troubleshooting entries for [`/web-setup`](</docs/en/web-quickstart#web-setup-shows-no-commands-match-or-unknown-command>) and [`/schedule`](</docs/en/routines#schedule-returns-unknown-command>) walk through two common cases
+ * A command from a [plugin](</docs/en/plugins>) or [MCP server](</docs/en/mcp#use-mcp-prompts-as-commands>) that isn’t installed or connected in this session
+
+Before v2.1.236, if you pressed `Enter` while the command menu listed a near match for the name you typed, Claude Code ran that match, so a typo such as `/hepl` ran `/help` instead of producing this message. **What to do:**
+
+ * Run the suggested name, or type `/` followed by part of the name to see what’s available in this session
+ * If Claude Code reports a documented command as unknown, check its row in the [commands reference](</docs/en/commands>) for the requirement it names
+
+###
+
+
+
Diff is too large for ultrareview
The diff between your branch and the base branch, including uncommitted and staged changes, exceeds the size limits for an [ultrareview](</docs/en/ultrareview>), so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts. A refused review doesn’t use a free run and doesn’t bill usage credits. The message names the limits in effect, the size of your diff, and the files that contribute the most changed lines. Before v2.1.216, the message showed only the raw diff statistics.
@@ -1837,7 +1887,7 @@
**What to do:**
- * In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings#available-settings>) there
+ * In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings-reference#tui>) there
##
@@ -1951,7 +2001,7 @@
When Claude Code refuses the Write tool, the message ends `and cannot be written` instead. **What to do:**
- * If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings#permission-settings>)
+ * If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings-reference#permission-settings>)
* If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path to block the NotebookEdit tool too
###
@@ -2376,7 +2426,7 @@
Is not matched by file permission checks
-Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#settings-files>), in [managed settings](</docs/en/permissions#managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else; the warning names the rule, its source in parentheses, and the replacement to write:
+Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#where-settings-live>), in [managed settings](</docs/en/managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else; the warning names the rule, its source in parentheses, and the replacement to write:
Permission deny rule (.claude/settings.json): Write(docs/**) is not matched by file permission checks — only Edit(path) rules are. Use Edit(docs/**) instead (Edit rules cover all file-editing tools).
@@ -2407,7 +2457,7 @@
**What to do:**
- * Set [`CLAUDE_CODE_AUTO_COMPACT_WINDOW=200000`](</docs/en/env-vars>), or the [`autoCompactWindow`](</docs/en/settings#available-settings>) setting to `200000`, so auto-compaction compacts at the 200K boundary
+ * Set [`CLAUDE_CODE_AUTO_COMPACT_WINDOW=200000`](</docs/en/env-vars>), or the [`autoCompactWindow`](</docs/en/settings-reference#autocompactwindow>) setting to `200000`, so auto-compaction compacts at the 200K boundary
* If the message names a model ID this version doesn’t recognize, run `claude update`. A version that recognizes the ID as a 1M-context model enforces the limit without further configuration.
* If you want the session to use the model’s full window instead, unset `CLAUDE_CODE_DISABLE_1M_CONTEXT`; the warning reports only that the 200K limit isn’t enforced
@@ -2435,7 +2485,7 @@
Claude Code writes the line once per model string per process. It writes a separate line for each further unrecognized ID, such as one that a [subagent](</docs/en/sub-agents#choose-a-model>) or [background functionality](</docs/en/costs#background-token-usage>) uses. Claude Code doesn’t write the line for provider IDs it resolves to a model it recognizes, such as Amazon Bedrock `us.anthropic.claude-...` IDs, Google Cloud’s Agent Platform IDs with an `@` version suffix, and Microsoft Foundry deployment names that contain a Claude model ID. Claude Code checks the model behind an Amazon Bedrock [application inference profile ARN](</docs/en/amazon-bedrock#map-each-model-version-to-an-inference-profile>) rather than the ARN itself. It writes no line for an ARN it can’t resolve, such as a mistyped one. **What to do:**
- * If you set the ID on purpose, such as an [LLM gateway](</docs/en/llm-gateway>) alias, add a [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry to your [settings file](</docs/en/settings#settings-files>) with the ID as its value. Use an Anthropic model ID as the key, not a family alias such as `opus`. For `my-proxy-model` from the example line, add this entry:
+ * If you set the ID on purpose, such as an [LLM gateway](</docs/en/llm-gateway>) alias, add a [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry to your [settings file](</docs/en/settings#where-settings-live>) with the ID as its value. Use an Anthropic model ID as the key, not a family alias such as `opus`. For `my-proxy-model` from the example line, add this entry:
{
"modelOverrides": {
Show diff (265 lines)
--- a/errors.md
+++ b/errors.md
@@ -8,7 +8,7 @@
Find your error
-Match the message you see in your terminal to a section below.
+Match the message you see to a section below.
Message| Section
---|---
@@ -28,6 +28,7 @@
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
+`the prompt to confirm went unanswered — nothing was sent`| Usage limits
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
@@ -50,7 +51,10 @@
`Claude.ai login expired`| Authentication
`Claude.ai login was rejected — run /login, then /remote-control`| Authentication
`OAuth token unavailable — run /login to restore Remote Control`| Authentication
+`Signed out of Claude — run /login, then /remote-control`| Authentication
`signed-in claude.ai account or organization changed on this machine`| Authentication
+`Remote Control stopped — the app running this session is now signed in to a different Claude account`| Authentication
+`Remote Control stopped — the app running this session is signed out of Claude`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
@@ -72,6 +76,7 @@
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
+`proxy refused the connection`| Network
`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
@@ -138,6 +143,9 @@
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Message too large for cross-session delivery`| Tool errors
+`Too many messages to this session just now`| Tool errors
+`Refusing to send: reply target is a symlink` / `Refusing to send: cannot vet reply target`| Tool errors
+`Refusing to send: connected endpoint is not the expected process` / `Refusing to send: connected endpoint identity could not be read`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -153,6 +161,7 @@
`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`headersHelper not run — this workspace has no persisted trust`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
`[claude-code:unrecognized_model]`| Configuration warnings
@@ -373,7 +382,7 @@
Usage limits
-Most errors in this section mean a quota tied to your account or plan has been reached. Two work differently: `Server is temporarily limiting requests` is a server-side throttle unrelated to your plan quota, and `Usage credits required for 1M context` is an entitlement check rather than an exhausted quota.
+Most errors in this section mean a quota tied to your account or plan has been reached. Three work differently: `Server is temporarily limiting requests` is a server-side throttle unrelated to your plan quota, `Usage credits required for 1M context` is an entitlement check rather than an exhausted quota, and `The prompt to confirm went unanswered` means a usage-credits consent prompt closed unanswered, whether or not a quota was reached.
###
@@ -419,6 +428,25 @@
+The prompt to confirm went unanswered
+
+On plans where Fable 5 usage [bills to usage credits](</docs/en/model-config#fable-5-and-usage-credits>), Claude Code asks you to confirm before a request bills them. When nobody answers that consent prompt in a session that may have no one at its terminal, Claude Code closes the prompt and ends the turn with one of these messages:
+
+ Fable 5 limit reached · continuing on Fable 5 uses usage credits, and the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
+ Fable 5 now uses usage credits · the prompt to confirm went unanswered — nothing was sent · answer it where this session is running, or /model to change
+
+This happens in [Remote Control](</docs/en/remote-control>) sessions, [background sessions](</docs/en/agent-view>), and [agent team](</docs/en/agent-teams>) teammate sessions. Claude Code shows the consent prompt only in the session’s own interactive view: the terminal where it runs, or, for a background session, the [agents view](</docs/en/agent-view>) once you attach. A Remote Control client can’t display it. Claude Code closes the prompt at the [`dialogExpiry`](</docs/en/settings#available-settings>) deadline, five minutes by default, or as soon as a new prompt arrives while nobody has typed at that terminal, such as a prompt sent from a Remote Control client. Typing at the terminal where the session runs cancels the deadline, and Claude Code waits for your answer. In a background session’s attached view, typing doesn’t cancel the deadline, so answer before it passes. Claude Code sends nothing and keeps your model, so when you send your next prompt, Claude Code shows the consent prompt again. **What to do:**
+
+ * At the terminal where the session runs, send another prompt and answer the consent prompt when it reappears. For a background session, attach to it from the [agents view](</docs/en/agent-view>) first. Resending from a Remote Control client shows this message again, because the client can’t display the prompt.
+ * Run `/model` to switch to a model that doesn’t bill usage credits
+ * To give yourself more time to reach that terminal, set [`dialogExpiry`](</docs/en/settings#available-settings>) to a longer value or `"never"`
+
+Before v2.1.236, this message didn’t appear: while a Remote Control client was connected, Claude Code waited 60 seconds for an answer and then continued the turn on your default model.
+
+###
+
+
+
Server is temporarily limiting requests
The API applied a short-lived throttle that is unrelated to your plan quota.
@@ -706,7 +734,7 @@
Remote Control couldn’t refresh your login
-Claude Code runs a live [Remote Control](</docs/en/remote-control>) connection on short-lived credentials that it obtains and renews using your saved claude.ai login. When Claude Code can’t produce a login token that claude.ai accepts, whether while connecting or mid-session, it stops Remote Control and shows the reason in a warning and a transcript line that starts with `Remote Control disconnected`. Your local session keeps running without Remote Control.
+Claude Code runs a live [Remote Control](</docs/en/remote-control>) connection on short-lived credentials that it obtains and renews using your saved claude.ai login. When claude.ai stops accepting that login, or Claude Code has no saved login left, Claude Code stops Remote Control and needs you to sign in again. Either failure can happen while Claude Code is still connecting or later, when it renews the credentials. When Claude Code asks the login service to refresh your saved login and gets no answer, it keeps Remote Control running and tries the refresh again while the connection’s current credential is still valid. A refresh gets no answer when Claude Code can’t reach the login service, the request times out, or the service fails without rejecting your login. If the login service still isn’t answering when that credential expires, Claude Code stops Remote Control and reports `OAuth token refresh failed`. When Claude Code stops Remote Control, it shows the reason in a warning and in a transcript line that starts with `Remote Control disconnected`. Your local session keeps running without Remote Control. This section covers these lines:
Remote Control disconnected — Claude.ai login expired — run /login to restore Remote Control
Remote Control disconnected — Claude.ai login expired — run /login, then /remote-control
@@ -714,20 +742,22 @@
Remote Control disconnected — OAuth token unavailable — run /login to restore Remote Control
Remote Control disconnected — OAuth token refresh failed — run /login to re-authenticate
Remote Control disconnected — JWT refresh failed: no OAuth token — run /login
-
-The middle of the message names what failed:
+ Remote Control disconnected — Signed out of Claude — run /login, then /remote-control
+
+Claude Code names the cause in the middle of the message:
* `Claude.ai login expired` and `Claude.ai login was rejected`: claude.ai no longer accepts your saved login token, because it expired or was revoked
* `OAuth token unavailable`: Claude Code had no saved login token when the connection’s credential came due for renewal
- * `OAuth token refresh failed`: Claude Code tried to refresh the saved login and the refresh failed, typically because the OAuth service rejected the stored refresh token
+ * `OAuth token refresh failed`: claude.ai rejected your saved login token while Claude Code was reconnecting, and refreshing the token produced no new one
* `JWT refresh failed: no OAuth token`: Claude Code found no saved login token to renew with
+ * `Signed out of Claude`: you signed out on this machine, for example by running `/logout` in another terminal, so Claude Code has no saved login left to renew the connection with
**What to do:**
* Run `/login` to sign in again
* Run `/remote-control` to reconnect the session. Messages ending `run /login to restore Remote Control` don’t need this step: Claude Code reconnects on its own once you sign in.
-Before v2.1.224, `OAuth token refresh failed — run /login to re-authenticate` read `OAuth token refresh failed — re-authenticate, then re-enable Remote Control`, and `JWT refresh failed: no OAuth token — run /login` read `no OAuth token available for recovery (code <N>)`. The `Claude.ai login expired`, `Claude.ai login was rejected`, and `OAuth token unavailable` messages were added in v2.1.225.
+Before v2.1.224, `OAuth token refresh failed — run /login to re-authenticate` read `OAuth token refresh failed — re-authenticate, then re-enable Remote Control`, and `JWT refresh failed: no OAuth token — run /login` read `no OAuth token available for recovery (code <N>)`. The `Claude.ai login expired`, `Claude.ai login was rejected`, and `OAuth token unavailable` messages were added in v2.1.225. Before v2.1.238, Claude Code reported the cases that now say `Signed out of Claude` as `JWT refresh failed: no OAuth token — run /login`, and stopped Remote Control with `Claude.ai login expired — run /login to restore Remote Control` as soon as one login refresh got no answer.
###
@@ -745,6 +775,24 @@
* To switch back, run `/login` and sign in to the previous account or organization again. Then run `/remote-control`.
Before v2.1.234, Claude Code didn’t notice when you switched to a different account or organization outside the Claude Code session. Claude Code kept the Remote Control session connected until a later request to the Remote Control server failed with `Remote Control server rejected the request (HTTP 404)`. That failure could come hours after the switch.
+
+###
+
+
+
+Remote Control stopped because the app running the session signed out or switched accounts
+
+When the Claude desktop app or an IDE hosts your session, Claude Code gets its login token from that app rather than from `/login`. When claude.ai rejects that token, Claude Code asks the app for a new one. If the app answers that it’s signed out, or that it’s now signed in to a different Claude account, Claude Code ends the [Remote Control](</docs/en/remote-control>) session and sends the app one of these lines:
+
+ Remote Control stopped — the app running this session is now signed in to a different Claude account
+ Remote Control stopped — the app running this session is signed out of Claude. Sign in there, then turn Remote Control back on
+
+Your local session keeps running without Remote Control. **What to do:**
+
+ * If the app is signed out, sign in to it again, then turn Remote Control back on in the app
+ * If the app switched accounts, Claude Code can’t continue the ended session under the new account. Start a new Remote Control session under that account.
+
+Before v2.1.238, Claude Code sent the app the `run /login` messages listed under Remote Control couldn’t refresh your login in both cases.
###
@@ -1033,6 +1081,32 @@
+The proxy refused the connection
+
+You see this message when Claude reads an [artifact](</docs/en/artifacts>) through the proxy you set in `HTTPS_PROXY` or a related [proxy variable](</docs/en/network-config#environment-variables>). Artifact content comes from `*.frame.claudeusercontent.com`, so Claude Code first sends the proxy a `CONNECT` request asking it to open a tunnel to that host. When the proxy refuses, nothing reaches the host, and the message carries the proxy’s HTTP status:
+
+ artifact content fetch failed (proxy refused the connection: HTTP 407)
+ artifact content fetch failed (proxy refused the connection: HTTP 403)
+ the proxy refused the connection to the artifact's content host (HTTP 502)
+
+The status is the proxy’s answer to the `CONNECT`. The host never answered, so each status points at a different fix:
+
+ * `HTTP 407`: the proxy requires credentials it didn’t get. Put them in the proxy URL, as [Basic authentication](</docs/en/network-config#basic-authentication>) shows.
+ * `HTTP 403`: the proxy refuses to tunnel to `*.frame.claudeusercontent.com`. Ask whoever runs the proxy to allow that host, which [Network access requirements](</docs/en/network-config#network-access-requirements>) lists.
+ * Any other status, such as `HTTP 502`: the proxy didn’t open the tunnel for its own reason, such as failing to reach the host. Look the status up in the proxy’s logs.
+ * `unreadable reply` in place of a status: whatever is at the proxy address didn’t answer with an HTTP status line. Check that the address is an HTTP proxy.
+
+**What to do:**
+
+ * Check the address and credentials in the proxy variable, as [Proxy configuration](</docs/en/network-config#proxy-configuration>) describes, then run `curl -x http://proxy.example.com:8080 -I https://api.anthropic.com` from the shell you start Claude Code in, using your own proxy URL. On Windows PowerShell, run `curl.exe`. If this probe fails the same way, fix the proxy setup first. If it succeeds, the refusal is specific to the artifact host.
+ * If your network lets Claude Code reach the artifact host directly, add `.claudeusercontent.com` to [`NO_PROXY`](</docs/en/network-config#environment-variables>).
+
+Before v2.1.238, Claude Code reported a refused tunnel as a generic network error.
+
+###
+
+
+
Couldn’t reconnect to your Remote Control session
Couldn't reconnect to your Remote Control session. Retry, or start a fresh session without --resume.
@@ -1763,7 +1837,7 @@
**What to do:**
- * In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings#available-settings>) there and uses it for every later session
+ * In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings#available-settings>) there
##
@@ -1968,6 +2042,47 @@
Before v2.1.235, Claude Code reported an oversized message as sent. The receiving session dropped it unread.
+###
+
+
+
+Too many messages to this session just now
+
+Claude sent a rapid burst of [cross-session messages](</docs/en/cross-session-messaging>) to one of your sessions on this machine, and the burst reached what that session’s inbox accepts. Claude Code refused the next send, and the receiving session got nothing from it. The refusal appears in the sending session’s tool result, not as a banner in your terminal:
+
+ Failed to send to api-worker: Too many messages to this session just now: 30 were sent recently and more would be dropped by its rate limit, so this one was not sent. Batch what remains into one message, or wait a little before sending more.
+
+**What to do:**
+
+ * Usually nothing: Claude batches the remaining content into one message, or waits before sending more
+ * If you prompted the burst yourself, ask Claude to combine what’s left into a single message
+
+Before v2.1.236, Claude Code reported these sends as sent. The receiving session dropped them unread.
+
+###
+
+
+
+Refusing to send a cross-session message
+
+Before Claude Code writes a [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine, it checks that the target session’s inbox socket is the endpoint the message was addressed to. When a check fails, Claude Code refuses the send in the sending session, and the target session receives nothing. For a message Claude sends, the refusal appears in the sending session’s tool result:
+
+ Failed to send to api-worker: Refusing to send: reply target is a symlink
+
+The text after `Refusing to send:` names the check that failed:
+
+ * `reply target is a symlink`: a symbolic link sits at the target session’s socket path. Claude Code doesn’t deliver through it, because a link there could redirect the message to an endpoint the target session didn’t create.
+ * `cannot vet reply target`: Claude Code couldn’t inspect the target path at all, for example because reading it failed with a permission error.
+ * `connected endpoint is not the expected process`: the process holding the socket isn’t the session the message was addressed to, so the address is stale or another process replaced the socket.
+ * `connected endpoint identity could not be read`: Claude Code connected but couldn’t read which process holds the other end, so it couldn’t confirm the target. This can be transient.
+
+**What to do:**
+
+ * Usually nothing: the checks keep a message from reaching an endpoint other than the session it was addressed to, and nothing was sent
+ * Ask Claude to list your sessions again and resend; a refusal caused by a stale address clears once Claude sends to the current one
+ * If `reply target is a symlink` repeats for one session, check what created a link at that session’s socket path, shown in its `/status` under `Peer address`
+ * For `connected endpoint identity could not be read`, resend; the condition can be transient
+
##
@@ -2238,6 +2353,22 @@
* Run `claude` in the directory and accept the trust dialog. [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>) says which folder that acceptance covers.
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
* If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
+
+###
+
+
+
+headersHelper not run
+
+Claude Code connected an MCP server with its static `headers` alone and skipped the server’s [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>), because the helper is a shell command and the folder has no saved trust. A folder gets saved trust when you set its entry in `~/.claude.json` by hand or, outside your home directory, when you accept the trust dialog for it in an interactive session. See [Trust a folder before its headersHelper runs](</docs/en/mcp#trust-a-folder-before-its-headershelper-runs>) for which servers this check applies to. Claude Code writes this line in [non-interactive mode](</docs/en/headless>) only, once per server. In an interactive session it writes the same refusal to the debug log instead.
+
+ MCP server 'internal-api': headersHelper not run — this workspace has no persisted trust; accept the trust dialog here once interactively, or set projects["/Users/you/project"].hasTrustDialogAccepted in /Users/you/.claude.json.
+
+The `projects` key the message prints is the folder [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>) says Claude Code keys the trust on. Accepting the trust dialog for a parent folder doesn’t satisfy the check, and a `-p` or SDK session doesn’t satisfy it either. **What to do:**
+
+ * Run `claude` in the folder the message names, accept the trust dialog, then run your `-p` or SDK command again
+ * Set the `hasTrustDialogAccepted` entry in `~/.claude.json` yourself, using the exact `projects` key the message prints
+ * If you started the session in your home directory, work from a project directory you have trusted. When you accept the trust dialog in your home directory, Claude Code holds that trust for the current session only.
###
--- a/errors.md
+++ b/errors.md
@@ -412,7 +412,7 @@
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
* Run `/usage-credits` to turn on metered billing for the 1M variant on Pro and Max, or to request it from your admin on Team and Enterprise
- * If the error persists after `/model`, a 1M model ID may be set elsewhere. See There’s an issue with the selected model for the configuration locations to check in priority order.
+ * If the error persists after `/model`, a 1M model ID may be set elsewhere. See [Setting your model](</docs/en/model-config#setting-your-model>) for the configuration locations to check in priority order.
* To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
###
@@ -1276,7 +1276,7 @@
* **Non-interactive mode (`-p`)**: pass `--model` with a valid alias or ID, or set [`ANTHROPIC_MODEL`](</docs/en/env-vars>). The error text shows `Run --model` on this surface.
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
- * If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
+ * If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check the places you can set a model in [priority order](</docs/en/model-config#setting-your-model>) and remove the stale value.
* A newly launched model can be available on the Anthropic API before Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry offers it. If you pinned a new model ID on one of those providers and see this error, check your provider’s model catalog for availability in your region, and keep the previous version pinned until the new one appears there.
* Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
@@ -1295,7 +1295,7 @@
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
* If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this check even when the model is newer than your Claude Code version, so upgrading isn’t needed for those.
- * A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under There’s an issue with the selected model.
+ * A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under [Setting your model](</docs/en/model-config#setting-your-model>).
* The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
###
@@ -2314,7 +2314,7 @@
Claude Code then treats `my-proxy-model` as `claude-opus-4-6` and stops writing the line.
* If the ID names a model newer than your Claude Code version, run `claude update`
- * If the ID is a typo, fix it where you set it: the `--model` flag, the `ANTHROPIC_MODEL` or `ANTHROPIC_DEFAULT_*_MODEL` environment variables, or the `model` setting. If `query_source` starts with `agent:`, fix it where you set the [subagent’s model](</docs/en/sub-agents#choose-a-model>) instead.
+ * If the ID is a typo, fix it in whichever of the [places you can set a model](</docs/en/model-config#setting-your-model>) or [alias variables](</docs/en/model-config#environment-variables>) holds it. If `query_source` starts with `agent:`, fix it where you set the [subagent’s model](</docs/en/sub-agents#choose-a-model>) instead.
Before v2.1.233, Claude Code wrote no line when it sent a request for a model ID it didn’t recognize.
Show diff (151 lines)
--- a/errors.md
+++ b/errors.md
@@ -76,8 +76,12 @@
`Couldn't reconnect to your Remote Control session`| Network
`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
+`Couldn't show context usage: the remote sent a reply this version can't display`| Network
+`The remote session sent a reply this version can't display`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
+`Context limit reached · /compact or /clear to continue`| Request errors
+`Context limit reached · /clear to continue`| Request errors
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -128,10 +132,12 @@
`Plugin archive integrity check failed`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
+`subagent_type is required: the general-purpose agent is not available in this session`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`pkill: refusing to run`| Tool errors
`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
+`Message too large for cross-session delivery`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
@@ -1058,6 +1064,23 @@
+The remote sent a reply this version can’t display
+
+`/context` shows this line in a terminal [attached to a cloud session](</docs/en/claude-code-on-the-web#send-follow-ups-from-the-cli>):
+
+ Couldn't show context usage: the remote sent a reply this version can't display
+
+While your terminal is attached, `/context` and `/btw` ask the cloud session for their answer. Sometimes the answer arrives in a form your terminal’s Claude Code can’t render. The usual cause is a version difference between the two. `/context` then shows the line above instead of the usage breakdown. `/btw` shows `The remote session sent a reply this version can't display` instead of its answer. The cloud session keeps running, and other commands still work. **What to do:**
+
+ * Update Claude Code with `claude update`, reattach, and rerun the command
+ * If the line still appears, run `/feedback` and name the command
+
+Before v2.1.235, this case showed a raw JavaScript error instead, such as `undefined is not an object`.
+
+###
+
+
+
Couldn’t share the transcript
After you agree to share your session transcript from a survey prompt, such as the [session quality survey](</docs/en/data-usage#session-quality-surveys>), Claude Code uploads it to Anthropic, or saves a local archive instead on third-party providers, on [Claude apps gateway](</docs/en/claude-apps-gateway>) sessions, and when no Anthropic credentials are available. This message means the share didn’t complete.
@@ -1087,18 +1110,26 @@
Prompt is too long
-Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
+In an interactive session, Claude Code shows this error as:
+
+ Context limit reached · /compact or /clear to continue
+
+The line names only `/clear` when [`DISABLE_COMPACT`](</docs/en/env-vars>) is set. Longer forms of the error, such as the compaction-failed form below, keep the `Prompt is too long ·` wording. In `-p` output and the transcript, the text stays `Prompt is too long`. When you turned auto-compact off in your [user settings](</docs/en/settings#available-settings>), the line also says so:
+
+ Context limit reached · /compact or /clear to continue · auto-compact is off · /config to turn it on
+
+The **Auto-compact** toggle in `/config` writes `autoCompactEnabled` to user settings. The hint appears only when a `/config` change would take effect. For example, it doesn’t appear when [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>) or [`DISABLE_COMPACT`](</docs/en/env-vars>) turned auto-compact off. It also doesn’t appear when a higher-precedence scope, such as project or managed settings, set `autoCompactEnabled` to `false`. Nor does it appear in a terminal attached to a cloud session, where the cloud session owns auto-compact. Before v2.1.235, the line carried no auto-compact hint. Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
Prompt is too long · automatic compaction failed: <the underlying error>
-Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced the bare `Prompt is too long` without the cause. **What to do:**
+Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced `Prompt is too long` without the cause. **What to do:**
* Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
* Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Subagents inherit every MCP tool definition from the parent session, which can fill their context window before the first turn. Disable MCP servers you are not using before spawning subagents.
- * Auto-compact is on by default and normally prevents this error. If you have set [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), re-enable it or run `/compact` manually before the window fills.
+ * Auto-compact is on by default and normally prevents this error. If you turned it off in `/config` or with [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), turn it back on. If you keep it off, run `/compact` yourself before the window fills.
See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
@@ -1108,7 +1139,7 @@
Context exceeds the token limit
-`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window. Requests fail with `Prompt is too long` until you free space.
+`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window. Requests fail with `Prompt is too long` until you free space. An interactive session shows that error as the `Context limit reached` line.
Context exceeds the 200k-token limit by 94k tokens — run /compact or /clear to continue.
@@ -1133,7 +1164,7 @@
Error during compaction: Conversation too long. Press esc twice to go up a few messages and try again.
-This can happen when the window is already full at the moment auto-compact triggers, or when you run `/compact` after seeing `Prompt is too long`. **What to do:**
+This can happen when the window is already full at the moment auto-compact triggers, or when you run `/compact` after seeing `Prompt is too long`. In an interactive session, that error is the `Context limit reached` line. **What to do:**
* Press Esc twice to open the message list and step back several turns. This drops the most recent messages from context. Then run `/compact` again.
* If stepping back doesn’t free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
@@ -1853,6 +1884,26 @@
+subagent_type is required
+
+ subagent_type is required: the general-purpose agent is not available in this session. Available agents: ...
+
+Claude called the [Agent tool](</docs/en/tools-reference#agent-tool-behavior>) without a `subagent_type`, and this session has no [general-purpose subagent](</docs/en/sub-agents#built-in-subagents>) to fall back on. That is the case in two setups:
+
+ * [`CLAUDE_AGENT_SDK_DISABLE_BUILTIN_AGENTS=1`](</docs/en/env-vars>) is set in non-interactive mode, which removes every built-in subagent
+ * The session’s main-thread agent has a [`tools: Agent(...)` allowlist](</docs/en/sub-agents#restrict-which-subagents-can-be-spawned>) that leaves out `general-purpose`
+
+**What to do:**
+
+ * Usually nothing: the message lists the subagents the session does have, so Claude can retry with one of them
+ * If Claude keeps failing, add `general-purpose` to the `tools: Agent(...)` allowlist, or unset `CLAUDE_AGENT_SDK_DISABLE_BUILTIN_AGENTS`
+
+Before v2.1.235, the same call failed with `Agent type 'general-purpose' not found`.
+
+###
+
+
+
Memory index is over its read limit
Claude wrote to the [auto memory](</docs/en/memory#auto-memory>) index `MEMORY.md` and left it over one of its read limits: 200 lines or 25KB. The write succeeded, but only the first 200 lines or 25KB, whichever comes first, load at the start of a session, so everything past the limit is dropped each time the index is read. Before v2.1.210, an over-limit index was silently truncated on the next load with no write-time signal.
@@ -1899,6 +1950,23 @@
* Ask the sender to resend the message; contention for the inbox lock is transient and clears on retry
* Check free disk space, and check that `~/.claude/teams` and the files under it are writable by your user
+
+###
+
+
+
+Message too large for cross-session delivery
+
+Claude’s [cross-session message](</docs/en/cross-session-messaging>) to another of your sessions on this machine was too long to send. Claude Code refused it, and the receiving session got nothing. The refusal appears in the sending session’s tool result, not as a banner in your terminal. It names both sizes and how to make the message fit:
+
+ Failed to send to api-worker: Message too large for cross-session delivery: the serialized message is 1,203,844 characters and the limit is 1,048,576. Shorten the message text — put bulk content in a file the recipient can read rather than in the message — or split it into smaller messages.
+
+Resending the same text fails the same way. **What to do:**
+
+ * Ask Claude to summarize the message, or to put the bulk content in a file and send the file’s path
+ * Ask Claude to split the content across several shorter messages
+
+Before v2.1.235, Claude Code reported an oversized message as sent. The receiving session dropped it unread.
##
Show diff (177 lines)
--- a/errors.md
+++ b/errors.md
@@ -50,11 +50,13 @@
`Claude.ai login expired`| Authentication
`Claude.ai login was rejected — run /login, then /remote-control`| Authentication
`OAuth token unavailable — run /login to restore Remote Control`| Authentication
+`signed-in claude.ai account or organization changed on this machine`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
+`Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
`AWS credentials expired or invalid`| Authentication
@@ -72,6 +74,7 @@
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`Couldn't reconnect to your Remote Control session`| Network
+`N sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.`| Network
`Couldn't share the transcript.`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
`Prompt is too long · automatic compaction failed:`| Request errors
@@ -116,6 +119,8 @@
`Your checkout has no branches (detached HEAD only)`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`No conversation found with session ID: <session-id>`| Command-line errors
+`Cannot switch renderers in this session`| Command-line errors
+`Cannot switch renderers while work is running in the background`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -379,6 +384,7 @@
Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus limit applies only to Opus requests, so switching to another model with `/model` keeps you working. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
* Wait for the reset time shown in the error
+ * In the Code tab of the [Desktop app](</docs/en/desktop>), the session-limit card shows an **Auto-continue when limits reset** checkbox. The weekly-limit card doesn’t offer it. When it’s checked, the Desktop app retries the interrupted turn after the reset and shows the retry time on the card. Uncheck it to turn this off for your account.
* For the Opus limit, run `/model` and switch to another model to keep working
* Run `/usage` to see your plan limits and when they reset
* Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
@@ -458,14 +464,14 @@
Credit balance is too low
-Your Console organization has run out of prepaid credits.
+Your Console organization has run out of prepaid credits, or Claude Code is sending your requests with a Console API key when you meant to use your subscription.
Credit balance is too low
**What to do:**
+ * If you have a Pro, Max, Team, or Enterprise plan and see this, run `/status` and check the `API key` row. An approved `ANTHROPIC_API_KEY` in your environment routes requests through that key instead of your subscription. Unset it in the current shell and remove it from your shell profile, then relaunch `claude`. Run `/login` if you haven’t signed in with your subscription yet.
* Add credits at [platform.claude.com/settings/billing](<https://platform.claude.com/settings/billing>), and consider enabling auto-reload there so the balance refills before it hits zero
- * Switch to subscription authentication with `/login` if you have a Pro, Max, Team, or Enterprise plan
* Set per-workspace spend caps in the Console to prevent a single project from draining the org balance. See [Manage costs effectively](</docs/en/costs>).
###
@@ -721,6 +727,23 @@
+Remote Control stopped because the signed-in account changed
+
+Claude Code shows this line during a [Remote Control](</docs/en/remote-control>) session when you sign in to a different claude.ai account or organization on this machine. You made the switch outside the Claude Code session, for example by running `/login` in another terminal. A Remote Control session that you started while signed in through `/login` belongs to the claude.ai account and organization that were signed in at the time.
+
+ Remote Control disconnected — signed-in claude.ai account or organization changed on this machine — run /remote-control to start a session for the current account, or /login to switch back, then /remote-control
+
+Claude Code stops the Remote Control session as soon as claude.ai confirms that the account or organization changed. Your local session keeps running without Remote Control. **What to do:**
+
+ * Run `/remote-control` to start a new Remote Control session under the current account or organization
+ * To switch back, run `/login` and sign in to the previous account or organization again. Then run `/remote-control`.
+
+Before v2.1.234, Claude Code didn’t notice when you switched to a different account or organization outside the Claude Code session. Claude Code kept the Remote Control session connected until a later request to the Remote Control server failed with `Remote Control server rejected the request (HTTP 404)`. That failure could come hours after the switch.
+
+###
+
+
+
OAuth token revoked or expired
Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
@@ -780,14 +803,15 @@
Anthropic profile login expired
-Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying, because only re-authenticating the profile produces a working credential.
+Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying, because a retry would read the same expired credential.
Anthropic profile login expired · Re-authenticate your Anthropic profile
-
-This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable or that Claude Code discovers as the active profile in your Anthropic configuration directory. Sessions that authenticate with `/login`, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. Running `/login` doesn’t renew the profile credential. Whether a working login can take over instead depends on how the profile was selected:
-
- * When you set `ANTHROPIC_PROFILE` explicitly, the profile keeps precedence over a saved login, so signing in doesn’t stop the error.
- * When Claude Code discovered the profile from your configuration directory, a working `/login` takes precedence over it, and Claude Code authenticates with your claude.ai or Console account instead.
+ Anthropic profile login expired · Run /login to use your claude.ai account instead, or re-authenticate the profile
+
+This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable or that Claude Code discovers as the active profile in your Anthropic configuration directory. Sessions that authenticate with `/login`, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. Running `/login` doesn’t renew the profile credential. Which form you see depends on whether you selected the profile or Claude Code discovered it, and tells you whether a working login can take over instead:
+
+ * When you set `ANTHROPIC_PROFILE` explicitly, the message ends with `Re-authenticate your Anthropic profile`. Claude Code gives the profile precedence over a saved login, so signing in doesn’t stop the error.
+ * When Claude Code discovered the profile from your configuration directory, the message offers `/login`, because Claude Code gives a working `/login` precedence over the discovered profile and then authenticates with your claude.ai or Console account instead. Before v2.1.234, Claude Code showed the `Re-authenticate your Anthropic profile` form in this case too.
**What to do:**
@@ -1019,6 +1043,21 @@
+Sessions ended while this machine was offline
+
+Claude Code shows this message in the terminal running [`claude remote-control`](</docs/en/remote-control#start-a-remote-control-session>) after your machine was offline long enough that the server cleaned up the Remote Control environment your machine was serving. The sessions in that environment ended, and you can’t resume them. The count is the number of sessions that ended.
+
+ 2 sessions ended while this machine was offline — the environment was cleaned up on the server and can't be resumed.
+
+**What to do:**
+
+ * When Claude Code lists kept worktrees under this message, pick up any uncommitted work from them
+ * Run `claude remote-control` to start a fresh environment
+
+###
+
+
+
Couldn’t share the transcript
After you agree to share your session transcript from a survey prompt, such as the [session quality survey](</docs/en/data-usage#session-quality-surveys>), Claude Code uploads it to Anthropic, or saves a local archive instead on third-party providers, on [Claude apps gateway](</docs/en/claude-apps-gateway>) sessions, and when no Anthropic credentials are available. This message means the share didn’t complete.
@@ -1394,7 +1433,7 @@
Command-line errors
-These errors come from the `claude` command line, its subcommands, and commands such as `/security-review` that gather context by running shell commands before their prompt runs.
+These errors come from the `claude` command line, its subcommands, and commands such as `/security-review` that gather context by running shell commands before their prompt runs. So do errors from `/tui`, which relaunches the CLI.
###
@@ -1668,6 +1707,32 @@
* For an interactive session, open the [session picker](</docs/en/sessions#use-the-session-picker>) with `claude --resume` and press `Ctrl+A` to widen it to every project on this machine, then select the session
* Sessions created with `claude -p` or the [Agent SDK](</docs/en/agent-sdk/overview>) don’t appear in the picker, so re-check the ID against the `session_id` your original run printed
+
+###
+
+
+
+Cannot switch renderers in this session
+
+When you switch renderers, Claude Code restarts its process. You ran [`/tui`](</docs/en/fullscreen#enable-fullscreen-rendering>) in a session Claude Code declines to restart, so it doesn’t switch and saves nothing. Which message you see tells you the cause:
+
+ * `Cannot switch renderers while work is running in the background`: you have background work running that a restart would abandon, such as a background shell or a subagent. Wait for the work to finish or stop it with [`/tasks`](</docs/en/commands>), then run `/tui fullscreen` or `/tui default` again
+ * `Cannot switch renderers in this session`: the session has restrictions Claude Code can’t pass to the restarted process. Before v2.1.234, Claude Code restarted anyway and the relaunched session ran without them
+
+In the restrictions message, the part in parentheses names the restrictions Claude Code found:
+
+ Cannot switch renderers in this session — it has restrictions a restart can't carry over (permission rules set for this session only). Nothing was changed. Running /tui fullscreen in a session started without them switches every later session too.
+
+Each reason the message can show in parentheses:
+
+ * `launch flags: a custom system prompt, a tool allowlist, or restricted settings`: you started the session with a flag Claude Code doesn’t pass back to the restarted process. These flags include [`--system-prompt`](</docs/en/cli-reference#cli-flags>), `--system-prompt-file`, `--append-system-prompt-file`, a [`--tools`](</docs/en/cli-reference#cli-flags>) allowlist, [`--setting-sources`](</docs/en/cli-reference#cli-flags>), and [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>)
+ * `permission rules set for this session only`: a [permission update](</docs/en/hooks#permission-update-entries>) from a hook or SDK caller added deny or ask rules with the `session` destination. Session-scoped allow rules don’t trigger the refusal. A restart drops them, and Claude Code prompts again instead
+ * `ask-before-running rules with no command-line form`: a permission update from a hook or SDK caller added ask rules alongside the rules Claude Code passes back as `--allowed-tools` and `--disallowed-tools`. No flag exists for ask rules
+ * `permission rules a command line cannot carry intact` and `added directories a command line cannot carry intact`: a permission update added a rule or directory path mid-session. The restarted process’s command line can’t carry its text as the same value
+
+**What to do:**
+
+ * In a session started without those restrictions, run `/tui fullscreen`, or `/tui default` to switch back. Claude Code saves the [`tui` setting](</docs/en/settings#available-settings>) there and uses it for every later session
##
@@ -2102,7 +2167,7 @@
**What to do:**
- * Run `claude` in the directory and accept the trust dialog. The dialog appears even when a parent directory is already trusted, lists the rules being held back, and lets you decline and keep working without them. Before v2.1.200, no dialog appeared in that situation, so this step couldn’t be completed there.
+ * Run `claude` in the directory and accept the trust dialog. [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>) says which folder that acceptance covers.
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
* If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
--- a/errors.md
+++ b/errors.md
@@ -144,6 +144,7 @@
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
+`[claude-code:unrecognized_model]`| Configuration warnings
Responses seem lower quality than usual| Response quality
##
@@ -1225,7 +1226,7 @@
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
* If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this check even when the model is newer than your Claude Code version, so upgrading isn’t needed for those.
* A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under There’s an issue with the selected model.
- * The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through.
+ * The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through. Claude Code can still write the unrecognized-model diagnostic line at request time, on every provider.
###
@@ -1764,7 +1765,7 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
- * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP` or `TaskCreate`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
+ * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
@@ -2087,7 +2088,7 @@
Configuration warnings
-Claude Code writes these messages to stderr at startup rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. They report configuration it read but didn’t apply.
+Claude Code writes these messages to stderr rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. It writes most of them at startup, reporting configuration it read but didn’t apply, and writes the unrecognized-model diagnostic line at request time.
###
@@ -2148,6 +2149,42 @@
In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr.
+###
+
+
+
+Unrecognized model ID on a request
+
+Claude Code sent a request for a model ID that your Claude Code version doesn’t recognize, and found no [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry that maps that ID to a model it does recognize. Claude Code still sends the request with the ID as you configured it, and doesn’t exit or switch models.
+
+ [claude-code:unrecognized_model] {"model":"my-proxy-model","query_source":"sdk"}
+
+In a script or harness that reads stderr, match on the `[claude-code:unrecognized_model]` prefix. After the prefix and one space, Claude Code writes a one-line JSON object. Claude Code can add fields to it in a later version, so ignore any field you don’t expect. It writes at least these two:
+
+ * `model`: the model string as you configured it
+ * `query_source`: the request path that used the model. Claude Code reports `sdk` for a `-p` run and a value that starts with `agent:` for a subagent.
+
+Claude Code writes the line to one of two places, depending on how you run it:
+
+ * In [non-interactive mode](</docs/en/headless>) with `-p`, Claude Code writes it to stderr under every `--output-format`, so you can parse stdout without filtering the line out
+ * In an interactive session or a [background session](</docs/en/agent-view>), Claude Code writes it to the debug log instead; run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`
+
+Claude Code writes the line once per model string per process. It writes a separate line for each further unrecognized ID, such as one that a [subagent](</docs/en/sub-agents#choose-a-model>) or [background functionality](</docs/en/costs#background-token-usage>) uses. Claude Code doesn’t write the line for provider IDs it resolves to a model it recognizes, such as Amazon Bedrock `us.anthropic.claude-...` IDs, Google Cloud’s Agent Platform IDs with an `@` version suffix, and Microsoft Foundry deployment names that contain a Claude model ID. Claude Code checks the model behind an Amazon Bedrock [application inference profile ARN](</docs/en/amazon-bedrock#map-each-model-version-to-an-inference-profile>) rather than the ARN itself. It writes no line for an ARN it can’t resolve, such as a mistyped one. **What to do:**
+
+ * If you set the ID on purpose, such as an [LLM gateway](</docs/en/llm-gateway>) alias, add a [`modelOverrides`](</docs/en/model-config#override-model-ids-per-version>) entry to your [settings file](</docs/en/settings#settings-files>) with the ID as its value. Use an Anthropic model ID as the key, not a family alias such as `opus`. For `my-proxy-model` from the example line, add this entry:
+
+ {
+ "modelOverrides": {
+ "claude-opus-4-6": "my-proxy-model"
+ }
+ }
+
+Claude Code then treats `my-proxy-model` as `claude-opus-4-6` and stops writing the line.
+ * If the ID names a model newer than your Claude Code version, run `claude update`
+ * If the ID is a typo, fix it where you set it: the `--model` flag, the `ANTHROPIC_MODEL` or `ANTHROPIC_DEFAULT_*_MODEL` environment variables, or the `model` setting. If `query_source` starts with `agent:`, fix it where you set the [subagent’s model](</docs/en/sub-agents#choose-a-model>) instead.
+
+Before v2.1.233, Claude Code wrote no line when it sent a request for a model ID it didn’t recognize.
+
##
--- a/errors.md
+++ b/errors.md
@@ -938,14 +938,7 @@
Socket is closed
-`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Depending on how far the response had progressed, Claude Code retries the request, keeps what Claude produced, or ends the turn:
-
- * If Claude hasn’t completed any part of the response yet, including its thinking, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues, even if some text had started streaming.
- * If Claude has finished thinking but hasn’t started any text or tool call, Claude Code re-issues the request up to two times in quick succession, then ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point. Before v2.1.227, that message read `Connection closed while thinking, before producing a response`.
- * If Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but hasn’t finished the response, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
- * If the socket closes after Claude has finished the response, Claude Code ends the turn normally with the complete response.
-
-Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
+`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Depending on how far the response had progressed, Claude Code retries the request, keeps what Claude produced, or ends the turn. See Automatic retries. Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
* If you see this error, update to v2.1.214 or later with `claude update`, then send your message again
* If turns keep failing behind the same proxy after updating, work through Unable to connect to API and check the proxy setup in [Network configuration](</docs/en/network-config>)
@@ -1019,7 +1012,7 @@
* Start a new session with `claude --remote-control` to create a new Remote Control session
* For other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
-When the server reports instead that the previous session no longer exists, Claude Code shows [`Remote Control could not resume the previous session under the current login`](</docs/en/remote-control#remote-control-could-not-resume-the-previous-session-under-the-current-login>) rather than this message and doesn’t create a replacement session. Earlier versions created a new Remote Control session instead of showing a message: before v2.1.200 on any reconnection failure, and through v2.1.226 when the server reported the session gone.
+If the server reports instead that the previous session is gone, you don’t see this message. Claude Code starts a new session in its place or shows [`Previous session is unavailable — run /remote-control to start a new one`](</docs/en/remote-control#previous-session-is-unavailable>), depending on [the conversation’s reconnection record](</docs/en/remote-control#resume-outcomes>). From v2.1.227 through v2.1.231, Claude Code showed a message that starts with `Remote Control could not resume the previous session under the current login` instead, and [earlier versions behaved differently again](</docs/en/remote-control#reconnect-history>).
###
@@ -1548,7 +1541,7 @@
The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>). A failed injected command aborts that skill’s invocation. Two sibling strings fire before the command runs at all:
- * `Shell command permission check failed for pattern "..."`: the command’s permission check returned something other than allow. Injected commands never prompt, so the invocation aborts without asking you. Pre-approve commands that would otherwise hit the default permission prompt with [`allowed-tools`](</docs/en/skills#pre-approve-tools-for-a-skill>). A matching ask or deny rule still aborts the invocation regardless of `allowed-tools`
+ * `Shell command permission check failed for pattern "..."`: the command’s permission check returned something other than allow. Injected commands never prompt, so the invocation aborts without asking you. Pre-approve commands that no rule matches with [`allowed-tools`](</docs/en/skills#pre-approve-tools-for-a-skill>). A matching ask or deny rule still aborts the invocation regardless of `allowed-tools`
* `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
**What to do:**
Show diff (123 lines)
--- a/errors.md
+++ b/errors.md
@@ -74,9 +74,11 @@
`Couldn't reconnect to your Remote Control session`| Network
`Couldn't share the transcript.`| Network
`Prompt is too long` / `Input is too long for requested model`| Request errors
+`Prompt is too long · automatic compaction failed:`| Request errors
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
+`Request too large for the API's 32MB request limit`| Request errors
`Image was too large`| Request errors
`Unable to resize image`| Request errors
`PDF too large` / `PDF is password protected`| Request errors
@@ -107,6 +109,8 @@
`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
+`Error: Input contained only whitespace`| Command-line errors
+`Blank prompt — the message was only whitespace, so nothing was sent to the model.`| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
`Your checkout has no branches (detached HEAD only)`| Command-line errors
@@ -286,9 +290,9 @@
The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on how the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is unavailable:
- <model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait briefly and then try this action again.
-
-More than one failure produces this same message, so the message alone doesn’t tell you the cause. When the classifier model is overloaded or rate-limited, the failure is transient and retrying works. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), the same message also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until the model is granted. **What to do:**
+ <model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait a moment and then try this action again.
+
+When Claude Code can determine the failure category, it names the category in parentheses after `temporarily unavailable`, for example `<model> is temporarily unavailable (rate-limited), so auto mode cannot determine the safety of <tool> right now`. The categories are `(rate-limited)`, `(overloaded)`, `(server error)`, `(timed out)`, and `(connection failed)`. Rate-limited, overloaded, and server errors are transient, and retrying works. If `(timed out)` or `(connection failed)` repeats, check your connection; see Unable to connect to API. Before v2.1.229, the message never named a category and read `Wait briefly and then try this action again`. When no category fits, the message appears with no category in parentheses; more than one failure produces that form. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), it also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until your account is granted access to the model. **What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
@@ -391,7 +395,7 @@
API Error: Usage credits required for 1M context · run /usage-credits to turn them on, or /model to switch to standard context
-This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
+This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. Claude Code runs this check when you pick the model with `/model`, and only on a direct connection to the Anthropic API; if you point `ANTHROPIC_BASE_URL` at an [LLM gateway](</docs/en/llm-gateway>), `/model` allows the `[1m]` selection and the gateway decides whether the request succeeds. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
* Run `/usage-credits` to turn on metered billing for the 1M variant on Pro and Max, or to request it from your admin on Team and Enterprise
@@ -1050,7 +1054,11 @@
Prompt is too long
-Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. **What to do:**
+Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. When automatic compaction ran on this turn and failed on an underlying error, such as an unavailable model or an authentication failure, the message names that error after a separator:
+
+ Prompt is too long · automatic compaction failed: <the underlying error>
+
+Resolve the named error first; `/compact` fails on the same error until you do. Before v2.1.229, a failed automatic compaction surfaced the bare `Prompt is too long` without the cause. **What to do:**
* Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
@@ -1105,14 +1113,19 @@
Request too large
-The raw request body exceeded the API’s 32MB limit before tokenization, usually because of a large pasted file or attachment.
+The raw request body exceeded the API’s 32MB limit before tokenization, usually because of large pasted content, tool results, or attachments. This limit is separate from the context window.
Request too large (max 32MB). Accumulated images and attachments in the conversation pushed the request over the limit. Run /compact, or double press esc to go back and remove attachments.
-This is a size limit on the HTTP request, separate from the context window limit. When Claude Code sends requests directly to the Claude API, it keeps the total size of images and attachments in each request below this limit by dropping the oldest ones, so conversations that accumulate many images don’t hit it. Before v2.1.212, that cap was higher than the request limit, so a conversation with enough accumulated images failed on every turn with `Request too large (max 32MB). Double press esc to go back and try with a smaller file.` **What to do:**
-
- * Run `/compact` to summarize the conversation, which drops accumulated images and attachments
- * Press Esc twice and step back past the turn that added the oversized content
+When the request went straight to the Claude API and the API itself rejected it, Claude Code measures the conversation and words the message by whether recovery can work. Through a proxy, gateway, or cloud provider you get the general message. The measured forms:
+
+ * `Request too large (max 32MB; 20.1MB of about 33.4MB is images or documents).`: images or documents pushed the request over the limit. Claude Code retries with them stripped.
+ * `Request too large for the API's 32MB request limit`: the messages alone are over the limit, so the message says `compacting cannot make it fit` and Claude Code doesn’t retry. In [non-interactive mode](</docs/en/headless>), the message tells you to reduce the input or start a new session instead.
+
+Before v2.1.212, conversations with enough accumulated images failed on every turn with `Request too large (max 32MB). Double press esc to go back and try with a smaller file.` Before v2.1.229, Claude Code showed the attachment advice for every rejection, even when compacting couldn’t help. **What to do:**
+
+ * If the message says `compacting cannot make it fit`, press Esc twice to step back past the turn that added the large content, or run `/clear` to start fresh
+ * Otherwise, run `/compact`, which drops accumulated images and attachments
* Reference large files by path instead of pasting their contents, so Claude can read them in chunks
* For images, see Image was too large below
@@ -1219,7 +1232,7 @@
* Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
* If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this check even when the model is newer than your Claude Code version, so upgrading isn’t needed for those.
* A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under There’s an issue with the selected model.
- * The check runs only on the Anthropic API. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), and behind an [LLM gateway](</docs/en/llm-gateway>) or a custom `ANTHROPIC_BASE_URL`, your provider or gateway defines the model names, so Claude Code accepts any string and passes it through.
+ * The check runs only on the Anthropic API. On any other provider or gateway, including a custom `ANTHROPIC_BASE_URL`, the provider defines the model names, so Claude Code accepts any string and passes it through.
###
@@ -1563,6 +1576,21 @@
+Input contained only whitespace
+
+In [non-interactive mode](</docs/en/headless>), Claude Code refuses a prompt made up entirely of spaces, tabs, or newlines instead of sending it, because the API rejects messages with no visible text. Which message you see depends on where the blank prompt came from:
+
+ * **Prompt argument or piped stdin for`claude -p`**: `claude` exits with `Error: Input contained only whitespace. Provide a prompt with text through stdin or as a prompt argument when using --print`
+ * **Message submitted to a running`--input-format stream-json` or [Agent SDK](</docs/en/agent-sdk/overview>) session**: Claude Code ends the turn without calling the model and the session stays usable. The refusal arrives as an informational message and as the turn’s result text: `Blank prompt — the message was only whitespace, so nothing was sent to the model.`
+
+Before v2.1.229, Claude Code sent the whitespace-only message to the API, which rejected the request with a 400 error. **What to do:**
+
+ * Include visible text in the prompt. If a script builds the prompt from a variable or file, check that the source isn’t empty before calling Claude Code.
+
+###
+
+
+
Diff is too large for ultrareview
The diff between your branch and the base branch, including uncommitted and staged changes, exceeds the size limits for an [ultrareview](</docs/en/ultrareview>), so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts. A refused review doesn’t use a free run and doesn’t bill usage credits. The message names the limits in effect, the size of your diff, and the files that contribute the most changed lines. Before v2.1.216, the message showed only the raw diff statistics.
@@ -1743,7 +1771,7 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
- * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP` or `TaskCreate`, remove the entry or ask Claude to run the subagent in the foreground
+ * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP` or `TaskCreate`, remove the entry. To keep the tool, [turn fork mode off](</docs/en/sub-agents#turn-fork-mode-on-or-off>) and ask Claude to run the subagent in the foreground
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
* For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
--- a/errors.md
+++ b/errors.md
@@ -307,20 +307,32 @@
Auto mode could not evaluate this action and is blocking it for safety — a safety check separate from auto mode blocked this request because of earlier conversation content — it isn't about the action itself — run with --debug for details
-Claude Code denies the action but tells Claude this isn’t a judgment that the action is unsafe, and to continue with other tasks rather than retry. These denials don’t count toward [auto mode’s pause thresholds](</docs/en/permission-modes#when-auto-mode-falls-back>). In [non-interactive mode](</docs/en/headless>) the run aborts with `Agent aborted: auto mode classifier request refused by the safety safeguard in headless mode`, since there is no user to prompt and the refusal repeats on every retry. Before v2.1.225, Claude Code counted these refusals toward the pause thresholds and returned the same rejection message as a genuine classifier block. **What to do:**
+Claude Code denies the action but tells Claude this isn’t a judgment that the action is unsafe, and to continue with other tasks rather than retry. These denials don’t count toward [auto mode’s pause thresholds](</docs/en/permission-modes#when-auto-mode-falls-back>). In a [non-interactive](</docs/en/headless>) `-p` run, Claude Code doesn’t stop the run. What Claude receives depends on where it requested the action:
+
+ * To a [background subagent](</docs/en/sub-agents#run-subagents-in-foreground-or-background>) in a `-p` run without `--input-format stream-json`, Claude Code returns an error result containing `Agent aborted: auto mode classifier request refused by the safety safeguard in headless mode`
+ * Everywhere else, including interactive sessions and the main conversation of a `-p` run, Claude Code returns that denial to Claude
+
+Before v2.1.225, Claude Code counted these refusals toward the pause thresholds and returned the same rejection message as a genuine classifier block. **What to do:**
* This is not a decision about your action. Content already in your conversation triggered a safety filter on the API when auto mode sent the conversation to the classifier
* Retrying will not help; the same conversation content will trigger the filter again
- * Switch to a different [permission mode](</docs/en/permission-modes>) so you can approve the action when prompted, or start a fresh conversation without the triggering content
+ * In an interactive session, switch to a different [permission mode](</docs/en/permission-modes>) so you can approve the action when prompted
+ * Start a fresh conversation without the triggering content
When the conversation has grown larger than the classifier’s context window:
Auto mode classifier transcript exceeded context window — falling back to manual approval (try /compact to reduce conversation size)
-In an interactive session, auto mode falls back to a normal permission prompt for that action so you can approve or deny it manually. In [non-interactive mode](</docs/en/headless>) the run aborts because the transcript only grows and retrying can’t succeed. **What to do:**
-
- * Approve or deny the action in the prompt that appears
- * Run `/compact` to reduce the conversation size so subsequent actions fit within the classifier window again
+What happens to the action depends on where Claude requested it:
+
+ * In an interactive session, auto mode falls back to a normal permission prompt for that action so you can approve or deny it manually
+ * To a [background subagent](</docs/en/sub-agents#run-subagents-in-foreground-or-background>) in a [non-interactive](</docs/en/headless>) `-p` run without `--input-format stream-json`, Claude Code returns an error result containing `Agent aborted: auto mode classifier transcript exceeded context window in headless mode`, and the run continues
+ * Elsewhere in a `-p` run without a [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>), there is no prompt to fall back to, so the action doesn’t run and the run continues
+
+**What to do:**
+
+ * In an interactive session, approve or deny the action in the prompt that appears
+ * In an interactive session, run `/compact` to reduce the conversation size so subsequent actions fit within the classifier window again
###
Show diff (747 lines)
--- a/errors.md
+++ b/errors.md
@@ -16,11 +16,15 @@
`API Error: Repeated 529 Overloaded errors`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`Server error mid-response. The response above may be incomplete.`| Server errors
+`Connection lost mid-response` / `Your computer went to sleep mid-response` / `The response stopped arriving`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
+`Connection lost before a response was produced` / `Your computer went to sleep before a response was produced` / `The response stalled before a response was produced`| Automatic retries
`Connection closed while thinking` / `Response stalled while thinking`| Automatic retries
+`Connection lost while your computer was asleep`| Automatic retries
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
+`Agent aborted: auto mode classifier request refused by the safety safeguard`| Server errors
`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
@@ -28,25 +32,37 @@
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
`Could not update your spend limit`| Usage limits
+`spend limit reached` / `spend limit unavailable`| Usage limits
`Not logged in · Please run /login`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`Your apiKeyHelper script is failing`| Authentication
+`Invalid auth token · Fix external auth token`| Authentication
+`Invalid ANTHROPIC_CUSTOM_HEADERS · Fix the environment variable`| Authentication
+`Invalid request header from the environment · Fix the environment variable`| Authentication
`This organization has been disabled`| Authentication
`Your organization has disabled API key authentication`| Authentication
`Your organization has disabled Claude subscription access`| Authentication
`Routines are disabled by your organization's policy`| Authentication
`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
+`OAuth token refresh failed — run /login to re-authenticate`| Authentication
+`JWT refresh failed: no OAuth token — run /login`| Authentication
+`Claude.ai login expired`| Authentication
+`Claude.ai login was rejected — run /login, then /remote-control`| Authentication
+`OAuth token unavailable — run /login to restore Remote Control`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
+`Anthropic profile login expired · Re-authenticate your Anthropic profile`| Authentication
`does not meet scope requirement user:profile`| Authentication
`claude.ai rejected the session token` / `session token rejected`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
+`Could not load the default credentials` on Google Cloud’s Agent Platform| Automatic retries
`Unable to connect to API`| Network
+`Connection refused —` / `Can't reach the API server —` / `No internet route —` / `Couldn't connect through your proxy` / `Connection dropped`, each ending with an error code in parentheses| Network
`Unable to connect to Anthropic services` during setup| Network
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
@@ -56,7 +72,8 @@
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`Couldn't reconnect to your Remote Control session`| Network
-`Prompt is too long`| Request errors
+`Couldn't share the transcript.`| Network
+`Prompt is too long` / `Input is too long for requested model`| Request errors
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -82,14 +99,19 @@
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Error: Settings file exceeds the 2MiB limit`| Command-line errors
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
+``claude import` is not yet available in this build`| Command-line errors
+`Could not read Claude Code config`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
-`Shell command failed for pattern "!`git ... origin/HEAD...`"`| Command-line errors
+`Shell command failed for pattern "..."`, from `/security-review` or any skill that injects dynamic context| Command-line errors
+`Shell command permission check failed for pattern "..."`, from a skill that injects dynamic context| Command-line errors
+`Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Could not find merge-base with <branch>`| Command-line errors
`Your checkout has no branches (detached HEAD only)`| Command-line errors
`Failed to resume the conversation`| Command-line errors
+`No conversation found with session ID: <session-id>`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -99,8 +121,12 @@
`File is covered by a Read deny rule in your permission settings`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`pkill: refusing to run`| Tool errors
+`Failed to write to <name>'s inbox — nothing was sent`| Tool errors
+`Failed to write the plan approval request to the lead's inbox — plan not submitted`| Tool errors
`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
+`blocked because the path is spelled in a form that cannot be safely resolved`| Background session errors
+`blocked because the path is network-shaped`| Background session errors
`This session has no saved transcript`| Background session errors
`This session was running agent '<name>', which is no longer available`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
@@ -108,8 +134,12 @@
`Claude Code process exited with code N`| Wrapper and IDE errors
`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings
+`Transcript writes are failing (...)`| Session saving warnings
+`Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set`| Session saving warnings
+`Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker`| Session saving warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
+`CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced`| Configuration warnings
Responses seem lower quality than usual| Response quality
##
@@ -121,11 +151,17 @@
Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure; the lists below say which failures get the full budget, which get a smaller one, and which get none. Claude Code retries these failures:
* Server errors, overloaded responses, and request timeouts that arrive before any of Claude’s response has streamed.
- * Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection closed while thinking, before producing a response` if the connection keeps dropping at that point.
- * A stalled response stream, when none of the response has arrived yet or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `Response stalled while thinking, before producing a response`.
- * Temporary 429 throttles. When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
-
-Claude Code doesn’t retry these failures:
+ * Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point.
+ * A connection that Claude Code detects was broken by your computer going to sleep partway through a request. Claude Code counts it as a dropped connection under the rules above; once the retry label names the specific reason, it reads `Connection lost while your computer was asleep`, and if the turn ends after Claude has finished thinking but before any text or tool call, the message reads `Your computer went to sleep before a response was produced`.
+ * A stalled response stream, when none of the response has arrived yet or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `The response stalled before a response was produced`.
+ * Temporary 429 throttles, but not a gateway’s spend-limit `429`, which isn’t a throttle; see Spend limit reached.
+ * When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
+ * A request rejected because the input plus `max_tokens` exceeds the context limit. Re-sending it unchanged would fail the same way, so Claude Code retries with a reduced `max_tokens`, and stops retrying and compacts instead in two cases:
+ * When no reduction can fit, for example when the conversation itself nearly fills the context window.
+ * When a retry can’t shrink `max_tokens` any further. Before v2.1.218, Claude Code could re-send a reduced request that still didn’t fit, such as when the extended thinking budget exceeded the remaining context, until the retry budget ran out.
+ * An expired or missing Google Cloud credential on [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), which surfaces as an error such as `Could not load the default credentials`. Claude Code discards its cached credentials and retries up to two times, running your [`gcpAuthRefresh`](</docs/en/google-vertex-ai#advanced-credential-configuration>) command if you configured one, then reports the error so you can re-authenticate right away. [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>) covers re-authenticating. Before v2.1.228, Claude Code retried a failing credential through the full retry budget before showing the error.
+
+Before v2.1.227, `Connection lost before a response was produced` read `Connection closed while thinking, before producing a response` and `The response stalled before a response was produced` read `Response stalled while thinking, before producing a response`. Claude Code doesn’t retry these failures:
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
* A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
@@ -220,17 +256,19 @@
A streaming request failed while the response was still in progress, after Claude had completed a block of text or a tool call, or had started one after finishing its thinking. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
API Error: Server error mid-response. The response above may be incomplete.
- API Error: Connection closed mid-response. The response above may be incomplete.
- API Error: Response stalled mid-stream. The response above may be incomplete.
+ API Error: Connection lost mid-response. The response above may be incomplete.
+ API Error: Your computer went to sleep mid-response. The response above may be incomplete.
+ API Error: The response stopped arriving. The response above may be incomplete.
* `Server error mid-response`: a mid-stream overloaded or 5xx server error. This variant requires Claude Code v2.1.199 or later; before then that case discarded the partial output and reported the whole turn as an error.
- * `Connection closed mid-response`: the connection dropped.
- * `Response stalled mid-stream`: the stream stopped sending data. Before v2.1.222, this variant could also appear on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because Claude Code counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-
-When one of these failures lands at another point in the turn, Claude Code handles it without this notice:
+ * `Connection lost mid-response`: the connection dropped.
+ * `Your computer went to sleep mid-response`: Claude Code detected that your computer went to sleep while the response was streaming. Once your computer wakes, Claude Code treats the connection as broken and stops reading from it.
+ * `The response stopped arriving`: the connection stayed open but stopped delivering data, so the streaming idle watchdog aborted it. Before v2.1.222, Claude Code could also report this failure on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because it counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
+
+Before v2.1.227, `Connection lost mid-response` read `Connection closed mid-response` and `The response stopped arriving` read `Response stalled mid-stream`. When one of these failures lands at another point in the turn, Claude Code handles it without this notice:
* Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
- * When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed the `Connection closed mid-response` or `Response stalled mid-stream` notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
+ * When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed this notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
**What to do:**
@@ -269,7 +307,7 @@
Auto mode could not evaluate this action and is blocking it for safety — a safety check separate from auto mode blocked this request because of earlier conversation content — it isn't about the action itself — run with --debug for details
-**What to do:**
+Claude Code denies the action but tells Claude this isn’t a judgment that the action is unsafe, and to continue with other tasks rather than retry. These denials don’t count toward [auto mode’s pause thresholds](</docs/en/permission-modes#when-auto-mode-falls-back>). In [non-interactive mode](</docs/en/headless>) the run aborts with `Agent aborted: auto mode classifier request refused by the safety safeguard in headless mode`, since there is no user to prompt and the refusal repeats on every retry. Before v2.1.225, Claude Code counted these refusals toward the pause thresholds and returned the same rejection message as a genuine classifier block. **What to do:**
* This is not a decision about your action. Content already in your conversation triggered a safety filter on the API when auto mode sent the conversation to the classifier
* Retrying will not help; the same conversation content will trigger the filter again
@@ -384,6 +422,23 @@
+Spend limit reached
+
+You connect through a [Claude apps gateway](</docs/en/claude-apps-gateway>) and have passed a [spend cap](</docs/en/claude-apps-gateway-spend-limits>) your gateway operator set. The gateway blocks your requests until the named period resets or the operator raises the cap. It marks each blocked `429` response `x-should-retry: false`, so Claude Code shows this message without retrying.
+
+ spend limit reached (daily; resets 2026-08-09 00:00 UTC)
+
+The message names the cap’s period and reset time, and when the operator configured a `blocked_message`, their instructions follow it. Before v2.1.225, the message read only `spend limit reached`; a gateway on an older version still sends that shorter form. **What to do:**
+
+ * Wait for the reset time the message names, or follow the operator’s instructions if the message carries them
+ * Ask your gateway operator to raise the cap if you hit it routinely
+
+A related message, `spend limit unavailable`, means the gateway could not read its spend records and blocked the request as a precaution rather than over your cap. It usually clears on its own; if it persists, tell your gateway operator.
+
+###
+
+
+
Credit balance is too low
Your Console organization has run out of prepaid credits.
@@ -462,11 +517,11 @@
Invalid API key
-The `ANTHROPIC_API_KEY` environment variable or `apiKeyHelper` script returned a key the API rejected.
+The `ANTHROPIC_API_KEY` environment variable or `apiKeyHelper` script returned a key the API rejected, or Claude Code blocked a key from `ANTHROPIC_API_KEY` before sending it.
Invalid API key · Fix external API key
-**What to do:**
+When the message continues past `Fix external API key` with a description such as `Invalid X-Api-Key header value from ANTHROPIC_API_KEY: it contains a line break at character 41 (120 characters on 2 lines).`, the API never saw the key. Claude Code found a character that HTTP headers can’t carry and stopped the request before sending it. See Invalid request header value for how to read the description and fix the value. **What to do:**
* Check for typos and confirm the key has not been revoked in the [Console](<https://platform.claude.com/settings/keys>)
* In the same shell, run `env | grep ANTHROPIC`, or in PowerShell `Get-ChildItem Env:ANTHROPIC*`. Tools like direnv, dotenv shell plugins, and IDE terminals can load a stale key from a `.env` file in your project without you setting it explicitly.
@@ -480,7 +535,11 @@
Your apiKeyHelper script is failing
-The command configured in the [`apiKeyHelper`](</docs/en/settings#available-settings>) setting exited with an error, timed out, or printed nothing to stdout. Without a key from the script, the request reaches the API with a placeholder credential, and the API rejects it with `401`.
+Claude Code ran the command in your [`apiKeyHelper`](</docs/en/settings#available-settings>) setting and didn’t get a key back. Without one, the request reaches the API with a placeholder credential, and the API rejects it with `401`. The `Authentication` panel in the terminal shows which of these happened:
+
+ * The command exited with an error or timed out
+ * The command printed nothing to stdout
+ * The command printed something besides the key, such as a login banner or a log line. The panel shows `returned output that cannot be used as an API key` and says what’s wrong, without repeating the output. Before v2.1.227, Claude Code sent whatever the command printed, after trimming surrounding whitespace.
Your apiKeyHelper script is failing · This usually means you need to re-authenticate with your provider · Run /status to see the script's error output
@@ -488,8 +547,36 @@
* Run the command configured in `apiKeyHelper` directly in your shell to reproduce the failure
* If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
- * Fix the command so it prints the key to stdout and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
+ * Fix the command so it prints only the key to stdout, as a single token of printable ASCII up to 16,384 characters, and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
* Run `/status` to confirm `apiKeyHelper` is the active credential source. Each time the command fails, its exit code and error output appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
+
+###
+
+
+
+Invalid request header value
+
+A value Claude Code was about to send as a request header contains a character that HTTP headers can’t carry: a line break, a NUL byte, or a character above `U+00FF`, such as a curly quote or a zero-width space. Claude Code stops the request before anything is sent and names the variable or setting to fix. The usual cause is a credential pasted from a document or chat that carried an invisible character or a stray line break. Claude Code runs this check when it sends requests to the Claude API directly or through an [LLM gateway](</docs/en/llm-gateway>). On a third-party cloud provider such as [Amazon Bedrock](</docs/en/amazon-bedrock>), Claude Code doesn’t run it before sending.
+
+ Invalid auth token · Fix external auth token
+ Invalid ANTHROPIC_CUSTOM_HEADERS · Fix the environment variable
+ Invalid request header from the environment · Fix the environment variable
+
+The first part of the message depends on where the bad value came from:
+
+ * `Invalid auth token`: a bearer token from [`ANTHROPIC_AUTH_TOKEN`](</docs/en/env-vars>) or [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>)
+ * `Invalid ANTHROPIC_CUSTOM_HEADERS`: a header name or value you set in [`ANTHROPIC_CUSTOM_HEADERS`](</docs/en/env-vars>). The description counts which `Name: Value` pair is at fault, such as `distinct header 2 of 3 parsed from ANTHROPIC_CUSTOM_HEADERS`, without repeating the name or value, since you chose both.
+ * `Invalid request header from the environment`: a value Claude Code copies into a request header from another environment variable, such as `CLAUDE_AGENT_SDK_CLIENT_APP`. The description names the variable to fix.
+
+Claude Code reports a bad `ANTHROPIC_API_KEY` caught by this check as Invalid API key, with the same trailing description. It reports a bad saved `/login` credential as Not logged in instead; run `/login` to save a fresh one. An [`apiKeyHelper`](</docs/en/settings#available-settings>) script’s output never reaches this check: Claude Code validates it when the script runs, and output an HTTP header can’t carry fails with Your apiKeyHelper script is failing. After the second `·`, the message describes the problem, as in this full example:
+
+ Invalid auth token · Fix external auth token · Invalid Authorization header value from ANTHROPIC_AUTH_TOKEN: it contains a line break at character 41 (120 characters on 2 lines).
+
+Positions count characters starting at one. The description is built from fixed phrases and character counts, so it never includes the value itself. It names the offending character only when it is a well-known invisible or typographic character, such as a byte-order mark, a zero-width space, or a curly quote, and reports anything else as `a non-ASCII character`. **What to do:**
+
+ * Re-set the variable or setting the message names, retyping the characters around the reported position rather than pasting from the same source again
+ * For `ANTHROPIC_CUSTOM_HEADERS`, keep one `Name: Value` pair per line and rewrite the pair the message counts
+ * Run `/status` to confirm which credential source is active
###
@@ -553,7 +640,7 @@
Routines are disabled by your organization’s policy
-An Owner in your Team or Enterprise organization has turned off routines at the organization level. The error appears when you try to create or run a routine, including from `/schedule` and the [Routines](</docs/en/routines>) UI on claude.ai/code.
+An Owner in your Team or Enterprise organization has turned off routines at the organization level. The error appears when you try to create or run a routine, for example from the [Routines](</docs/en/routines>) UI on claude.ai/code. On Claude Code v2.1.227 or later, the same setting also [hides `/schedule`](</docs/en/routines#troubleshooting>) in the CLI.
Routines are disabled by your organization's policy.
@@ -570,20 +657,56 @@
The session isn’t talking to the Anthropic API directly, so there is no claude.ai backend for [Remote Control](</docs/en/remote-control>) to pair with.
- Remote Control is only available when using Claude via api.anthropic.com.
-
-This appears on Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry. As of v2.1.196 it also appears when [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai. **What to do:**
-
- * Unset `ANTHROPIC_BASE_URL` and restart the session, or start Remote Control from a session that talks to the Anthropic API directly
+ Remote Control is only available when using Claude via api.anthropic.com. CLAUDE_CODE_USE_BEDROCK is set, so this session is using Amazon Bedrock — unset it (or run in a shell without it) to use Remote Control.
+
+A second sentence explains what routed the session away from the Anthropic API; before v2.1.219, the message was the first sentence alone. Depending on the cause, the message names:
+
+ * A `CLAUDE_CODE_USE_*` provider variable, such as `CLAUDE_CODE_USE_BEDROCK` for [Amazon Bedrock](</docs/en/amazon-bedrock>) or `CLAUDE_CODE_USE_VERTEX` for [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>)
+ * [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) pointing at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai; before v2.1.196, a custom base URL didn’t block Remote Control
+ * An enterprise [cloud gateway](</docs/en/claude-apps-gateway>) sign-in made through `/login`, which doesn’t support Remote Control and has no variable to unset
+
+**What to do:**
+
+ * Unset the variable the message names, such as `CLAUDE_CODE_USE_BEDROCK` or `ANTHROPIC_BASE_URL`, and restart the session, or start Remote Control from a session that talks to the Anthropic API directly
+ * If the variable isn’t set in your shell, check the `env` key in your [settings files](</docs/en/settings#settings-files>), which applies environment variables to every session
* For this and the other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
###
+Remote Control couldn’t refresh your login
+
+Claude Code runs a live [Remote Control](</docs/en/remote-control>) connection on short-lived credentials that it obtains and renews using your saved claude.ai login. When Claude Code can’t produce a login token that claude.ai accepts, whether while connecting or mid-session, it stops Remote Control and shows the reason in a warning and a transcript line that starts with `Remote Control disconnected`. Your local session keeps running without Remote Control.
+
+ Remote Control disconnected — Claude.ai login expired — run /login to restore Remote Control
+ Remote Control disconnected — Claude.ai login expired — run /login, then /remote-control
+ Remote Control disconnected — Claude.ai login was rejected — run /login, then /remote-control
+ Remote Control disconnected — OAuth token unavailable — run /login to restore Remote Control
+ Remote Control disconnected — OAuth token refresh failed — run /login to re-authenticate
+ Remote Control disconnected — JWT refresh failed: no OAuth token — run /login
+
+The middle of the message names what failed:
+
+ * `Claude.ai login expired` and `Claude.ai login was rejected`: claude.ai no longer accepts your saved login token, because it expired or was revoked
+ * `OAuth token unavailable`: Claude Code had no saved login token when the connection’s credential came due for renewal
+ * `OAuth token refresh failed`: Claude Code tried to refresh the saved login and the refresh failed, typically because the OAuth service rejected the stored refresh token
+ * `JWT refresh failed: no OAuth token`: Claude Code found no saved login token to renew with
+
+**What to do:**
+
+ * Run `/login` to sign in again
+ * Run `/remote-control` to reconnect the session. Messages ending `run /login to restore Remote Control` don’t need this step: Claude Code reconnects on its own once you sign in.
+
+Before v2.1.224, `OAuth token refresh failed — run /login to re-authenticate` read `OAuth token refresh failed — re-authenticate, then re-enable Remote Control`, and `JWT refresh failed: no OAuth token — run /login` read `no OAuth token available for recovery (code <N>)`. The `Claude.ai login expired`, `Claude.ai login was rejected`, and `OAuth token unavailable` messages were added in v2.1.225.
+
+###
+
+
+
OAuth token revoked or expired
-Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead.
+Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead. If you authenticate with a long-lived token in [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), you see the same messages when that token expires or is revoked.
OAuth token revoked · Please run /login
OAuth token has expired · Please run /login
@@ -593,6 +716,7 @@
* Run `/login` to sign in again
* If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
+ * If you authenticate with the `CLAUDE_CODE_OAUTH_TOKEN` environment variable, Claude Code keeps sending the value you set after a request fails with a 401, rather than switching to a stored login’s token. [`/status`](</docs/en/commands>) shows this credential as an `Auth token` row reading `CLAUDE_CODE_OAUTH_TOKEN`. Generate a fresh token with [`claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>) and restart with it, or unset the variable and run `/login`. Before v2.1.225, Claude Code could replace the variable’s value mid-session with the short-lived access token from a stored login, and the session failed with 401 errors again once that token expired.
* For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
@@ -637,6 +761,28 @@
+Anthropic profile login expired
+
+Claude Code is authenticating through an Anthropic credential profile whose saved login credential has expired, and the profile holds no refresh credential Claude Code can use to renew it. Claude Code stops each request locally without retrying, because only re-authenticating the profile produces a working credential.
+
+ Anthropic profile login expired · Re-authenticate your Anthropic profile
+
+This appears only when the active credential comes from an Anthropic credential profile, one you select with the `ANTHROPIC_PROFILE` environment variable or that Claude Code discovers as the active profile in your Anthropic configuration directory. Sessions that authenticate with `/login`, an API key, a bearer token such as `ANTHROPIC_AUTH_TOKEN`, or a third-party provider never see this message. Running `/login` doesn’t renew the profile credential. Whether a working login can take over instead depends on how the profile was selected:
+
+ * When you set `ANTHROPIC_PROFILE` explicitly, the profile keeps precedence over a saved login, so signing in doesn’t stop the error.
+ * When Claude Code discovered the profile from your configuration directory, a working `/login` takes precedence over it, and Claude Code authenticates with your claude.ai or Console account instead.
+
+**What to do:**
+
+ * Sign in to the profile again with the tool that created it, then retry
+ * If an administrator provisioned the profile’s credential, ask them to issue a new one
+ * Run `/status` to confirm the active credential source and profile name
+ * To stop using the profile, unset `ANTHROPIC_PROFILE` if you set it, then authenticate another way, such as `/login` or `ANTHROPIC_API_KEY`
+
+###
+
+
+
OAuth scope requirement
The stored token predates a permission scope that a newer feature needs. You see this most often from `/usage` and the status line usage indicator:
@@ -718,7 +864,7 @@
Network and connection errors
-These errors mean a network request from Claude Code failed to reach its destination, or something between Claude Code and the API altered the response on its way back. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
+Most of these errors mean a network request from Claude Code failed to reach its destination, or something between Claude Code and the API altered the response on its way back; where an entry also has a local cause, such as a failed archive write, its body says so. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
###
@@ -726,16 +872,18 @@
Unable to connect to API
-The TCP connection to the API failed or never completed.
+The TCP connection to the API failed or never completed. For the common connection error codes, the message names the kind of failure and keeps the code in parentheses:
Unable to connect to API. Check your internet connection
- Unable to connect to API (ECONNREFUSED)
- Unable to connect to API (ECONNRESET)
- Unable to connect to API (ETIMEDOUT)
+ Connection refused — a firewall or proxy may be blocking it (ConnectionRefused)
+ Can't reach the API server — check your internet or DNS (ENOTFOUND)
+ No internet route — check your connection or VPN (EHOSTUNREACH)
+ Couldn't connect through your proxy (ERR_PROXY_TUNNEL)
+ Connection dropped (ECONNRESET)
fetch failed
Request timed out. Check your internet connection and proxy settings
-Common causes include no internet access, a VPN that blocks `api.anthropic.com`, or a required corporate proxy that is not configured. **What to do:**
+A code Claude Code doesn’t recognize appears as `Unable to connect to API` followed by the code in parentheses. Some of these messages can show more than one code: `Connection refused` can show `ConnectionRefused` or `ECONNREFUSED`, for example, and `Can't reach the API server` can show `ENOTFOUND` or `FailedToOpenSocket`. Before v2.1.227, each of these coded messages read `Unable to connect to API` followed by the code, for example `Unable to connect to API (ECONNREFUSED)`. Common causes include no internet access, a VPN that blocks `api.anthropic.com`, or a required corporate proxy that is not configured. **What to do:**
* Confirm you can reach the API host from the same shell by running `curl -I https://api.anthropic.com`. On Windows PowerShell use `curl.exe -I https://api.anthropic.com` so the built-in `Invoke-WebRequest` alias is not used.
* If you are behind a corporate proxy, set `HTTPS_PROXY` before launching Claude Code and see [Network configuration](</docs/en/network-config>)
@@ -777,7 +925,7 @@
`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Depending on how far the response had progressed, Claude Code retries the request, keeps what Claude produced, or ends the turn:
* If Claude hasn’t completed any part of the response yet, including its thinking, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues, even if some text had started streaming.
- * If Claude has finished thinking but hasn’t started any text or tool call, Claude Code re-issues the request up to two times in quick succession, then ends the turn with `Connection closed while thinking, before producing a response` if the connection keeps dropping at that point.
+ * If Claude has finished thinking but hasn’t started any text or tool call, Claude Code re-issues the request up to two times in quick succession, then ends the turn with `Connection lost before a response was produced` if the connection keeps dropping at that point. Before v2.1.227, that message read `Connection closed while thinking, before producing a response`.
* If Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but hasn’t finished the response, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
* If the socket closes after Claude has finished the response, Claude Code ends the turn normally with the complete response.
@@ -852,10 +1000,25 @@
Resuming with `claude --resume` or `claude --continue` reconnects to the [Remote Control](</docs/en/remote-control>) session recorded in that conversation. This message means the reconnection failed for a reason that may be temporary, such as a network interruption or a server error, so Claude Code can’t confirm whether the remote session still exists. Your local session keeps running without Remote Control. **What to do:**
* Run `/remote-control` to retry the connection
- * Start Claude Code without `--resume` to create a new Remote Control session
+ * Start a new session with `claude --remote-control` to create a new Remote Control session
* For other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
-You won’t see this message when the server confirms the previous session no longer exists; Claude Code creates a new one in that case. Before v2.1.200, any reconnection failure created a new Remote Control session, which left extra sessions in the session list at claude.ai/code.
+When the server reports instead that the previous session no longer exists, Claude Code shows [`Remote Control could not resume the previous session under the current login`](</docs/en/remote-control#remote-control-could-not-resume-the-previous-session-under-the-current-login>) rather than this message and doesn’t create a replacement session. Earlier versions created a new Remote Control session instead of showing a message: before v2.1.200 on any reconnection failure, and through v2.1.226 when the server reported the session gone.
+
+###
+
+
+
+Couldn’t share the transcript
+
+After you agree to share your session transcript from a survey prompt, such as the [session quality survey](</docs/en/data-usage#session-quality-surveys>), Claude Code uploads it to Anthropic, or saves a local archive instead on third-party providers, on [Claude apps gateway](</docs/en/claude-apps-gateway>) sessions, and when no Anthropic credentials are available. This message means the share didn’t complete.
+
+ Couldn't share the transcript.
+
+The upload must fit an 8 MiB limit. On a long session, Claude Code progressively drops parts of the share, the last request’s model settings first, then the structured conversation and subagent transcripts, and shows this message only when no reduced version can be sent or a network or server error stops the upload. When Claude Code saves a local archive instead, the message means it couldn’t write the archive. **What to do:**
+
+ * Run `/feedback` to send the transcript with a description of what happened. See Report an error if `/feedback` is unavailable in your environment
+ * If other requests are failing too, check your network connection and see Unable to connect to API
##
@@ -875,7 +1038,7 @@
Prompt is too long
-**What to do:**
+Amazon Bedrock reports this condition as `Input is too long for requested model.`, which Claude Code handles the same way. Before v2.1.217, Claude Code didn’t recognize the Bedrock wording, so auto-compact never triggered on it and `/compact` failed with the same error. **What to do:**
* Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
@@ -1006,7 +1169,7 @@
Claude Code sends beta-only fields such as `context_management` and `effort` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
* Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
- * As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. This disables features that require the beta header so requests succeed through a gateway that cannot forward it.
+ * As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. [Disable pre-release capabilities](</docs/en/llm-gateway-protocol#disable-pre-release-capabilities>) covers the exact scope.
###
@@ -1072,10 +1235,10 @@
Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
-Claude Code treats a model family alias, one of `opus`, `sonnet`, `haiku`, or `fable`, as a request for that family rather than for its newest version. On the Anthropic API and on [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), a restricted family alias resolves to the newest version of the family that your organization and the `availableModels` allowlist permit, and the substitution notice names that version. Claude Code rejects `/model <alias>` only when every version of the family is restricted. Before v2.1.205, a family alias was substituted or rejected based on its newest version alone, even when an older version of the same family was allowed. **What to do:**
+A notice prefixed with an agent, skill, or command name means the restriction applied to that [subagent’s requested model](</docs/en/sub-agents#choose-a-model>): the subagent runs on the substituted model and your session’s model is unchanged. Before v2.1.223, Claude Code showed the notice only for subagents launched with the Agent tool. Claude Code treats a model family alias, one of `opus`, `sonnet`, `haiku`, or `fable`, as a request for that family rather than for its newest version. On the Anthropic API and on [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), a restricted family alias resolves to the newest version of the family that your organization and the `availableModels` allowlist permit, and the substitution notice names that version. Claude Code rejects `/model <alias>` only when every version of the family is restricted. Before v2.1.205, a family alias was substituted or rejected based on its newest version alone, even when an older version of the same family was allowed. **What to do:**
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
- * If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, or the `model` field of a settings file, remove or update that value so the notice doesn’t recur on each launch
+ * If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, the `model` field of a settings file, or the `model` frontmatter of a [subagent](</docs/en/sub-agents#choose-a-model>), skill, or command, remove or update that value so the notice doesn’t recur
* If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
###
@@ -1282,6 +1445,42 @@
+claude import is not yet available in this build
+
+You ran [`claude import`](</docs/en/cli-reference#cli-commands>), and Claude Code found the import flow turned off, so the command exits with code 1 instead of starting the import. Before v2.1.222, a build with the import flow off treated `import` as a prompt and started an interactive session instead of printing this message.
+
+ `claude import` is not yet available in this build. Run `claude` and use /mcp or edit ~/.claude/settings.json directly.
+
+Claude Code turns `claude import` on through a feature flag it fetches from Anthropic and caches on disk. This message means the cached value is off. The cause is usually one of the following:
+
+ * You haven’t started a session since installing, so Claude Code hasn’t fetched the flag yet. The first `claude import` can print this even when the feature is available to you.
+ * You use Claude Code through Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or Claude Platform on AWS. Claude Code doesn’t fetch feature flags on these providers, so `claude import` stays unavailable.
+ * You set `DISABLE_TELEMETRY`, `DO_NOT_TRACK`, `DISABLE_GROWTHBOOK`, or [`CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`](</docs/en/env-vars>), which turn off feature-flag fetching, so `claude import` stays unavailable.
+
+**What to do:**
+
+ * On a fresh installation, start `claude`, wait for the session to load, exit, and run `claude import` again
+ * Where feature-flag fetching stays off, set the configuration up yourself: add MCP servers with [`claude mcp add`](</docs/en/mcp#installing-mcp-servers>), and create the [`CLAUDE.md` files](</docs/en/memory#how-claude-md-files-load>), [skills and commands](</docs/en/skills#where-skills-live>), and [subagents](</docs/en/sub-agents#choose-the-subagent-scope>) you want to carry over. The message also names `~/.claude/settings.json`. Of the configuration `claude import` carries, that file holds only the [permission mode](</docs/en/settings#permission-settings>); Claude Code doesn’t read MCP servers from it.
+
+###
+
+
+
+Could not read Claude Code config
+
+You ran [`claude import`](</docs/en/cli-reference#cli-commands>) while Claude Code couldn’t parse `~/.claude.json`, the file where it stores your login and per-project state. The subcommand reads that file to check availability but doesn’t show the recovery dialog the interactive session shows, so it exits with code 1. Before v2.1.222, `claude import` with an unreadable config file started an interactive session, whose recovery dialog handled the file.
+
+ Could not read Claude Code config — run `claude` with no arguments to recover it.
+
+**What to do:**
+
+ * Run `claude` with no arguments. Claude Code detects the invalid file and offers to reset it. Then run `claude import` again.
+ * To keep manual edits you’ve made, fix the JSON syntax in `~/.claude.json` in an editor instead, then rerun `claude import`
+
+###
+
+
+
Could not import a server from Claude Desktop
Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import and none of the selected servers were added.
@@ -1322,7 +1521,12 @@
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
-The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. **What to do:**
+The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. Claude Code shows the same error for any skill that [injects dynamic context](</docs/en/skills#when-an-injected-command-fails>). A failed injected command aborts that skill’s invocation. Two sibling strings fire before the command runs at all:
+
+ * `Shell command permission check failed for pattern "..."`: the command’s permission check returned something other than allow. Injected commands never prompt, so the invocation aborts without asking you. Pre-approve commands that would otherwise hit the default permission prompt with [`allowed-tools`](</docs/en/skills#pre-approve-tools-for-a-skill>). A matching ask or deny rule still aborts the invocation regardless of `allowed-tools`
+ * `Skill <name> requires bash (`shell: bash` in frontmatter) but Git Bash was not found`: the skill’s frontmatter demands bash on a machine without it. Install Git for Windows or change the frontmatter to `shell: powershell`. See [How injected commands run](</docs/en/skills#how-injected-commands-run>)
+
+**What to do:**
* Create the ref by naming your remote’s default branch: `git remote set-head origin <default-branch>`. This works whenever the local tracking ref `origin/<default-branch>` exists. If it doesn’t, as in single-branch clones, fetch the branch first: run `git remote set-branches --add origin <branch>`, then `git fetch origin`, then rerun the set-head command. Rerun `/security-review`.
* If you’d rather not name the branch, run `git fetch origin` and then `git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
@@ -1408,6 +1612,28 @@
* Run `claude --resume <session-id>` with the session ID from the message to retry
* If the retry fails again, run `claude` to start a new session
+
+###
+
+
+
+No conversation found with the session ID
+
+You passed a session ID to `claude --resume <session-id>` and no saved transcript matched it:
+
+ No conversation found with session ID: <session-id>
+
+Claude Code exits with code 1 after showing the message. Claude Code [searches the current project first, then every other project on this machine](</docs/en/sessions#resume-a-session>) for the ID. Before v2.1.223, the lookup stopped at the current project directory and its git worktrees, so resume from the directory the session last worked in. Common causes:
+
+ * **Mistyped ID** : for a non-interactive run, the ID is the `session_id` field of the [`--output-format json` output](</docs/en/headless#get-structured-output>)
+ * **Deleted transcript** : Claude Code removes transcripts after the [retention period](</docs/en/sessions#where-transcripts-are-stored>), 30 days by default, following the [retention sweep rules](</docs/en/claude-directory#cleaned-up-automatically>)
+ * **Different machine** : Claude Code stores transcripts locally, so resume the session on the machine where it ran
+ * **Duplicate copies** : if you copied a project directory under `~/.claude/projects` so two transcripts carry the same ID, Claude Code reports this message rather than resume one copy arbitrarily
+
+**What to do:**
+
+ * For an interactive session, open the [session picker](</docs/en/sessions#use-the-session-picker>) with `claude --resume` and press `Ctrl+A` to widen it to every project on this machine, then select the session
+ * Sessions created with `claude -p` or the [Agent SDK](</docs/en/agent-sdk/overview>) don’t appear in the picker, so re-check the ID against the `session_id` your original run printed
##
@@ -1515,14 +1741,14 @@
File is covered by a Read deny rule
-The Edit tool was called on a path matched by a [`Read` deny rule](</docs/en/permissions#read-and-edit>), including creating a new file at that path. Editing rewrites content Claude has to be able to read back, so the call is refused before any file access. The rule blocks the Edit tool only: Write and NotebookEdit aren’t covered by `Read` deny rules. Before v2.1.208, only an `Edit` deny rule blocked edits, and a `Read` deny rule alone didn’t.
+The Edit or Write tool was called on a path matched by a [`Read` deny rule](</docs/en/permissions#read-and-edit>), including creating a new file at that path. Both tools change content Claude has to be able to read back, so Claude Code refuses the call before any file access. NotebookEdit isn’t covered by `Read` deny rules. Before v2.1.228, the rule blocked the Edit tool only, and before v2.1.208, only an `Edit` deny rule blocked edits.
File is covered by a Read deny rule in your permission settings and cannot be edited.
-**What to do:**
-
- * If Claude should be able to edit the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings#permission-settings>)
- * If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path so the Write and NotebookEdit tools are blocked too
+When Claude Code refuses the Write tool, the message ends `and cannot be written` instead. **What to do:**
+
+ * If Claude should be able to change the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings#permission-settings>)
+ * If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path to block the NotebookEdit tool too
###
@@ -1554,13 +1780,34 @@
* Narrow the pattern so it matches only the intended process, for example the full path of the target binary rather than a short substring
* To stop processes started by the current shell, use `pkill -P $$` with the pattern, which limits the match to the shell’s own child processes
+###
+
+
+
+Failed to write to a teammate’s inbox
+
+Claude Code couldn’t write a message to a teammate’s mailbox file under `~/.claude/teams/{team-name}/inboxes/`, so the recipient received nothing. The write fails when Claude Code can’t create or update the file, for example because the disk is full, the directory isn’t writable, or another agent holds the inbox lock for too long. Before v2.1.224, Claude Code reported the message as sent even when the write failed. The error appears in the sending agent’s tool result rather than as a banner in your terminal, and its text tells Claude to try again:
+
+ Failed to write to researcher's inbox — nothing was sent. Try again, or message the lead.
+
+Structured [agent team](</docs/en/agent-teams>) protocol messages fail the same way, and the error names the undelivered message: when Claude Code can’t write a plan approval, plan rejection, shutdown request, or shutdown rejection, the error reads `Failed to write the <message> to <name>'s inbox — nothing was sent`. The `plan approval` in that list is the lead’s decision approving a teammate’s plan; the teammate’s plan submission is the separate `plan approval request` message. That message and two other protocol messages carry their own message text and consequence:
+
+ * `Failed to write the plan approval request to the lead's inbox — plan not submitted; try again`: the teammate’s plan never reached the lead, and the teammate stays in plan mode until a resubmission succeeds
+ * `The permission request could not be delivered to the team lead (mailbox write failed)`: the teammate’s permission request never reached the lead, so nobody approved the tool call
+ * `The confirmation could not be written to team-lead's inbox.`: the shutdown approval itself took effect and the teammate exits; only the confirmation to the lead is missing
+
+When you message a teammate yourself, typing `@name` followed by the message in the lead session, the same failure appears as a notification, `Couldn't write to @name's inbox — message not sent. Try again.`, and Claude Code keeps your text in the prompt box so you can send it again. **What to do:**
+
+ * Ask the sender to resend the message; contention for the inbox lock is transient and clears on retry
+ * Check free disk space, and check that `~/.claude/teams` and the files under it are writable by your user
+
##
Background session errors
-[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in the terminal that attaches to one, or in the session or shell you dispatch from; where a message is specific to one surface, its entry says so.
+[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in the terminal that attaches to one, in the session or shell you dispatch from, or, for the worktree-guard entries below, in any session isolated in a worktree or running a worktree-isolated subagent; where a message is specific to one surface, its entry says so.
###
@@ -1576,6 +1823,36 @@
* Attach to the session from agent view, where it’s listed under **Needs input** , and run the command again
* Or use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`, which work without attaching
+
+###
+
+
+
+Write or command blocked because the path cannot be safely resolved
+
+Claude addressed a file or working directory through a spelling that the [worktree-isolation guard](</docs/en/agent-view#how-file-edits-are-isolated>) can’t resolve to one verifiable location. The guard checks writes and command working directories in [any session isolated in a worktree](</docs/en/worktrees#how-claude-code-enforces-isolation>), interactive or background, and in [worktree-isolated subagents](</docs/en/worktrees#isolate-subagents-with-worktrees>). It resolves symlinks before checking that the operation doesn’t reach the shared checkout, and when resolution fails, it blocks the operation rather than letting it land there. The message names the path forms it refuses and how to retry:
+
+ This write was blocked because the path is spelled in a form that cannot be safely resolved (for example through a symlink storing a raw dot segment, a network-share or device-namespace shape, or an unreadable ancestor directory). If the file is inside the worktree /path/to/worktree, address it by its direct symlink-free path instead.
+
+A blocked command reports the same cause for its working directory and ends with `re-run the command from its direct symlink-free path`. Before v2.1.217, the guard compared path spellings without resolving symlinks, so these spellings weren’t blocked and a write routed through a symlink could land in the shared checkout. **What to do:**
+
+ * Usually nothing: the full message goes to Claude as a tool error, and Claude retries with the direct path it names. For a blocked file edit, the conversation view shows only a short `Error editing file` line; the full message appears in the transcript view, which you open with `Ctrl+O`. A blocked command prints it in its command output.
+ * If the block repeats on the same file, the path likely runs through a committed symlink whose target contains `..`, such as `docs/current -> ../README.md`; ask Claude to edit the target file by its real path instead of through the link
+
+###
+
+
+
+Write or command blocked because the path names a network location
+
+Claude addressed a file or working directory through a path that names a drive that isn’t on your machine, a UNC share such as `\\server\share\file` or a `/net` automount path, while the session’s checkout is on a local disk. The same worktree-isolation guard can’t verify that such a path stays out of the shared checkout, so it blocks the operation. Isolating the session in a worktree doesn’t lift the block. The message names the form of path to use instead:
+
+ This write was blocked because the path is network-shaped (a UNC share or /net automount spelling) while this session's checkout is local. Isolating cannot unblock it. If the file is genuinely inside the worktree /path/to/worktree, address it by its local, plainly-spelled path instead.
+
+A blocked command reports the same cause for its working directory and ends with `re-run the command from its local, plainly-spelled path`. Before v2.1.217, the guard compared path text only, so addressing a file inside the checkout through a UNC or `/net` path wasn’t blocked. **What to do:**
+
+ * Usually nothing: Claude retries with the local spelling the message asks for
+ * If the file genuinely lives on a network share, it’s outside the session’s local workspace; edit it from a regular interactive session instead
###
@@ -1710,6 +1987,66 @@
* Identify which files were skipped so you can handle each one with the steps below. The message gives only a count; the debug log at `~/.claude/debug/<session-id>.txt` names each skipped path as the restore runs, so turn on debug logging with `/debug` before your next restore. On macOS or Linux, you can instead find the links directly: `find . -type l` for symlinks and `find . -type f -links +1` for hard-linked files.
* If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
* If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
+
+##
+
+
+
+Session saving warnings
+
+Claude Code shows these warnings on a persistent line below the input box when it isn’t saving your session transcript. The session keeps working either way; the warnings tell you the session may be missing from [`--resume`](</docs/en/sessions>) later.
+
+###
+
+
+
+Transcript writes are failing
+
+Claude Code saves the transcript to disk as you work, and its writes to [the transcript file](</docs/en/sessions#where-transcripts-are-stored>) are failing. The message names the cause with the underlying error code, for example a full disk:
+
+ Transcript writes are failing (disk full — ENOSPC) · recent messages may not be saved for resume
+
+The warning appears at different points depending on the error:
+
+ * On the first failure for conditions that don’t clear on their own: a full disk, an exceeded disk quota, a read-only filesystem, a path over the filesystem’s length limit, or, on macOS and Linux, a permission error
+ * After repeated failures spanning at least a minute for everything else, including permission errors on Windows, where an antivirus scan can fail a single write that then succeeds on retry
+
+Before v2.1.217, Claude Code dropped the failing writes without a warning, and a later `--resume` missing recent messages was the first sign. **What to do:**
+
+ * Fix the condition the error code names: free disk space for `ENOSPC`; raise or clear the quota for `EDQUOT`; restore write access to the transcript location for `EACCES`, `EPERM`, or `EROFS`
+ * The warning clears on its own at the next successful write; no restart is needed
+ * Messages sent while the warning was showing may still be missing when you resume the session later
+
+###
+
+
+
+Transcript saving is off because CLAUDE_CODE_SKIP_PROMPT_HISTORY is set
+
+This session started with [`CLAUDE_CODE_SKIP_PROMPT_HISTORY`](</docs/en/env-vars>) set, so Claude Code writes no transcript or prompt history for it:
+
+ Transcript saving is off — CLAUDE_CODE_SKIP_PROMPT_HISTORY is set · --resume will not find this session; if unintended, unset it and restart
+
+The variable is an intentional opt-out for ephemeral scripted sessions, but it can also reach a session through a shell profile, a wrapper script, or a parent process that exported it. **What to do:**
+
+ * If you set the variable on purpose, no action is needed; the notice confirms the session won’t appear in `--resume`, `--continue`, or up-arrow history
+ * If you didn’t, remove the variable from the shell or script that launches `claude`, then start a new session. Messages from the current session aren’t saved retroactively.
+
+###
+
+
+
+Transcript saving is off because of an inherited CLAUDE_CODE_CHILD_SESSION marker
+
+Claude Code sets [`CLAUDE_CODE_CHILD_SESSION`](</docs/en/env-vars>) in the subprocesses it spawns, and treats an interactive session that inherits it as nested: Claude Code saves no transcript for it, so sessions that Claude itself starts don’t fill your `--resume` list. This notice means your current session inherited the marker:
+
+ Transcript saving is off — inherited CLAUDE_CODE_CHILD_SESSION marker · restart with CLAUDE_CODE_FORCE_SESSION_PERSISTENCE=1 to keep future transcripts
+
+The notice is expected when you ran `claude` from inside another Claude Code session; it signals a misclassification when the marker leaked through a long-lived intermediary, for example a terminal, `screen` session, or launcher that a Claude Code session originally started. Inside tmux, Claude Code detects a marker that arrived through the tmux server’s global environment and keeps saving, so this notice doesn’t appear for that case. **What to do:**
+
+ * If you started this session from inside another Claude Code session on purpose, no action is needed
+ * If this is a top-level session, exit and restart with [`CLAUDE_CODE_FORCE_SESSION_PERSISTENCE=1`](</docs/en/env-vars>) set. Saving applies from the restart, so messages sent before it aren’t saved.
+ * To fix future launches from the same terminal or launcher, remove `CLAUDE_CODE_CHILD_SESSION` from its environment
##
@@ -1755,6 +2092,29 @@
In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean; run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.210, Claude Code accepted these rules without a warning.
+###
+
+
+
+The 200K limit isn’t enforced
+
+You set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>), which normally makes [auto-compaction](</docs/en/model-config#default-auto-compact-thresholds>) hold sessions on 1M-context models to a 200K window, but no compaction threshold caps this session at or below 200K, so the conversation can grow past it.
+
+ CLAUDE_CODE_DISABLE_1M_CONTEXT is set, but the 200K limit isn't enforced for <model>, so this session can grow past it. To enforce it, set CLAUDE_CODE_AUTO_COMPACT_WINDOW=200000 (or the autoCompactWindow setting).
+
+Claude Code enforces the 200K limit on its own for every model it recognizes as having a native 1M window, and for model IDs it doesn’t recognize it compacts at the window it assumes. The warning appears when other configuration defeats that enforcement:
+
+ * The model ID isn’t one Claude Code recognizes, such as an [LLM gateway](</docs/en/llm-gateway>) alias, and you set [`CLAUDE_CODE_DISABLE_UNKNOWN_MODEL_WINDOW_ENFORCEMENT=1`](</docs/en/env-vars>) or raised the assumed window past 200K with [`CLAUDE_CODE_MAX_CONTEXT_TOKENS`](</docs/en/env-vars>). In this case the message also offers `or update to a Claude Code version that recognizes <model>` as a remedy.
+ * A `context-1m` beta requested through [`ANTHROPIC_BETAS`](</docs/en/env-vars>) or the [`--betas`](</docs/en/cli-reference#cli-flags>) flag still asks the API for the 1M window on a model that accepts that beta, while nothing compacts the session at 200K
+
+**What to do:**
+
+ * Set [`CLAUDE_CODE_AUTO_COMPACT_WINDOW=200000`](</docs/en/env-vars>), or the [`autoCompactWindow`](</docs/en/settings#available-settings>) setting to `200000`, so auto-compaction compacts at the 200K boundary
+ * If the message names a model ID this version doesn’t recognize, run `claude update`. A version that recognizes the ID as a 1M-context model enforces the limit without further configuration.
+ * If you want the session to use the model’s full window instead, unset `CLAUDE_CODE_DISABLE_1M_CONTEXT`; the warning reports only that the 200K limit isn’t enforced
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr.
+
##
--- a/errors.md
+++ b/errors.md
@@ -54,6 +54,7 @@
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
+`403` with `This GraphQL query is not enabled for this session` in a cloud session| [GitHub proxy](</docs/en/cloud-environments#github-proxy>)
`Couldn't reconnect to your Remote Control session`| Network
`Prompt is too long`| Request errors
`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
@@ -105,6 +106,7 @@
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`Claude Code process exited with code N`| Wrapper and IDE errors
+`Could not locate the Claude CLI on PATH`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
`... is not matched by file permission checks`| Configuration warnings
@@ -1197,7 +1199,7 @@
The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
-The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. Before v2.1.205, the same 10-minute deadline was reported as the HTTP client’s generic `timeout of 600000ms exceeded`. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
+The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
* Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run. For the timed-out message, run it again from a faster or less throttled network.
* If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](</docs/en/troubleshoot-install#check-network-connectivity>).
@@ -1663,6 +1665,22 @@
* Run `claude` in a terminal in the same project. The failure usually reproduces there with its real error message, which you can then look up on this page.
* Run `claude doctor` in a terminal to check the installation and configuration
+###
+
+
+
+Could not locate the Claude CLI on PATH
+
+The [VS Code extension](</docs/en/vs-code>) shows this error on Windows when you open Claude Code in the integrated terminal, the terminal’s shell is PowerShell, and the extension can’t find the installed `claude` executable on PATH. The extension refuses to launch Claude Code until it finds the installed `claude` on PATH.
+
+ Failed to run Claude Code: Error: Could not locate the Claude CLI on PATH. Launching by name in a PowerShell terminal would run a 'claude' from the open folder instead of the installed CLI, so the launch was blocked. Make sure the Claude CLI's install directory is on your system PATH (not only your PowerShell profile), then restart VS Code and try again. VS Code reads PATH when it starts, so PATH changes take effect only after a restart.
+
+**What to do:**
+
+ * Open a new PowerShell window outside VS Code and run `where.exe claude`. If it doesn’t print a path, the CLI isn’t on your PATH: add its install directory by following [Verify your PATH](</docs/en/troubleshoot-install#verify-your-path>). If it prints a path, the entry comes from your PowerShell profile or from a PATH change VS Code hasn’t picked up yet; the next two steps cover those cases.
+ * Set the PATH entry as a user or system environment variable, not in your PowerShell profile. The extension doesn’t run your profile, so a PATH edit that lives only there never reaches it.
+ * Restart VS Code after changing PATH. The extension checks the PATH that VS Code captured at startup, so a PATH change takes effect only after a restart.
+
##
Show diff (146 lines)
--- a/errors.md
+++ b/errors.md
@@ -17,6 +17,7 @@
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`Server error mid-response. The response above may be incomplete.`| Server errors
`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
+`Connection closed while thinking` / `Response stalled while thinking`| Automatic retries
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
@@ -92,6 +93,7 @@
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
+`Plugin archive integrity check failed`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
@@ -114,17 +116,17 @@
Automatic retries
-Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already exhausted those retries, unless the failure is one it doesn’t retry. Claude Code retries these failures:
-
- * Server errors, overloaded responses, and request timeouts.
- * Dropped connections. This covers a connection that drops in the middle of a request, before Claude has started a block of text or a tool call in its response: Claude Code re-issues the request with the same backoff, and the turn continues. Before v2.1.198, Claude Code stopped the turn with a connection error when the connection dropped mid-response, before any visible output had streamed.
- * A stalled response stream while the response is still in progress, before Claude has started a block of text or a tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above.
+Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already made whatever retries apply to that failure; the lists below say which failures get the full budget, which get a smaller one, and which get none. Claude Code retries these failures:
+
+ * Server errors, overloaded responses, and request timeouts that arrive before any of Claude’s response has streamed.
+ * Dropped connections. When a connection drops partway through a request before Claude has completed any part of its response, including its thinking, Claude Code re-issues the request with the same backoff and the turn continues, even if some text had already started streaming. When it drops after Claude has finished thinking but before it has started any text or tool call, Claude Code instead re-issues the request up to two times in quick succession, and ends the turn with `Connection closed while thinking, before producing a response` if the connection keeps dropping at that point.
+ * A stalled response stream, when none of the response has arrived yet or when Claude has finished thinking but hasn’t started any text or tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above. If the response stalls a second time after Claude has finished thinking but before any text or tool call, Claude Code ends the turn with `Response stalled while thinking, before producing a response`.
* Temporary 429 throttles. When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
Claude Code doesn’t retry these failures:
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
- * A server error, dropped connection, or stalled stream that arrives after Claude has started a block of text or a tool call in its response, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
* A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
@@ -213,7 +215,7 @@
The response above may be incomplete
-A streaming request failed after Claude had started a block of text or a tool call, while the response was still in progress. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
+A streaming request failed while the response was still in progress, after Claude had completed a block of text or a tool call, or had started one after finishing its thinking. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
API Error: Server error mid-response. The response above may be incomplete.
API Error: Connection closed mid-response. The response above may be incomplete.
@@ -223,9 +225,9 @@
* `Connection closed mid-response`: the connection dropped.
* `Response stalled mid-stream`: the stream stopped sending data. Before v2.1.222, this variant could also appear on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because Claude Code counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
-Claude Code shows this notice only when the failure lands after Claude has started a block of text or a tool call and before the response finishes:
-
- * While the response is in progress, before Claude has started a block of text or a tool call, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
+When one of these failures lands at another point in the turn, Claude Code handles it without this notice:
+
+ * Earlier in the response, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
* When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed the `Connection closed mid-response` or `Response stalled mid-stream` notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
**What to do:**
@@ -465,7 +467,7 @@
**What to do:**
* Check for typos and confirm the key has not been revoked in the [Console](<https://platform.claude.com/settings/keys>)
- * Run `env | grep ANTHROPIC` in the same shell. Tools like direnv, dotenv shell plugins, and IDE terminals can load a stale key from a `.env` file in your project without you setting it explicitly.
+ * In the same shell, run `env | grep ANTHROPIC`, or in PowerShell `Get-ChildItem Env:ANTHROPIC*`. Tools like direnv, dotenv shell plugins, and IDE terminals can load a stale key from a `.env` file in your project without you setting it explicitly.
* Unset `ANTHROPIC_API_KEY` and run `/login` to use subscription auth instead
* If the key comes from an [`apiKeyHelper`](</docs/en/settings#available-settings>) script, run the script directly to confirm it prints a valid key on stdout
* Run `/status` to confirm which credential source Claude Code is actually using
@@ -604,7 +606,7 @@
**What to do:**
- * If `/status` shows an `API key` row, an approved [`ANTHROPIC_API_KEY`](</docs/en/authentication#authentication-precedence>) is the active credential and takes precedence over your login, so `/login` doesn’t replace it. Rotate the key in the Claude Console, or run `unset ANTHROPIC_API_KEY` to fall back to your subscription.
+ * If `/status` shows an `API key` row, an approved [`ANTHROPIC_API_KEY`](</docs/en/authentication#authentication-precedence>) is the active credential and takes precedence over your login, so `/login` doesn’t replace it. Rotate the key in the Claude Console, or fall back to your subscription by running `unset ANTHROPIC_API_KEY`, or in PowerShell `Remove-Item Env:ANTHROPIC_API_KEY`.
* If `/status` shows only your login, run `/login` once. If the credential was revoked, a fresh login replaces it.
* If the same message returns for the same login account, the account or organization is no longer active. Check the account and organization that `/status` reports, and ask your organization admin to restore access.
* If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
@@ -770,10 +772,11 @@
Socket is closed
-`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Claude Code either retries the request or keeps the response Claude produced:
-
- * If the response is still in progress and Claude hasn’t started any block of text or a tool call, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues.
- * If Claude has started a block of text or a tool call but hasn’t finished the response, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
+`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Depending on how far the response had progressed, Claude Code retries the request, keeps what Claude produced, or ends the turn:
+
+ * If Claude hasn’t completed any part of the response yet, including its thinking, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues, even if some text had started streaming.
+ * If Claude has finished thinking but hasn’t started any text or tool call, Claude Code re-issues the request up to two times in quick succession, then ends the turn with `Connection closed while thinking, before producing a response` if the connection keeps dropping at that point.
+ * If Claude has completed a block of text or a tool call, or has started one after finishing its thinking, but hasn’t finished the response, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
* If the socket closes after Claude has finished the response, Claude Code ends the turn normally with the complete response.
Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
@@ -1319,8 +1322,8 @@
The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. **What to do:**
- * Create the ref by naming your remote’s default branch: `git remote set-head origin <default-branch>`. This works whenever the local tracking ref `origin/<default-branch>` exists. If it doesn’t, as in single-branch clones, fetch the branch first: `git remote set-branches --add origin <branch> && git fetch origin`, then rerun the set-head command. Rerun `/security-review`.
- * If you’d rather not name the branch, run `git fetch origin && git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
+ * Create the ref by naming your remote’s default branch: `git remote set-head origin <default-branch>`. This works whenever the local tracking ref `origin/<default-branch>` exists. If it doesn’t, as in single-branch clones, fetch the branch first: run `git remote set-branches --add origin <branch>`, then `git fetch origin`, then rerun the set-head command. Rerun `/security-review`.
+ * If you’d rather not name the branch, run `git fetch origin` and then `git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
* If the repository has no remote, add one with `git remote add origin <url>` and fetch before creating the ref. If the remote is empty, push your branch first with `git push -u origin HEAD` and name that branch in the set-head command; `origin/HEAD` then points at the branch you just pushed, so `/security-review` sees an empty diff until the branch diverges from it.
###
@@ -1451,6 +1454,26 @@
* For a hook, add an `args` array so it runs in [exec form](</docs/en/hooks#exec-form-and-shell-form>), where each `${user_config.KEY}` becomes one argument with no shell in between. Or drop the reference and read the `$CLAUDE_PLUGIN_OPTION_<KEY>` environment variable inside the script
* For a monitor, drop the reference and have the monitor script read the value from a config file
* For a `headersHelper`, move `${user_config.KEY}` into the server’s `headers` field, which isn’t shell-parsed, or read the value inside the helper script
+
+###
+
+
+
+Plugin archive integrity check failed
+
+The plugin’s marketplace entry uses an [`archive` source](</docs/en/plugin-marketplaces#zip-archives>) with a `sha256` pin, and the digest of the downloaded file doesn’t match the pin. Claude Code refuses the install, so nothing changes in the plugin cache. The mismatch has three possible causes:
+
+ * The file at the URL changed after the author computed the pin
+ * The author entered the wrong digest in the marketplace entry
+ * The URL serves a different file than the author pinned
+
+ Plugin archive integrity check failed for https://artifacts.example.com/claude-plugins/my-plugin.zip: expected sha256 6bfa50e3d2e00c052b46abe51fff89346ac803e45771f76dcf6df1ab74cca5e1, got ac52220c0914ef8ca6a602e4a7362f88d30fb021110f72a6d15b68c3fe7df2b7. The archive was not installed. Verify the sha256 in the marketplace entry, or that the URL serves the intended file.
+
+**What to do:**
+
+ * If you publish the plugin, recompute the digest of the exact file the URL serves, for example with `shasum -a 256 my-plugin.zip`, or `Get-FileHash -Algorithm SHA256 my-plugin.zip` in PowerShell, and update the `sha256` in the marketplace entry
+ * If you install the plugin, run `/plugin marketplace update <name>` to refresh the catalog in case the entry was corrected, then retry the install
+ * If the digests still disagree after a refresh, ask the marketplace owner which file they pinned before installing
##
@@ -1666,8 +1689,7 @@
**What to do:**
- * Identify which files were skipped so you can handle each one with the steps below. The message gives only a count, so list your project’s links to find them: `find . -type l` for symlinks and `find . -type f -links +1` for hard-linked files.
- * If debug logging is on, the log at `~/.claude/debug/<session-id>.txt` names each skipped path as the restore runs. Turn it on with `/debug` before your next restore to skip the search.
+ * Identify which files were skipped so you can handle each one with the steps below. The message gives only a count; the debug log at `~/.claude/debug/<session-id>.txt` names each skipped path as the restore runs, so turn on debug logging with `/debug` before your next restore. On macOS or Linux, you can instead find the links directly: `find . -type l` for symlinks and `find . -type f -links +1` for hard-linked files.
* If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
* If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
Show diff (222 lines)
--- a/errors.md
+++ b/errors.md
@@ -41,10 +41,12 @@
`Login expired · Please run /login`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`does not meet scope requirement user:profile`| Authentication
+`claude.ai rejected the session token` / `session token rejected`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
`Unable to connect to API`| Network
+`Unable to connect to Anthropic services` during setup| Network
`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
@@ -83,6 +85,8 @@
`Shell command failed for pattern "!`git ... origin/HEAD...`"`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
+`Could not find merge-base with <branch>`| Command-line errors
+`Your checkout has no branches (detached HEAD only)`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
@@ -113,13 +117,15 @@
Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already exhausted those retries, unless the failure is one it doesn’t retry. Claude Code retries these failures:
* Server errors, overloaded responses, and request timeouts.
- * Dropped connections. This covers a connection that drops in the middle of a request, before any part of Claude’s response has completed: Claude Code re-issues the request with the same backoff, and the turn continues. Before v2.1.198, Claude Code stopped the turn with a connection error when the connection dropped mid-response, before any visible output had streamed.
+ * Dropped connections. This covers a connection that drops in the middle of a request, before Claude has started a block of text or a tool call in its response: Claude Code re-issues the request with the same backoff, and the turn continues. Before v2.1.198, Claude Code stopped the turn with a connection error when the connection dropped mid-response, before any visible output had streamed.
+ * A stalled response stream while the response is still in progress, before Claude has started a block of text or a tool call: Claude Code aborts the stalled connection and re-issues the request at most once, outside the 10-attempt budget above.
* Temporary 429 throttles. When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
Claude Code doesn’t retry these failures:
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
- * A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call in its response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * A server error, dropped connection, or stalled stream that arrives after Claude has started a block of text or a tool call in its response, but before it finishes the response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * A failure that arrives after Claude has finished the response: nothing needs retrying, so Claude Code keeps the complete response and ends the turn normally.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
###
@@ -128,7 +134,7 @@
What you see while Claude Code retries or waits
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection, after which it retries the request, ends the turn with an error such as The response above may be incomplete, or shows that notice and continues the turn from the results of any tool calls Claude completed. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request hasn’t failed yet: the countdown runs to the point where Claude Code aborts the stalled connection. After the abort, Claude Code retries the request, ends the turn with an error when the failure isn’t retryable or retries run out, shows The response above may be incomplete and continues the turn from the results of any tool calls Claude completed, or ends the turn normally when Claude had already finished the response before the stall. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. Before v2.1.185, the banner appeared after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
###
@@ -207,7 +213,7 @@
The response above may be incomplete
-A streaming request failed after Claude had started producing a response. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
+A streaming request failed after Claude had started a block of text or a tool call, while the response was still in progress. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
API Error: Server error mid-response. The response above may be incomplete.
API Error: Connection closed mid-response. The response above may be incomplete.
@@ -215,9 +221,14 @@
* `Server error mid-response`: a mid-stream overloaded or 5xx server error. This variant requires Claude Code v2.1.199 or later; before then that case discarded the partial output and reported the whole turn as an error.
* `Connection closed mid-response`: the connection dropped.
- * `Response stalled mid-stream`: the stream stopped sending data.
-
-Claude Code never shows this notice for a failure that happens before Claude starts producing a response: at that point it either retries the failure or ends the turn with a different error. See Automatic retries. **What to do:**
+ * `Response stalled mid-stream`: the stream stopped sending data. Before v2.1.222, this variant could also appear on [gateway](</docs/en/gateways>) connections reached through `ANTHROPIC_BASE_URL` or `ANTHROPIC_AWS_BASE_URL` while the server’s keep-alive pings were still arriving, because Claude Code counted only parsed response events there; upgrading stops those spurious timeouts on those routes. Gateways reached through a provider base URL such as `ANTHROPIC_BEDROCK_BASE_URL` aren’t wrapped by the byte watchdog; see [Streaming idle watchdogs](</docs/en/network-config#streaming-idle-watchdogs>).
+
+Claude Code shows this notice only when the failure lands after Claude has started a block of text or a tool call and before the response finishes:
+
+ * While the response is in progress, before Claude has started a block of text or a tool call, Claude Code either retries the failure or ends the turn with a different error. See Automatic retries.
+ * When one of these failures arrives after Claude has finished the response, Claude Code keeps the complete response and ends the turn normally, without this notice. Before v2.1.222, Claude Code showed the `Connection closed mid-response` or `Response stalled mid-stream` notice when the connection dropped or stalled after the response finished, and reported the turn as an error even though the response was complete.
+
+**What to do:**
* In an interactive session, read the response that remains on screen: Claude Code keeps every block Claude completed before the error, but discards an interrupted final block when the turn ends, so the final sentences or tool calls may be missing. Reply with `continue` to have Claude pick up from its last completed block.
* In [non-interactive mode](</docs/en/headless>) (`-p`):
@@ -434,9 +445,9 @@
Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
-Before v2.1.174, a background or cloud session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Upgrade to recover. On current versions the error means no credential was available to the worker process. **What to do:**
-
- * Upgrade to v2.1.174 or later if this appears in a background or cloud session and your credentials are already configured
+On current versions the error means no credential was available to the worker process. Before v2.1.174, a background session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Before v2.1.176, a cloud session that sat idle before being claimed could too. Upgrade to recover. **What to do:**
+
+ * Upgrade to v2.1.176 or later if this appears in a background or cloud session and your credentials are already configured
* Confirm `ANTHROPIC_API_KEY`, `CLAUDE_CODE_OAUTH_TOKEN`, or your cloud provider credentials are set in the environment that launches the worker, not only in your interactive shell
* For the Agent SDK, see [authentication setup in the quickstart](</docs/en/agent-sdk/quickstart#setup>)
* Run `/status` in an interactive session in the same environment to confirm which credential source resolves
@@ -482,14 +493,16 @@
This organization has been disabled
-A stale `ANTHROPIC_API_KEY` from a disabled Console organization is overriding your subscription login.
-
- Your ANTHROPIC_API_KEY belongs to a disabled organization · Unset the environment variable to use your other credentials
+Claude Code is using a stale `ANTHROPIC_API_KEY` from a disabled Console organization. When you have a saved subscription login, the key overrides it.
+
+ Your ANTHROPIC_API_KEY belongs to a disabled organization · Unset the environment variable to use your subscription instead
+ Your ANTHROPIC_API_KEY belongs to a disabled organization · Update or unset the environment variable
API Error: 400 ... This organization has been disabled.
-Environment variables take precedence over `/login`, so a key exported in your shell profile or loaded from a `.env` file is used even when you have a working Pro or Max subscription. In non-interactive mode (`-p`), the key is always used when present. **What to do:**
+The hint after the `·` depends on your saved credentials: the first form appears when a stored `/login` can take over after you unset the key, and the second when the key is your only credential. Environment variables take precedence over `/login`, so a key exported in your shell profile or loaded from a `.env` file is used even when you have a working Pro or Max subscription. In non-interactive mode (`-p`), the key is always used when present. **What to do:**
* Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
+ * If the message says `Update or unset`, you have no saved login to fall back to. Unset the key and run `/login`, or replace the key with one from an active Console organization.
* Run `/status` afterward to confirm the active credential is your subscription
* If no environment variable is set and the error persists, the disabled organization is the one tied to your `/login`. Contact support or sign in with a different account.
@@ -629,6 +642,23 @@
**What to do:**
* Run `/login` to get a new token with the current scopes. You don’t need to log out first.
+
+###
+
+
+
+claude.ai rejected the session token
+
+A [claude.ai connector](</docs/en/mcp#use-mcp-servers-from-claude-ai>) request failed because claude.ai rejected the token from your Claude Code login, usually a login that expired and couldn’t be refreshed. The rejected token is your login, not the connector’s own authorization in claude.ai, so authorizing the connector again doesn’t resolve it. In `/mcp`, the connector shows as `connected · session token rejected` and its detail view reads:
+
+ claude.ai rejected the session token. Run /login, then reconnect.
+
+**What to do:**
+
+ * Run `/login` to sign in again
+ * Reconnect the connector from `/mcp`, or run `/mcp reconnect <server>`. Reconnecting before you sign in again leaves the connector in the same state. The `/mcp` panel’s **Reconnect** option reports `your claude.ai session token was rejected`; the typed `/mcp reconnect <server>` form reports a successful reconnect even though the token is still rejected.
+
+Before v2.1.222, Claude Code marked the connector as needing authentication instead, which pointed you at the connector’s authorization flow even though completing it didn’t resolve the state.
###
@@ -719,12 +749,32 @@
+Unable to connect to Anthropic services
+
+During first-run setup, Claude Code checks that it can reach `api.anthropic.com` and `platform.claude.com` before showing the sign-in step. When either check fails, Claude Code prints the reason and exits.
+
+ Unable to connect to Anthropic services
+ Failed to connect to api.anthropic.com: ECONNREFUSED
+ Connection to api.anthropic.com timed out after 10 seconds
+ A proxy is configured via HTTPS_PROXY. Check that it allows connections to the host above.
+
+Claude Code sends the check through the same [proxy configuration](</docs/en/network-config>) as API requests and gives each probe 10 seconds. When the failed probe went through a proxy, the message names the environment variable that configured it, such as `HTTPS_PROXY`. Before v2.1.222, the check used a different proxy transport with no timeout: behind a proxy URL with the `https://` scheme, it could stall on `Checking connectivity...` indefinitely and then fail even though API requests through the same proxy succeed. **What to do:**
+
+ * If the message names a proxy variable, check that its value points at the right proxy and ask your network team to allow HTTPS connections through it to the host in the message. See [Network configuration](</docs/en/network-config>).
+ * Work through the checks in Unable to connect to API. The `curl` test and firewall guidance there apply to this check too.
+ * If your network is open and the failure persists, Claude Code may not be [available in your country](<https://www.anthropic.com/supported-countries>)
+
+###
+
+
+
Socket is closed
-`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Claude Code either retries the request or keeps the partial response:
-
- * If Claude hasn’t completed any text or tool call yet, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues.
- * If Claude has completed a block of text or a tool call, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
+`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Claude Code either retries the request or keeps the response Claude produced:
+
+ * If the response is still in progress and Claude hasn’t started any block of text or a tool call, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues.
+ * If Claude has started a block of text or a tool call but hasn’t finished the response, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
+ * If the socket closes after Claude has finished the response, Claude Code ends the turn normally with the complete response.
Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
@@ -946,10 +996,9 @@
A proxy or LLM gateway between Claude Code and the API stripped the `anthropic-beta` request header, so the API rejected fields that depend on it.
API Error: 400 ... Extra inputs are not permitted ... context_management
- API Error: 400 ... Extra inputs are not permitted ... tools.0.custom.input_examples
API Error: 400 ... Unexpected value(s) for the `anthropic-beta` header
-Claude Code sends beta-only fields such as `context_management`, `effort`, and tool `input_examples` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
+Claude Code sends beta-only fields such as `context_management` and `effort` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
* Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. This disables features that require the beta header so requests succeed through a gateway that cannot forward it.
@@ -1000,7 +1049,7 @@
Your active subscription plan does not include the model you selected.
- Claude Opus is not available with the Claude Pro plan · Select a different model in /model
+ Claude Opus is not available with the Claude Pro plan. If you have updated your subscription plan recently, run /logout and /login for the plan to take effect.
**What to do:**
@@ -1303,6 +1352,27 @@
* Pass a base branch closer to your work, such as `/code-review ultra develop`, so the review covers only the diff against that branch
* Split the change into smaller branches and review each one. The files the message names contribute the most changed lines, so start by moving those to their own branch.
+
+###
+
+
+
+Could not find merge-base with the base branch
+
+`/code-review ultra` and the `claude ultrareview` subcommand review the diff between your branch and a base branch, which needs a commit the two share. When `git merge-base` finds none, Claude Code refuses the review before the cloud session starts. On a clone Claude Code can verify is complete, with at least one branch, it falls back to [reviewing every tracked file](</docs/en/ultrareview#diff-limits-and-fallbacks>) instead of refusing. You see this refusal when the base branch can’t be found at all, when Claude Code can’t verify that your clone is complete, or in the rare repository where the whole-tree diff isn’t possible, such as the SHA-256 object format.
+
+ Could not find merge-base with main. Pass the base branch explicitly (e.g. `/code-review ultra develop`) or make sure you're in a git repo with a main branch.
+
+The hint after the first sentence depends on what Claude Code observed:
+
+ * **You didn’t pass a base branch** : Claude Code compared against the repository’s default branch and suggests passing your base explicitly, as in the example above
+ * **You passed a base branch that was already in your clone** : the hint reads `Make sure <branch> exists locally or on origin (try `git fetch origin <branch>`)`
+ * **You passed a base branch that wasn’t in your clone** : Claude Code fetched it from origin before comparing. The hint reads `<branch> was fetched from origin but shares no history with HEAD. If another branch is your real base, pass it explicitly (`/code-review ultra <branch>`)`; when Claude Code can’t tell whether your clone is shallow, it suggests `git fetch --unshallow origin` instead. Before v2.1.221, the hint suggested `git fetch --unshallow origin` for every fetched base branch, and on a complete clone that command fails with `fatal: --unshallow on a complete repository does not make sense`.
+
+**What to do:**
+
+ * If another branch is your real base, pass it explicitly: `/code-review ultra <branch>`
+ * If your clone might not have full history, run `git fetch --unshallow origin` and rerun the review
###
--- a/errors.md
+++ b/errors.md
@@ -119,7 +119,7 @@
Claude Code doesn’t retry these failures:
* A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
- * A server error, dropped connection, or stalled stream that arrives partway through a response, once Claude has completed a block of text or a tool call in that response: Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps the completed output and ends the turn with an incomplete-response notice. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * A server error, dropped connection, or stalled stream that arrives after Claude has completed a block of text or a tool call in its response. Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps what Claude completed and shows an incomplete-response notice. Claude Code still runs any tool calls Claude completed and continues the turn from their results. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
* An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
###
@@ -128,7 +128,7 @@
What you see while Claude Code retries or waits
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection, after which the turn either retries or ends with an error such as The response above may be incomplete. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection, after which it retries the request, ends the turn with an error such as The response above may be incomplete, or shows that notice and continues the turn from the results of any tool calls Claude completed. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
###
@@ -221,7 +221,7 @@
* In an interactive session, read the response that remains on screen: Claude Code keeps every block Claude completed before the error, but discards an interrupted final block when the turn ends, so the final sentences or tool calls may be missing. Reply with `continue` to have Claude pick up from its last completed block.
* In [non-interactive mode](</docs/en/headless>) (`-p`):
- * With the default text output, Claude Code prints the last completed block of text it still holds from earlier in the turn, followed by this message. When it holds none, Claude Code prints this message alone, for example because Claude completed only tool calls before the error, or because Claude Code compacted the conversation mid-turn and cleared that text. Before v2.1.219, Claude Code printed only this message in `-p` text output and dropped the response it had already produced.
+ * With the default text output, Claude Code prints the last completed block of text it still holds from earlier in the turn, followed by this message. When it holds none, Claude Code prints this message alone, for example because Claude Code compacted the conversation mid-turn and cleared that text. Before v2.1.219, Claude Code printed only this message in `-p` text output and dropped the response it had already produced.
* With `--output-format json` or `stream-json`, Claude Code reports this message in the `result` field.
* To continue the turn, resume the session and send `continue` as described in [Continue conversations](</docs/en/headless#continue-conversations>).
@@ -721,7 +721,12 @@
Socket is closed
-`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. When nothing in the interrupted response had completed yet, Claude Code treats this as a dropped connection and retries it automatically, so the turn continues. Once Claude has completed a block of text or a tool call in the response, Claude Code keeps that output and ends the turn with an incomplete-response notice instead. Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
+`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. Claude Code either retries the request or keeps the partial response:
+
+ * If Claude hasn’t completed any text or tool call yet, Claude Code treats the failure as a dropped connection and retries the request automatically, so the turn continues.
+ * If Claude has completed a block of text or a tool call, Claude Code keeps what Claude completed and shows an incomplete-response notice. It still runs any tool calls Claude completed and continues the turn from their results.
+
+Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
* If you see this error, update to v2.1.214 or later with `claude update`, then send your message again
* If turns keep failing behind the same proxy after updating, work through Unable to connect to API and check the proxy setup in [Network configuration](</docs/en/network-config>)
@@ -1303,6 +1308,20 @@
+Your checkout has no branches
+
+A checkout can have commits but no branches: if you run `git init` followed by `git fetch <url>` and `git checkout FETCH_HEAD`, you get a detached HEAD with no refs. Claude Code packages your repository as a git bundle to upload it for an [ultrareview](</docs/en/ultrareview>), and it can’t bundle a repository that has no branches or other refs, so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts.
+
+ Your checkout has no branches (detached HEAD only), which cloud review can't bundle. Create one first — `git checkout -b <name>` — then rerun /code-review ultra.
+
+Before v2.1.221, Claude Code attempted to review every tracked file in this checkout, and the upload failed. **What to do:**
+
+ * Create a branch at your current commit with `git checkout -b <name>`, then rerun the review
+
+###
+
+
+
Failed to resume the conversation
Claude Code couldn’t read or process the saved transcript for the session you selected from the [`claude --resume` picker](</docs/en/sessions#use-the-session-picker>), so it ends the process rather than continue in a partially loaded state. The message includes the command to retry:
--- a/errors.md
+++ b/errors.md
@@ -101,6 +101,7 @@
`Claude Code process exited with code N`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
+`... is not matched by file permission checks`| Configuration warnings
Responses seem lower quality than usual| Response quality
##
@@ -1587,7 +1588,7 @@
Configuration warnings
-Claude Code writes these messages to stderr at startup rather than showing an error in the conversation. They report configuration it read but didn’t apply.
+Claude Code writes these messages to stderr at startup rather than showing an error in the conversation, except where an entry notes that it writes the message to the debug log instead. They report configuration it read but didn’t apply.
###
@@ -1604,6 +1605,26 @@
* Run `claude` in the directory and accept the trust dialog. The dialog appears even when a parent directory is already trusted, lists the rules being held back, and lets you decline and keep working without them. Before v2.1.200, no dialog appeared in that situation, so this step couldn’t be completed there.
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
* If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
+
+###
+
+
+
+Is not matched by file permission checks
+
+Claude Code found a `Write`, `NotebookEdit`, `MultiEdit`, or `Glob` [permission rule](</docs/en/permissions#read-and-edit>) with a path in one of your [settings files](</docs/en/settings#settings-files>), in [managed settings](</docs/en/permissions#managed-settings>), or in a `--allowedTools`, `--disallowedTools`, or `--settings` flag value. It checks file permissions against `Edit` and `Read` rules only, so it never consults a path rule that names one of the other file tools. It keeps the rule and changes nothing else; the warning names the rule, its source in parentheses, and the replacement to write:
+
+ Permission deny rule (.claude/settings.json): Write(docs/**) is not matched by file permission checks — only Edit(path) rules are. Use Edit(docs/**) instead (Edit rules cover all file-editing tools).
+
+**What to do:**
+
+ * Replace `Write(path)`, `NotebookEdit(path)`, and legacy `MultiEdit(path)` rules with `Edit(path)`. `Edit` rules cover all file-editing tools.
+ * Except in `--allowedTools`, where Claude Code accepts a `Glob` rule without warning, replace `Glob(path)` rules with `Read(path)`.
+ * Fix the rule at the source the warning names in parentheses: a settings file path, or the flag itself for `--allowed-tools` and `--disallowed-tools`. A `claude-settings-<hash>.json` path that doesn’t exist on disk stands for an inline `--settings` value; fix the JSON you pass to that flag.
+ * Leave bare tool-name rules such as `Write` or `Glob` alone. Claude Code matches them at the [tool level](</docs/en/permissions#match-all-uses-of-a-tool>) and doesn’t warn about them.
+ * If the source reads `managed policy settings`, forward the warning to whoever maintains your managed settings; you can’t clear it yourself.
+
+In a [background session](</docs/en/agent-view>) or with `--output-format json` or `stream-json`, Claude Code writes the warning to the debug log instead of stderr, so machine-read output stays clean; run with `--debug` to capture it at `~/.claude/debug/<session-id>.txt`. Before v2.1.210, Claude Code accepted these rules without a warning.
##
Show diff (158 lines)
--- a/errors.md
+++ b/errors.md
@@ -80,6 +80,7 @@
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
+`Shell command failed for pattern "!`git ... origin/HEAD...`"`| Command-line errors
`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Failed to resume the conversation`| Command-line errors
@@ -108,13 +109,33 @@
Automatic retries
-Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. As of v2.1.198, this covers connections that drop in the middle of a response before any visible output has streamed: Claude Code re-issues the request with the same backoff and the turn continues instead of stopping with a connection error. As of v2.1.199, temporary 429 throttles that don’t carry your plan’s quota headers are also retried when you’re signed in with a claude.ai subscription; earlier versions retried them only for API key and Enterprise sign-ins. Some failure classes aren’t retried, because a retry can’t succeed:
-
- * As of v2.1.199, a TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate, fails on the first attempt so the fix appears immediately instead of after the full retry budget. See SSL certificate errors. Transient TLS conditions such as a handshake timeout still retry.
- * As of v2.1.199, a server error that arrives after Claude has already streamed visible output keeps the partial response and appends an incomplete-response notice instead of retrying, since re-running the request could execute the same tools twice. Earlier versions discarded the partial output and reported the turn as an error.
- * An Amazon Bedrock streaming response with an unexpected content-type fails on the first attempt, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
-
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong. When you see one of the errors on this page, those retries have already been exhausted, unless it belongs to a class that isn’t retried, such as a certificate-validation failure. You can tune the behavior with these environment variables:
+Claude Code retries transient failures up to 10 times with exponential backoff before showing you an error. It doesn’t always retry a failure that arrives partway through Claude’s response. When you see one of the errors on this page, Claude Code has already exhausted those retries, unless the failure is one it doesn’t retry. Claude Code retries these failures:
+
+ * Server errors, overloaded responses, and request timeouts.
+ * Dropped connections. This covers a connection that drops in the middle of a request, before any part of Claude’s response has completed: Claude Code re-issues the request with the same backoff, and the turn continues. Before v2.1.198, Claude Code stopped the turn with a connection error when the connection dropped mid-response, before any visible output had streamed.
+ * Temporary 429 throttles. When you’re signed in with a claude.ai subscription, this includes 429 throttles that don’t carry your plan’s quota headers. Before v2.1.199, Claude Code retried those throttles only for API key and Enterprise sign-ins.
+
+Claude Code doesn’t retry these failures:
+
+ * A TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate. Claude Code reports the error on the first attempt, so you can fix the certificate setup right away; see SSL certificate errors. Claude Code still retries transient TLS conditions such as a handshake timeout. Before v2.1.199, Claude Code retried certificate failures through the full retry budget before showing the error.
+ * A server error, dropped connection, or stalled stream that arrives partway through a response, once Claude has completed a block of text or a tool call in that response: Claude Code could execute the same tool calls twice if it re-ran the request, so it keeps the completed output and ends the turn with an incomplete-response notice. Before v2.1.199, Claude Code discarded the partial output and reported the whole turn as an error when a server error arrived mid-stream.
+ * An Amazon Bedrock streaming response with an unexpected content-type, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
+
+###
+
+
+
+What you see while Claude Code retries or waits
+
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection, after which the turn either retries or ends with an error such as The response above may be incomplete. The banner clears on its own once data resumes or a retry succeeds; if it reappears on every attempt, treat it as a network issue. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong.
+
+###
+
+
+
+Tune retry behavior
+
+You can tune retry behavior with these environment variables:
Variable| Default| Effect
---|---|---
@@ -128,7 +149,7 @@
Server errors
-Most of these errors come from the inference provider’s infrastructure: Anthropic’s on the Anthropic API, and that provider’s on Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway. Auto mode cannot determine the safety of an action and Agent terminated early due to an API error also cover causes on your side, such as an Amazon Bedrock account that can’t invoke the classifier model or a subagent that hit a usage limit.
+Most of these errors come from the inference provider: Anthropic’s service on the Anthropic API, and the service behind that provider’s endpoint on Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway. Auto mode cannot determine the safety of an action and Agent terminated early due to an API error also cover causes on your side, such as an Amazon Bedrock account that can’t invoke the classifier model or a subagent that hit a usage limit.
###
@@ -185,7 +206,7 @@
The response above may be incomplete
-A streaming response failed after Claude had already produced visible output. Re-sending the request could run the same tool calls twice, so Claude Code keeps what already streamed and appends this notice instead of discarding the turn. Which variant you see names the cause:
+A streaming request failed after Claude had started producing a response. Re-sending the request could run the same tool calls twice, so Claude Code keeps the output Claude completed and appends this notice instead of discarding the turn. Which variant you see names the cause:
API Error: Server error mid-response. The response above may be incomplete.
API Error: Connection closed mid-response. The response above may be incomplete.
@@ -195,11 +216,13 @@
* `Connection closed mid-response`: the connection dropped.
* `Response stalled mid-stream`: the stream stopped sending data.
-**What to do:**
-
- * Read the response that streamed. Nothing has been lost, but the final sentences or tool calls may be missing.
- * Reply with `continue` to have Claude pick up where it stopped
- * If the same error appears before any visible output, Claude Code retries the request instead of finalizing it. See Automatic retries.
+Claude Code never shows this notice for a failure that happens before Claude starts producing a response: at that point it either retries the failure or ends the turn with a different error. See Automatic retries. **What to do:**
+
+ * In an interactive session, read the response that remains on screen: Claude Code keeps every block Claude completed before the error, but discards an interrupted final block when the turn ends, so the final sentences or tool calls may be missing. Reply with `continue` to have Claude pick up from its last completed block.
+ * In [non-interactive mode](</docs/en/headless>) (`-p`):
+ * With the default text output, Claude Code prints the last completed block of text it still holds from earlier in the turn, followed by this message. When it holds none, Claude Code prints this message alone, for example because Claude completed only tool calls before the error, or because Claude Code compacted the conversation mid-turn and cleared that text. Before v2.1.219, Claude Code printed only this message in `-p` text output and dropped the response it had already produced.
+ * With `--output-format json` or `stream-json`, Claude Code reports this message in the `result` field.
+ * To continue the turn, resume the session and send `continue` as described in [Continue conversations](</docs/en/headless#continue-conversations>).
###
@@ -414,7 +437,7 @@
* Upgrade to v2.1.174 or later if this appears in a background or cloud session and your credentials are already configured
* Confirm `ANTHROPIC_API_KEY`, `CLAUDE_CODE_OAUTH_TOKEN`, or your cloud provider credentials are set in the environment that launches the worker, not only in your interactive shell
- * For the Agent SDK, see [authentication setup](</docs/en/agent-sdk/overview#get-started>)
+ * For the Agent SDK, see [authentication setup in the quickstart](</docs/en/agent-sdk/quickstart#setup>)
* Run `/status` in an interactive session in the same environment to confirm which credential source resolves
###
@@ -697,7 +720,7 @@
Socket is closed
-The connection carrying a streaming response was closed while the response was still arriving, and the failure surfaced with the text `Socket is closed`. This happens almost exclusively on Windows behind a corporate proxy, when the proxy drops an established tunnel mid-response. Claude Code treats this as a dropped connection and retries it automatically, so the turn continues. Before v2.1.214, the retry didn’t cover this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
+`Socket is closed` means the connection carrying a streaming response was closed while the response was still arriving. The most common cause is a corporate proxy on Windows dropping an established tunnel mid-response. When nothing in the interrupted response had completed yet, Claude Code treats this as a dropped connection and retries it automatically, so the turn continues. Once Claude has completed a block of text or a tool call in the response, Claude Code keeps that output and ends the turn with an incomplete-response notice instead. Before v2.1.214, Claude Code didn’t retry this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
* If you see this error, update to v2.1.214 or later with `claude update`, then send your message again
* If turns keep failing behind the same proxy after updating, work through Unable to connect to API and check the proxy setup in [Network configuration](</docs/en/network-config>)
@@ -749,13 +772,13 @@
HTTP 403
x-deny-reason: host_not_allowed
-You may also see a TLS certificate that doesn’t match the destination’s real certificate. The cloud environment routes outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed environment whose outbound traffic is filtered to the environment’s allowlist. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/claude-code-on-the-web#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains but blocks everything else. **What to do:**
+You may also see a TLS certificate that doesn’t match the destination’s real certificate. Cloud sessions route outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed VM whose outbound traffic through the session’s network is filtered to the [cloud environment’s](</docs/en/cloud-environments>) allowlist; [GitHub operations](</docs/en/cloud-environments#github-proxy>) and MCP connector traffic use separate channels, which is why they can keep working while other hosts are blocked. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains and blocks other domains on that path. **What to do:**
* Open the routine for editing, or start a cloud session. Select the cloud icon showing your environment’s name, such as **Default** , to open the selector. Hover over your environment and click the settings icon.
- * In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/claude-code-on-the-web#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/cloud-environments#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
* Click **Save changes**. The next run uses the updated allowlist.
-See [Network access](</docs/en/claude-code-on-the-web#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
+See [Network access](</docs/en/cloud-environments#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
###
@@ -1129,7 +1152,7 @@
Command-line errors
-These errors come from the `claude` command line and its subcommands. Claude Code prints them before running your prompt or sending any API request.
+These errors come from the `claude` command line, its subcommands, and commands such as `/security-review` that gather context by running shell commands before their prompt runs.
###
@@ -1225,6 +1248,25 @@
* Check that the server starts and stays connected: run `claude mcp list` in the same directory and confirm the server is listed as connected
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
* If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
+
+###
+
+
+
+/security-review fails without origin/HEAD
+
+[`/security-review`](</docs/en/commands#all-commands>) builds its review context by diffing your branch against `origin/HEAD`, the local ref that records which branch is the default on your `origin` remote. When that ref doesn’t exist, the git commands that gather the diff fail and the review stops before it starts.
+
+ Error: Shell command failed for pattern "!`git diff --name-only origin/HEAD...`": [stderr]
+ fatal: ambiguous argument 'origin/HEAD...': unknown revision or path not in the working tree.
+ Use '--' to separate paths from revisions, like this:
+ 'git <command> [<revision>...] -- [<file>...]'
+
+The quoted command varies between runs: the review starts several `git` commands against `origin/HEAD` at once and reports whichever fails first, so you may see `git log` or a different `git diff` in its place. Git creates the ref only when the remote’s default branch is both advertised by the remote and covered by your fetch refspec. A full `git clone` of a remote with commits meets both conditions. Single-branch and CI checkouts fetch too narrow a refspec, a server-side HEAD left pointing at a branch nobody pushed advertises no default, and a repository with no `origin` remote, or one you never fetched, provides neither. **What to do:**
+
+ * Create the ref by naming your remote’s default branch: `git remote set-head origin <default-branch>`. This works whenever the local tracking ref `origin/<default-branch>` exists. If it doesn’t, as in single-branch clones, fetch the branch first: `git remote set-branches --add origin <branch> && git fetch origin`, then rerun the set-head command. Rerun `/security-review`.
+ * If you’d rather not name the branch, run `git fetch origin && git remote set-head origin --auto`, which asks the remote which branch is its default. It fails with `error: Cannot determine remote HEAD` when the remote advertises no default branch, because it is empty or its HEAD points at a branch nobody pushed; name the branch explicitly instead. It fails with `error: Not a valid ref` when your clone doesn’t fetch that branch; widen the refspec as above first.
+ * If the repository has no remote, add one with `git remote add origin <url>` and fetch before creating the ref. If the remote is empty, push your branch first with `git push -u origin HEAD` and name that branch in the set-head command; `origin/HEAD` then points at the branch you just pushed, so `/security-review` sees an empty diff until the branch diverges from it.
###
--- a/errors.md
+++ b/errors.md
@@ -67,7 +67,9 @@
`thinking.type.enabled is not supported for this model`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
+`<model> can't help with this. Start a new session to continue`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
+`<model>'s safeguards flagged this message`| Request errors
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
@@ -1049,9 +1051,11 @@
The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID you can quote to support if you believe the refusal is incorrect.
- API Error: Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.
-
-The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), this message also covers requests the model’s safety measures flagged as a cybersecurity topic. See Safety measures flagged a cybersecurity topic. **What to do:**
+ API Error: Opus 4.6 can't help with this. Start a new session to continue.
+
+ Send feedback with /feedback or learn more: https://www.anthropic.com/legal/aup
+
+The message names the model that declined, or `Claude` when no model is recorded. In [non-interactive mode](</docs/en/headless>) (`-p`), the final line reads `Learn more:` followed by the link, without the `/feedback` mention. The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), this message also covers requests the model’s safety measures flagged as a cybersecurity topic. See Safety measures flagged a cybersecurity topic. Before v2.1.219, the message read `Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.` **What to do:**
* Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
* If you can’t identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
@@ -1065,16 +1069,14 @@
The model’s safety measures flagged content in the conversation as a cybersecurity topic. The message names the model that flagged the request:
- API Error: Opus 4.8 has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude.
-
- If you were not engaging in a cybersecurity topic, please send feedback via /feedback.
-
-The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. The safeguard itself is server-side and predates v2.1.203; this release changed only the wording of the message and the page it links to. What you see depends on your provider and mode:
+ API Error: Opus 4.8's safeguards flagged this message. Our intentionally broad safeguards allow us to deliver more capabilities faster, but can sometimes flag legitimate cybersecurity work. Apply to the Cyber Verification Program to reduce these interruptions. Send feedback with /feedback or learn more: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude
+
+The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. What you see depends on your provider and mode:
* On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead.
- * [Non-interactive mode](</docs/en/headless>) omits the `/feedback` sentence.
-
-Before v2.1.203, the message read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+ * In [non-interactive mode](</docs/en/headless>), the final sentence reads `Learn more:` followed by the link, without the `/feedback` mention.
+
+The safeguard itself is server-side and predates v2.1.203; client releases since then have changed only the message’s wording. From v2.1.203 through v2.1.218, the message read `<model> has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center:` followed by the same help-center link, and interactive sessions appended `If you were not engaging in a cybersecurity topic, please send feedback via /feedback.` Before v2.1.203, it read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
* If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
* If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
@@ -1336,7 +1338,7 @@
* **Unrecognized** : the entry matches no tool name, usually a typo such as `Grpe` for `Grep`.
* **Not available to subagents** : the entry names a real tool that [subagents can’t use](</docs/en/sub-agents#available-tools>). Background subagents keep a smaller built-in tool set, so an entry that only a foreground subagent can use lands here when the subagent would run in the background, which is the default. If you list `Agent`, the message reports it under the next group instead.
- * **Matched no tools in this session** : the entry is valid but no tool in the current session matches it right now, such as `mcp__github__*` with no GitHub MCP server connected, or `Agent` while [nested spawning](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) is off.
+ * **Matched no tools in this session** : the entry is valid but no tool in the current session matches it right now, such as `mcp__github__*` with no GitHub MCP server connected, or `Agent` for a subagent at the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>).
Omitting the `tools` field never triggers this refusal. If you leave the `tools` list empty, or `disallowedTools` removes every entry in it, Claude Code also skips the refusal and launches the subagent without tools. Before v2.1.208, the subagent launched with no tools and could return an empty or confusing result.
@@ -1348,7 +1350,7 @@
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
* For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP` or `TaskCreate`, remove the entry or ask Claude to run the subagent in the foreground
* Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
- * For a `tools` list that contains only `Agent`, allow [nested spawning](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: `Agent` isn’t available inside a subagent by default, so a list with nothing else in it resolves to no tools
+ * For a `tools` list that contains only `Agent`, raise the [depth limit](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: Claude Code withholds `Agent` at that limit, so a list with nothing else in it resolves to no tools
###
--- a/errors.md
+++ b/errors.md
@@ -940,6 +940,7 @@
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
+ * A newly launched model can be available on the Anthropic API before Amazon Bedrock, Google Cloud’s Agent Platform, or Microsoft Foundry offers it. If you pinned a new model ID on one of those providers and see this error, check your provider’s model catalog for availability in your region, and keep the previous version pinned until the new one appears there.
* Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
@@ -998,15 +999,15 @@
thinking.type.enabled is not supported for this model
-Your Claude Code version is older than the minimum for Sonnet 5, Opus 4.8, or Opus 4.7. The CLI sent a thinking configuration the model no longer accepts.
+Your Claude Code version is older than the minimum for the selected model. The CLI sent a thinking configuration the model no longer accepts.
API Error: 400 ... "thinking.type.enabled" is not supported for this model. Use "thinking.type.adaptive" and "output_config.effort" to control thinking behavior.
**What to do:**
- * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later
+ * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later. Opus 5 needs v2.1.219 or later
* If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
- * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later
+ * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later. Opus 5 needs TypeScript SDK v0.3.219 or later
###
@@ -1570,7 +1571,7 @@
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
- * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5 moves the session to the default Opus model and shows a notice in the transcript
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5 and Opus 5 moves the session to the flagged category’s fallback model, when that category has one, and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
Show diff (166 lines)
--- a/errors.md
+++ b/errors.md
@@ -1,4 +1,4 @@
-This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). These errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For surface-specific issues, see the troubleshooting section on that surface’s page.
+This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). Except for Wrapper and IDE errors, which the launching program prints rather than Claude Code itself, these errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For other surface-specific issues, see the troubleshooting section on that surface’s page.
Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
@@ -37,6 +37,7 @@
`Routines are disabled by your organization's policy`| Authentication
`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
+`API Error: 401 Invalid authentication credentials`| Authentication
`Login expired · Please run /login`| Authentication
`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`does not meet scope requirement user:profile`| Authentication
@@ -77,6 +78,7 @@
`Error: Workspace not trusted` when starting Remote Control| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
+`Input must be provided either through stdin or as a prompt argument when using --print`| Command-line errors
`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
`Failed to resume the conversation`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
@@ -93,6 +95,7 @@
`This session was running agent '<name>', which is no longer available`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
+`Claude Code process exited with code N`| Wrapper and IDE errors
`Restored the code, but skipped N files`| Rewind warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -123,7 +126,7 @@
Server errors
-These errors come from the inference provider rather than your account or request. On the Anthropic API that means Anthropic infrastructure. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway it means that provider’s infrastructure.
+Most of these errors come from the inference provider’s infrastructure: Anthropic’s on the Anthropic API, and that provider’s on Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway. Auto mode cannot determine the safety of an action and Agent terminated early due to an API error also cover causes on your side, such as an Amazon Bedrock account that can’t invoke the classifier model or a subagent that hit a usage limit.
###
@@ -202,15 +205,15 @@
Auto mode cannot determine the safety of an action
-The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on why the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is overloaded:
+The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on how the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is unavailable:
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait briefly and then try this action again.
-**What to do:**
-
- * Retry after a few seconds; Claude sees the same message and usually retries on its own
+More than one failure produces this same message, so the message alone doesn’t tell you the cause. When the classifier model is overloaded or rate-limited, the failure is transient and retrying works. On [Amazon Bedrock](</docs/en/amazon-bedrock>), including the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), the same message also appears when your AWS account can’t invoke the model named in the message, and that failure repeats on every retry until the model is granted. **What to do:**
+
+ * Retry after a few seconds; Claude sees the same message and usually retries on its own. A transient failure is unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
- * This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
+ * On Amazon Bedrock, if the message returns on every retry, check that your account can invoke the model it names: for standard Amazon Bedrock models, confirm your [IAM policy](</docs/en/amazon-bedrock#iam-configuration>) allows invoking it; for Mantle model IDs, [contact your AWS account team](</docs/en/amazon-bedrock#mantle-endpoint-errors>)
When a classifier request fails because your OAuth token expired or was rotated by another session, Claude Code refreshes the token and retries the request once, so a routine token expiry doesn’t surface as this message. Before v2.1.216, an expired or rotated token failed each classifier request, and auto mode denied every checked action with this message until the token was refreshed. When the classifier returned an unparseable response:
@@ -263,7 +266,7 @@
Usage limits
-These errors mean a quota tied to your account or plan has been reached. They are distinct from server errors, which affect everyone.
+Most errors in this section mean a quota tied to your account or plan has been reached. Two work differently: `Server is temporarily limiting requests` is a server-side throttle unrelated to your plan quota, and `Usage credits required for 1M context` is an entitlement check rather than an exhausted quota.
###
@@ -549,6 +552,23 @@
* If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
* For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
* For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
+
+###
+
+
+
+API Error: 401 Invalid authentication credentials
+
+The API recognized the format of your credential but rejected the account or organization behind it. Anthropic returns this message when a credential was recently revoked, when an organization was disabled or removed your access, or when the account itself was deactivated, so an expired token isn’t the cause. The credential can be your saved login or an approved `ANTHROPIC_API_KEY`, and the fix differs, so start by running `/status` to see which one is active.
+
+ Please run /login · API Error: 401 Invalid authentication credentials
+
+**What to do:**
+
+ * If `/status` shows an `API key` row, an approved [`ANTHROPIC_API_KEY`](</docs/en/authentication#authentication-precedence>) is the active credential and takes precedence over your login, so `/login` doesn’t replace it. Rotate the key in the Claude Console, or run `unset ANTHROPIC_API_KEY` to fall back to your subscription.
+ * If `/status` shows only your login, run `/login` once. If the credential was revoked, a fresh login replaces it.
+ * If the same message returns for the same login account, the account or organization is no longer active. Check the account and organization that `/status` reports, and ask your organization admin to restore access.
+ * If [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at an [LLM gateway](</docs/en/llm-gateway>), the text after `401` is your gateway’s message rather than Anthropic’s, and `/login` doesn’t change it. Fix the credential your gateway expects instead.
###
@@ -1207,6 +1227,21 @@
+Input must be provided when using —print
+
+Bare `claude` needs stdout to be a terminal to start the interactive UI. When stdout is redirected, or the console isn’t a real terminal, such as PowerShell ISE and some IDE output panes, `claude` runs [non-interactively](</docs/en/headless>) instead. That is the same mode as `claude -p`, which requires a prompt, so the message names `--print` even when you didn’t pass the flag. Passing `-p`/`--print` with no prompt and nothing piped on stdin produces the same error anywhere.
+
+ Error: Input must be provided either through stdin or as a prompt argument when using --print
+
+**What to do:**
+
+ * For interactive use, run `claude` in a real terminal: Windows Terminal or the PowerShell console rather than ISE, and your IDE’s integrated terminal rather than an output pane
+ * For one-shot use, pass the prompt: `claude -p "your question"`, or pipe it with `echo "your question" | claude -p`
+
+###
+
+
+
Diff is too large for ultrareview
The diff between your branch and the base branch, including uncommitted and staged changes, exceeds the size limits for an [ultrareview](</docs/en/ultrareview>), so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts. A refused review doesn’t use a free run and doesn’t bill usage credits. The message names the limits in effect, the size of your diff, and the files that contribute the most changed lines. Before v2.1.216, the message showed only the raw diff statistics.
@@ -1373,7 +1408,7 @@
Commands refused in a background session
-Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message, and the session appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, Claude Code refused these commands outright: in v2.1.214 and v2.1.215 the message told you to attach and run the command again, and from v2.1.208 through v2.1.212 Claude Code refused them even while a terminal was attached, with a message naming a form that works there, such as `Can't open MCP settings in a background session`. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
+Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message, and the session appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, the session didn’t appear under **Needs input** after one of these refusals. In v2.1.213 through v2.1.215, the commands still worked while a terminal was attached, and the refusal message told you to attach and run the command again. From v2.1.208 through v2.1.212, Claude Code refused them even while a terminal was attached, with a message such as `Can't open MCP settings in a background session`; on those versions, run the command from a regular `claude` session instead, or upgrade. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
Can't open MCP settings while no terminal is attached to this background session. This session now shows "needs input" in agent view — open it and run /mcp to manage servers, or use `/mcp enable|disable|reconnect <server>` to steer without the panel.
@@ -1404,7 +1439,7 @@
Session agent no longer available
-You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and no agent by that name exists anymore. Claude Code searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from, and warns when neither has the agent. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
+You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and Claude Code didn’t find an agent by that name. It searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
This session was running agent 'code-reviewer', which is no longer available (no agent by that name in /home/you/project). Continuing with the default tools and system prompt — the agent's tool restrictions no longer apply. To restore it, re-create the agent, or resume with an explicit --agent <name>.
@@ -1445,6 +1480,30 @@
* If the message reads `Couldn't start the session`, upgrade to v2.1.212 or later. On earlier versions you can also run `claude daemon run` in a separate terminal first, then start the background session again. That command runs the background service in the terminal’s foreground, so the service lasts only as long as that terminal stays open.
* If the error appears on v2.1.212 or later, ask your Windows administrator to allow the Claude Code executable in the restriction policy
* If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
+
+##
+
+
+
+Wrapper and IDE errors
+
+These errors come from the program that launched Claude Code for you, such as an IDE extension or an [Agent SDK](</docs/en/agent-sdk/overview>) application, rather than from Claude Code itself.
+
+###
+
+
+
+Claude Code process exited with code N
+
+The underlying `claude` process exited with a non-zero code. The exit code alone doesn’t say what failed: the real error is in the process’s own output, which the wrapper appends when it captured any and otherwise keeps in its logs.
+
+ Error: Claude Code process exited with code 1
+
+**What to do:**
+
+ * In VS Code, follow the **View output logs** link shown with the error to see the underlying failure
+ * Run `claude` in a terminal in the same project. The failure usually reproduces there with its real error message, which you can then look up on this page.
+ * Run `claude doctor` in a terminal to check the installation and configuration
##
--- a/errors.md
+++ b/errors.md
@@ -1296,7 +1296,13 @@
Agent would be spawned with zero tools
-Nothing in a [subagent’s `tools` list](</docs/en/sub-agents#supported-frontmatter-fields>) resolved to a tool, so Claude Code refuses to launch the subagent rather than start one that can’t act. The message groups the entries by why they didn’t resolve: not a recognized tool, a tool that isn’t available to subagents, or recognized but matching no tool in the current session. Omitting the `tools` field never triggers this refusal. An MCP server pattern such as `mcp__github__*` isn’t exempt: when no connected tool comes from that server, the launch is refused with the pattern in the matched-nothing group. Before v2.1.208, the subagent launched with no tools and returned an empty or confusing result.
+Every entry in the subagent’s [`tools` list](</docs/en/sub-agents#supported-frontmatter-fields>) failed to match a usable tool, so Claude Code refused to launch the subagent: with no tools, it couldn’t act. The message groups your entries by what went wrong:
+
+ * **Unrecognized** : the entry matches no tool name, usually a typo such as `Grpe` for `Grep`.
+ * **Not available to subagents** : the entry names a real tool that [subagents can’t use](</docs/en/sub-agents#available-tools>). Background subagents keep a smaller built-in tool set, so an entry that only a foreground subagent can use lands here when the subagent would run in the background, which is the default. If you list `Agent`, the message reports it under the next group instead.
+ * **Matched no tools in this session** : the entry is valid but no tool in the current session matches it right now, such as `mcp__github__*` with no GitHub MCP server connected, or `Agent` while [nested spawning](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) is off.
+
+Omitting the `tools` field never triggers this refusal. If you leave the `tools` list empty, or `disallowedTools` removes every entry in it, Claude Code also skips the refusal and launches the subagent without tools. Before v2.1.208, the subagent launched with no tools and could return an empty or confusing result.
Agent 'code-reviewer' would be spawned with zero tools — refusing. Its tools list resolved to nothing: unrecognized [Grpe]. Fix the agent's tools frontmatter or pass a different subagent_type.
@@ -1304,7 +1310,9 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
- * To give the subagent every [subagent-available](</docs/en/sub-agents#available-tools>) tool the parent has, delete the `tools` field instead of listing tools
+ * For a tool that [background subagents drop](</docs/en/sub-agents#available-tools>), such as `LSP` or `TaskCreate`, remove the entry or ask Claude to run the subagent in the foreground
+ * Delete the `tools` field instead of listing tools to give the subagent every [tool available to subagents](</docs/en/sub-agents#available-tools>)
+ * For a `tools` list that contains only `Agent`, allow [nested spawning](</docs/en/sub-agents#let-subagents-spawn-their-own-subagents>) or give the agent at least one other tool: `Agent` isn’t available inside a subagent by default, so a list with nothing else in it resolves to no tools
###
--- a/errors.md
+++ b/errors.md
@@ -26,7 +26,7 @@
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
-`Failed to update spend limit` / `Failed to update auto-reload` / `Could not update your spend limit`| Usage limits
+`Could not update your spend limit`| Usage limits
`Not logged in · Please run /login`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
@@ -356,17 +356,15 @@
-Failed to update spend limit or auto-reload
-
-The server rejected a spend limit or auto-reload change you made from the [`/usage-credits` dialog](</docs/en/costs#set-a-spend-limit-on-pro-and-max>) or from the prompt that appears when you reach your spend limit.
-
- Failed to update spend limit: <reason from the server>
- Failed to update auto-reload: <reason from the server>
+Could not update your spend limit
+
+The server rejected a spend limit change you made from the prompt that appears when you reach your spend limit.
+
Could not update your spend limit: <reason from the server>
-When the server explains the rejection, for example a ceiling on auto-reload amounts, the message ends with that reason, and retrying the same value fails again. When the failure has no server-provided reason, such as a dropped connection, the message is the generic form without the trailing reason, and the spend limit prompt adds `Press Enter to retry`. Before v2.1.216, Claude Code showed the generic form for every failure. **What to do:**
-
- * If the message includes a reason, enter a value that satisfies it, such as a lower amount
+When the server explains the rejection, the message ends with that reason, and retrying the same value fails again. When the failure has no server-provided reason, such as a dropped connection, the message reads `Could not update your spend limit. Press Enter to retry.` and retrying can succeed. Before v2.1.216, Claude Code showed the generic form for every failure. **What to do:**
+
+ * If the message includes a reason, choose a limit that satisfies it, such as a lower amount
* If the message shows only the generic form, retry; the failure may be transient
* If the change keeps failing, make it from your [claude.ai billing settings](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) in the browser instead
@@ -1466,8 +1464,9 @@
**What to do:**
- * Run Claude Code with `--debug` and repeat the restore. The debug log names each skipped path.
- * If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, restore its contents from [version control](</docs/en/checkpointing#not-a-replacement-for-version-control>) instead
+ * Identify which files were skipped so you can handle each one with the steps below. The message gives only a count, so list your project’s links to find them: `find . -type l` for symlinks and `find . -type f -links +1` for hard-linked files.
+ * If debug logging is on, the log at `~/.claude/debug/<session-id>.txt` names each skipped path as the restore runs. Turn it on with `/debug` before your next restore to skip the search.
+ * If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, the rewind left its contents alone. To undo the session’s changes to it, ask Claude to reverse the edit or edit the file yourself
* If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
##
Show diff (362 lines)
--- a/errors.md
+++ b/errors.md
@@ -26,6 +26,7 @@
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
+`Failed to update spend limit` / `Failed to update auto-reload` / `Could not update your spend limit`| Usage limits
`Not logged in · Please run /login`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
@@ -43,6 +44,7 @@
`AWS authentication failed`| Authentication
`AWS default-chain credential resolve timed out`| Authentication
`Unable to connect to API`| Network
+`Socket is closed`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
`SSL certificate verification failed`| Network
@@ -50,6 +52,7 @@
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`Couldn't reconnect to your Remote Control session`| Network
`Prompt is too long`| Request errors
+`Context exceeds the ...-token limit by ... tokens` in `/context` output| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
`Image was too large`| Request errors
@@ -70,8 +73,12 @@
`Download timed out: exceeded the total deadline`| Installation errors
`--bg and --print conflict`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
+`Error: Settings file exceeds the 2MiB limit`| Command-line errors
+`Error: Workspace not trusted` when starting Remote Control| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
+`Diff is too large for ultrareview` / `PR #<N> is too large for ultrareview`| Command-line errors
+`Failed to resume the conversation`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
@@ -79,10 +86,14 @@
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
+`pkill: refusing to run`| Tool errors
+`Can't open MCP settings while no terminal is attached to this background session`| Background session errors
`Can't open MCP settings in a background session`| Background session errors
`This session has no saved transcript`| Background session errors
+`This session was running agent '<name>', which is no longer available`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`EUNKNOWN: unknown error, uv_spawn`| Background session errors
+`Restored the code, but skipped N files`| Rewind warnings
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -98,7 +109,7 @@
* As of v2.1.199, a server error that arrives after Claude has already streamed visible output keeps the partial response and appends an incomplete-response notice instead of retrying, since re-running the request could execute the same tools twice. Earlier versions discarded the partial output and reported the turn as an error.
* An Amazon Bedrock streaming response with an unexpected content-type fails on the first attempt, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
-While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. When you see one of the errors on this page, those retries have already been exhausted, unless it belongs to a class that isn’t retried, such as a certificate-validation failure. You can tune the behavior with these environment variables:
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. While Claude is consulting the [advisor](</docs/en/advisor>), the banner appears after 90 seconds without data instead of 20, because a long advisor review can send nothing for well over 20 seconds. Before v2.1.214, the 20-second threshold applied during advisor calls too, so the banner appeared during advisor reviews even when nothing was wrong. When you see one of the errors on this page, those retries have already been exhausted, unless it belongs to a class that isn’t retried, such as a certificate-validation failure. You can tune the behavior with these environment variables:
Variable| Default| Effect
---|---|---
@@ -201,7 +212,7 @@
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
* This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
-When the classifier returned an unparseable response:
+When a classifier request fails because your OAuth token expired or was rotated by another session, Claude Code refreshes the token and retries the request once, so a routine token expiry doesn’t surface as this message. Before v2.1.216, an expired or rotated token failed each classifier request, and auto mode denied every checked action with this message until the token was refreshed. When the classifier returned an unparseable response:
Auto mode could not evaluate this action and is blocking it for safety — run with --debug for details
@@ -340,6 +351,24 @@
* Add credits at [platform.claude.com/settings/billing](<https://platform.claude.com/settings/billing>), and consider enabling auto-reload there so the balance refills before it hits zero
* Switch to subscription authentication with `/login` if you have a Pro, Max, Team, or Enterprise plan
* Set per-workspace spend caps in the Console to prevent a single project from draining the org balance. See [Manage costs effectively](</docs/en/costs>).
+
+###
+
+
+
+Failed to update spend limit or auto-reload
+
+The server rejected a spend limit or auto-reload change you made from the [`/usage-credits` dialog](</docs/en/costs#set-a-spend-limit-on-pro-and-max>) or from the prompt that appears when you reach your spend limit.
+
+ Failed to update spend limit: <reason from the server>
+ Failed to update auto-reload: <reason from the server>
+ Could not update your spend limit: <reason from the server>
+
+When the server explains the rejection, for example a ceiling on auto-reload amounts, the message ends with that reason, and retrying the same value fails again. When the failure has no server-provided reason, such as a dropped connection, the message is the generic form without the trailing reason, and the spend limit prompt adds `Press Enter to retry`. Before v2.1.216, Claude Code showed the generic form for every failure. **What to do:**
+
+ * If the message includes a reason, enter a value that satisfies it, such as a lower amount
+ * If the message shows only the generic form, retry; the failure may be transient
+ * If the change keeps failing, make it from your [claude.ai billing settings](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) in the browser instead
##
@@ -646,6 +675,17 @@
+Socket is closed
+
+The connection carrying a streaming response was closed while the response was still arriving, and the failure surfaced with the text `Socket is closed`. This happens almost exclusively on Windows behind a corporate proxy, when the proxy drops an established tunnel mid-response. Claude Code treats this as a dropped connection and retries it automatically, so the turn continues. Before v2.1.214, the retry didn’t cover this failure, and the turn stopped with an error containing `Socket is closed`. **What to do:**
+
+ * If you see this error, update to v2.1.214 or later with `claude update`, then send your message again
+ * If turns keep failing behind the same proxy after updating, work through Unable to connect to API and check the proxy setup in [Network configuration](</docs/en/network-config>)
+
+###
+
+
+
Bedrock streaming response has an unexpected content-type
A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`, and Claude Code rejects a successful streaming response that reports a different content-type instead of decoding a body it can’t read. The request isn’t retried.
@@ -746,6 +786,27 @@
+Context exceeds the token limit
+
+`/context` shows this warning at the top of its output when the conversation has grown past the model’s context window. Requests fail with `Prompt is too long` until you free space.
+
+ Context exceeds the 200k-token limit by 94k tokens — run /compact or /clear to continue.
+
+When the limit you exceeded is a compaction window smaller than the model’s context window, such as the 200K boundary on 1M-context models, the warning reads differently. Requests still succeed past a compaction window; run the named command to bring usage back under it.
+
+ Context is 94k tokens past the 200k-token compaction window — run /compact to reduce usage.
+
+Both forms name `/clear` instead of `/compact` when you have set [`DISABLE_COMPACT`](</docs/en/env-vars>). **What to do:**
+
+ * Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
+ * For more ways to reduce usage, see Prompt is too long
+
+Before v2.1.216, `/context` showed usage above 100% with no warning line explaining what that meant or how to recover.
+
+###
+
+
+
Error during compaction: Conversation too long
`/compact` itself failed because there is not enough free context to hold the summary it produces.
@@ -756,6 +817,8 @@
* Press Esc twice to open the message list and step back several turns. This drops the most recent messages from context. Then run `/compact` again.
* If stepping back doesn’t free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
+
+This message and other `/compact` failures display in error styling. Before v2.1.216, they rendered in the same dim style as successful command output, so you could read a failed compaction as a success.
###
@@ -814,11 +877,11 @@
PDF errors
-The PDF you attached couldn’t be processed.
-
- PDF too large (max 100 pages, 32 MB). Try splitting it or extracting text first.
- PDF is password protected. Try removing protection or extracting text first.
- The PDF file was not valid. Try converting to a different format first.
+The PDF you attached couldn’t be processed. The messages are shown here in their non-interactive form; in an interactive session they instead prompt you to double press esc and try again.
+
+ PDF too large (max 100 pages, 20MB). Try reading the file a different way (e.g., extract text with pdftotext).
+ PDF is password protected. Try using a CLI tool to extract or convert the PDF.
+ The PDF file was not valid. Try converting it to text first (e.g., pdftotext).
**What to do:**
@@ -1082,6 +1145,39 @@
+Settings file exceeds the 2MiB limit
+
+The file you passed to [`--settings`](</docs/en/cli-reference#cli-flags>) is larger than 2 MiB, so `claude` exits with code 1 at startup instead of loading it. A settings file is a small JSON document, so a file this large usually means the path points at the wrong file. Before v2.1.214, Claude Code read the file with no size check, and a multi-gigabyte file or a device file such as `/dev/zero` grew memory without bound.
+
+ Error: Settings file exceeds the 2MiB limit: /path/to/settings.json
+
+Claude Code rejects a `--settings` path that isn’t a regular file the same way: a device, FIFO, or socket reports `Error: Cannot use settings file (Not a regular file (device, FIFO, or socket))` followed by the path, and a directory reports an `EISDIR` reason. **What to do:**
+
+ * Point `--settings` at a regular JSON settings file under 2 MiB. See [Settings](</docs/en/settings>) for the format.
+
+###
+
+
+
+Workspace not trusted when starting Remote Control
+
+You started [Remote Control](</docs/en/remote-control>) server mode with `claude remote-control` or its `claude rc` alias in a directory you haven’t trusted. The command doesn’t show the workspace trust dialog itself, so it exits with code 1 and names the fix:
+
+ Error: Workspace not trusted. Please run `claude` in /Users/you/project first to review and accept the workspace trust dialog.
+
+In your home directory the message is different, because the workspace trust dialog never saves trust for the home directory, so accepting it there can’t satisfy this check. Before v2.1.214, the home directory showed the message above, whose advice can’t succeed there.
+
+ Error: Workspace not trusted. /Users/you is your home directory, and for security home-directory trust is never saved, so running `claude` here first won't help. Run `claude rc` from a project directory instead (run `claude` there once to accept the trust dialog).
+
+**What to do:**
+
+ * Run `claude` in the directory, accept the [workspace trust dialog](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then run `claude remote-control` again
+ * In your home directory, change to a project directory and start Remote Control there
+
+###
+
+
+
Could not import a server from Claude Desktop
Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import and none of the selected servers were added.
@@ -1109,6 +1205,37 @@
* Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
* If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
+###
+
+
+
+Diff is too large for ultrareview
+
+The diff between your branch and the base branch, including uncommitted and staged changes, exceeds the size limits for an [ultrareview](</docs/en/ultrareview>), so `/code-review ultra` and the `claude ultrareview` subcommand refuse the review before the cloud session starts. A refused review doesn’t use a free run and doesn’t bill usage credits. The message names the limits in effect, the size of your diff, and the files that contribute the most changed lines. Before v2.1.216, the message showed only the raw diff statistics.
+
+ Diff is too large for ultrareview: 812 files, 96,410 lines changed (limits: 500 files, 8,000 lines). Largest files: package-lock.json (41,904 lines), dist/bundle.js (18,210 lines), src/generated/api.ts (9,876 lines). Pass a closer base branch (`/code-review ultra <branch>`) to narrow the scope, or split the change.
+
+Reviewing a pull request applies the same limits; that form of the message begins `PR #<N> is too large for ultrareview` and names the PR’s file and line counts. **What to do:**
+
+ * Pass a base branch closer to your work, such as `/code-review ultra develop`, so the review covers only the diff against that branch
+ * Split the change into smaller branches and review each one. The files the message names contribute the most changed lines, so start by moving those to their own branch.
+
+###
+
+
+
+Failed to resume the conversation
+
+Claude Code couldn’t read or process the saved transcript for the session you selected from the [`claude --resume` picker](</docs/en/sessions#use-the-session-picker>), so it ends the process rather than continue in a partially loaded state. The message includes the command to retry:
+
+ Failed to resume the conversation.
+ Run claude --resume <session-id> to retry, or claude to start a new session.
+
+Claude Code exits with code 1 after showing the message. The `/resume` picker inside a running session reports `Failed to resume conversation` in the conversation instead, and your current session keeps running. Before v2.1.216, a failed resume from the `claude --resume` picker stayed on the `Resuming conversation…` spinner indefinitely instead of showing this message. **What to do:**
+
+ * Run `claude --resume <session-id>` with the session ID from the message to retry
+ * If the retry fails again, run `claude` to start a new session
+
##
@@ -1179,7 +1306,7 @@
* Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
* Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
- * To give the subagent every tool the parent has, delete the `tools` field instead of listing tools
+ * To give the subagent every [subagent-available](</docs/en/sub-agents#available-tools>) tool the parent has, delete the `tools` field instead of listing tools
###
@@ -1211,6 +1338,21 @@
* Let Claude rewrite `MEMORY.md`, or ask it to: keep one line per entry, move detail into topic files, and merge or drop stale entries
* To trim the index yourself, see [Audit and edit your memory](</docs/en/memory#audit-and-edit-your-memory>)
+###
+
+
+
+pkill pattern matches the Claude Code process
+
+A `pkill` command in a Bash tool call used a pattern, typically with `-f`, that matches the Claude Code process itself, so Claude Code refuses the command instead of letting it end the session. Claude Code tests the pattern with `pgrep` before running `pkill` and refuses when its own process ID is in the result. The check runs on Linux only; on macOS, `pkill` runs unmodified. Before v2.1.214, the command ran, and a matching pattern killed the Claude Code session mid-turn.
+
+ pkill: refusing to run — this pattern matches the Claude CLI process (PID 12345). Narrow the pattern, or target your own children with `pkill -P $$ ...`.
+
+The refusal appears in the Bash tool result rather than as a banner in your terminal, and Claude usually adjusts the command on its own. **What to do:**
+
+ * Narrow the pattern so it matches only the intended process, for example the full path of the target binary rather than a short substring
+ * To stop processes started by the current shell, use `pkill -P $$` with the pattern, which limits the match to the shell’s own child processes
+
##
@@ -1225,14 +1367,14 @@
Commands refused in a background session
-Commands that open an interactive dialog are refused in a background session with a message naming a form that works there or telling you to run the command from a regular terminal. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu are all refused this way. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, the `/model` picker was also refused in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command that was refused. The `/mcp` settings list reports:
-
- Can't open MCP settings in a background session — use `/mcp enable|disable|reconnect <server>` to steer, or run /mcp from an interactive terminal to authenticate.
-
-**What to do:**
-
- * Use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`
- * For sign-in and authorization flows, run the command from a regular `claude` session in a terminal
+Commands that open an interactive dialog can’t do so while no terminal is attached to a background session. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu respond with a message, and the session appears under **Needs input** in [agent view](</docs/en/agent-view>) so you can find it, attach, and run the command again. While a terminal is attached, these commands work normally. Before v2.1.216, Claude Code refused these commands outright: in v2.1.214 and v2.1.215 the message told you to attach and run the command again, and from v2.1.208 through v2.1.212 Claude Code refused them even while a terminal was attached, with a message naming a form that works there, such as `Can't open MCP settings in a background session`. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, Claude Code also refused the `/model` picker in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command. The `/mcp` settings list reports:
+
+ Can't open MCP settings while no terminal is attached to this background session. This session now shows "needs input" in agent view — open it and run /mcp to manage servers, or use `/mcp enable|disable|reconnect <server>` to steer without the panel.
+
+**What to do:**
+
+ * Attach to the session from agent view, where it’s listed under **Needs input** , and run the command again
+ * Or use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`, which work without attaching
###
@@ -1248,6 +1390,23 @@
* The conversation you backgrounded from is intact: resume it with [`claude --resume`](</docs/en/sessions>) or keep working in it
* To start the stopped session fresh anyway, run `claude respawn <id>` with the ID from the message, or press `Enter` twice on its row in agent view
+ * If the session did finish a response and you still see this refusal on a version before v2.1.214, an unreadable folder in `~/.claude/projects` could make the transcript scan miss the saved conversation; update to v2.1.214 or later, which tolerates unreadable folders during the scan
+
+###
+
+
+
+Session agent no longer available
+
+You resumed a session that was running a [custom agent](</docs/en/sub-agents#invoke-subagents-explicitly>), started with `--agent` or the `agent` setting, and no agent by that name exists anymore. Claude Code searches the session’s original directory first, when you have [trusted that workspace](</docs/en/permissions#project-allow-rules-and-workspace-trust>), then the directory you resume from, and warns when neither has the agent. The session still resumes, but with the default tools and system prompt, so the agent’s tool restrictions no longer apply:
+
+ This session was running agent 'code-reviewer', which is no longer available (no agent by that name in /home/you/project). Continuing with the default tools and system prompt — the agent's tool restrictions no longer apply. To restore it, re-create the agent, or resume with an explicit --agent <name>.
+
+The warning names only the directories Claude Code searched, and it appears in the resumed conversation whether you wake a [background session](</docs/en/agent-view>), run `/resume` or `claude --resume`, or resume in [non-interactive mode](</docs/en/headless>), where it also goes to stderr. Sessions using `--input-format stream-json` don’t show it, because the Agent SDK supplies agents after startup. Claude Code doesn’t save the fallback to the session, so the warning repeats on each resume until you act. The built-in `claude` agent doesn’t trigger the warning, since falling back to the default toolset changes nothing for it. Before v2.1.216, Claude Code silently continued as the default agent, and the lookup covered only the directory you resumed from, so a project-scoped agent was lost on any resume from another directory. **What to do:**
+
+ * Re-create the agent file at `.claude/agents/<name>.md` in the session’s project, or at `~/.claude/agents/<name>.md` for a personal agent, then resume again
+ * Or resume with `--agent <name>` naming an agent that does exist, to run the session as that agent instead
+ * If the agent is project-scoped and you haven’t trusted the session’s original directory, run Claude Code there once, accept the trust dialog, then resume again
###
@@ -1280,6 +1439,36 @@
* If the message reads `Couldn't start the session`, upgrade to v2.1.212 or later. On earlier versions you can also run `claude daemon run` in a separate terminal first, then start the background session again. That command runs the background service in the terminal’s foreground, so the service lasts only as long as that terminal stays open.
* If the error appears on v2.1.212 or later, ask your Windows administrator to allow the Claude Code executable in the restriction policy
* If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
+
+##
+
+
+
+Rewind warnings
+
+This warning comes from a [`/rewind`](</docs/en/checkpointing>) code restore. It reports paths the restore refused to touch; the restore completed for every other tracked file.
+
+###
+
+
+
+Restored the code, but skipped files
+
+A `/rewind` code restore skipped one or more tracked paths instead of writing or deleting through them. Claude Code skips a path when:
+
+ * it is, or became, a symlink, hard link, or other non-regular file
+ * its directory changed since the checkpoint
+ * its backup can’t be safely read
+
+Skipped paths keep their current contents. Before v2.1.216, `/rewind` wrote and deleted through links at tracked paths, and didn’t report a partial restore.
+
+ Restored the code, but skipped 2 files: the tracked path is (or became) a link or other non-regular file, its directory changed since the checkpoint, or its backup could not be safely read. Skipped files were left untouched — run with --debug for the paths.
+
+**What to do:**
+
+ * Run Claude Code with `--debug` and repeat the restore. The debug log names each skipped path.
+ * If a skipped file is a link you created on purpose, such as a config file managed by a dotfile manager or a file hard-linked by tools like pnpm, restore its contents from [version control](</docs/en/checkpointing#not-a-replacement-for-version-control>) instead
+ * If you didn’t create the link, inspect the path before trusting its contents: something replaced the file after the checkpoint
##
--- a/errors.md
+++ b/errors.md
@@ -82,6 +82,7 @@
`Can't open MCP settings in a background session`| Background session errors
`This session has no saved transcript`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
+`EUNKNOWN: unknown error, uv_spawn`| Background session errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -417,7 +418,7 @@
* Run the command configured in `apiKeyHelper` directly in your shell to reproduce the failure
* If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
* Fix the command so it prints the key to stdout and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
- * Run `/status` to confirm `apiKeyHelper` is the active credential source. Each time the command fails, its exit code and error output appear in a `Cloud authentication` panel in the terminal.
+ * Run `/status` to confirm `apiKeyHelper` is the active credential source. Each time the command fails, its exit code and error output appear in an `Authentication` panel in the terminal. Before v2.1.212, the panel was titled `Cloud authentication`.
###
@@ -762,12 +763,13 @@
Request too large
-The raw request body exceeded the API’s byte limit before tokenization, usually because of a large pasted file or attachment.
-
- Request too large (max 30 MB). Double press esc to go back and remove or shrink the attached content.
-
-This is a size limit on the HTTP request, separate from the context window limit. **What to do:**
-
+The raw request body exceeded the API’s 32MB limit before tokenization, usually because of a large pasted file or attachment.
+
+ Request too large (max 32MB). Accumulated images and attachments in the conversation pushed the request over the limit. Run /compact, or double press esc to go back and remove attachments.
+
+This is a size limit on the HTTP request, separate from the context window limit. When Claude Code sends requests directly to the Claude API, it keeps the total size of images and attachments in each request below this limit by dropping the oldest ones, so conversations that accumulate many images don’t hit it. Before v2.1.212, that cap was higher than the request limit, so a conversation with enough accumulated images failed on every turn with `Request too large (max 32MB). Double press esc to go back and try with a smaller file.` **What to do:**
+
+ * Run `/compact` to summarize the conversation, which drops accumulated images and attachments
* Press Esc twice and step back past the turn that added the oversized content
* Reference large files by path instead of pasting their contents, so Claude can read them in chunks
* For images, see Image was too large below
@@ -1215,7 +1217,7 @@
Background session errors
-[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in agent view or after attaching.
+[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in the terminal that attaches to one, or in the session or shell you dispatch from; where a message is specific to one surface, its entry says so.
###
@@ -1238,14 +1240,14 @@
This session has no saved transcript
-You opened a stopped [background session](</docs/en/agent-view>) that was backgrounded from another conversation with `←` or `/background` and stopped before its first response finished. Until that first response finishes, the conversation still lives only in the session it was backgrounded from, so Claude Code refuses to start the stopped session rather than begin a blank conversation under the same session ID. The message ends with the `claude respawn` command for this session:
+You attached to a stopped [background session](</docs/en/agent-view>) that was backgrounded from another conversation with `←` or `/background` and stopped before its first response finished. Until that first response finishes, the conversation still lives only in the session it was backgrounded from, so `claude attach` refuses to start the stopped session rather than begin a blank conversation under the same session ID. The message ends with the `claude respawn` command for this session:
This session has no saved transcript — it was stopped before its first response finished. If it was backgrounded from another conversation, that one is still intact; `claude respawn <id>` starts this one fresh.
-Before v2.1.211, opening the stopped session silently started that blank conversation and could re-run the session’s original prompt. **What to do:**
+Opening the same session’s row in [agent view](</docs/en/agent-view>) shows `Press enter again to restart this session fresh` below the list instead, and a second `Enter` on the row restarts the session with an empty conversation. Before v2.1.212, opening the row showed the refusal message with no way to restart from agent view. Before v2.1.211, opening the stopped session silently started that blank conversation and could re-run the session’s original prompt. **What to do:**
* The conversation you backgrounded from is intact: resume it with [`claude --resume`](</docs/en/sessions>) or keep working in it
- * To start the stopped session fresh anyway, run `claude respawn <id>` with the ID from the message
+ * To start the stopped session fresh anyway, run `claude respawn <id>` with the ID from the message, or press `Enter` twice on its row in agent view
###
@@ -1262,6 +1264,22 @@
* Set the variable to the absolute path of an executable that ends by calling `exec "$@"`. See [the launcher contract](</docs/en/corporate-launcher#the-launcher-contract>) for the full contract
* Check `/status`, which shows the resolved launch command in its Self-exec entry and warns when the running background service doesn’t match it, or run `claude daemon status` from a shell
* After fixing the value in the `env` block of [settings](</docs/en/corporate-launcher#set-up-the-launcher>), restart the background service with `claude daemon stop --any` so the next dispatch starts a wrapped one
+
+###
+
+
+
+EUNKNOWN when starting a background session
+
+Windows refused to start a program with an error code that has no standard name, so the failure surfaces as `EUNKNOWN`. The usual trigger is a software restriction policy, such as Group Policy or AppLocker, blocking the program being started. The error appears when you start a [background session](</docs/en/agent-view>) with `/background` or `claude --bg`:
+
+ Couldn't reach the background service (spawn background service: EUNKNOWN: unknown error, uv_spawn) — run 'claude daemon status'
+
+On some accounts the message says `daemon` in place of `background service`. Claude Code starts the background service through PowerShell so the service survives closing the terminal, using PowerShell 7 when it’s installed and Windows PowerShell 5.1 otherwise. When neither PowerShell can run, Claude Code starts the service directly instead, so a policy that blocks only PowerShell doesn’t cause this error. If you see it, the policy is blocking the Claude Code executable itself. Before v2.1.212, Claude Code used only Windows PowerShell 5.1 to start the service, so any machine where Group Policy blocked PowerShell 5.1 failed with `Couldn't start the session — EUNKNOWN: unknown error, uv_spawn`, even with PowerShell 7 installed. **What to do:**
+
+ * If the message reads `Couldn't start the session`, upgrade to v2.1.212 or later. On earlier versions you can also run `claude daemon run` in a separate terminal first, then start the background session again. That command runs the background service in the terminal’s foreground, so the service lasts only as long as that terminal stays open.
+ * If the error appears on v2.1.212 or later, ask your Windows administrator to allow the Claude Code executable in the restriction policy
+ * If the background service stops when you close the terminal, Claude Code started it without PowerShell. Install PowerShell 7, or ask your administrator to unblock PowerShell, so the service can outlive the terminal.
##
--- a/errors.md
+++ b/errors.md
@@ -78,7 +78,9 @@
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`would be spawned with zero tools — refusing`| Tool errors
`File is covered by a Read deny rule in your permission settings`| Tool errors
+`Error: this write left the memory index at MEMORY.md at ..., over its ... read limit`| Tool errors
`Can't open MCP settings in a background session`| Background session errors
+`This session has no saved transcript`| Background session errors
`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -534,7 +536,7 @@
Failed to authenticate: OAuth session expired and could not be refreshed
-This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. **What to do:**
+This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. You can check for this state before a request fails: [`/status`](</docs/en/commands>) shows a `Login` row reading `Expired — log in again`, plus the organization and email it has saved for the expired login. The row appears only when the saved login is your active credential and can no longer be refreshed. Sessions authenticated another way don’t show the row, even if an expired login remains saved. Before v2.1.210, `/status` gave no indication in this state that a login had ever existed, because the cleared credential left it nothing to report. **What to do:**
* Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
* In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
@@ -1159,7 +1161,7 @@
Tool errors
-These errors come from Claude’s built-in tools refusing an input. Claude corrects most tool errors on its own; the two below need a change from you, because they come from a subagent definition or a permission rule you control.
+These errors come from Claude’s built-in tools. Claude corrects most tool errors on its own; the first two below need a change from you, because they come from a subagent definition or a permission rule you control.
###
@@ -1192,6 +1194,21 @@
* If Claude should be able to edit the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings#permission-settings>)
* If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path so the Write and NotebookEdit tools are blocked too
+###
+
+
+
+Memory index is over its read limit
+
+Claude wrote to the [auto memory](</docs/en/memory#auto-memory>) index `MEMORY.md` and left it over one of its read limits: 200 lines or 25KB. The write succeeded, but only the first 200 lines or 25KB, whichever comes first, load at the start of a session, so everything past the limit is dropped each time the index is read. Before v2.1.210, an over-limit index was silently truncated on the next load with no write-time signal.
+
+ Error: this write left the memory index at MEMORY.md at 214 lines, over its 200-line read limit. The write succeeded, but everything past the limit is silently dropped each time the index is loaded — entries at the end are already invisible to readers. Rewrite it to under 140 lines now: keep one line per entry, move detail into topic files, and merge or drop stale entries.
+
+Only the content that loads counts toward the limits. YAML frontmatter and block-level HTML comments are stripped before the index is loaded, so they’re excluded from the measurement. Before v2.1.211, Claude Code measured the raw file, and frontmatter or comments could trigger this error even when the loaded content fit. Claude Code delivers the error to Claude after the write rather than printing it as a banner in your terminal, so you may notice it only in the transcript. When Claude’s write brings the file near a limit without crossing it, Claude Code returns a milder reminder to compact the index instead of this error. **What to do:**
+
+ * Let Claude rewrite `MEMORY.md`, or ask it to: keep one line per entry, move detail into topic files, and merge or drop stale entries
+ * To trim the index yourself, see [Audit and edit your memory](</docs/en/memory#audit-and-edit-your-memory>)
+
##
@@ -1214,6 +1231,21 @@
* Use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`
* For sign-in and authorization flows, run the command from a regular `claude` session in a terminal
+
+###
+
+
+
+This session has no saved transcript
+
+You opened a stopped [background session](</docs/en/agent-view>) that was backgrounded from another conversation with `←` or `/background` and stopped before its first response finished. Until that first response finishes, the conversation still lives only in the session it was backgrounded from, so Claude Code refuses to start the stopped session rather than begin a blank conversation under the same session ID. The message ends with the `claude respawn` command for this session:
+
+ This session has no saved transcript — it was stopped before its first response finished. If it was backgrounded from another conversation, that one is still intact; `claude respawn <id>` starts this one fresh.
+
+Before v2.1.211, opening the stopped session silently started that blank conversation and could re-run the session’s original prompt. **What to do:**
+
+ * The conversation you backgrounded from is intact: resume it with [`claude --resume`](</docs/en/sessions>) or keep working in it
+ * To start the stopped session fresh anyway, run `claude respawn <id>` with the ID from the message
###
--- a/errors.md
+++ b/errors.md
@@ -263,7 +263,7 @@
You've hit your weekly limit · resets Mon 12:00am
You've hit your Opus limit · resets 3:45pm
-Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus limit applies only to Opus requests, so switching to another model with `/model` keeps you working. **What to do:**
+Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus limit applies only to Opus requests, so switching to another model with `/model` keeps you working. Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets. **What to do:**
* Wait for the reset time shown in the error
* For the Opus limit, run `/model` and switch to another model to keep working
Show diff (182 lines)
--- a/errors.md
+++ b/errors.md
@@ -29,6 +29,7 @@
`Not logged in · Please run /login`| Authentication
`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
+`Your apiKeyHelper script is failing`| Authentication
`This organization has been disabled`| Authentication
`Your organization has disabled API key authentication`| Authentication
`Your organization has disabled Claude subscription access`| Authentication
@@ -43,6 +44,7 @@
`AWS default-chain credential resolve timed out`| Authentication
`Unable to connect to API`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
+`Bedrock streaming response has content-type "..."; expected "application/vnd.amazon.eventstream"`| Network
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
@@ -74,6 +76,10 @@
`references ${user_config.*} in a shell-form command`| Plugin errors
`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
+`would be spawned with zero tools — refusing`| Tool errors
+`File is covered by a Read deny rule in your permission settings`| Tool errors
+`Can't open MCP settings in a background session`| Background session errors
+`CLAUDE_CODE_PROCESS_WRAPPER: launcher ...`| Background session errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -83,10 +89,11 @@
Automatic retries
-Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. As of v2.1.198, this covers connections that drop in the middle of a response before any visible output has streamed: Claude Code re-issues the request with the same backoff and the turn continues instead of stopping with a connection error. As of v2.1.199, temporary 429 throttles that don’t carry your plan’s quota headers are also retried when you’re signed in with a claude.ai subscription; earlier versions retried them only for API key and Enterprise sign-ins. Two failure classes aren’t retried, because a retry can’t succeed:
+Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. As of v2.1.198, this covers connections that drop in the middle of a response before any visible output has streamed: Claude Code re-issues the request with the same backoff and the turn continues instead of stopping with a connection error. As of v2.1.199, temporary 429 throttles that don’t carry your plan’s quota headers are also retried when you’re signed in with a claude.ai subscription; earlier versions retried them only for API key and Enterprise sign-ins. Some failure classes aren’t retried, because a retry can’t succeed:
* As of v2.1.199, a TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate, fails on the first attempt so the fix appears immediately instead of after the full retry budget. See SSL certificate errors. Transient TLS conditions such as a handshake timeout still retry.
* As of v2.1.199, a server error that arrives after Claude has already streamed visible output keeps the partial response and appends an incomplete-response notice instead of retrying, since re-running the request could execute the same tools twice. Earlier versions discarded the partial output and reported the turn as an error.
+ * An Amazon Bedrock streaming response with an unexpected content-type fails on the first attempt, because the gateway or proxy rewriting the response would rewrite the retry the same way. Requires Claude Code v2.1.208 or later.
While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. When you see one of the errors on this page, those retries have already been exhausted, unless it belongs to a class that isn’t retried, such as a certificate-validation failure. You can tune the behavior with these environment variables:
@@ -397,6 +404,23 @@
+Your apiKeyHelper script is failing
+
+The command configured in the [`apiKeyHelper`](</docs/en/settings#available-settings>) setting exited with an error, timed out, or printed nothing to stdout. Without a key from the script, the request reaches the API with a placeholder credential, and the API rejects it with `401`.
+
+ Your apiKeyHelper script is failing · This usually means you need to re-authenticate with your provider · Run /status to see the script's error output
+
+Claude Code re-runs the script and retries the request up to two more times before showing this message, so the failure surfaces within three attempts. Before v2.1.208, Claude Code spent the full retry budget resending the request with the placeholder credential and then reported a generic `401` authentication error instead of the script failure. Running `/login` doesn’t help here: the helper’s output [takes precedence](</docs/en/authentication#authentication-precedence>) over a saved login for as long as the setting is present. **What to do:**
+
+ * Run the command configured in `apiKeyHelper` directly in your shell to reproduce the failure
+ * If the command reports an expired session, re-authenticate with your credential provider, for example by signing in to your SSO or secrets vault again
+ * Fix the command so it prints the key to stdout and exits with code 0. See [rotate credentials with apiKeyHelper](</docs/en/llm-gateway-connect#rotate-credentials-with-apikeyhelper>) for a working setup.
+ * Run `/status` to confirm `apiKeyHelper` is the active credential source. Each time the command fails, its exit code and error output appear in a `Cloud authentication` panel in the terminal.
+
+###
+
+
+
This organization has been disabled
A stale `ANTHROPIC_API_KEY` from a disabled Console organization is overriding your subscription login.
@@ -584,7 +608,7 @@
Network and connection errors
-These errors mean a network request from Claude Code failed to reach its destination. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
+These errors mean a network request from Claude Code failed to reach its destination, or something between Claude Code and the API altered the response on its way back. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
###
@@ -614,6 +638,21 @@
* On Linux and WSL, check `/etc/resolv.conf` for an unreachable nameserver. WSL in particular can inherit a broken resolver from the host.
* On macOS, a VPN client that was disconnected or uninstalled can leave a tunnel interface or routing rule behind. Check `ifconfig` for stale `utun` interfaces and remove the VPN’s network extension in System Settings.
* Docker Desktop and similar container runtimes can intercept outbound traffic. Quit them and retry to rule this out.
+
+###
+
+
+
+Bedrock streaming response has an unexpected content-type
+
+A gateway or proxy between Claude Code and [Amazon Bedrock](</docs/en/amazon-bedrock>) is transforming the streaming response body or its `Content-Type` header. Amazon Bedrock streams responses as `application/vnd.amazon.eventstream`, and Claude Code rejects a successful streaming response that reports a different content-type instead of decoding a body it can’t read. The request isn’t retried.
+
+ Bedrock streaming response has content-type "text/event-stream"; expected "application/vnd.amazon.eventstream". A gateway or proxy between Claude Code and Bedrock is likely transforming the response body — Bedrock's binary event-stream format must be passed through unmodified. Set CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1 to suppress this check while the gateway is being fixed.
+
+Before v2.1.208, the same misconfiguration surfaced as `API Error: Truncated event message received` after the whole response had been buffered. **What to do:**
+
+ * Configure the gateway to pass the `InvokeModelWithResponseStream` response body and its `Content-Type` header through unmodified. An intermediary that re-emits the stream as server-sent events is a common cause.
+ * If the gateway rewrites only the header and passes the binary body through intact, set [`CLAUDE_CODE_DISABLE_BEDROCK_CONTENT_TYPE_GUARD=1`](</docs/en/env-vars>) to skip the check until the gateway is fixed. See [Streaming errors behind a gateway or proxy](</docs/en/amazon-bedrock#streaming-errors-behind-a-gateway-or-proxy>).
###
@@ -1118,6 +1157,84 @@
+Tool errors
+
+These errors come from Claude’s built-in tools refusing an input. Claude corrects most tool errors on its own; the two below need a change from you, because they come from a subagent definition or a permission rule you control.
+
+###
+
+
+
+Agent would be spawned with zero tools
+
+Nothing in a [subagent’s `tools` list](</docs/en/sub-agents#supported-frontmatter-fields>) resolved to a tool, so Claude Code refuses to launch the subagent rather than start one that can’t act. The message groups the entries by why they didn’t resolve: not a recognized tool, a tool that isn’t available to subagents, or recognized but matching no tool in the current session. Omitting the `tools` field never triggers this refusal. An MCP server pattern such as `mcp__github__*` isn’t exempt: when no connected tool comes from that server, the launch is refused with the pattern in the matched-nothing group. Before v2.1.208, the subagent launched with no tools and returned an empty or confusing result.
+
+ Agent 'code-reviewer' would be spawned with zero tools — refusing. Its tools list resolved to nothing: unrecognized [Grpe]. Fix the agent's tools frontmatter or pass a different subagent_type.
+
+**What to do:**
+
+ * Correct each entry the error names against the [tools available to subagents](</docs/en/sub-agents#available-tools>)
+ * Remove entries for tools the session doesn’t have, such as MCP tools from a server that isn’t connected
+ * To give the subagent every tool the parent has, delete the `tools` field instead of listing tools
+
+###
+
+
+
+File is covered by a Read deny rule
+
+The Edit tool was called on a path matched by a [`Read` deny rule](</docs/en/permissions#read-and-edit>), including creating a new file at that path. Editing rewrites content Claude has to be able to read back, so the call is refused before any file access. The rule blocks the Edit tool only: Write and NotebookEdit aren’t covered by `Read` deny rules. Before v2.1.208, only an `Edit` deny rule blocked edits, and a `Read` deny rule alone didn’t.
+
+ File is covered by a Read deny rule in your permission settings and cannot be edited.
+
+**What to do:**
+
+ * If Claude should be able to edit the file, remove or narrow the `Read` deny rule in `/permissions` or in [settings](</docs/en/settings#permission-settings>)
+ * If the file must stay untouched, keep the rule and add an `Edit` deny rule for the same path so the Write and NotebookEdit tools are blocked too
+
+##
+
+
+
+Background session errors
+
+[Background sessions](</docs/en/agent-view>) run without an interactive terminal of their own, so commands that need one behave differently there. These messages appear in the transcript of a background session, in agent view or after attaching.
+
+###
+
+
+
+Commands refused in a background session
+
+Commands that open an interactive dialog are refused in a background session with a message naming a form that works there or telling you to run the command from a regular terminal. `/install-github-app`, the `/mcp` settings list, and the authentication actions in the MCP server menu are all refused this way. Before v2.1.208, they opened their dialog inside the background session. In v2.1.208 only, the `/model` picker was also refused in a background session, and `/upgrade` printed the upgrade URL instead of opening a browser. The wording names the command that was refused. The `/mcp` settings list reports:
+
+ Can't open MCP settings in a background session — use `/mcp enable|disable|reconnect <server>` to steer, or run /mcp from an interactive terminal to authenticate.
+
+**What to do:**
+
+ * Use the form the message names, such as `/mcp reconnect <server>`, `/mcp enable`, or `/mcp disable`
+ * For sign-in and authorization flows, run the command from a regular `claude` session in a terminal
+
+###
+
+
+
+CLAUDE_CODE_PROCESS_WRAPPER launcher errors
+
+[`CLAUDE_CODE_PROCESS_WRAPPER`](</docs/en/corporate-launcher>) is set, and its value can’t be used, so Claude Code refuses to start the affected process rather than run it without the launcher. Configuration problems are reported with a message that starts with the variable name and states the reason, for example:
+
+ CLAUDE_CODE_PROCESS_WRAPPER: launcher `/opt/corp/launcher` is not an executable regular file
+
+A launcher that starts but exits without replacing itself with Claude Code fails the session it was starting, and the session’s row in agent view reports that the launcher `must exec, not daemonize`, followed by anything the launcher printed. A session that can’t start or reach the background service because of the launcher reports the launcher problem as the reason inside `Couldn't reach the background service (...)`. **What to do:**
+
+ * Set the variable to the absolute path of an executable that ends by calling `exec "$@"`. See [the launcher contract](</docs/en/corporate-launcher#the-launcher-contract>) for the full contract
+ * Check `/status`, which shows the resolved launch command in its Self-exec entry and warns when the running background service doesn’t match it, or run `claude daemon status` from a shell
+ * After fixing the value in the `env` block of [settings](</docs/en/corporate-launcher#set-up-the-launcher>), restart the background service with `claude daemon stop --any` so the next dispatch starts a wrapped one
+
+##
+
+
+
Configuration warnings
Claude Code writes these messages to stderr at startup rather than showing an error in the conversation. They report configuration it read but didn’t apply.
Show diff (187 lines)
--- a/errors.md
+++ b/errors.md
@@ -35,9 +35,12 @@
`Routines are disabled by your organization's policy`| Authentication
`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
+`Login expired · Please run /login`| Authentication
+`Failed to authenticate: OAuth session expired and could not be refreshed`| Authentication
`does not meet scope requirement user:profile`| Authentication
`AWS credentials expired or invalid`| Authentication
`AWS authentication failed`| Authentication
+`AWS default-chain credential resolve timed out`| Authentication
`Unable to connect to API`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`SSL certificate verification failed`| Network
@@ -66,7 +69,11 @@
`--bg and --print conflict`| Command-line errors
`Error: --json-schema is not a valid JSON Schema`| Command-line errors
`Could not import <server>: <reason>`| Command-line errors
+`Error: MCP tool <name> (passed via --permission-prompt-tool) not found`| Command-line errors
`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
+`references ${user_config.*} in a shell-form command`| Plugin errors
+`Monitor "<name>" from plugin <plugin> references ${user_config.*} in its command`| Plugin errors
+`headersHelper for MCP server '<name>' references ${user_config.*}`| Plugin errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -249,9 +256,10 @@
You've hit your weekly limit · resets Mon 12:00am
You've hit your Opus limit · resets 3:45pm
-Claude Code blocks further requests until the reset time shown in the message. **What to do:**
+Claude Code blocks further requests until the reset time shown in the message. The session and weekly limits are shared across all models, so switching models doesn’t restore access. The Opus limit applies only to Opus requests, so switching to another model with `/model` keeps you working. **What to do:**
* Wait for the reset time shown in the error
+ * For the Opus limit, run `/model` and switch to another model to keep working
* Run `/usage` to see your plan limits and when they reset
* Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
@@ -475,7 +483,7 @@
OAuth token revoked or expired
-Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session.
+Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session. Both messages report a rejection the API returned for a request Claude Code sent. When the saved login has already been cleared after a failed refresh, you see Login expired instead.
OAuth token revoked · Please run /login
OAuth token has expired · Please run /login
@@ -492,6 +500,26 @@
+Login expired
+
+Claude Code tried to renew your saved claude.ai or Claude Console login and the OAuth service rejected the stored refresh token, so Claude Code cleared the saved credentials. After that, each request stops locally before it reaches the API, because only `/login` can create new credentials. Before v2.1.206, Claude Code sent the request anyway with whatever credential remained in the environment, and every model then failed with There’s an issue with the selected model or a 401 instead of a prompt to sign in.
+
+ Login expired · Please run /login
+
+In [non-interactive mode](</docs/en/headless>) (`-p`) and the [Agent SDK](</docs/en/agent-sdk/overview>), the message reads as follows, and the structured error code is `authentication_failed`:
+
+ Failed to authenticate: OAuth session expired and could not be refreshed
+
+This is not the same state as OAuth token revoked or expired. Those messages report a 401 the API returned. Claude Code itself produces `Login expired` for a login it already failed to renew, so it sends no request. Sessions authenticated with an API key, [`CLAUDE_CODE_OAUTH_TOKEN`](</docs/en/env-vars>), or a third-party provider don’t use the saved login and never see this message. **What to do:**
+
+ * Run `/login` to sign in again. Retrying without signing in shows the same message on every request.
+ * In non-interactive mode, run `claude` in the same environment, complete `/login`, then rerun your command. For automation that can’t sign in interactively, authenticate with `ANTHROPIC_API_KEY` or [generate a long-lived token with `claude setup-token`](</docs/en/authentication#generate-a-long-lived-token>).
+ * If signing in keeps failing, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
+
+###
+
+
+
OAuth scope requirement
The stored token predates a permission scope that a newer feature needs. You see this most often from `/usage` and the status line usage indicator:
@@ -533,6 +561,22 @@
* Run the `awsAuthRefresh` command named in the message, or `aws sso login`, in case an expired credential is the cause
* If your credentials are current, confirm the IAM permissions in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>) are attached to the identity you’re using and that the selected model is enabled for your account and region
* Run `aws sts get-caller-identity` to confirm which identity your requests use; a stale `AWS_PROFILE` or default profile is a common cause of a permission mismatch
+
+###
+
+
+
+AWS default-chain credential resolve timed out
+
+The AWS default credential provider chain didn’t produce credentials within 60 seconds, so Claude Code stopped the resolve and failed the request. The failure is local credential resolution: the request never reached [Amazon Bedrock](</docs/en/amazon-bedrock>), [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>). Claude Code clears its [credential cache](</docs/en/amazon-bedrock#credential-caching-and-resolution-timeout>) and retries before this error surfaces, so by the time you see it the chain has stalled on repeated attempts.
+
+ API Error: AWS default-chain credential resolve timed out
+
+Common causes are a `credential_process` command in your AWS profile that waits for input it can’t receive, and a container or VM whose instance metadata service (IMDS) never answers the chain’s probe. Before v2.1.207, a stalled chain left the request waiting indefinitely instead of failing with this message. **What to do:**
+
+ * Run `aws sts get-caller-identity` in the same shell with the same `AWS_PROFILE`. If it also hangs, fix the profile; a `credential_process` command that prompts interactively is a common cause.
+ * Complete the sign-in step before starting Claude Code, for example `aws sso login --profile myprofile`, so the chain resolves from the local SSO cache instead of waiting on a browser flow
+ * If your chain runs an interactive sign-in that legitimately needs more than 60 seconds, such as SSO with MFA through a wrapper like `aws-vault`, raise the limit in milliseconds with [`CLAUDE_CODE_AWS_CHAIN_RESOLVE_TIMEOUT_MS`](</docs/en/env-vars>)
##
@@ -772,6 +816,7 @@
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
+ * Claude Code reports an expired claude.ai login as Login expired, not as this error. Before v2.1.206, an expired login that could no longer be refreshed failed every model with this error; run `/login` if you see that on an older version.
* For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
###
@@ -1005,6 +1050,22 @@
* Rename the server in `claude_desktop_config.json` to use only letters, numbers, hyphens, and underscores, then run `claude mcp add-from-claude-desktop` again
* Add that server directly with `claude mcp add` or `claude mcp add-json` under a valid name. See [Import MCP servers from Claude Desktop](</docs/en/mcp#import-mcp-servers-from-claude-desktop>).
+###
+
+
+
+MCP permission prompt tool not found
+
+The tool you passed to [`--permission-prompt-tool`](</docs/en/cli-reference#cli-flags>) wasn’t among the connected MCP tools when the run first needed a permission decision, either because its server never connected or because no connected server exposes a tool by that name. Claude Code still sends your prompt: the [non-interactive](</docs/en/headless>) run exits with this error, and exit code 1, on the first tool call that needs approval, so it produces no answer even though the request was made. Before the first prompt, Claude Code waits up to the per-server connection timeout of 30 seconds set by [`MCP_TIMEOUT`](</docs/en/env-vars>) for that server to connect. Before v2.1.206, startup didn’t wait for the server to finish connecting, so a slow-starting but healthy server produced this error too.
+
+ Error: MCP tool mcp__permissions__approve (passed via --permission-prompt-tool) not found. Available MCP tools: none
+
+The list after `Available MCP tools:` names the MCP tools that were connected when the wait ended. **What to do:**
+
+ * Check that the server starts and stays connected: run `claude mcp list` in the same directory and confirm the server is listed as connected
+ * Confirm the tool name matches the `mcp__<server>__<tool>` name the server exposes
+ * If the server needs longer than 30 seconds to start, raise [`MCP_TIMEOUT`](</docs/en/env-vars>)
+
##
@@ -1029,6 +1090,30 @@
* If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
* See the reserved name list under [Marketplace schema](</docs/en/plugin-marketplaces#marketplace-schema>)
+###
+
+
+
+Plugin command references user_config in a shell command
+
+A plugin hook, [monitor](</docs/en/plugins-reference#monitors>), or MCP [`headersHelper`](</docs/en/mcp#use-dynamic-headers-for-custom-authentication>) command references a `${user_config.KEY}` [plugin option](</docs/en/plugins-reference#user-configuration>), and the substituted string would be passed to a shell. A configured value containing `$(...)`, backticks, or `;` would run as code there, so Claude Code refuses to start the component instead of substituting the value. The check runs on the command template, so the error appears even when no value is configured yet. Before v2.1.207, the value was substituted into the shell command. The wording depends on which surface referenced the option. A shell-form hook reports:
+
+ Hook from plugin formatter@acme-tools references ${user_config.*} in a shell-form command. The substituted value would be re-parsed by the shell. Use exec form instead — {"command": "<executable>", "args": ["${user_config.KEY}", ...]} — or read $CLAUDE_PLUGIN_OPTION_<KEY> from the hook's environment. Command: ./scripts/notify.sh ${user_config.webhook_url}
+
+A monitor reports:
+
+ Monitor "deploy-status" from plugin deploy-tools references ${user_config.*} in its command. The substituted value would be passed to a shell. Monitor commands cannot safely reference ${user_config.*}; have the monitor script read the value from a config file or prompt instead.
+
+An MCP `headersHelper` reports:
+
+ headersHelper for MCP server 'internal-api' references ${user_config.*}. The substituted value would be passed to a shell; read the value inside the helper script instead (e.g. from an env var set in the server's "env" block).
+
+**What to do:**
+
+ * For a hook, add an `args` array so it runs in [exec form](</docs/en/hooks#exec-form-and-shell-form>), where each `${user_config.KEY}` becomes one argument with no shell in between. Or drop the reference and read the `$CLAUDE_PLUGIN_OPTION_<KEY>` environment variable inside the script
+ * For a monitor, drop the reference and have the monitor script read the value from a config file
+ * For a `headersHelper`, move `${user_config.KEY}` into the server’s `headers` field, which isn’t shell-parsed, or read the value inside the helper script
+
##
@@ -1051,7 +1136,7 @@
* Run `claude` in the directory and accept the trust dialog. The dialog appears even when a parent directory is already trusted, lists the rules being held back, and lets you decline and keep working without them. Before v2.1.200, no dialog appeared in that situation, so this step couldn’t be completed there.
* In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
- * If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
+ * If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. On v2.1.207 and later, updating isn’t enough outside a git repository if you haven’t trusted the folder: determining that a folder isn’t inside a repository runs git, and Claude Code runs that check only after you accept the trust dialog, so use the first step. Your home directory and any other [configuration home](</docs/en/permissions#project-allow-rules-and-workspace-trust>) are exempt and don’t wait for the dialog. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
##
@@ -1072,7 +1157,7 @@
* **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
* **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. The `/doctor` checkup flags oversized memory files and unused extensions, and `/context` shows MCP tool token usage. Before v2.1.205, `/doctor` opened a diagnostics screen that flagged oversized memory files and subagent definitions.
-When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment. If Sonnet 5 refuses a request and cites a suspected prompt injection on Claude Code v2.1.200 or earlier, run `claude update` to pick up the v2.1.201 fix.
+When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment. If Claude warns about a suspected prompt injection, or refuses a request because of a suspected injection, and the text the warning names is context Claude Code adds to the conversation automatically rather than file or web content, run `claude update` and retry. If the warning repeats after updating, report it rather than pasting the flagged content back into the prompt. Before v2.1.201, Sonnet 5 refused some requests the same way.
##
@@ -1088,7 +1173,7 @@
If an error is not listed here or the suggested fix does not help:
- * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and other third-party providers, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
+ * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. Sending to Anthropic requires [authentication](</docs/en/authentication>). On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and other third-party providers, or when no Anthropic credentials are configured, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
* Run `claude doctor` from your shell for a read-only diagnostic of your installation, or run the `/doctor` checkup inside Claude Code to find and fix setup problems
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub
Show diff (133 lines)
--- a/errors.md
+++ b/errors.md
@@ -62,7 +62,11 @@
`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
+`Download timed out: exceeded the total deadline`| Installation errors
`--bg and --print conflict`| Command-line errors
+`Error: --json-schema is not a valid JSON Schema`| Command-line errors
+`Could not import <server>: <reason>`| Command-line errors
+`Marketplace "<name>" is registered from an untrusted source`| Plugin errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -580,7 +584,7 @@
As of v2.1.199, a certificate validation failure isn’t retried, so this error appears on the first attempt instead of after the full retry budget. Earlier versions spent a few minutes retrying before showing it. Transient TLS conditions, such as a handshake timeout, still retry. During `/login` and the startup connectivity check, the same failure is reported with the OpenSSL code and the fix inline:
- SSL certificate error (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). If you are behind a corporate proxy or TLS-intercepting firewall, set NODE_EXTRA_CA_CERTS to your CA bundle path, or ask IT to allowlist *.anthropic.com. Run /doctor for details.
+ SSL certificate error (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). If you are behind a corporate proxy or TLS-intercepting firewall, set NODE_EXTRA_CA_CERTS to your CA bundle path, or ask IT to allowlist *.anthropic.com. Run `claude doctor` for details.
**What to do:**
@@ -813,7 +817,7 @@
Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
-**What to do:**
+Claude Code treats a model family alias, one of `opus`, `sonnet`, `haiku`, or `fable`, as a request for that family rather than for its newest version. On the Anthropic API and on [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), a restricted family alias resolves to the newest version of the family that your organization and the `availableModels` allowlist permit, and the substitution notice names that version. Claude Code rejects `/model <alias>` only when every version of the family is restricted. Before v2.1.205, a family alias was substituted or rejected based on its newest version alone, even when an older version of the same family was allowed. **What to do:**
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
* If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, or the `model` field of a settings file, remove or update that value so the notice doesn’t recur on each launch
@@ -940,9 +944,9 @@
The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
-The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
-
- * Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run.
+The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. A download that stays connected but doesn’t finish within 10 minutes fails with `Download timed out: exceeded the total deadline` instead. Claude Code doesn’t retry a timed-out download, because a connection too slow to finish inside the deadline won’t finish on an immediate retry either. The steps below apply to both messages. Before v2.1.205, the same 10-minute deadline was reported as the HTTP client’s generic `timeout of 600000ms exceeded`. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
+
+ * Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run. For the timed-out message, run it again from a faster or less throttled network.
* If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](</docs/en/troubleshoot-install#check-network-connectivity>).
* If a corporate proxy keeps closing the transfer, ask your network team to allow the full download from `downloads.claude.ai`. See [Network access requirements](</docs/en/network-config#network-access-requirements>).
* Run `claude doctor` from your shell for installation diagnostics
@@ -953,7 +957,7 @@
Command-line errors
-These errors come from Claude Code’s own validation of the `claude` command line. Claude Code prints them immediately, before it creates a session or sends any API request.
+These errors come from the `claude` command line and its subcommands. Claude Code prints them before running your prompt or sending any API request.
###
@@ -969,6 +973,61 @@
* Drop `-p` or `--print`. `--bg` takes the prompt as its positional argument, so `claude --bg "<task>"` is the complete command. See [Dispatch new agents from your shell](</docs/en/agent-view#from-your-shell>).
* To run the prompt non-interactively and print the result instead of creating a background session, drop `--bg` and run `claude -p "<task>"`
+
+###
+
+
+
+The —json-schema value is not a valid JSON Schema
+
+The schema you passed to [`--json-schema`](</docs/en/cli-reference#cli-flags>) in [non-interactive mode](</docs/en/headless#get-structured-output>) failed JSON Schema compilation, so `claude` exits with code 1 instead of running the prompt. Before v2.1.205, an invalid schema produced unstructured output with no error, and any schema that used the `format` keyword was treated as invalid.
+
+ Error: --json-schema is not a valid JSON Schema: data/type must be equal to one of the allowed values
+
+The text after the second colon is the validator’s diagnostic and names the keyword or location that failed. Schemas that use the `format` keyword, such as `"format": "email"`, are valid: Claude Code accepts `format` as an annotation and doesn’t enforce it. Claude Code runs two checks before schema compilation: it rejects a value that isn’t parseable JSON with `Error: --json-schema is not valid JSON`, and valid JSON that isn’t an object with `Error: --json-schema must be a JSON object`. **What to do:**
+
+ * Fix the part of the schema the diagnostic names, then rerun the command
+ * If the diagnostic is `schema too large`, reduce the schema’s nesting and `$ref` reuse
+ * See [Get structured output](</docs/en/headless#get-structured-output>) for a working schema and command
+
+###
+
+
+
+Could not import a server from Claude Desktop
+
+Claude Code couldn’t add one of the servers you selected in `claude mcp add-from-claude-desktop`. The command still imports the other selected servers and prints one line per server it couldn’t add. Before v2.1.205, the first server that failed stopped the import and none of the selected servers were added.
+
+ Could not import my server: Invalid name my server. Names can only contain letters, numbers, hyphens, and underscores.
+
+The text after the server name is the reason. The most common one is the name check: Claude Desktop allows characters in server names, such as spaces and periods, that `claude mcp` restricts to letters, numbers, hyphens, and underscores. Other reasons include a server configuration that fails validation and a server blocked by your organization’s [MCP policy](</docs/en/managed-mcp>). **What to do:**
+
+ * Rename the server in `claude_desktop_config.json` to use only letters, numbers, hyphens, and underscores, then run `claude mcp add-from-claude-desktop` again
+ * Add that server directly with `claude mcp add` or `claude mcp add-json` under a valid name. See [Import MCP servers from Claude Desktop](</docs/en/mcp#import-mcp-servers-from-claude-desktop>).
+
+##
+
+
+
+Plugin errors
+
+These errors come from [plugin](</docs/en/plugins>) and [marketplace](</docs/en/plugin-marketplaces>) configuration. For plugin problems that don’t produce one of the messages on this page, such as a marketplace URL that doesn’t load or a plugin that installs but doesn’t appear, see [Plugin troubleshooting](</docs/en/discover-plugins#troubleshooting>).
+
+###
+
+
+
+Marketplace is registered from an untrusted source
+
+The marketplace is registered under a name that is [reserved for official Anthropic marketplaces](</docs/en/plugin-marketplaces#marketplace-schema>), but its registered source isn’t an `anthropics` GitHub repository. Claude Code re-checks reserved names every time it loads or refreshes a marketplace, so the marketplace and the plugins installed from it stop loading. Before v2.1.205, the name was checked only when the marketplace was added, so an entry registered before its name became reserved kept loading.
+
+ Marketplace "claude-community" is registered from an untrusted source: The name 'claude-community' is reserved for official Anthropic marketplaces. Only repositories from 'github.com/anthropics/' can use this name. To fix it, remove the marketplace and re-add it from the official source.
+
+**What to do:**
+
+ * Run `claude plugin marketplace remove <name>`, then add the marketplace again from the official `github.com/anthropics` repository
+ * If you publish a third-party marketplace that used the name before it became reserved, rename it and ask users to re-add it from your source
+ * See the reserved name list under [Marketplace schema](</docs/en/plugin-marketplaces#marketplace-schema>)
##
@@ -1011,7 +1070,7 @@
* **Model selection** : run `/model` to confirm you are on the model you expect. A previous `/model` choice or an `ANTHROPIC_MODEL` environment variable may have you on a smaller model than you intended.
* **Effort level** : run `/effort` to check the current reasoning level and raise it for hard debugging or design work. Defaults vary by model, so check before assuming you are below the maximum. See [Adjust effort level](</docs/en/model-config#adjust-effort-level>) for per-model defaults and the `ultrathink` shortcut.
* **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
- * **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. `/doctor` flags oversized memory files and subagent definitions; `/context` shows MCP tool token usage.
+ * **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. The `/doctor` checkup flags oversized memory files and unused extensions, and `/context` shows MCP tool token usage. Before v2.1.205, `/doctor` opened a diagnostics screen that flagged oversized memory files and subagent definitions.
When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment. If Sonnet 5 refuses a request and cites a suspected prompt injection on Claude Code v2.1.200 or earlier, run `claude update` to pick up the v2.1.201 fix.
@@ -1030,6 +1089,6 @@
If an error is not listed here or the suggested fix does not help:
* Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and other third-party providers, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
- * Run `/doctor` to check for local configuration problems
+ * Run `claude doctor` from your shell for a read-only diagnostic of your installation, or run the `/doctor` checkup inside Claude Code to find and fix setup problems
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub
--- a/errors.md
+++ b/errors.md
@@ -59,6 +59,7 @@
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
+`<model> has safety measures that flagged this message for a cybersecurity topic`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
`The connection dropped while downloading the update`| Installation errors
`--bg and --print conflict`| Command-line errors
@@ -876,11 +877,34 @@
API Error: Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.
-The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. **What to do:**
+The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), this message also covers requests the model’s safety measures flagged as a cybersecurity topic. See Safety measures flagged a cybersecurity topic. **What to do:**
* Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
* If you can’t identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
* In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt in a new session without `--continue`. Policy checks vary by model, so switching to a different model with `--model` may also resolve the refusal in some cases.
+
+###
+
+
+
+Safety measures flagged a cybersecurity topic
+
+The model’s safety measures flagged content in the conversation as a cybersecurity topic. The message names the model that flagged the request:
+
+ API Error: Opus 4.8 has safety measures that flagged this message for a cybersecurity topic. To learn about the Cyber Verification Program and apply for access, visit our help center: https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude.
+
+ If you were not engaging in a cybersecurity topic, please send feedback via /feedback.
+
+The message links to the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>), which grants access for legitimate cybersecurity work. The safeguard itself is server-side and predates v2.1.203; this release changed only the wording of the message and the page it links to. What you see depends on your provider and mode:
+
+ * On [Amazon Bedrock](</docs/en/amazon-bedrock>), [Google Cloud’s Agent Platform](</docs/en/google-vertex-ai>), and [Microsoft Foundry](</docs/en/microsoft-foundry>), a cybersecurity flag produces the Usage Policy refusal message instead.
+ * [Non-interactive mode](</docs/en/headless>) omits the `/feedback` sentence.
+
+Before v2.1.203, the message read `<model>'s safeguards flagged this message for a cybersecurity topic. If your work requires this access, you can apply for an exemption:` followed by an exemption form link. **What to do:**
+
+ * If your work requires this content, apply for access through the [Cyber Verification Program](<https://support.claude.com/en/articles/14604842-real-time-cyber-safeguards-on-claude>)
+ * If your request wasn’t about a cybersecurity topic, run `/feedback` to report the false positive
+ * To keep working in the same session, press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the flag, then take a different approach. See [Checkpointing](</docs/en/checkpointing>).
##
--- a/errors.md
+++ b/errors.md
@@ -60,6 +60,7 @@
`API Error: 400 due to tool use concurrency issues`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
`Installation was killed before it could finish (exit code 137)`| Installation errors
+`The connection dropped while downloading the update`| Installation errors
`--bg and --print conflict`| Command-line errors
`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
@@ -887,7 +888,7 @@
Installation errors
-These errors come from the [install script](</docs/en/setup#install-claude-code>) before Claude Code has started. For `command not found`, PATH, permission, and TLS problems during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>).
+These errors appear while installing or updating Claude Code, from the [install script](</docs/en/setup#install-claude-code>), `claude install`, or `claude update`. For `command not found`, PATH, permission, and TLS problems during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>).
###
@@ -904,6 +905,23 @@
* Stop other processes to free memory, then rerun the installer
* Add swap space or move to a larger instance. See [Install killed on low-memory Linux servers](</docs/en/troubleshoot-install#install-killed-on-low-memory-linux-servers>) for the swap-file commands.
+
+###
+
+
+
+The connection dropped while downloading the update
+
+The connection to the download server closed while `claude install`, `claude update`, or the [automatic updater](</docs/en/setup#auto-updates>) was fetching the Claude Code binary, and the retries didn’t recover. Claude Code retries the download when the connection drops, the transfer stalls, or the downloaded file fails its checksum, up to three attempts in total. A completed HTTP error, such as a 404, isn’t retried because the server already answered. Before v2.1.202, a single dropped connection failed the download immediately with the bare error `aborted` instead of retrying.
+
+ The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
+
+The text in parentheses names which attempt failed and the underlying network error. `claude update` precedes the message with `Error: Failed to install native update` on stderr. The usual cause is a proxy or gateway that closes a long transfer before it finishes. The Claude Code binary is a large download, so a proxy connection limit that never affects normal API traffic can still interrupt it. **What to do:**
+
+ * Run `claude update` again. On an otherwise healthy network, the download usually succeeds on the next run.
+ * If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](</docs/en/troubleshoot-install#check-network-connectivity>).
+ * If a corporate proxy keeps closing the transfer, ask your network team to allow the full download from `downloads.claude.ai`. See [Network access requirements](</docs/en/network-config#network-access-requirements>).
+ * Run `claude doctor` from your shell for installation diagnostics
##
@@ -971,7 +989,7 @@
* **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
* **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. `/doctor` flags oversized memory files and subagent definitions; `/context` shows MCP tool token usage.
-When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment.
+When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment. If Sonnet 5 refuses a request and cites a suspected prompt injection on Claude Code v2.1.200 or earlier, run `claude update` to pick up the v2.1.201 fix.
##
Show diff (230 lines)
--- a/errors.md
+++ b/errors.md
@@ -43,6 +43,7 @@
`SSL certificate verification failed`| Network
`SSL certificate error (...)` during login or startup| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
+`Couldn't reconnect to your Remote Control session`| Network
`Prompt is too long`| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -51,13 +52,16 @@
`PDF too large` / `PDF is password protected`| Request errors
`Extra inputs are not permitted`| Request errors
`There's an issue with the selected model`| Request errors
+`Model ... is not a recognized model id`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
`Model ... is restricted by your organization's settings`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
+`Installation was killed before it could finish (exit code 137)`| Installation errors
`--bg and --print conflict`| Command-line errors
+`Ignoring N permissions.allow entries from ... this workspace has not been trusted`| Configuration warnings
Responses seem lower quality than usual| Response quality
##
@@ -85,7 +89,7 @@
Server errors
-These errors come from the inference provider rather than your account or request. On the Anthropic API that means Anthropic infrastructure. On Bedrock, Vertex AI, Foundry, or a custom gateway it means that provider’s infrastructure.
+These errors come from the inference provider rather than your account or request. On the Anthropic API that means Anthropic infrastructure. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, or a custom gateway it means that provider’s infrastructure.
###
@@ -97,7 +101,7 @@
API Error: 500 Internal server error. This is a server-side issue, usually temporary — try again in a moment. If it persists, check https://status.claude.com.
-The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
+The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
@@ -217,7 +221,7 @@
* Match the error detail after the colon to its own section on this page, such as Usage limits or Server errors, and follow that section’s steps
* Once the underlying error clears, ask Claude to retry the task or [resume the subagent](</docs/en/sub-agents#resume-subagents>)
-When a rate limit, overload, or server error interrupts a foreground subagent that already produced output, Claude receives that partial output marked as incomplete instead of this error. See [API errors in subagents](</docs/en/sub-agents#api-errors-in-subagents>).
+When a rate limit, overload, or server error interrupts a foreground subagent that already produced text output, Claude receives that partial output marked as incomplete instead of this error. A subagent whose only output was tool calls gets this error too; in v2.1.199 that shape returned an empty partial result instead. See [API errors in subagents](</docs/en/sub-agents#api-errors-in-subagents>).
##
@@ -286,11 +290,11 @@
Request rejected (429)
-You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Vertex AI project.
+You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Cloud project.
API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check https://status.claude.com.
-The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. **What to do:**
+The trailing sentence names where to check service health and varies by provider. Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. **What to do:**
* Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
* Check your provider console for the active limits and request a higher tier if needed
@@ -454,7 +458,7 @@
Remote Control is only available when using Claude via api.anthropic.com.
-This appears on Amazon Bedrock, Google Vertex AI, and Microsoft Foundry. As of v2.1.196 it also appears when [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai. **What to do:**
+This appears on Amazon Bedrock, Google Cloud’s Agent Platform, and Microsoft Foundry. As of v2.1.196 it also appears when [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai. **What to do:**
* Unset `ANTHROPIC_BASE_URL` and restart the session, or start Remote Control from a session that talks to the Anthropic API directly
* For this and the other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
@@ -514,7 +518,7 @@
AWS authentication failed
-This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Claude Code can’t tell which cause you hit. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission or a model that isn’t enabled for your account. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
+This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Claude Code can’t tell which cause you hit. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission or a model that isn’t enabled for your account. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Amazon Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
AWS authentication failed · run /login and select "Claude Platform on AWS · refresh credentials", or run `aws sso login --profile myprofile` in another terminal · if credentials are current, check AWS permissions and model access · API Error: 403 ...
@@ -601,13 +605,29 @@
See [Network access](</docs/en/claude-code-on-the-web#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
+###
+
+
+
+Couldn’t reconnect to your Remote Control session
+
+ Couldn't reconnect to your Remote Control session. Retry, or start a fresh session without --resume.
+
+Resuming with `claude --resume` or `claude --continue` reconnects to the [Remote Control](</docs/en/remote-control>) session recorded in that conversation. This message means the reconnection failed for a reason that may be temporary, such as a network interruption or a server error, so Claude Code can’t confirm whether the remote session still exists. Your local session keeps running without Remote Control. **What to do:**
+
+ * Run `/remote-control` to retry the connection
+ * Start Claude Code without `--resume` to create a new Remote Control session
+ * For other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
+
+You won’t see this message when the server confirms the previous session no longer exists; Claude Code creates a new one in that case. Before v2.1.200, any reconnection failure created a new Remote Control session, which left extra sessions in the session list at claude.ai/code.
+
##
Request errors
-These errors mean the API received your request but rejected its content.
+These errors relate to the content of your request. Most come back from the API after it rejected the request; a few are produced locally by Claude Code before any request is sent.
###
@@ -746,7 +766,24 @@
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
- * For Vertex AI deployments, see [Vertex AI troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
+ * For Google Cloud’s Agent Platform deployments, see [Google Cloud’s Agent Platform troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
+
+###
+
+
+
+Model is not a recognized model id
+
+The model string you passed to a model switch isn’t a model alias, a model ID this Claude Code version knows, or an ID that starts with `claude-`. The usual causes are a typo in the ID, a display name such as `Sonnet 5` where the ID `claude-sonnet-5` is expected, or an alias that only newer Claude Code versions recognize. Claude Code rejects the switch immediately. Before v2.1.200, Claude Code saved the string and failed on the next request with There’s an issue with the selected model.
+
+ Model "claud-sonnet-5" is not a recognized model id. Did you mean 'claude-sonnet-5'?
+
+The trailing hint names the closest matching alias or model ID. When nothing is close enough, it reads `Run /model to see available models.` instead. Claude Code produces this error locally at the moment the switch is requested, before any API request is made. It applies when a model is set through the [Agent SDK](</docs/en/agent-sdk/typescript>) `setModel()` method or by an app such as the [Desktop app](</docs/en/desktop>) that runs the Claude Code CLI for you. **What to do:**
+
+ * Run `/model` with no argument to open the picker and choose from the models available to your account, then pass the alias or ID shown there
+ * If you used an alias that a newer Claude Code version supports, run `claude update`. A full ID that starts with `claude-` passes this check even when the model is newer than your Claude Code version, so upgrading isn’t needed for those.
+ * A model saved before v2.1.200 isn’t repaired by this check. If a stale value keeps coming back, remove it from the locations listed under There’s an issue with the selected model.
+ * The check runs only on the Anthropic API. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, [Claude Platform on AWS](</docs/en/claude-platform-on-aws>), and behind an [LLM gateway](</docs/en/llm-gateway>) or a custom `ANTHROPIC_BASE_URL`, your provider or gateway defines the model names, so Claude Code accepts any string and passes it through.
###
@@ -806,7 +843,7 @@
API Error: 400 ... max_tokens must be greater than thinking.budget_tokens
-Claude Code adjusts these values automatically on the Anthropic API. You typically see this error on Amazon Bedrock or Google Vertex AI when [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) is set higher than the provider’s output limit, or when plan mode raises the thinking budget. **What to do:**
+Claude Code adjusts these values automatically on the Anthropic API. You typically see this error on Amazon Bedrock or Google Cloud’s Agent Platform when [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) is set higher than the provider’s output limit, or when plan mode raises the thinking budget. **What to do:**
* Lower `MAX_THINKING_TOKENS`, or raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
* See [Extended thinking](</docs/en/model-config#extended-thinking>) for how the budget interacts with output length
@@ -848,6 +885,30 @@
+Installation errors
+
+These errors come from the [install script](</docs/en/setup#install-claude-code>) before Claude Code has started. For `command not found`, PATH, permission, and TLS problems during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>).
+
+###
+
+
+
+Installation was killed before it could finish
+
+The install script reports when the `claude install` step is terminated by a signal. On Linux, exit code 137 means the process received SIGKILL, and on a low-memory host that’s usually the kernel out-of-memory (OOM) killer. The script prints this explanation and exits with code 137:
+
+ Installation was killed before it could finish (exit code 137). This usually means the system ran out of memory.
+ Claude Code needs roughly 512MB of free memory to install. Free up memory, then run this script again.
+
+For any other fatal signal, and for exit code 137 on macOS, the script prints `Installation was killed before it could finish (exit code <N>)` with the actual exit code and omits the out-of-memory explanation. The message comes from the install script macOS and Linux use, which also covers installs inside WSL; the native Windows install scripts never print it. Before v2.1.200, the script exited with only the shell’s bare `Killed` line. **What to do:**
+
+ * Stop other processes to free memory, then rerun the installer
+ * Add swap space or move to a larger instance. See [Install killed on low-memory Linux servers](</docs/en/troubleshoot-install#install-killed-on-low-memory-linux-servers>) for the swap-file commands.
+
+##
+
+
+
Command-line errors
These errors come from Claude Code’s own validation of the `claude` command line. Claude Code prints them immediately, before it creates a session or sends any API request.
@@ -871,12 +932,36 @@
+Configuration warnings
+
+Claude Code writes these messages to stderr at startup rather than showing an error in the conversation. They report configuration it read but didn’t apply.
+
+###
+
+
+
+Workspace has not been trusted
+
+Claude Code found `permissions.allow` rules or `permissions.additionalDirectories` entries in the project’s `.claude/settings.json` or `.claude/settings.local.json` and didn’t apply them, because [allow rules from project settings require workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>). The count, the setting name, and the file named in the message vary with your configuration. `deny` and `ask` rules aren’t affected.
+
+ Ignoring 2 permissions.allow entries from .claude/settings.local.json: this workspace has not been trusted. Run Claude Code interactively here once and accept the trust dialog, or set projects["/Users/you/project"].hasTrustDialogAccepted: true in /Users/you/.claude.json.
+
+**What to do:**
+
+ * Run `claude` in the directory and accept the trust dialog. The dialog appears even when a parent directory is already trusted, lists the rules being held back, and lets you decline and keep working without them. Before v2.1.200, no dialog appeared in that situation, so this step couldn’t be completed there.
+ * In [non-interactive mode](</docs/en/headless>) with `-p` no dialog is shown. Set the `hasTrustDialogAccepted` entry in `~/.claude.json` using the exact `projects` key the message prints.
+ * If the message names `.claude/settings.local.json` and you started Claude Code outside a git repository or in your home directory, update to v2.1.200 or later. Versions 2.1.196 through 2.1.199 treated your own `.claude/settings.local.json` as repository-supplied in those workspaces. See [Project allow rules and workspace trust](</docs/en/permissions#project-allow-rules-and-workspace-trust>).
+
+##
+
+
+
Responses seem lower quality than usual
If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code doesn’t silently change model versions. It can switch to a fallback model in three specific cases:
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
- * A Bedrock or Vertex AI startup check finds your default model unavailable
+ * An Amazon Bedrock or Google Cloud’s Agent Platform startup check finds your default model unavailable
* [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5 moves the session to the default Opus model and shows a notice in the transcript
The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
@@ -902,7 +987,7 @@
If an error is not listed here or the suggested fix does not help:
- * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. On Bedrock, Vertex AI, Foundry, and other third-party providers, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
+ * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. On Amazon Bedrock, Google Cloud’s Agent Platform, Microsoft Foundry, and other third-party providers, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
* Run `/doctor` to check for local configuration problems
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub
Show diff (407 lines)
--- a/errors.md
+++ b/errors.md
@@ -15,9 +15,12 @@
`API Error: 500 Internal server error`| Server errors
`API Error: Repeated 529 Overloaded errors`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
+`Server error mid-response. The response above may be incomplete.`| Server errors
+`Connection closed mid-response` / `Response stalled mid-stream`| Server errors
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
+`Agent terminated early due to an API error`| Server errors
`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
`Usage credits required for 1M context`| Usage limits
`Server is temporarily limiting requests`| Usage limits
@@ -33,9 +36,12 @@
`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`does not meet scope requirement user:profile`| Authentication
+`AWS credentials expired or invalid`| Authentication
+`AWS authentication failed`| Authentication
`Unable to connect to API`| Network
`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`SSL certificate verification failed`| Network
+`SSL certificate error (...)` during login or startup| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`Prompt is too long`| Request errors
`Error during compaction: Conversation too long`| Request errors
@@ -51,6 +57,7 @@
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
+`--bg and --print conflict`| Command-line errors
Responses seem lower quality than usual| Response quality
##
@@ -59,12 +66,17 @@
Automatic retries
-Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. When you see one of the errors on this page, those retries have already been exhausted. You can tune the behavior with these environment variables:
+Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. As of v2.1.198, this covers connections that drop in the middle of a response before any visible output has streamed: Claude Code re-issues the request with the same backoff and the turn continues instead of stopping with a connection error. As of v2.1.199, temporary 429 throttles that don’t carry your plan’s quota headers are also retried when you’re signed in with a claude.ai subscription; earlier versions retried them only for API key and Enterprise sign-ins. Two failure classes aren’t retried, because a retry can’t succeed:
+
+ * As of v2.1.199, a TLS certificate validation failure, such as a TLS-inspecting proxy, a missing `NODE_EXTRA_CA_CERTS` bundle, or an expired certificate, fails on the first attempt so the fix appears immediately instead of after the full retry budget. See SSL certificate errors. Transient TLS conditions such as a handshake timeout still retry.
+ * As of v2.1.199, a server error that arrives after Claude has already streamed visible output keeps the partial response and appends an incomplete-response notice instead of retrying, since re-running the request could execute the same tools twice. Earlier versions discarded the partial output and reported the turn as an error.
+
+While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown after an error label. The label names the specific reason from the first attempt for failures you can act on right away: the network is down, a TLS handshake failed, or you hit a rate limit. For other errors it reads `API error` at first. As of v2.1.198 it switches to the specific reason from the third attempt, or on the final attempt when `CLAUDE_CODE_MAX_RETRIES` allows fewer than three; earlier versions switch only on the final attempt. As of v2.1.198, the usual spinner tip is suppressed during retries. Once the error reason is revealed, if the failure is a 529 overload the line below the countdown also names where to check service status: `status.claude.com` on the Anthropic API, or the provider or gateway host named in the message on other configurations. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. When you see one of the errors on this page, those retries have already been exhausted, unless it belongs to a class that isn’t retried, such as a certificate-validation failure. You can tune the behavior with these environment variables:
Variable| Default| Effect
---|---|---
-[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186. Lower it to surface failures faster in scripts.
-[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts.
+[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186; as of v2.1.199 `CLAUDE_CODE_RETRY_WATCHDOG` raises the default and removes the cap. Lower it to surface failures faster in scripts.
+[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts. As of v2.1.199 it also raises the default retry count for other transient errors, such as server errors, timeouts, and dropped connections, to 300, roughly three hours of backoff, and removes the cap of 15 on `CLAUDE_CODE_MAX_RETRIES` if you set that variable explicitly.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies.
##
@@ -101,7 +113,7 @@
API Error: Repeated 529 Overloaded errors. The API is at capacity — this is usually temporary. Try again in a moment. If it persists, check https://status.claude.com.
-The trailing sentence varies by provider in the same way as the 500 error above. A 529 is not your usage limit and does not count against your quota. **What to do:**
+The trailing sentence varies by provider in the same way as the 500 error above. A 529 is not your usage limit and doesn’t count against your quota. **What to do:**
* Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for capacity notices
* Try again in a few minutes
@@ -113,11 +125,11 @@
Request timed out
-The API did not respond before the connection deadline.
+The API didn’t respond before the connection deadline.
Request timed out
-This can happen during periods of high load or when a very large response is being generated. The default request timeout is 10 minutes. **What to do:**
+This can happen during periods of high load or when the model is generating a very large response. The default request timeout is 10 minutes. **What to do:**
* Retry the request
* For long-running tasks, break the work into smaller prompts
@@ -128,9 +140,31 @@
+The response above may be incomplete
+
+A streaming response failed after Claude had already produced visible output. Re-sending the request could run the same tool calls twice, so Claude Code keeps what already streamed and appends this notice instead of discarding the turn. Which variant you see names the cause:
+
+ API Error: Server error mid-response. The response above may be incomplete.
+ API Error: Connection closed mid-response. The response above may be incomplete.
+ API Error: Response stalled mid-stream. The response above may be incomplete.
+
+ * `Server error mid-response`: a mid-stream overloaded or 5xx server error. This variant requires Claude Code v2.1.199 or later; before then that case discarded the partial output and reported the whole turn as an error.
+ * `Connection closed mid-response`: the connection dropped.
+ * `Response stalled mid-stream`: the stream stopped sending data.
+
+**What to do:**
+
+ * Read the response that streamed. Nothing has been lost, but the final sentences or tool calls may be missing.
+ * Reply with `continue` to have Claude pick up where it stopped
+ * If the same error appears before any visible output, Claude Code retries the request instead of finalizing it. See Automatic retries.
+
+###
+
+
+
Auto mode cannot determine the safety of an action
-The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions could not produce a decision, so auto mode did not approve the action automatically. The message you see depends on why the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is overloaded:
+The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions couldn’t produce a decision, so auto mode didn’t approve the action automatically. The message you see depends on why the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is overloaded:
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait briefly and then try this action again.
@@ -138,7 +172,7 @@
* Retry after a few seconds; Claude sees the same message and usually retries on its own
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
- * This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you do not need to change settings
+ * This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you don’t need to change settings
When the classifier returned an unparseable response:
@@ -155,7 +189,7 @@
**What to do:**
- * This is not a decision about your action. A safety filter on the API was triggered by existing content in your conversation when auto mode sent the conversation to the classifier
+ * This is not a decision about your action. Content already in your conversation triggered a safety filter on the API when auto mode sent the conversation to the classifier
* Retrying will not help; the same conversation content will trigger the filter again
* Switch to a different [permission mode](</docs/en/permission-modes>) so you can approve the action when prompted, or start a fresh conversation without the triggering content
@@ -163,10 +197,27 @@
Auto mode classifier transcript exceeded context window — falling back to manual approval (try /compact to reduce conversation size)
-In an interactive session, auto mode falls back to a normal permission prompt for that action so you can approve or deny it manually. In [non-interactive mode](</docs/en/headless>) the run aborts because the transcript only grows and retrying cannot succeed. **What to do:**
+In an interactive session, auto mode falls back to a normal permission prompt for that action so you can approve or deny it manually. In [non-interactive mode](</docs/en/headless>) the run aborts because the transcript only grows and retrying can’t succeed. **What to do:**
* Approve or deny the action in the prompt that appears
* Run `/compact` to reduce the conversation size so subsequent actions fit within the classifier window again
+
+###
+
+
+
+Agent terminated early due to an API error
+
+A [subagent](</docs/en/sub-agents>)’s API request failed terminally, for example because a usage limit was reached or retries for a server error ran out, so the subagent stopped before finishing its task. This message requires Claude Code v2.1.199 or later; before then the API error text was returned to Claude as if it were the subagent’s result.
+
+ Agent terminated early due to an API error: <error detail>
+
+**What to do:**
+
+ * Match the error detail after the colon to its own section on this page, such as Usage limits or Server errors, and follow that section’s steps
+ * Once the underlying error clears, ask Claude to retry the task or [resume the subagent](</docs/en/sub-agents#resume-subagents>)
+
+When a rate limit, overload, or server error interrupts a foreground subagent that already produced output, Claude receives that partial output marked as incomplete instead of this error. See [API errors in subagents](</docs/en/sub-agents#api-errors-in-subagents>).
##
@@ -224,7 +275,7 @@
API Error: Server is temporarily limiting requests (not your usage limit)
-This is retried automatically before being shown. **What to do:**
+Claude Code tells these apart from your plan limit by the absence of the unified quota headers a real limit response carries. As of v2.1.199 this is retried automatically with backoff before being shown, whichever way you authenticate. On earlier versions, a session signed in with a claude.ai subscription failed the turn on the first occurrence; only API key and Enterprise sign-ins retried it. **What to do:**
* Wait briefly and try again
* Check [status.claude.com](<https://status.claude.com>) if it persists
@@ -285,7 +336,7 @@
* Run `/login` to authenticate with your Claude subscription or Console account
* If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
* For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings#available-settings>) script that fetches a key at startup
- * See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential wins when several are present
+ * See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential Claude Code uses when several are present
If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
@@ -295,7 +346,7 @@
Could not resolve authentication method
-The session reached the API client without any credential. This appears in [background sessions](</docs/en/agent-view>), cloud sessions, and Agent SDK contexts where the interactive login check does not run before the first request.
+The session reached the API client without any credential. This appears in [background sessions](</docs/en/agent-view>), cloud sessions, and Agent SDK contexts where the interactive login check doesn’t run before the first request.
Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
@@ -347,14 +398,14 @@
Your organization has disabled API key authentication
-Your Console organization’s admin has turned off API key authentication, so the API rejects the key Claude Code is sending. The recovery hint after the `·` varies by where the key came from:
+This message requires Claude Code v2.1.169 or later. Your Console organization’s admin has turned off API key authentication, so the API rejects the key Claude Code is sending. The recovery hint after the `·` varies by where the key came from:
Your organization has disabled API key authentication · Run /login to sign in with your claude.ai account
Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY to use your claude.ai account instead
Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY and run /login to sign in with your claude.ai account
Your organization has disabled API key authentication · Unset the apiKeyHelper setting and run /login to sign in with your claude.ai account
-Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone does not help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
+Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone doesn’t help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
* If the message names `ANTHROPIC_API_KEY`, unset it in the current shell and remove it from your shell profile or `.env` file, then relaunch `claude`
* If the message names `apiKeyHelper`, remove the [`apiKeyHelper`](</docs/en/settings#available-settings>) setting from your `settings.json`
@@ -368,11 +419,11 @@
Your organization has disabled Claude subscription access
-Your Claude organization does not allow signing in to Claude Code with a subscription login. Running `/login` again with the same account returns the same error.
+Your Claude organization doesn’t allow signing in to Claude Code with a subscription login. Running `/login` again with the same account returns the same error.
Your organization has disabled Claude subscription access for Claude Code · Use an Anthropic API key instead, or ask your admin to enable access
-This is a server-side organization setting, so it cannot be overridden from local settings, environment variables, or CLI flags. The Agent SDK and `-p` non-interactive mode surface this as the `oauth_org_not_allowed` error code. **What to do:**
+This is a server-side organization setting, so it can’t be overridden from local settings, environment variables, or CLI flags. The Agent SDK and `-p` non-interactive mode surface this as the `oauth_org_not_allowed` error code. **What to do:**
* Ask your admin to enable Claude Code access for your organization
* Authenticate with a Console API key instead of your subscription. See [Claude Console authentication](</docs/en/authentication#claude-console-authentication>) for setup.
@@ -388,7 +439,7 @@
Routines are disabled by your organization's policy.
-This is a server-side setting, so it cannot be overridden from local settings, environment variables, or CLI flags. **What to do:**
+This is a server-side setting, so it can’t be overridden from local settings, environment variables, or CLI flags. **What to do:**
* Ask an Owner in your organization to enable the **Routines** toggle at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
* For one-off scheduled work that does not require organization-level routines, see [scheduled tasks](</docs/en/scheduled-tasks>)
@@ -439,7 +490,39 @@
**What to do:**
- * Run `/login` to mint a new token with the current scopes. You do not need to log out first.
+ * Run `/login` to get a new token with the current scopes. You don’t need to log out first.
+
+###
+
+
+
+AWS credentials expired or invalid
+
+This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS session token expired or was rejected, and the automatic refresh Claude Code already ran didn’t produce a credential the API accepts. It appears on a 401 from [Claude Platform on AWS](</docs/en/claude-platform-on-aws>) or the [Mantle endpoint](</docs/en/amazon-bedrock#use-the-mantle-endpoint>), which is how those providers report an expired security token. The action hint in the middle names the `awsAuthRefresh` command from your settings, so it varies. The stable part is the leading `AWS credentials expired or invalid`:
+
+ AWS credentials expired or invalid · run /login and select "Claude Platform on AWS · refresh credentials", or run `aws sso login --profile myprofile` in another terminal · API Error: 401 ...
+
+Without `awsAuthRefresh` configured, the same 401 shows the generic `Please run /login` message instead, which can’t refresh AWS credentials. **What to do:**
+
+ * Run the `awsAuthRefresh` command named in the message, such as `aws sso login --profile myprofile`, in another terminal and complete the browser sign-in, then retry
+ * In an interactive session, run `/login`, choose **3rd-party platform** , then select **Claude Platform on AWS · refresh credentials** under **Using 3rd-party platforms** to run the same command without restarting Claude Code. See [Configure AWS credentials](</docs/en/claude-platform-on-aws#1-configure-aws-credentials>)
+ * If the error repeats after the refresh command succeeds, confirm the identity is valid outside Claude Code with `aws sts get-caller-identity` in the same shell and profile
+
+###
+
+
+
+AWS authentication failed
+
+This message requires Claude Code v2.1.198 or later and only appears when [`awsAuthRefresh`](</docs/en/amazon-bedrock#advanced-credential-configuration>) is set in your settings file. Your AWS provider returned a 403, or [Amazon Bedrock](</docs/en/amazon-bedrock>) returned a 401. Claude Code can’t tell which cause you hit. Amazon Bedrock reports an expired security token as a 403, but a 403 is also how it reports an authorization denial, such as an `AccessDeniedException` from a missing IAM permission or a model that isn’t enabled for your account. A 401 from Amazon Bedrock also lands here rather than under AWS credentials expired or invalid, because Bedrock doesn’t report an expired token as a 401. A 401 from that endpoint typically comes from something else in the request path, such as a corporate proxy. A credential refresh fixes an expired token and can’t fix the other causes, so the message offers both:
+
+ AWS authentication failed · run /login and select "Claude Platform on AWS · refresh credentials", or run `aws sso login --profile myprofile` in another terminal · if credentials are current, check AWS permissions and model access · API Error: 403 ...
+
+The action hint in the middle names the `awsAuthRefresh` command from your settings, so it varies. The stable part is the leading `AWS authentication failed`. **What to do:**
+
+ * Run the `awsAuthRefresh` command named in the message, or `aws sso login`, in case an expired credential is the cause
+ * If your credentials are current, confirm the IAM permissions in [IAM configuration](</docs/en/amazon-bedrock#iam-configuration>) are attached to the identity you’re using and that the selected model is enabled for your account and region
+ * Run `aws sts get-caller-identity` to confirm which identity your requests use; a stale `AWS_PROFILE` or default profile is a common cause of a permission mismatch
##
@@ -489,11 +572,15 @@
Unable to connect to API: SSL certificate verification failed. Check your proxy or corporate SSL certificates
Unable to connect to API: Self-signed certificate detected
+As of v2.1.199, a certificate validation failure isn’t retried, so this error appears on the first attempt instead of after the full retry budget. Earlier versions spent a few minutes retrying before showing it. Transient TLS conditions, such as a handshake timeout, still retry. During `/login` and the startup connectivity check, the same failure is reported with the OpenSSL code and the fix inline:
+
+ SSL certificate error (UNABLE_TO_GET_ISSUER_CERT_LOCALLY). If you are behind a corporate proxy or TLS-intercepting firewall, set NODE_EXTRA_CA_CERTS to your CA bundle path, or ask IT to allowlist *.anthropic.com. Run /doctor for details.
+
**What to do:**
* Export your organization’s CA bundle and point Claude Code at it with `NODE_EXTRA_CA_CERTS=/path/to/ca-bundle.pem`
* See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
- * Do not set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
+ * Don’t set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
###
@@ -556,7 +643,7 @@
This can happen when the window is already full at the moment auto-compact triggers, or when you run `/compact` after seeing `Prompt is too long`. **What to do:**
* Press Esc twice to open the message list and step back several turns. This drops the most recent messages from context. Then run `/compact` again.
- * If stepping back does not free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
+ * If stepping back doesn’t free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
###
@@ -596,14 +683,14 @@
Unable to resize image
-Claude Code could not downscale an attached image before sending it to the API.
+Claude Code couldn’t downscale an attached image before sending it to the API.
Unable to resize image — image processing is unavailable and dimensions could not be read from the file header. Please convert the image to PNG, JPEG, GIF, or WebP.
Unable to resize image — dimensions exceed the 2000x2000px limit and image processing failed. Please resize the image to reduce its pixel dimensions.
Unable to resize image (… raw, … base64). The image exceeds the … API limit and compression failed. Please resize the image manually or use a smaller image.
Unable to resize image — could not verify image dimensions are within the 2000x2000px API limit.
-Claude Code normally resizes large images automatically. These errors mean the native image processor failed to load or returned an error, so the image could not be resized to fit within API limits. **What to do:**
+Claude Code normally resizes large images automatically. These errors mean the native image processor failed to load or returned an error, so the image couldn’t be resized to fit within API limits. **What to do:**
* If the message asks you to convert the image, convert it to PNG, JPEG, GIF, or WebP and attach it again. Claude Code can verify dimensions for these formats without the image processor.
* If the message reports a dimension or size limit, resize or recompress the image below that limit before attaching.
@@ -614,7 +701,7 @@
PDF errors
-The PDF you attached could not be processed.
+The PDF you attached couldn’t be processed.
PDF too large (max 100 pages, 32 MB). Try splitting it or extracting text first.
PDF is password protected. Try removing protection or extracting text first.
@@ -637,7 +724,7 @@
API Error: 400 ... Extra inputs are not permitted ... tools.0.custom.input_examples
API Error: 400 ... Unexpected value(s) for the `anthropic-beta` header
-Claude Code sends beta-only fields such as `context_management`, `effort`, and tool `input_examples` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it does not recognize. **What to do:**
+Claude Code sends beta-only fields such as `context_management`, `effort`, and tool `input_examples` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it doesn’t recognize. **What to do:**
* Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. This disables features that require the beta header so requests succeed through a gateway that cannot forward it.
@@ -657,7 +744,7 @@
* **Interactive CLI** : run `/model` to pick from models available to your account.
* **Non-interactive mode (`-p`)**: pass `--model` with a valid alias or ID, or set [`ANTHROPIC_MODEL`](</docs/en/env-vars>). The error text shows `Run --model` on this surface.
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
- * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they do not go stale. See [Model configuration](</docs/en/model-config>).
+ * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they don’t go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
* For Vertex AI deployments, see [Vertex AI troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
@@ -690,7 +777,7 @@
**What to do:**
* Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
- * If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, or the `model` field of a settings file, remove or update that value so the notice does not recur on each launch
+ * If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, or the `model` field of a settings file, remove or update that value so the notice doesn’t recur on each launch
* If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
###
@@ -738,7 +825,7 @@
All three variants mean the same thing: the sequence of `tool_use`, `tool_result`, and `thinking` blocks in history no longer matches what the API expects. **What to do:**
- * If you are using Opus 4.7 or Opus 4.8, run `claude update` first. Versions before v2.1.156 can trigger this error during normal tool use, and `/rewind` does not clear it.
+ * If you are using Opus 4.7 or Opus 4.8, run `claude update` first. Versions before v2.1.156 can trigger this error during normal tool use, and `/rewind` doesn’t clear it.
* Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
###
@@ -754,16 +841,39 @@
The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. **What to do:**
* Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
- * If you cannot identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
+ * If you can’t identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
* In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt in a new session without `--continue`. Policy checks vary by model, so switching to a different model with `--model` may also resolve the refusal in some cases.
##
+Command-line errors
+
+These errors come from Claude Code’s own validation of the `claude` command line. Claude Code prints them immediately, before it creates a session or sends any API request.
+
+###
+
+
+
+Conflict between —bg and —print
+
+This message requires Claude Code v2.1.198 or later. You combined `--bg` with `-p` or `--print` in the same `claude` invocation. `--bg` starts a [background session](</docs/en/agent-view#from-your-shell>) that you later attach to with `claude agents`, while `--print` runs [non-interactively](</docs/en/headless>) and never starts the interactive session that `claude agents` attaches to. Before v2.1.198 this combination silently created a background job that could never be attached to.
+
+ --bg and --print conflict: --print never starts the interactive session that `claude agents` attaches to, so the job would be unattachable. The prompt is the positional — drop --print: `claude --bg '<task>'`.
+
+**What to do:**
+
+ * Drop `-p` or `--print`. `--bg` takes the prompt as its positional argument, so `claude --bg "<task>"` is the complete command. See [Dispatch new agents from your shell](</docs/en/agent-view#from-your-shell>).
+ * To run the prompt non-interactively and print the result instead of creating a background session, drop `--bg` and run `claude -p "<task>"`
+
+##
+
+
+
Responses seem lower quality than usual
-If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code does not silently change model versions. It can switch to a fallback model in three specific cases:
+If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code doesn’t silently change model versions. It can switch to a fallback model in three specific cases:
* A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
* A Bedrock or Vertex AI startup check finds your default model unavailable
@@ -784,7 +894,7 @@
Report an error
-This page covers errors from the Claude API. For errors from other Claude Code components, see the relevant guide:
+For errors from components this page doesn’t cover, see the relevant guide:
* MCP server failed to connect or authenticate: [MCP](</docs/en/mcp>)
* Hook script failed or blocked a tool: [Debug hooks](</docs/en/hooks#debug-hooks>)
--- a/errors.md
+++ b/errors.md
@@ -683,7 +683,7 @@
Model is restricted by your organization’s settings
-Your organization admin has disabled this model in the Claude Console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model.
+Your organization admin has disabled this model in the claude.ai admin console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model.
Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
--- a/errors.md
+++ b/errors.md
@@ -699,15 +699,15 @@
thinking.type.enabled is not supported for this model
-Your Claude Code version is older than the minimum for Opus 4.7 or Opus 4.8. The CLI sent a thinking configuration the model no longer accepts.
+Your Claude Code version is older than the minimum for Sonnet 5, Opus 4.8, or Opus 4.7. The CLI sent a thinking configuration the model no longer accepts.
API Error: 400 ... "thinking.type.enabled" is not supported for this model. Use "thinking.type.adaptive" and "output_config.effort" to control thinking behavior.
**What to do:**
- * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later
- * If you cannot upgrade, run `/model` and select Opus 4.6 or Sonnet instead
- * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later
+ * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later. Sonnet 5 needs v2.1.197 or later
+ * If you can’t upgrade, run `/model` and select Opus 4.6 or Sonnet 4.6 instead
+ * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later. Sonnet 5 needs TypeScript SDK v0.3.197 or later
###
--- a/errors.md
+++ b/errors.md
@@ -30,6 +30,7 @@
`Your organization has disabled API key authentication`| Authentication
`Your organization has disabled Claude subscription access`| Authentication
`Routines are disabled by your organization's policy`| Authentication
+`Remote Control is only available when using Claude via api.anthropic.com`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`does not meet scope requirement user:profile`| Authentication
`Unable to connect to API`| Network
@@ -396,6 +397,21 @@
+Remote Control requires the Anthropic API
+
+The session isn’t talking to the Anthropic API directly, so there is no claude.ai backend for [Remote Control](</docs/en/remote-control>) to pair with.
+
+ Remote Control is only available when using Claude via api.anthropic.com.
+
+This appears on Amazon Bedrock, Google Vertex AI, and Microsoft Foundry. As of v2.1.196 it also appears when [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) points at a host other than `api.anthropic.com`, such as an [LLM gateway](</docs/en/llm-gateway>) or proxy, even when you sign in with claude.ai. **What to do:**
+
+ * Unset `ANTHROPIC_BASE_URL` and restart the session, or start Remote Control from a session that talks to the Anthropic API directly
+ * For this and the other Remote Control startup messages, see [Troubleshoot Remote Control](</docs/en/remote-control#troubleshooting>)
+
+###
+
+
+
OAuth token revoked or expired
Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session.
--- a/errors.md
+++ b/errors.md
@@ -691,7 +691,7 @@
* Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later
* If you cannot upgrade, run `/model` and select Opus 4.6 or Sonnet instead
- * If you hit this in the Agent SDK, see [SDK troubleshooting](</docs/en/agent-sdk/quickstart#troubleshooting>)
+ * If you hit this in the [Agent SDK](</docs/en/agent-sdk/overview>), upgrade the SDK package instead. Opus 4.8 needs TypeScript SDK v0.3.154 or later and Python SDK v0.2.88 or later
###
--- a/errors.md
+++ b/errors.md
@@ -383,13 +383,13 @@
Routines are disabled by your organization’s policy
-Your Team or Enterprise admin has turned off routines at the organization level. The error appears when you try to create or run a routine, including from `/schedule` and the [Routines](</docs/en/routines>) UI on claude.ai/code.
+An Owner in your Team or Enterprise organization has turned off routines at the organization level. The error appears when you try to create or run a routine, including from `/schedule` and the [Routines](</docs/en/routines>) UI on claude.ai/code.
Routines are disabled by your organization's policy.
This is a server-side setting, so it cannot be overridden from local settings, environment variables, or CLI flags. **What to do:**
- * Ask your admin to enable the **Routines** toggle at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
+ * Ask an Owner in your organization to enable the **Routines** toggle at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
* For one-off scheduled work that does not require organization-level routines, see [scheduled tasks](</docs/en/scheduled-tasks>)
###
--- a/errors.md
+++ b/errors.md
@@ -45,6 +45,7 @@
`Extra inputs are not permitted`| Request errors
`There's an issue with the selected model`| Request errors
`Claude Opus is not available with the Claude Pro plan`| Request errors
+`Model ... is restricted by your organization's settings`| Request errors
`thinking.type.enabled is not supported for this model`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
@@ -146,6 +147,16 @@
* Retry the action; this usually succeeds on the next attempt
* Run `claude --debug` and repeat the action to see the underlying classifier response in the debug log
+
+When a separate API safety check blocked the classifier request because of earlier conversation content:
+
+ Auto mode could not evaluate this action and is blocking it for safety — a safety check separate from auto mode blocked this request because of earlier conversation content — it isn't about the action itself — run with --debug for details
+
+**What to do:**
+
+ * This is not a decision about your action. A safety filter on the API was triggered by existing content in your conversation when auto mode sent the conversation to the classifier
+ * Retrying will not help; the same conversation content will trigger the filter again
+ * Switch to a different [permission mode](</docs/en/permission-modes>) so you can approve the action when prompted, or start a fresh conversation without the triggering content
When the conversation has grown larger than the classifier’s context window:
@@ -441,7 +452,7 @@
* Confirm you can reach the API host from the same shell by running `curl -I https://api.anthropic.com`. On Windows PowerShell use `curl.exe -I https://api.anthropic.com` so the built-in `Invoke-WebRequest` alias is not used.
* If you are behind a corporate proxy, set `HTTPS_PROXY` before launching Claude Code and see [Network configuration](</docs/en/network-config>)
- * If you route through an LLM gateway or relay, set [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) to its address. See [LLM gateway configuration](</docs/en/llm-gateway>) for setup.
+ * If you route through an LLM gateway or relay, set [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) to its address. See [Connect Claude Code to an LLM gateway](</docs/en/llm-gateway-connect>) for setup.
* Ensure your firewall allows the hosts listed in [Network access requirements](</docs/en/network-config#network-access-requirements>)
* Intermittent failures are retried automatically; persistent failures point to a local network issue
@@ -612,7 +623,7 @@
Claude Code sends beta-only fields such as `context_management`, `effort`, and tool `input_examples` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it does not recognize. **What to do:**
- * Configure your gateway to forward the `anthropic-beta` header. See [LLM gateway configuration](</docs/en/llm-gateway>).
+ * Configure your gateway to forward the `anthropic-beta` header. See [feature pass-through](</docs/en/llm-gateway-protocol#feature-pass-through>) for what gateways must forward.
* As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. This disables features that require the beta header so requests succeed through a gateway that cannot forward it.
###
@@ -654,6 +665,22 @@
+Model is restricted by your organization’s settings
+
+Your organization admin has disabled this model in the Claude Console, or it is excluded by an [`availableModels`](</docs/en/model-config#restrict-model-selection>) allowlist in managed settings. When the restricted model was set with `--model`, `ANTHROPIC_MODEL`, or the `model` setting, Claude Code substitutes an allowed model and continues. Typing `/model <name>` for a restricted model is rejected with `Run /model to choose a different model.` and the session keeps its current model.
+
+ Model "claude-opus-4-8" is restricted by your organization's settings. Using claude-sonnet-4-6 instead.
+
+**What to do:**
+
+ * Run `/model` to pick from the models your organization allows. Restricted models are hidden from the picker.
+ * If the restricted model was set in `--model`, `ANTHROPIC_MODEL`, or the `model` field of a settings file, remove or update that value so the notice does not recur on each launch
+ * If you need access to the restricted model, ask your organization admin to enable it. See [Organization model restrictions](</docs/en/model-config#organization-model-restrictions>).
+
+###
+
+
+
thinking.type.enabled is not supported for this model
Your Claude Code version is older than the minimum for Opus 4.7 or Opus 4.8. The CLI sent a thinking configuration the model no longer accepts.
--- a/errors.md
+++ b/errors.md
@@ -33,6 +33,7 @@
`OAuth token revoked` / `OAuth token has expired`| Authentication
`does not meet scope requirement user:profile`| Authentication
`Unable to connect to API`| Network
+`Waiting for API response · will retry in`| Automatic retries, or Network if it persists
`SSL certificate verification failed`| Network
`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`Prompt is too long`| Request errors
@@ -56,11 +57,12 @@
Automatic retries
-Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown. When you see one of the errors on this page, those retries have already been exhausted. You can tune the behavior with two environment variables:
+Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown. If no data arrives on the response stream for 20 seconds while a request is still pending, the spinner shows `Waiting for API response · will retry in … · check your network` before any retry has started. The request has not failed yet: the countdown runs to the point where Claude Code aborts the stalled connection and retries, so the banner clears on its own once data resumes or the retry succeeds. As of v2.1.185 the threshold is 20 seconds; earlier versions show the banner after 10 seconds with different wording. If it reappears on every attempt, treat it as a network issue. When you see one of the errors on this page, those retries have already been exhausted. You can tune the behavior with these environment variables:
Variable| Default| Effect
---|---|---
-[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Lower it to surface failures faster in scripts; raise it to wait through longer incidents.
+[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Capped at 15 as of v2.1.186. Lower it to surface failures faster in scripts.
+[`CLAUDE_CODE_RETRY_WATCHDOG`](</docs/en/env-vars>)| unset| Set to `1` in unattended sessions such as CI jobs to retry `429` and `529` capacity errors indefinitely instead of failing after `CLAUDE_CODE_MAX_RETRIES` attempts.
[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies.
##
--- a/errors.md
+++ b/errors.md
@@ -24,6 +24,7 @@
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
`Not logged in · Please run /login`| Authentication
+`Could not resolve authentication method`| Authentication
`Invalid API key`| Authentication
`This organization has been disabled`| Authentication
`Your organization has disabled API key authentication`| Authentication
@@ -192,7 +193,7 @@
API Error: Usage credits required for 1M context · run /usage-credits to turn them on, or /model to switch to standard context
-This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. **What to do:**
+This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. When this error appears mid-conversation because the context grew past 200K tokens, Claude Code automatically compacts the conversation back under the standard context limit and keeps the session at that limit afterward, so no action is needed. On versions before v2.1.172, the error repeated on every subsequent request including `/compact`; run `/clear` on those versions to recover. The steps below apply when you explicitly selected a `[1m]` model. **What to do:**
* Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
* Run `/usage-credits` to turn on metered billing for the 1M variant on Pro and Max, or to request it from your admin on Team and Enterprise
@@ -273,6 +274,23 @@
* See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential wins when several are present
If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
+
+###
+
+
+
+Could not resolve authentication method
+
+The session reached the API client without any credential. This appears in [background sessions](</docs/en/agent-view>), cloud sessions, and Agent SDK contexts where the interactive login check does not run before the first request.
+
+ Could not resolve authentication method. Expected one of apiKey, authToken, credentials, config, or profile to be set. Or for one of the "X-Api-Key" or "Authorization" headers to be explicitly omitted
+
+Before v2.1.174, a background or cloud session assigned to an idle pre-initialized worker could fail this way even when valid credentials were configured. Upgrade to recover. On current versions the error means no credential was available to the worker process. **What to do:**
+
+ * Upgrade to v2.1.174 or later if this appears in a background or cloud session and your credentials are already configured
+ * Confirm `ANTHROPIC_API_KEY`, `CLAUDE_CODE_OAUTH_TOKEN`, or your cloud provider credentials are set in the environment that launches the worker, not only in your interactive shell
+ * For the Agent SDK, see [authentication setup](</docs/en/agent-sdk/overview#get-started>)
+ * Run `/status` in an interactive session in the same environment to confirm which credential source resolves
###
@@ -692,7 +710,7 @@
* Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
* If you cannot identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
- * In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt or start a new session without `--continue`.
+ * In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt in a new session without `--continue`. Policy checks vary by model, so switching to a different model with `--model` may also resolve the refusal in some cases.
##
--- a/errors.md
+++ b/errors.md
@@ -19,12 +19,14 @@
`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
`Auto mode classifier transcript exceeded context window`| Server errors
`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
+`Usage credits required for 1M context`| Usage limits
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
`Credit balance is too low`| Usage limits
`Not logged in · Please run /login`| Authentication
`Invalid API key`| Authentication
`This organization has been disabled`| Authentication
+`Your organization has disabled API key authentication`| Authentication
`Your organization has disabled Claude subscription access`| Authentication
`Routines are disabled by your organization's policy`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
@@ -184,6 +186,23 @@
+Usage credits required for 1M context
+
+The selected model uses the 1M-token extended context window, and your plan only includes it through usage credits.
+
+ API Error: Usage credits required for 1M context · run /usage-credits to turn them on, or /model to switch to standard context
+
+This is an entitlement check, not a quota exhaustion. It fires even when your session and weekly allowances have capacity remaining. See [Extended context](</docs/en/model-config#extended-context>) for which plans include 1M context directly and which require usage credits. **What to do:**
+
+ * Run `/model` and select the variant without the `[1m]` suffix to fall back to the standard context window
+ * Run `/usage-credits` to turn on metered billing for the 1M variant on Pro and Max, or to request it from your admin on Team and Enterprise
+ * If the error persists after `/model`, a 1M model ID may be set elsewhere. See There’s an issue with the selected model for the configuration locations to check in priority order.
+ * To remove 1M variants from the model picker entirely, set [`CLAUDE_CODE_DISABLE_1M_CONTEXT=1`](</docs/en/env-vars>)
+
+###
+
+
+
Server is temporarily limiting requests
The API applied a short-lived throttle that is unrelated to your plan quota.
@@ -289,6 +308,27 @@
* Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
* Run `/status` afterward to confirm the active credential is your subscription
* If no environment variable is set and the error persists, the disabled organization is the one tied to your `/login`. Contact support or sign in with a different account.
+
+###
+
+
+
+Your organization has disabled API key authentication
+
+Your Console organization’s admin has turned off API key authentication, so the API rejects the key Claude Code is sending. The recovery hint after the `·` varies by where the key came from:
+
+ Your organization has disabled API key authentication · Run /login to sign in with your claude.ai account
+ Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY to use your claude.ai account instead
+ Your organization has disabled API key authentication · Unset ANTHROPIC_API_KEY and run /login to sign in with your claude.ai account
+ Your organization has disabled API key authentication · Unset the apiKeyHelper setting and run /login to sign in with your claude.ai account
+
+Environment variables and `apiKeyHelper` take precedence over `/login`, so running `/login` alone does not help while either is still supplying a key. See [Authentication precedence](</docs/en/authentication#authentication-precedence>). **What to do:**
+
+ * If the message names `ANTHROPIC_API_KEY`, unset it in the current shell and remove it from your shell profile or `.env` file, then relaunch `claude`
+ * If the message names `apiKeyHelper`, remove the [`apiKeyHelper`](</docs/en/settings#available-settings>) setting from your `settings.json`
+ * Run `/login` to sign in with your claude.ai account
+ * Run `/status` afterward to confirm the active credential is your subscription rather than an API key
+ * If you need API key authentication for automation, ask your organization admin to re-enable it in the Console
###
@@ -498,9 +538,8 @@
Image was too large. Double press esc to go back and try again with a smaller image.
API Error: 400 ... image dimensions exceed max allowed size
-The image stays in conversation history after the error, so every subsequent message fails with the same error until you remove it. **What to do:**
-
- * Press Esc twice and step back past the turn where the image was added
+Claude Code replaces the unprocessable image with a text placeholder and retries, so subsequent messages succeed. On versions before 2.1.142, a pasted image could remain in the conversation and repeat the same error on every subsequent message. To recover on those versions, press Esc twice and step back past the turn where the image was added. **What to do:**
+
* Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 2000 pixels when many images are in context.
* Take a tighter screenshot of the relevant region instead of the full screen
@@ -661,7 +700,13 @@
Responses seem lower quality than usual
-If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code does not silently change model versions. It can switch to a fallback model in specific cases such as an Opus quota being reached or a Bedrock or Vertex AI region lacking your model; the Model selection check below catches both, and [Model configuration](</docs/en/model-config>) explains when fallback applies. Check these first:
+If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code does not silently change model versions. It can switch to a fallback model in three specific cases:
+
+ * A configured [`--fallback-model`](</docs/en/cli-reference#cli-flags>) takes over after an availability error, for that turn only, with a notice in the transcript
+ * A Bedrock or Vertex AI startup check finds your default model unavailable
+ * [Automatic model fallback](</docs/en/model-config#automatic-model-fallback>) on Fable 5 moves the session to the default Opus model and shows a notice in the transcript
+
+The Model selection check below catches the second and third cases; the first appears as a transcript notice rather than a `/model` change. [Model configuration](</docs/en/model-config>) explains when each fallback applies. Check these first:
* **Model selection** : run `/model` to confirm you are on the model you expect. A previous `/model` choice or an `ANTHROPIC_MODEL` environment variable may have you on a smaller model than you intended.
* **Effort level** : run `/effort` to check the current reasoning level and raise it for hard debugging or design work. Defaults vary by model, so check before assuming you are below the maximum. See [Adjust effort level](</docs/en/model-config#adjust-effort-level>) for per-model defaults and the `ultrathink` shortcut.
--- a/errors.md
+++ b/errors.md
@@ -571,7 +571,7 @@
* **Interactive CLI** : run `/model` to pick from models available to your account.
* **Non-interactive mode (`-p`)**: pass `--model` with a valid alias or ID, or set [`ANTHROPIC_MODEL`](</docs/en/env-vars>). The error text shows `Run --model` on this surface.
* **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
- * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases track the latest release so they do not go stale. See [Model configuration](</docs/en/model-config>).
+ * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases resolve to a maintained default so they do not go stale. See [Model configuration](</docs/en/model-config>).
* If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
* For Vertex AI deployments, see [Vertex AI troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
--- a/errors.md
+++ b/errors.md
@@ -1,9 +1,3 @@
-> ## Documentation Index
->
-> Fetch the complete documentation index at: <https://code.claude.com/docs/llms.txt>
->
-> Use this file to discover all available pages before exploring further.
-
This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). These errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For surface-specific issues, see the troubleshooting section on that surface’s page.
Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
--- a/errors.md
+++ b/errors.md
@@ -568,15 +568,17 @@
There’s an issue with the selected model
-The configured model name was not recognized or your account lacks access to it.
-
- There's an issue with the selected model (claude-...). It may not exist or you may not have access to it. Run /model to select a different one.
-
-**What to do:**
-
- * Run `/model` to pick from models available to your account
+The configured model name was not recognized or your account lacks access to it. As of v2.1.160 the trailing hint, shown here in its interactive form, varies by surface.
+
+ There's an issue with the selected model (claude-...). It may not exist or you may not have access to it. Run /model to pick a different model.
+
+**What to do:**
+
+ * **Interactive CLI** : run `/model` to pick from models available to your account.
+ * **Non-interactive mode (`-p`)**: pass `--model` with a valid alias or ID, or set [`ANTHROPIC_MODEL`](</docs/en/env-vars>). The error text shows `Run --model` on this surface.
+ * **Agent SDK** : the error text omits the hint because the model is set programmatically. Set [`model` on `Options`](</docs/en/agent-sdk/typescript#options>) in TypeScript or [`ClaudeAgentOptions(model=...)`](</docs/en/agent-sdk/python#claudeagentoptions>) in Python, and handle the structured `model_not_found` error to surface your own retry or model picker.
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases track the latest release so they do not go stale. See [Model configuration](</docs/en/model-config>).
- * If the wrong model keeps coming back, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
+ * If the wrong model keeps coming back in the CLI, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
* For Vertex AI deployments, see [Vertex AI troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
###
--- a/errors.md
+++ b/errors.md
@@ -640,6 +640,7 @@
All three variants mean the same thing: the sequence of `tool_use`, `tool_result`, and `thinking` blocks in history no longer matches what the API expects. **What to do:**
+ * If you are using Opus 4.7 or Opus 4.8, run `claude update` first. Versions before v2.1.156 can trigger this error during normal tool use, and `/rewind` does not clear it.
* Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
###
--- a/errors.md
+++ b/errors.md
@@ -601,13 +601,13 @@
thinking.type.enabled is not supported for this model
-Your Claude Code version is older than the minimum for Opus 4.7. The CLI sent a thinking configuration the model no longer accepts.
+Your Claude Code version is older than the minimum for Opus 4.7 or Opus 4.8. The CLI sent a thinking configuration the model no longer accepts.
API Error: 400 ... "thinking.type.enabled" is not supported for this model. Use "thinking.type.adaptive" and "output_config.effort" to control thinking behavior.
**What to do:**
- * Run `claude update` to upgrade to v2.1.111 or later, then restart Claude Code
+ * Run `claude update` and restart Claude Code. Opus 4.7 needs v2.1.111 or later. Opus 4.8 needs v2.1.154 or later
* If you cannot upgrade, run `/model` and select Opus 4.6 or Sonnet instead
* If you hit this in the Agent SDK, see [SDK troubleshooting](</docs/en/agent-sdk/quickstart#troubleshooting>)
--- a/errors.md
+++ b/errors.md
@@ -82,7 +82,7 @@
Claude Code shows the status code and the API’s error message for any 5xx response. The example below shows a 500 response on the Anthropic API:
- API Error: 500 Internal server error. This is a server-side issue, usually temporary — try again in a moment. If it persists, check status.claude.com.
+ API Error: 500 Internal server error. This is a server-side issue, usually temporary — try again in a moment. If it persists, check https://status.claude.com.
The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
@@ -98,7 +98,7 @@
The API is temporarily at capacity across all users. Claude Code has already retried several times before showing this message:
- API Error: Repeated 529 Overloaded errors. The API is at capacity — this is usually temporary. Try again in a moment. If it persists, check status.claude.com.
+ API Error: Repeated 529 Overloaded errors. The API is at capacity — this is usually temporary. Try again in a moment. If it persists, check https://status.claude.com.
The trailing sentence varies by provider in the same way as the 500 error above. A 529 is not your usage limit and does not count against your quota. **What to do:**
@@ -209,7 +209,7 @@
You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Vertex AI project.
- API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check status.claude.com.
+ API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check https://status.claude.com.
The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. **What to do:**
--- a/errors.md
+++ b/errors.md
@@ -18,7 +18,7 @@
Message| Section
---|---
-`API Error: 500 ... Internal server error`| Server errors
+`API Error: 500 Internal server error`| Server errors
`API Error: Repeated 529 Overloaded errors`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
@@ -42,6 +42,7 @@
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
`Image was too large`| Request errors
+`Unable to resize image`| Request errors
`PDF too large` / `PDF is password protected`| Request errors
`Extra inputs are not permitted`| Request errors
`There's an issue with the selected model`| Request errors
@@ -71,7 +72,7 @@
Server errors
-These errors come from Anthropic infrastructure rather than your account or request.
+These errors come from the inference provider rather than your account or request. On the Anthropic API that means Anthropic infrastructure. On Bedrock, Vertex AI, Foundry, or a custom gateway it means that provider’s infrastructure.
###
@@ -79,13 +80,13 @@
API Error: 500 Internal server error
-Claude Code shows the raw API response body for any 5xx status. The example below shows a 500 response:
-
- API Error: 500 {"type":"error","error":{"type":"api_error","message":"Internal server error"}} · check status.claude.com
-
-This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
-
- * Check [status.claude.com](<https://status.claude.com>) for active incidents
+Claude Code shows the status code and the API’s error message for any 5xx response. The example below shows a 500 response on the Anthropic API:
+
+ API Error: 500 Internal server error. This is a server-side issue, usually temporary — try again in a moment. If it persists, check status.claude.com.
+
+The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status. A custom `ANTHROPIC_BASE_URL` names the gateway host. This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
+
+ * Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
* If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable in your environment.
@@ -97,11 +98,11 @@
The API is temporarily at capacity across all users. Claude Code has already retried several times before showing this message:
- API Error: Repeated 529 Overloaded errors · check status.claude.com
-
-A 529 is not your usage limit and does not count against your quota. **What to do:**
-
- * Check [status.claude.com](<https://status.claude.com>) for capacity notices
+ API Error: Repeated 529 Overloaded errors. The API is at capacity — this is usually temporary. Try again in a moment. If it persists, check status.claude.com.
+
+The trailing sentence varies by provider in the same way as the 500 error above. A 529 is not your usage limit and does not count against your quota. **What to do:**
+
+ * Check [status.claude.com](<https://status.claude.com>), or the provider status page named in the message, for capacity notices
* Try again in a few minutes
* Run `/model` and switch to a different model to keep working, since capacity is tracked per model. Claude Code prompts you to do this when one model is under particularly high load, for example `Opus is experiencing high load, please use /model to switch to Sonnet`.
@@ -210,7 +211,7 @@
API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check status.claude.com.
-The trailing sentence names where to check service health and varies by provider. Bedrock and Vertex AI configurations name that provider’s service status instead of the Anthropic status page. **What to do:**
+The trailing sentence names where to check service health and varies by provider. Bedrock, Vertex AI, and Foundry configurations name that provider’s service status instead of the Anthropic status page. A custom `ANTHROPIC_BASE_URL` names the gateway host. **What to do:**
* Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
* Check your provider console for the active limits and request a higher tier if needed
@@ -513,6 +514,24 @@
+Unable to resize image
+
+Claude Code could not downscale an attached image before sending it to the API.
+
+ Unable to resize image — image processing is unavailable and dimensions could not be read from the file header. Please convert the image to PNG, JPEG, GIF, or WebP.
+ Unable to resize image — dimensions exceed the 2000x2000px limit and image processing failed. Please resize the image to reduce its pixel dimensions.
+ Unable to resize image (… raw, … base64). The image exceeds the … API limit and compression failed. Please resize the image manually or use a smaller image.
+ Unable to resize image — could not verify image dimensions are within the 2000x2000px API limit.
+
+Claude Code normally resizes large images automatically. These errors mean the native image processor failed to load or returned an error, so the image could not be resized to fit within API limits. **What to do:**
+
+ * If the message asks you to convert the image, convert it to PNG, JPEG, GIF, or WebP and attach it again. Claude Code can verify dimensions for these formats without the image processor.
+ * If the message reports a dimension or size limit, resize or recompress the image below that limit before attaching.
+
+###
+
+
+
PDF errors
The PDF you attached could not be processed.
--- a/errors.md
+++ b/errors.md
@@ -31,6 +31,7 @@
`Not logged in · Please run /login`| Authentication
`Invalid API key`| Authentication
`This organization has been disabled`| Authentication
+`Your organization has disabled Claude subscription access`| Authentication
`Routines are disabled by your organization's policy`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`does not meet scope requirement user:profile`| Authentication
@@ -48,6 +49,7 @@
`thinking.type.enabled is not supported for this model`| Request errors
`max_tokens must be greater than thinking.budget_tokens`| Request errors
`API Error: 400 due to tool use concurrency issues`| Request errors
+`Claude Code is unable to respond to this request, which appears to violate our Usage Policy`| Request errors
Responses seem lower quality than usual| Response quality
##
@@ -178,7 +180,7 @@
* Wait for the reset time shown in the error
* Run `/usage` to see your plan limits and when they reset
- * Run `/extra-usage` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [Extra usage for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
+ * Run `/usage-credits` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [usage credits for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
* To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
To watch your remaining allowance before you hit the limit, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
@@ -206,9 +208,9 @@
You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Vertex AI project.
- API Error: Request rejected (429) · this may be a temporary capacity issue
-
-**What to do:**
+ API Error: Request rejected (429) · this may be a temporary capacity issue. If it persists, check status.claude.com.
+
+The trailing sentence names where to check service health and varies by provider. Bedrock and Vertex AI configurations name that provider’s service status instead of the Anthropic status page. **What to do:**
* Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
* Check your provider console for the active limits and request a higher tier if needed
@@ -292,6 +294,22 @@
* Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
* Run `/status` afterward to confirm the active credential is your subscription
* If no environment variable is set and the error persists, the disabled organization is the one tied to your `/login`. Contact support or sign in with a different account.
+
+###
+
+
+
+Your organization has disabled Claude subscription access
+
+Your Claude organization does not allow signing in to Claude Code with a subscription login. Running `/login` again with the same account returns the same error.
+
+ Your organization has disabled Claude subscription access for Claude Code · Use an Anthropic API key instead, or ask your admin to enable access
+
+This is a server-side organization setting, so it cannot be overridden from local settings, environment variables, or CLI flags. The Agent SDK and `-p` non-interactive mode surface this as the `oauth_org_not_allowed` error code. **What to do:**
+
+ * Ask your admin to enable Claude Code access for your organization
+ * Authenticate with a Console API key instead of your subscription. See [Claude Console authentication](</docs/en/authentication#claude-console-authentication>) for setup.
+ * If you are the admin and do not see an option to enable access, contact [Anthropic support](<https://support.claude.com>)
###
@@ -605,6 +623,22 @@
* Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
+###
+
+
+
+Usage Policy refusal
+
+The API declined to respond because content in the conversation triggered a [Usage Policy](<https://www.anthropic.com/legal/aup>) check. The message includes a Request ID you can quote to support if you believe the refusal is incorrect.
+
+ API Error: Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message or start a new session for Claude Code to assist with a different task.
+
+The check evaluates the full conversation, not only your latest prompt, so sending a new message in the same session usually re-triggers the same refusal. The same applies after exiting and reopening the session with `--continue` or `--resume`, since the transcript on disk still contains the triggering content. **What to do:**
+
+ * Press Esc twice or run `/rewind` to step back to a checkpoint before the turn that triggered the refusal, then rephrase or take a different approach. See [Checkpointing](</docs/en/checkpointing>).
+ * If you cannot identify which turn caused it, run `/clear` to start a fresh conversation in the same project. Your previous conversation is preserved on disk and remains available in `/resume`.
+ * In [non-interactive mode](</docs/en/headless>) (`-p`), where rewind is unavailable, retry with a rephrased prompt or start a new session without `--continue`.
+
##
--- a/errors.md
+++ b/errors.md
@@ -85,7 +85,7 @@
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
- * If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable on your provider.
+ * If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable in your environment.
###
@@ -618,7 +618,7 @@
* **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
* **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. `/doctor` flags oversized memory files and subagent definitions; `/context` shows MCP tool token usage.
-When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable on your provider.
+When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable in your environment.
##
@@ -634,7 +634,7 @@
If an error is not listed here or the suggested fix does not help:
- * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. Feedback is unavailable on Bedrock, Vertex AI, and Foundry deployments.
+ * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. On Bedrock, Vertex AI, Foundry, and other third-party providers, `/feedback` saves a local archive you can send to your Anthropic account representative instead.
* Run `/doctor` to check for local configuration problems
* Check [status.claude.com](<https://status.claude.com>) for active incidents
* Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub
--- a/errors.md
+++ b/errors.md
@@ -22,6 +22,8 @@
`API Error: Repeated 529 Overloaded errors`| Server errors
`Request timed out`| Server errors, or Network if the message mentions your internet connection
`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
+`Auto mode could not evaluate this action and is blocking it for safety`| Server errors
+`Auto mode classifier transcript exceeded context window`| Server errors
`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
`Server is temporarily limiting requests`| Usage limits
`Request rejected (429)`| Usage limits
@@ -124,15 +126,33 @@
Auto mode cannot determine the safety of an action
-The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions is overloaded, so auto mode blocked the action instead of approving it unchecked.
+The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions could not produce a decision, so auto mode did not approve the action automatically. The message you see depends on why the classifier failed. Reads, searches, and edits inside your working directory skip the classifier, so they keep working in all of these cases. When the classifier model is overloaded:
<model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait briefly and then try this action again.
-Reads, searches, and edits inside your working directory skip the classifier, so they keep working during the outage. **What to do:**
+**What to do:**
* Retry after a few seconds; Claude sees the same message and usually retries on its own
* If retries keep failing, continue with read-only tasks and come back to the blocked action later
* This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you do not need to change settings
+
+When the classifier returned an unparseable response:
+
+ Auto mode could not evaluate this action and is blocking it for safety — run with --debug for details
+
+**What to do:**
+
+ * Retry the action; this usually succeeds on the next attempt
+ * Run `claude --debug` and repeat the action to see the underlying classifier response in the debug log
+
+When the conversation has grown larger than the classifier’s context window:
+
+ Auto mode classifier transcript exceeded context window — falling back to manual approval (try /compact to reduce conversation size)
+
+In an interactive session, auto mode falls back to a normal permission prompt for that action so you can approve or deny it manually. In [non-interactive mode](</docs/en/headless>) the run aborts because the transcript only grows and retrying cannot succeed. **What to do:**
+
+ * Approve or deny the action in the prompt that appears
+ * Run `/compact` to reduce the conversation size so subsequent actions fit within the classifier window again
##
--- a/errors.md
+++ b/errors.md
@@ -29,6 +29,7 @@
`Not logged in · Please run /login`| Authentication
`Invalid API key`| Authentication
`This organization has been disabled`| Authentication
+`Routines are disabled by your organization's policy`| Authentication
`OAuth token revoked` / `OAuth token has expired`| Authentication
`does not meet scope requirement user:profile`| Authentication
`Unable to connect to API`| Network
@@ -276,6 +277,21 @@
+Routines are disabled by your organization’s policy
+
+Your Team or Enterprise admin has turned off routines at the organization level. The error appears when you try to create or run a routine, including from `/schedule` and the [Routines](</docs/en/routines>) UI on claude.ai/code.
+
+ Routines are disabled by your organization's policy.
+
+This is a server-side setting, so it cannot be overridden from local settings, environment variables, or CLI flags. **What to do:**
+
+ * Ask your admin to enable the **Routines** toggle at [claude.ai/admin-settings/claude-code](<https://claude.ai/admin-settings/claude-code>)
+ * For one-off scheduled work that does not require organization-level routines, see [scheduled tasks](</docs/en/scheduled-tasks>)
+
+###
+
+
+
OAuth token revoked or expired
Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session.
--- a/errors.md
+++ b/errors.md
@@ -33,6 +33,7 @@
`does not meet scope requirement user:profile`| Authentication
`Unable to connect to API`| Network
`SSL certificate verification failed`| Network
+`403` with `x-deny-reason: host_not_allowed` in a cloud or routine session| Network
`Prompt is too long`| Request errors
`Error during compaction: Conversation too long`| Request errors
`Request too large`| Request errors
@@ -310,7 +311,7 @@
Network and connection errors
-These errors mean Claude Code could not reach the API at all. They almost always originate in your local network, proxy, or firewall rather than Anthropic infrastructure.
+These errors mean a network request from Claude Code failed to reach its destination. They usually originate in your local network, proxy, or firewall, or in the cloud environment’s network policy.
###
@@ -358,6 +359,25 @@
* See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
* Do not set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
+###
+
+
+
+Host not allowed in a cloud session
+
+An outbound HTTP request from a cloud session or routine was blocked by the environment’s network policy.
+
+ HTTP 403
+ x-deny-reason: host_not_allowed
+
+You may also see a TLS certificate that doesn’t match the destination’s real certificate. The cloud environment routes outbound traffic through a proxy that enforces the network policy, so a mismatched certificate means the proxy terminated the connection, not the destination. This is not a client-side network problem. Cloud sessions and [routines](</docs/en/routines>) run inside a sandboxed environment whose outbound traffic is filtered to the environment’s allowlist. The **Default** environment uses **Trusted** access, which permits the [default allowlist](</docs/en/claude-code-on-the-web#default-allowed-domains>) of package registries, cloud provider APIs, container registries, and common development domains but blocks everything else. **What to do:**
+
+ * Open the routine for editing, or start a cloud session. Select the cloud icon showing your environment’s name, such as **Default** , to open the selector. Hover over your environment and click the settings icon.
+ * In the **Update cloud environment** dialog, change **Network access** from **Trusted** to **Custom** , then add the blocked domain to **Allowed domains**. Enter one domain per line. Check **Also include default list of common package managers** to keep the [default allowlist](</docs/en/claude-code-on-the-web#default-allowed-domains>) alongside your custom domains. Select **Full** instead if you want unrestricted access.
+ * Click **Save changes**. The next run uses the updated allowlist.
+
+See [Network access](</docs/en/claude-code-on-the-web#network-access>) for access levels and the default allowlist. Local CLI sessions are not affected by this policy.
+
##
--- a/errors.md
+++ b/errors.md
@@ -335,7 +335,7 @@
* Ensure your firewall allows the hosts listed in [Network access requirements](</docs/en/network-config#network-access-requirements>)
* Intermittent failures are retried automatically; persistent failures point to a local network issue
-If `curl` succeeds but Claude Code still fails, the cause is usually something between Node.js and the network rather than the network itself:
+If `curl` succeeds but Claude Code still fails, the cause is usually something between the runtime and the network rather than the network itself:
* On Linux and WSL, check `/etc/resolv.conf` for an unreachable nameserver. WSL in particular can inherit a broken resolver from the host.
* On macOS, a VPN client that was disconnected or uninstalled can leave a tunnel interface or routing rule behind. Check `ifconfig` for stale `utun` interfaces and remove the VPN’s network extension in System Settings.
@@ -347,14 +347,14 @@
SSL certificate errors
-A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Node.js does not trust it.
+A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Claude Code does not trust it.
Unable to connect to API: SSL certificate verification failed. Check your proxy or corporate SSL certificates
Unable to connect to API: Self-signed certificate detected
**What to do:**
- * Export your organization’s CA bundle and point Node at it with `NODE_EXTRA_CA_CERTS=/path/to/ca-bundle.pem`
+ * Export your organization’s CA bundle and point Claude Code at it with `NODE_EXTRA_CA_CERTS=/path/to/ca-bundle.pem`
* See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
* Do not set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
--- a/errors.md
+++ b/errors.md
@@ -531,7 +531,7 @@
Claude Code adjusts these values automatically on the Anthropic API. You typically see this error on Amazon Bedrock or Google Vertex AI when [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) is set higher than the provider’s output limit, or when plan mode raises the thinking budget. **What to do:**
* Lower `MAX_THINKING_TOKENS`, or raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
- * See [Extended thinking](</docs/en/common-workflows#use-extended-thinking-thinking-mode>) for how the budget interacts with output length
+ * See [Extended thinking](</docs/en/model-config#extended-thinking>) for how the budget interacts with output length
###
--- a/errors.md
+++ b/errors.md
@@ -1,4 +1,10 @@
-This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshooting](</docs/en/troubleshooting>). These errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For surface-specific issues, see the troubleshooting section on that surface’s page.
+> ## Documentation Index
+>
+> Fetch the complete documentation index at: <https://code.claude.com/docs/llms.txt>
+>
+> Use this file to discover all available pages before exploring further.
+
+This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshoot installation and login](</docs/en/troubleshoot-install>). These errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For surface-specific issues, see the troubleshooting section on that surface’s page.
Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
@@ -228,7 +234,7 @@
* For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings#available-settings>) script that fetches a key at startup
* See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential wins when several are present
-If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshooting#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
+If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
###
@@ -281,8 +287,8 @@
* Run `/login` to sign in again
* If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
- * For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshooting#not-logged-in-or-token-expired>)
- * For other failures including `403 Forbidden` and OAuth browser issues, see [Permissions and authentication](</docs/en/troubleshooting#permissions-and-authentication>)
+ * For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshoot-install#not-logged-in-or-token-expired>)
+ * For other failures including `403 Forbidden` and OAuth browser issues, see [Login and authentication](</docs/en/troubleshoot-install#login-and-authentication>)
###
@@ -477,7 +483,8 @@
* Run `/model` to pick from models available to your account
* Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases track the latest release so they do not go stale. See [Model configuration](</docs/en/model-config>).
- * See [Model not found](</docs/en/troubleshooting#model-not-found-or-not-accessible>) to locate where a stale ID is set across `--model`, `ANTHROPIC_MODEL`, and settings files
+ * If the wrong model keeps coming back, a stale ID is set somewhere. Check in [priority order](</docs/en/model-config#setting-your-model>): the `--model` flag, the `ANTHROPIC_MODEL` environment variable, then the `model` field in `.claude/settings.local.json`, your project’s `.claude/settings.json`, and `~/.claude/settings.json`. Remove the stale value and Claude Code falls back to your account default.
+ * For Vertex AI deployments, see [Vertex AI troubleshooting](</docs/en/google-vertex-ai#troubleshooting>).
###
@@ -567,7 +574,7 @@
* MCP server failed to connect or authenticate: [MCP](</docs/en/mcp>)
* Hook script failed or blocked a tool: [Debug hooks](</docs/en/hooks#debug-hooks>)
- * Permission denied or filesystem errors during install: [Troubleshooting](</docs/en/troubleshooting>)
+ * Permission denied or filesystem errors during install: [Troubleshoot installation and login](</docs/en/troubleshoot-install>)
If an error is not listed here or the suggested fix does not help:
--- a/errors.md
+++ b/errors.md
@@ -375,7 +375,7 @@
* Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
* Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
* Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
- * Trim large `CLAUDE.md` memory files or split them into [imports](</docs/en/memory>)
+ * Trim large `CLAUDE.md` memory files, or move instructions into [path-scoped rules](</docs/en/memory#path-specific-rules>) that load only when relevant
* Subagents inherit every MCP tool definition from the parent session, which can fill their context window before the first turn. Disable MCP servers you are not using before spawning subagents.
* Auto-compact is on by default and normally prevents this error. If you have set [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), re-enable it or run `/compact` manually before the window fills.
@@ -551,7 +551,7 @@
If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code does not silently change model versions. It can switch to a fallback model in specific cases such as an Opus quota being reached or a Bedrock or Vertex AI region lacking your model; the Model selection check below catches both, and [Model configuration](</docs/en/model-config>) explains when fallback applies. Check these first:
* **Model selection** : run `/model` to confirm you are on the model you expect. A previous `/model` choice or an `ANTHROPIC_MODEL` environment variable may have you on a smaller model than you intended.
- * **Effort level** : run `/effort` to check the current reasoning level and raise it for hard debugging or design work. Defaults vary by model and plan, so check before assuming you are below the maximum. See [Adjust effort level](</docs/en/model-config#adjust-effort-level>) for per-model defaults and the `ultrathink` shortcut.
+ * **Effort level** : run `/effort` to check the current reasoning level and raise it for hard debugging or design work. Defaults vary by model, so check before assuming you are below the maximum. See [Adjust effort level](</docs/en/model-config#adjust-effort-level>) for per-model defaults and the `ultrathink` shortcut.
* **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
* **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. `/doctor` flags oversized memory files and subagent definitions; `/context` shows MCP tool token usage.
Show diff (580 lines)
--- a/errors.md
+++ b/errors.md
@@ -0,0 +1,577 @@
+This page lists runtime errors Claude Code displays and how to recover from each one, plus what to check when responses seem off without an error. For installation errors such as `command not found` or TLS failures during setup, see [Troubleshooting](</docs/en/troubleshooting>). These errors and recovery commands apply across the CLI, the [Desktop app](</docs/en/desktop>), and [Claude Code on the web](</docs/en/claude-code-on-the-web>), since all three wrap the same Claude Code CLI. For surface-specific issues, see the troubleshooting section on that surface’s page.
+
+Claude Code calls the Claude API for model responses, so most runtime errors map to an underlying API error code. This page covers what each error means inside Claude Code and how to recover. For the raw HTTP status code definitions, see the [Claude Platform error reference](<https://platform.claude.com/docs/en/api/errors>).
+
+##
+
+
+
+Find your error
+
+Match the message you see in your terminal to a section below.
+
+Message| Section
+---|---
+`API Error: 500 ... Internal server error`| Server errors
+`API Error: Repeated 529 Overloaded errors`| Server errors
+`Request timed out`| Server errors, or Network if the message mentions your internet connection
+`<model> is temporarily unavailable, so auto mode cannot determine the safety of...`| Server errors
+`You've hit your session limit` / `You've hit your weekly limit`| Usage limits
+`Server is temporarily limiting requests`| Usage limits
+`Request rejected (429)`| Usage limits
+`Credit balance is too low`| Usage limits
+`Not logged in · Please run /login`| Authentication
+`Invalid API key`| Authentication
+`This organization has been disabled`| Authentication
+`OAuth token revoked` / `OAuth token has expired`| Authentication
+`does not meet scope requirement user:profile`| Authentication
+`Unable to connect to API`| Network
+`SSL certificate verification failed`| Network
+`Prompt is too long`| Request errors
+`Error during compaction: Conversation too long`| Request errors
+`Request too large`| Request errors
+`Image was too large`| Request errors
+`PDF too large` / `PDF is password protected`| Request errors
+`Extra inputs are not permitted`| Request errors
+`There's an issue with the selected model`| Request errors
+`Claude Opus is not available with the Claude Pro plan`| Request errors
+`thinking.type.enabled is not supported for this model`| Request errors
+`max_tokens must be greater than thinking.budget_tokens`| Request errors
+`API Error: 400 due to tool use concurrency issues`| Request errors
+Responses seem lower quality than usual| Response quality
+
+##
+
+
+
+Automatic retries
+
+Claude Code retries transient failures before showing you an error. Server errors, overloaded responses, request timeouts, temporary 429 throttles, and dropped connections are all retried up to 10 times with exponential backoff. While retrying, the spinner shows a `Retrying in Ns · attempt x/y` countdown. When you see one of the errors on this page, those retries have already been exhausted. You can tune the behavior with two environment variables:
+
+Variable| Default| Effect
+---|---|---
+[`CLAUDE_CODE_MAX_RETRIES`](</docs/en/env-vars>)| 10| Number of retry attempts. Lower it to surface failures faster in scripts; raise it to wait through longer incidents.
+[`API_TIMEOUT_MS`](</docs/en/env-vars>)| 600000| Per-request timeout in milliseconds. Raise it for slow networks or proxies.
+
+##
+
+
+
+Server errors
+
+These errors come from Anthropic infrastructure rather than your account or request.
+
+###
+
+
+
+API Error: 500 Internal server error
+
+Claude Code shows the raw API response body for any 5xx status. The example below shows a 500 response:
+
+ API Error: 500 {"type":"error","error":{"type":"api_error","message":"Internal server error"}} · check status.claude.com
+
+This indicates an unexpected failure inside the API. It is not caused by your prompt, settings, or account. **What to do:**
+
+ * Check [status.claude.com](<https://status.claude.com>) for active incidents
+ * Wait a minute, then send your message again. Your original message is still in the conversation, so for a long prompt you can type `try again` instead of pasting the whole thing.
+ * If the error persists with no posted incident, run `/feedback` so Anthropic can investigate with your request details. See Report an error if `/feedback` is unavailable on your provider.
+
+###
+
+
+
+API Error: Repeated 529 Overloaded errors
+
+The API is temporarily at capacity across all users. Claude Code has already retried several times before showing this message:
+
+ API Error: Repeated 529 Overloaded errors · check status.claude.com
+
+A 529 is not your usage limit and does not count against your quota. **What to do:**
+
+ * Check [status.claude.com](<https://status.claude.com>) for capacity notices
+ * Try again in a few minutes
+ * Run `/model` and switch to a different model to keep working, since capacity is tracked per model. Claude Code prompts you to do this when one model is under particularly high load, for example `Opus is experiencing high load, please use /model to switch to Sonnet`.
+
+###
+
+
+
+Request timed out
+
+The API did not respond before the connection deadline.
+
+ Request timed out
+
+This can happen during periods of high load or when a very large response is being generated. The default request timeout is 10 minutes. **What to do:**
+
+ * Retry the request
+ * For long-running tasks, break the work into smaller prompts
+ * If a slow network or proxy is the cause, raise `API_TIMEOUT_MS` as described in Automatic retries
+ * If timeouts are frequent and your network is otherwise healthy, see Network and connection errors below
+
+###
+
+
+
+Auto mode cannot determine the safety of an action
+
+The model that [auto mode](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>) uses to classify actions is overloaded, so auto mode blocked the action instead of approving it unchecked.
+
+ <model> is temporarily unavailable, so auto mode cannot determine the safety of <tool> right now. Wait briefly and then try this action again.
+
+Reads, searches, and edits inside your working directory skip the classifier, so they keep working during the outage. **What to do:**
+
+ * Retry after a few seconds; Claude sees the same message and usually retries on its own
+ * If retries keep failing, continue with read-only tasks and come back to the blocked action later
+ * This is transient and unrelated to [auto mode eligibility](</docs/en/permission-modes#eliminate-prompts-with-auto-mode>); you do not need to change settings
+
+##
+
+
+
+Usage limits
+
+These errors mean a quota tied to your account or plan has been reached. They are distinct from server errors, which affect everyone.
+
+###
+
+
+
+You’ve hit your session limit
+
+Subscription plans include a rolling usage allowance. When it runs out you see one of these messages:
+
+ You've hit your session limit · resets 3:45pm
+ You've hit your weekly limit · resets Mon 12:00am
+ You've hit your Opus limit · resets 3:45pm
+
+Claude Code blocks further requests until the reset time shown in the message. **What to do:**
+
+ * Wait for the reset time shown in the error
+ * Run `/usage` to see your plan limits and when they reset
+ * Run `/extra-usage` to buy additional usage on Pro and Max, or to request it from your admin on Team and Enterprise. See [Extra usage for paid plans](<https://support.claude.com/en/articles/12429409-extra-usage-for-paid-claude-plans>) for how this is billed.
+ * To upgrade your plan for higher base limits, see [claude.com/pricing](<https://claude.com/pricing>)
+
+To watch your remaining allowance before you hit the limit, add the `rate_limits` fields to a [custom status line](</docs/en/statusline#rate-limit-usage>), or in the Desktop app click the [usage ring](</docs/en/desktop#check-usage>) next to the model picker.
+
+###
+
+
+
+Server is temporarily limiting requests
+
+The API applied a short-lived throttle that is unrelated to your plan quota.
+
+ API Error: Server is temporarily limiting requests (not your usage limit)
+
+This is retried automatically before being shown. **What to do:**
+
+ * Wait briefly and try again
+ * Check [status.claude.com](<https://status.claude.com>) if it persists
+
+###
+
+
+
+Request rejected (429)
+
+You have hit the rate limit configured for your API key, Amazon Bedrock project, or Google Vertex AI project.
+
+ API Error: Request rejected (429) · this may be a temporary capacity issue
+
+**What to do:**
+
+ * Run `/status` and confirm the active credential is the one you expect. A stray `ANTHROPIC_API_KEY` in your environment can route requests through a low-tier key instead of your subscription.
+ * Check your provider console for the active limits and request a higher tier if needed
+ * For Anthropic API keys, see the [rate limits reference](<https://platform.claude.com/docs/en/api/rate-limits>) for how tiers work and how to set per-workspace caps
+ * Reduce concurrency: lower [`CLAUDE_CODE_MAX_TOOL_USE_CONCURRENCY`](</docs/en/env-vars>), avoid running many parallel subagents, or switch to a smaller model with `/model` for high-volume scripted runs
+
+###
+
+
+
+Credit balance is too low
+
+Your Console organization has run out of prepaid credits.
+
+ Credit balance is too low
+
+**What to do:**
+
+ * Add credits at [platform.claude.com/settings/billing](<https://platform.claude.com/settings/billing>), and consider enabling auto-reload there so the balance refills before it hits zero
+ * Switch to subscription authentication with `/login` if you have a Pro, Max, Team, or Enterprise plan
+ * Set per-workspace spend caps in the Console to prevent a single project from draining the org balance. See [Manage costs effectively](</docs/en/costs>).
+
+##
+
+
+
+Authentication errors
+
+These errors mean Claude Code cannot prove who you are to the API. Run `/status` at any time to see which credential is currently active.
+
+###
+
+
+
+Not logged in
+
+No valid credential is available for this session.
+
+ Not logged in · Please run /login
+
+**What to do:**
+
+ * Run `/login` to authenticate with your Claude subscription or Console account
+ * If you expected an environment variable to authenticate you, confirm `ANTHROPIC_API_KEY` is set and exported in the shell where you launched `claude`
+ * For CI or automation where interactive login is not possible, configure an [`apiKeyHelper`](</docs/en/settings#available-settings>) script that fetches a key at startup
+ * See [Authentication precedence](</docs/en/authentication#authentication-precedence>) to understand which credential wins when several are present
+
+If you are prompted to log in repeatedly, see [Not logged in or token expired](</docs/en/troubleshooting#not-logged-in-or-token-expired>) for system clock and macOS Keychain fixes.
+
+###
+
+
+
+Invalid API key
+
+The `ANTHROPIC_API_KEY` environment variable or `apiKeyHelper` script returned a key the API rejected.
+
+ Invalid API key · Fix external API key
+
+**What to do:**
+
+ * Check for typos and confirm the key has not been revoked in the [Console](<https://platform.claude.com/settings/keys>)
+ * Run `env | grep ANTHROPIC` in the same shell. Tools like direnv, dotenv shell plugins, and IDE terminals can load a stale key from a `.env` file in your project without you setting it explicitly.
+ * Unset `ANTHROPIC_API_KEY` and run `/login` to use subscription auth instead
+ * If the key comes from an [`apiKeyHelper`](</docs/en/settings#available-settings>) script, run the script directly to confirm it prints a valid key on stdout
+ * Run `/status` to confirm which credential source Claude Code is actually using
+
+###
+
+
+
+This organization has been disabled
+
+A stale `ANTHROPIC_API_KEY` from a disabled Console organization is overriding your subscription login.
+
+ Your ANTHROPIC_API_KEY belongs to a disabled organization · Unset the environment variable to use your other credentials
+ API Error: 400 ... This organization has been disabled.
+
+Environment variables take precedence over `/login`, so a key exported in your shell profile or loaded from a `.env` file is used even when you have a working Pro or Max subscription. In non-interactive mode (`-p`), the key is always used when present. **What to do:**
+
+ * Unset `ANTHROPIC_API_KEY` in the current shell and remove it from your shell profile, then relaunch `claude`
+ * Run `/status` afterward to confirm the active credential is your subscription
+ * If no environment variable is set and the error persists, the disabled organization is the one tied to your `/login`. Contact support or sign in with a different account.
+
+###
+
+
+
+OAuth token revoked or expired
+
+Your saved login is no longer valid. A revoked token means you signed out everywhere or an admin removed access; an expired token means the automatic refresh failed mid-session.
+
+ OAuth token revoked · Please run /login
+ OAuth token has expired · Please run /login
+ API Error: 401 ... authentication_error
+
+**What to do:**
+
+ * Run `/login` to sign in again
+ * If the error returns within the same session after re-authenticating, run `/logout` first to fully clear the stored token, then `/login`
+ * For repeated prompts to log in across launches, see the system clock and macOS Keychain checks in [Troubleshooting](</docs/en/troubleshooting#not-logged-in-or-token-expired>)
+ * For other failures including `403 Forbidden` and OAuth browser issues, see [Permissions and authentication](</docs/en/troubleshooting#permissions-and-authentication>)
+
+###
+
+
+
+OAuth scope requirement
+
+The stored token predates a permission scope that a newer feature needs. You see this most often from `/usage` and the status line usage indicator:
+
+ OAuth token does not meet scope requirement: user:profile
+
+**What to do:**
+
+ * Run `/login` to mint a new token with the current scopes. You do not need to log out first.
+
+##
+
+
+
+Network and connection errors
+
+These errors mean Claude Code could not reach the API at all. They almost always originate in your local network, proxy, or firewall rather than Anthropic infrastructure.
+
+###
+
+
+
+Unable to connect to API
+
+The TCP connection to the API failed or never completed.
+
+ Unable to connect to API. Check your internet connection
+ Unable to connect to API (ECONNREFUSED)
+ Unable to connect to API (ECONNRESET)
+ Unable to connect to API (ETIMEDOUT)
+ fetch failed
+ Request timed out. Check your internet connection and proxy settings
+
+Common causes include no internet access, a VPN that blocks `api.anthropic.com`, or a required corporate proxy that is not configured. **What to do:**
+
+ * Confirm you can reach the API host from the same shell by running `curl -I https://api.anthropic.com`. On Windows PowerShell use `curl.exe -I https://api.anthropic.com` so the built-in `Invoke-WebRequest` alias is not used.
+ * If you are behind a corporate proxy, set `HTTPS_PROXY` before launching Claude Code and see [Network configuration](</docs/en/network-config>)
+ * If you route through an LLM gateway or relay, set [`ANTHROPIC_BASE_URL`](</docs/en/env-vars>) to its address. See [LLM gateway configuration](</docs/en/llm-gateway>) for setup.
+ * Ensure your firewall allows the hosts listed in [Network access requirements](</docs/en/network-config#network-access-requirements>)
+ * Intermittent failures are retried automatically; persistent failures point to a local network issue
+
+If `curl` succeeds but Claude Code still fails, the cause is usually something between Node.js and the network rather than the network itself:
+
+ * On Linux and WSL, check `/etc/resolv.conf` for an unreachable nameserver. WSL in particular can inherit a broken resolver from the host.
+ * On macOS, a VPN client that was disconnected or uninstalled can leave a tunnel interface or routing rule behind. Check `ifconfig` for stale `utun` interfaces and remove the VPN’s network extension in System Settings.
+ * Docker Desktop and similar container runtimes can intercept outbound traffic. Quit them and retry to rule this out.
+
+###
+
+
+
+SSL certificate errors
+
+A proxy or security appliance on your network is intercepting TLS traffic with its own certificate, and Node.js does not trust it.
+
+ Unable to connect to API: SSL certificate verification failed. Check your proxy or corporate SSL certificates
+ Unable to connect to API: Self-signed certificate detected
+
+**What to do:**
+
+ * Export your organization’s CA bundle and point Node at it with `NODE_EXTRA_CA_CERTS=/path/to/ca-bundle.pem`
+ * See [Network configuration](</docs/en/network-config#custom-ca-certificates>) for full setup instructions
+ * Do not set `NODE_TLS_REJECT_UNAUTHORIZED=0`, which disables certificate validation entirely
+
+##
+
+
+
+Request errors
+
+These errors mean the API received your request but rejected its content.
+
+###
+
+
+
+Prompt is too long
+
+The conversation plus attached files exceeds the model’s context window.
+
+ Prompt is too long
+
+**What to do:**
+
+ * Run `/compact` to summarize earlier turns and free space, or `/clear` to start fresh
+ * Run `/context` to see a breakdown of what is consuming the window: system prompt, tools, memory files, and messages
+ * Disable MCP servers you are not using with `/mcp disable <name>` to remove their tool definitions from context
+ * Trim large `CLAUDE.md` memory files or split them into [imports](</docs/en/memory>)
+ * Subagents inherit every MCP tool definition from the parent session, which can fill their context window before the first turn. Disable MCP servers you are not using before spawning subagents.
+ * Auto-compact is on by default and normally prevents this error. If you have set [`DISABLE_AUTO_COMPACT`](</docs/en/env-vars>), re-enable it or run `/compact` manually before the window fills.
+
+See [Explore the context window](</docs/en/context-window>) for an interactive view of how context fills up.
+
+###
+
+
+
+Error during compaction: Conversation too long
+
+`/compact` itself failed because there is not enough free context to hold the summary it produces.
+
+ Error during compaction: Conversation too long. Press esc twice to go up a few messages and try again.
+
+This can happen when the window is already full at the moment auto-compact triggers, or when you run `/compact` after seeing `Prompt is too long`. **What to do:**
+
+ * Press Esc twice to open the message list and step back several turns. This drops the most recent messages from context. Then run `/compact` again.
+ * If stepping back does not free enough space, run `/clear` to start a fresh session. Your previous conversation is preserved and can be reopened with `/resume`.
+
+###
+
+
+
+Request too large
+
+The raw request body exceeded the API’s byte limit before tokenization, usually because of a large pasted file or attachment.
+
+ Request too large (max 30 MB). Double press esc to go back and remove or shrink the attached content.
+
+This is a size limit on the HTTP request, separate from the context window limit. **What to do:**
+
+ * Press Esc twice and step back past the turn that added the oversized content
+ * Reference large files by path instead of pasting their contents, so Claude can read them in chunks
+ * For images, see Image was too large below
+
+###
+
+
+
+Image was too large
+
+A pasted or attached image exceeds the API’s size or dimension limits.
+
+ Image was too large. Double press esc to go back and try again with a smaller image.
+ API Error: 400 ... image dimensions exceed max allowed size
+
+The image stays in conversation history after the error, so every subsequent message fails with the same error until you remove it. **What to do:**
+
+ * Press Esc twice and step back past the turn where the image was added
+ * Resize the image before pasting. The API accepts images up to 8000 pixels on the longest edge for a single image, or 2000 pixels when many images are in context.
+ * Take a tighter screenshot of the relevant region instead of the full screen
+
+###
+
+
+
+PDF errors
+
+The PDF you attached could not be processed.
+
+ PDF too large (max 100 pages, 32 MB). Try splitting it or extracting text first.
+ PDF is password protected. Try removing protection or extracting text first.
+ The PDF file was not valid. Try converting to a different format first.
+
+**What to do:**
+
+ * For oversized PDFs, ask Claude to read a page range with the Read tool instead of attaching the whole file, or extract text with a tool like `pdftotext` and reference the output file by path
+ * For protected or invalid PDFs, remove the password or re-export the file from its source application, then try again
+
+###
+
+
+
+Extra inputs are not permitted
+
+A proxy or LLM gateway between Claude Code and the API stripped the `anthropic-beta` request header, so the API rejected fields that depend on it.
+
+ API Error: 400 ... Extra inputs are not permitted ... context_management
+ API Error: 400 ... Extra inputs are not permitted ... tools.0.custom.input_examples
+ API Error: 400 ... Unexpected value(s) for the `anthropic-beta` header
+
+Claude Code sends beta-only fields such as `context_management`, `effort`, and tool `input_examples` alongside an `anthropic-beta` header that enables them. When a gateway forwards the body but drops the header, the API sees fields it does not recognize. **What to do:**
+
+ * Configure your gateway to forward the `anthropic-beta` header. See [LLM gateway configuration](</docs/en/llm-gateway>).
+ * As a fallback, set [`CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1`](</docs/en/env-vars>) before launching. This disables features that require the beta header so requests succeed through a gateway that cannot forward it.
+
+###
+
+
+
+There’s an issue with the selected model
+
+The configured model name was not recognized or your account lacks access to it.
+
+ There's an issue with the selected model (claude-...). It may not exist or you may not have access to it. Run /model to select a different one.
+
+**What to do:**
+
+ * Run `/model` to pick from models available to your account
+ * Use an alias such as `sonnet` or `opus` instead of a full versioned ID. Aliases track the latest release so they do not go stale. See [Model configuration](</docs/en/model-config>).
+ * See [Model not found](</docs/en/troubleshooting#model-not-found-or-not-accessible>) to locate where a stale ID is set across `--model`, `ANTHROPIC_MODEL`, and settings files
+
+###
+
+
+
+Claude Opus is not available with the Claude Pro plan
+
+Your active subscription plan does not include the model you selected.
+
+ Claude Opus is not available with the Claude Pro plan · Select a different model in /model
+
+**What to do:**
+
+ * Run `/model` and select a model your plan includes
+ * If you upgraded your plan recently and still see this, run `/logout` then `/login`. The stored token reflects your plan at the time you signed in, so upgrading on the web does not take effect in an existing session until you re-authenticate.
+ * See [claude.com/pricing](<https://claude.com/pricing>) for which models each plan includes
+
+###
+
+
+
+thinking.type.enabled is not supported for this model
+
+Your Claude Code version is older than the minimum for Opus 4.7. The CLI sent a thinking configuration the model no longer accepts.
+
+ API Error: 400 ... "thinking.type.enabled" is not supported for this model. Use "thinking.type.adaptive" and "output_config.effort" to control thinking behavior.
+
+**What to do:**
+
+ * Run `claude update` to upgrade to v2.1.111 or later, then restart Claude Code
+ * If you cannot upgrade, run `/model` and select Opus 4.6 or Sonnet instead
+ * If you hit this in the Agent SDK, see [SDK troubleshooting](</docs/en/agent-sdk/quickstart#troubleshooting>)
+
+###
+
+
+
+Thinking budget exceeds output limit
+
+The configured extended thinking budget exceeds the maximum response length, so there is no room left for the actual answer.
+
+ API Error: 400 ... max_tokens must be greater than thinking.budget_tokens
+
+Claude Code adjusts these values automatically on the Anthropic API. You typically see this error on Amazon Bedrock or Google Vertex AI when [`MAX_THINKING_TOKENS`](</docs/en/env-vars>) is set higher than the provider’s output limit, or when plan mode raises the thinking budget. **What to do:**
+
+ * Lower `MAX_THINKING_TOKENS`, or raise [`CLAUDE_CODE_MAX_OUTPUT_TOKENS`](</docs/en/env-vars>) above the thinking budget
+ * See [Extended thinking](</docs/en/common-workflows#use-extended-thinking-thinking-mode>) for how the budget interacts with output length
+
+###
+
+
+
+Tool use or thinking block mismatch
+
+The conversation history reached the API in an inconsistent state, usually after a tool call was interrupted or a turn was edited mid-stream.
+
+ API Error: 400 due to tool use concurrency issues. Run /rewind to recover the conversation.
+ API Error: 400 ... unexpected `tool_use_id` found in `tool_result` blocks
+ API Error: 400 ... thinking blocks ... cannot be modified
+
+All three variants mean the same thing: the sequence of `tool_use`, `tool_result`, and `thinking` blocks in history no longer matches what the API expects. **What to do:**
+
+ * Run `/rewind`, or press Esc twice, to step back to a checkpoint before the corrupted turn and continue from there. See [Checkpointing](</docs/en/checkpointing>) for how checkpoints are created and restored.
+
+##
+
+
+
+Responses seem lower quality than usual
+
+If Claude’s answers seem less capable than you expect but no error is shown, the cause is usually conversation state rather than the model itself. Claude Code does not silently change model versions. It can switch to a fallback model in specific cases such as an Opus quota being reached or a Bedrock or Vertex AI region lacking your model; the Model selection check below catches both, and [Model configuration](</docs/en/model-config>) explains when fallback applies. Check these first:
+
+ * **Model selection** : run `/model` to confirm you are on the model you expect. A previous `/model` choice or an `ANTHROPIC_MODEL` environment variable may have you on a smaller model than you intended.
+ * **Effort level** : run `/effort` to check the current reasoning level and raise it for hard debugging or design work. Defaults vary by model and plan, so check before assuming you are below the maximum. See [Adjust effort level](</docs/en/model-config#adjust-effort-level>) for per-model defaults and the `ultrathink` shortcut.
+ * **Context pressure** : run `/context` to see how full the window is. If it is near capacity, run `/compact` at a natural breakpoint or `/clear` to start fresh. See [Explore the context window](</docs/en/context-window>) for how auto-compact affects earlier turns.
+ * **Stale instructions** : large or outdated `CLAUDE.md` files and MCP tool definitions consume context and can steer responses. `/doctor` flags oversized memory files and subagent definitions; `/context` shows MCP tool token usage.
+
+When a response goes wrong, rewinding usually works better than replying with corrections. Press Esc twice or run `/rewind` to step back to before the bad turn, then rephrase the prompt with more specifics. Correcting in-thread keeps the wrong attempt in context, which can anchor later answers to it. See [Checkpointing](</docs/en/checkpointing>). If quality still seems off after checking the above, run `/feedback` and describe what you expected versus what you got. Feedback submitted this way includes the conversation transcript, which is the fastest way for Anthropic to diagnose a real regression. See Report an error if `/feedback` is unavailable on your provider.
+
+##
+
+
+
+Report an error
+
+This page covers errors from the Claude API. For errors from other Claude Code components, see the relevant guide:
+
+ * MCP server failed to connect or authenticate: [MCP](</docs/en/mcp>)
+ * Hook script failed or blocked a tool: [Debug hooks](</docs/en/hooks#debug-hooks>)
+ * Permission denied or filesystem errors during install: [Troubleshooting](</docs/en/troubleshooting>)
+
+If an error is not listed here or the suggested fix does not help:
+
+ * Run `/feedback` inside Claude Code to send the transcript and a description to Anthropic. The command also offers to open a prefilled GitHub issue. Feedback is unavailable on Bedrock, Vertex AI, and Foundry deployments.
+ * Run `/doctor` to check for local configuration problems
+ * Check [status.claude.com](<https://status.claude.com>) for active incidents
+ * Search [existing issues](<https://github.com/anthropics/claude-code/issues>) on GitHub