15| What you see | Solution |15| What you see | Solution |
16| :- | :- |16| :- | :- |
17| `command not found: claude` or `'claude' is not recognized` | [Fix your PATH](#command-not-found-claude-after-installation) |17| `command not found: claude` or `'claude' is not recognized` | [Fix your PATH](#command-not-found-claude-after-installation) |
18| `Native installation exists but ... is not in your PATH` | [Add the install directory to your PATH](#verify-your-path) |
19| `INFO: Could not find files for the given pattern(s).` from `where.exe claude` | [Check whether Claude Code is installed](#check-for-conflicting-installations) |
20| `zsh: permission denied: /Users/you/.zshrc` or `bash: /home/you/.bashrc: Permission denied` | [Make your shell config file writable](#permission-denied-when-adding-to-your-path) |
18| `syntax error near unexpected token '<'` | [Install script returns HTML](#install-script-returns-html-instead-of-a-shell-script) |21| `syntax error near unexpected token '<'` | [Install script returns HTML](#install-script-returns-html-instead-of-a-shell-script) |
22| `< was unexpected at this time` in CMD | [Install script returns HTML](#install-script-returns-html-instead-of-a-shell-script) |
23| `The term 'System.Xml.XmlDocument' is not recognized` | [Install script returns HTML](#install-script-returns-html-instead-of-a-shell-script) |
19| `curl: (22) The requested URL returned error: 403` | [Install script returned 403](#install-script-returns-html-instead-of-a-shell-script) |24| `curl: (22) The requested URL returned error: 403` | [Install script returned 403](#install-script-returns-html-instead-of-a-shell-script) |
20| `curl: (23)` or `curl: (56) Failure writing output to destination` | [Check connectivity or use an alternative installer](#curl-56-failure-writing-output-to-destination) |25| `curl: (23)` or `curl: (56) Failure writing output to destination` | [Check connectivity or use an alternative installer](#curl-56-failure-writing-output-to-destination) |
21| `Killed` during install on Linux, or `Installation was killed before it could finish (exit code 137)` | [Free memory or add swap space](#install-killed-on-low-memory-linux-servers) |26| `Killed` during install on Linux | [Free memory or add swap space](#install-killed-on-low-memory-linux-servers) |
27| `Installation was killed before it could finish` | [Free memory, then rerun the installer](#installation-was-killed-before-it-could-finish) |
22| `Raw mode is not supported` during install | [Rerun the installer](#raw-mode-is-not-supported-during-install) |28| `Raw mode is not supported` during install | [Rerun the installer](#raw-mode-is-not-supported-during-install) |
23| `EACCES: permission denied` during install | [Fix the install directory's permissions](#permission-errors-during-installation) |29| `EACCES: permission denied` during install | [Fix the install directory's permissions](#permission-errors-during-installation) |
24| `TLS connect error` or `SSL/TLS secure channel` | [Update CA certificates](#tls-or-ssl-connection-errors) |30| `TLS connect error` or `SSL/TLS secure channel` | [Update CA certificates](#tls-or-ssl-connection-errors) |
31| `CRYPT_E_NO_REVOCATION_CHECK` or `CRYPT_E_REVOCATION_OFFLINE` | [Work around blocked revocation checks](#tls-or-ssl-connection-errors) |
25| `Failed to fetch version` or can't reach download server | [Check network and proxy settings](#check-network-connectivity) |32| `Failed to fetch version` or can't reach download server | [Check network and proxy settings](#check-network-connectivity) |
33| `The connection dropped while downloading the update` or `Download timed out: exceeded the total deadline` | [Run the update again or set your proxy](#the-connection-dropped-while-downloading-the-update) |
26| `irm is not recognized` or `The token '&&' is not a valid statement separator` | [Use the right command for your shell](#wrong-install-command-on-windows) |34| `irm is not recognized` or `The token '&&' is not a valid statement separator` | [Use the right command for your shell](#wrong-install-command-on-windows) |
27| `Cask 'claude-code' is unavailable: No Cask with this name exists` | [Update Homebrew](#homebrew-cask-unavailable-or-outdated) |35| `Cask 'claude-code' is unavailable: No Cask with this name exists` | [Update Homebrew](#homebrew-cask-unavailable-or-outdated) |
36| `Cask 'claude-code@latest' is not installed` | [Upgrade the cask you installed](#cask-is-not-installed) |
28| `'bash' is not recognized as the name of a cmdlet` | [Use the Windows installer command](#wrong-install-command-on-windows) |37| `'bash' is not recognized as the name of a cmdlet` | [Use the Windows installer command](#wrong-install-command-on-windows) |
29| `A parameter cannot be found that matches parameter name 'fsSL'` | [Use the Windows installer command](#wrong-install-command-on-windows) |38| `A parameter cannot be found that matches parameter name 'fsSL'` | [Use the Windows installer command](#wrong-install-command-on-windows) |
30| `Claude Code on Windows requires either Git for Windows (for bash) or PowerShell` | [Install a shell](#claude-code-on-windows-requires-either-git-for-windows-for-bash-or-powershell) |39| `Claude Code on Windows requires either Git for Windows (for bash) or PowerShell` | [Install a shell](#claude-code-on-windows-requires-either-git-for-windows-for-bash-or-powershell) |
117 126
118If installation succeeded but you get a `command not found` or `not recognized` error when running `claude`, the install directory isn't in your PATH. Your shell searches for programs in directories listed in PATH, and the installer places `claude` at `~/.local/bin/claude` on macOS/Linux or `%USERPROFILE%\.local\bin\claude.exe` on Windows.127If installation succeeded but you get a `command not found` or `not recognized` error when running `claude`, the install directory isn't in your PATH. Your shell searches for programs in directories listed in PATH, and the installer places `claude` at `~/.local/bin/claude` on macOS/Linux or `%USERPROFILE%\.local\bin\claude.exe` on Windows.
119 128
129The installer detects this case and reports it under `Setup notes:` in its output: `Native installation exists but ~/.local/bin is not in your PATH.` on macOS and Linux, or `Native installation exists but C:\Users\you\.local\bin is not in your PATH.` on Windows. It prints the fix with that note but doesn't change PATH itself.
130
120<Note>131<Note>
121 The [VS Code extension](/docs/en/vs-code) does not place `claude` at this location. It bundles a private copy of the CLI inside the extension directory for its own chat panel and does not add it to PATH. If you have only installed the extension, `~/.local/bin/claude` will not exist. Run the [standalone install](/docs/en/setup) to use `claude` from a terminal, then continue below.132 The [VS Code extension](/docs/en/vs-code) does not place `claude` at this location. It bundles a private copy of the CLI inside the extension directory for its own chat panel and does not add it to PATH. If you have only installed the extension, `~/.local/bin/claude` will not exist. Run the [standalone install](/docs/en/setup) to use `claude` from a terminal, then continue below.
122</Note>133</Note>
123 134
124Check if the install directory is in your PATH by listing your PATH entries and filtering for `local/bin`:135First check that the program is there at all, then check whether its folder is in your PATH. The PATH fix is permanent, so you apply it once. Pick your platform's tab and run its commands there: in your terminal on macOS and Linux, or in PowerShell or Command Prompt on Windows.
125 136
126<Tabs>137<Tabs>
127 <Tab title="macOS/Linux">138 <Tab title="macOS/Linux">
139 Check that the installer put the program in place:
140
141 ```bash theme={null}
142 ls -la ~/.local/bin/claude
143 ```
144
145 * **`No such file or directory`**: there's no native install. If you haven't installed Claude Code another way, such as with npm, Homebrew, or a Linux package manager, [install Claude Code](/docs/en/setup#install-claude-code). If you installed it another way, see [Check for conflicting installations](#check-for-conflicting-installations).
146 * **A listing for the file**: the program is there. Check your PATH next.
147
148 List your PATH entries and filter for the install folder:
149
128 ```bash theme={null}150 ```bash theme={null}
129 echo $PATH | tr ':' '\n' | grep -Fx "$HOME/.local/bin"151 echo $PATH | tr ':' '\n' | grep -Fx "$HOME/.local/bin"
130 ```152 ```
131 153
132 If this prints `/Users/you/.local/bin` or `/home/you/.local/bin`, the directory is in your PATH and you can skip to [Check for conflicting installations](#check-for-conflicting-installations). If there's no output, add it to your shell configuration.154 If this prints `/Users/you/.local/bin` or `/home/you/.local/bin`, the directory is in your PATH and you can skip to [Check for conflicting installations](#check-for-conflicting-installations). If there's no output, add it to your shell configuration with the two commands for your shell. The `echo` command saves the setting for every new terminal, and `source` applies it to the window you're in. The `echo` command prints nothing when it succeeds.
133 155
134 For Zsh, the default on macOS:156 For Zsh, the default on macOS:
135 157
154 176
155 Alternatively, close and reopen your terminal.177 Alternatively, close and reopen your terminal.
156 178
179 If the `echo` command prints `permission denied`, see [`permission denied` when adding to your PATH](#permission-denied-when-adding-to-your-path).
180
157 For other shells such as fish or Nushell, add `~/.local/bin` to your PATH using your shell's own configuration syntax, then restart your terminal.181 For other shells such as fish or Nushell, add `~/.local/bin` to your PATH using your shell's own configuration syntax, then restart your terminal.
158 182
159 Verify the fix worked:183 Verify the fix worked:
161 ```bash theme={null}185 ```bash theme={null}
162 claude --version186 claude --version
163 ```187 ```
188
189 If `claude` is still not found, check these causes:
190
191 * **The terminal predates the change**: a window that was already open keeps its old PATH, and a terminal inside an editor takes its PATH from the editor. Open a new window, or quit and reopen the editor.
192 * **The line wasn't saved**: run `grep -n '.local/bin' ~/.zshrc`, using your shell's file name. It prints the line with its line number when the line is there. If it prints nothing, run the two PATH commands again.
193 * **The line went to another shell's file**: run `echo $0` to see your shell, then run the two PATH commands for that shell.
164 </Tab>194 </Tab>
165 195
166 <Tab title="Windows PowerShell">196 <Tab title="Windows PowerShell">
197 Check that the installer put the program in place:
198
199 ```powershell theme={null}
200 Test-Path "$env:USERPROFILE\.local\bin\claude.exe"
201 ```
202
203 * **`False`**: there's no native install. If you haven't installed Claude Code another way, such as with npm or WinGet, [install Claude Code](/docs/en/setup#install-claude-code). If you installed it another way, see [Check for conflicting installations](#check-for-conflicting-installations).
204 * **`True`**: the program is there. Check your PATH next.
205
206 List your PATH entries and filter for the install folder:
207
167 ```powershell theme={null}208 ```powershell theme={null}
168 $env:PATH -split ';' | Select-String '\.local\\bin'209 $env:PATH -split ';' | Select-String '\.local\\bin'
169 ```210 ```
170 211
171 If there's no output, add the install directory to your User PATH:212 If this prints `C:\Users\you\.local\bin`, the directory is in your PATH and you can skip to [Check for conflicting installations](#check-for-conflicting-installations). If there's no output, add the install directory to your User PATH:
172 213
173 ```powershell theme={null}214 ```powershell theme={null}
174 $currentPath = [Environment]::GetEnvironmentVariable('PATH', 'User')215 $currentPath = [Environment]::GetEnvironmentVariable('PATH', 'User')
182 ```powershell theme={null}223 ```powershell theme={null}
183 claude --version224 claude --version
184 ```225 ```
226
227 If `claude` is still not found in a new terminal, check these causes:
228
229 * **The terminal runs inside an editor**: it takes its PATH from the editor, so quit and reopen the editor.
230 * **The change wasn't saved**: run `[Environment]::GetEnvironmentVariable('PATH', 'User')` and look for `.local\bin` in the PATH it prints. If it's missing, run the two commands again.
185 </Tab>231 </Tab>
186 232
187 <Tab title="Windows CMD">233 <Tab title="Windows CMD">
234 Check that the installer put the program in place:
235
236 ```batch theme={null}
237 dir "%USERPROFILE%\.local\bin\claude.exe"
238 ```
239
240 * **`File Not Found` or `The system cannot find the path specified.`**: there's no native install. If you haven't installed Claude Code another way, such as with npm or WinGet, [install Claude Code](/docs/en/setup#install-claude-code). If you installed it another way, see [Check for conflicting installations](#check-for-conflicting-installations).
241 * **A listing for `claude.exe`**: the program is there. Check your PATH next.
242
243 List your PATH entries and filter for the install folder:
244
188 ```batch theme={null}245 ```batch theme={null}
189 echo %PATH% | findstr /i "local\bin"246 echo %PATH% | findstr /i "local\bin"
190 ```247 ```
196 ```batch theme={null}253 ```batch theme={null}
197 claude --version254 claude --version
198 ```255 ```
256
257 If `claude` is still not found in a new terminal, a terminal inside an editor takes its PATH from the editor, so quit and reopen the editor too.
199 </Tab>258 </Tab>
200</Tabs>259</Tabs>
201 260
211 which -a claude270 which -a claude
212 ```271 ```
213 272
214 If this prints nothing, no `claude` is on your PATH yet. Go back to [Verify your PATH](#verify-your-path).273 If this prints `claude not found`, a `no claude in` line, or nothing, no `claude` is on your PATH. The next checks show whether one is installed at all.
215 274
216 Check the three locations a `claude` binary can come from. `~/.local/bin/claude` is the native installer, `~/.claude/local/` is a legacy local npm install created by older versions of Claude Code, and the npm global list shows a `-g` install:275 Check the three locations a `claude` binary can come from. `~/.local/bin/claude` is the native installer, `~/.claude/local/` is a legacy local npm install created by older versions of Claude Code, and the npm global list shows a `-g` install:
217 276
230 ```bash theme={null}289 ```bash theme={null}
231 npm -g ls @anthropic-ai/claude-code 2>/dev/null290 npm -g ls @anthropic-ai/claude-code 2>/dev/null
232 ```291 ```
292
293 If `ls -la ~/.local/bin/claude` printed `No such file or directory`, there's no native install. If you haven't installed Claude Code another way, such as with npm, Homebrew, or a Linux package manager, [install Claude Code](/docs/en/setup#install-claude-code). If `~/.local/bin/claude` exists but `which -a claude` didn't list it, the folder isn't in your PATH: see [Verify your PATH](#verify-your-path).
233 </Tab>294 </Tab>
234 295
235 <Tab title="Windows PowerShell">296 <Tab title="Windows PowerShell">
239 where.exe claude300 where.exe claude
240 ```301 ```
241 302
303 If this prints `INFO: Could not find files for the given pattern(s).`, no `claude` is on your PATH.
304
242 Check whether the native installer placed a binary:305 Check whether the native installer placed a binary:
243 306
244 ```powershell theme={null}307 ```powershell theme={null}
245 Test-Path "$env:USERPROFILE\.local\bin\claude.exe"308 Test-Path "$env:USERPROFILE\.local\bin\claude.exe"
246 ```309 ```
310
311 * **`True`**: the native install is there. If `where.exe` found nothing, its folder isn't in your PATH: see [Verify your PATH](#verify-your-path).
312 * **`False`**: there's no native install. If you haven't installed Claude Code another way, such as with npm or WinGet, [install Claude Code](/docs/en/setup#install-claude-code).
247 </Tab>313 </Tab>
248</Tabs>314</Tabs>
249 315
350 416
351### Install script returns HTML instead of a shell script417### Install script returns HTML instead of a shell script
352 418
353When running the install command, you may see one of these errors:419The install command fails with one of these errors when what it downloaded isn't the install script.
420
421**Bash or Zsh**: the error quotes the first line of the returned page.
354 422
355```text theme={null}423```text theme={null}
356bash: line 1: syntax error near unexpected token `<'424bash: line 1: syntax error near unexpected token `<'
357bash: line 1: `<!DOCTYPE html>'425bash: line 1: `<!DOCTYPE html>'
358```426```
359 427
360On PowerShell, the same problem appears as parse errors pointing into the returned page, with `iex` trying to run HTML and CSS as PowerShell:428**PowerShell, parse errors**: the errors point into the returned page, with `iex` trying to run HTML and CSS as PowerShell.
361 429
362```text theme={null}430```text theme={null}
363iex : At line:1 char:2310431iex : At line:1 char:2310
368 436
369The wording varies with the PowerShell version and system language: you may see `Missing expression after unary operator '--'` or a `ParserError` with `ParseException` instead. HTML tags or CSS in the quoted text identify this failure. If you download with `-OutFile install.ps1` instead, the saved file is the same web page, so that doesn't help either.437The wording varies with the PowerShell version and system language: you may see `Missing expression after unary operator '--'` or a `ParserError` with `ParseException` instead. HTML tags or CSS in the quoted text identify this failure. If you download with `-OutFile install.ps1` instead, the saved file is the same web page, so that doesn't help either.
370 438
371Depending on how the request was routed, you may instead see a 403 with no HTML body:439**PowerShell, `System.Xml.XmlDocument`**: the error names this type instead of quoting the page.
440
441```text theme={null}
442System.Xml.XmlDocument : The term 'System.Xml.XmlDocument' is not recognized as the name of a cmdlet, function, script
443file, or operable program.
444```
445
446When `irm` can parse the response as XML, it returns an XML object instead of text, and `iex` then tries to run that object's type name as a command. The install script is PowerShell code and doesn't parse as XML, so this error also means the response was something other than the script. The wording around the type name varies with the PowerShell version and system language, but `System.Xml.XmlDocument` itself stays the same, so match on the type name.
447
448**CMD**: you see this error, followed by the HTML of the returned page.
449
450```text theme={null}
451< was unexpected at this time.
452
453C:\Users\you><!DOCTYPE html>...
454```
455
456The first line appears in your system language, so look for the HTML that follows it.
457
458**A 403 with no page**: depending on how the request was routed, curl reports a 403 status with no HTML body.
372 459
373```text theme={null}460```text theme={null}
374curl: (22) The requested URL returned error: 403461curl: (22) The requested URL returned error: 403
375```462```
376 463
377These all mean the install URL returned an HTML page or an error status instead of the install script. If the HTML page says "App unavailable in region," Claude Code is not available in your country. See [supported countries](https://www.anthropic.com/supported-countries).464These all mean the install URL returned a web page, an XML document, or an error status instead of the install script. If the error output quotes "App unavailable in region," Claude Code isn't available in your country. See [supported countries](https://www.anthropic.com/supported-countries).
378 465
379A bare 403 with no body often has the same cause, but it can also come from a corporate proxy or firewall blocking the download. If you are in a supported country and still see the 403, work through [Check network connectivity](#check-network-connectivity) before trying the alternative installers below, since those reach the same hosts.466A bare 403 with no body often has the same cause, but it can also come from a corporate proxy or firewall blocking the download. If you are in a supported country and still see the 403, work through [Check network connectivity](#check-network-connectivity) before trying the alternative installers below, since those reach the same hosts.
380 467
382 469
383**Solutions:**470**Solutions:**
384 471
3851. **Use an alternative install method**:4721. **Retry after a few minutes**: the issue is often temporary. Wait and try the original command again.
473
4742. **Use an alternative install method**: unlike a native install, a Homebrew or WinGet install [doesn't update itself by default](/docs/en/setup#auto-updates).
386 475
387 On macOS, install via Homebrew:476 On macOS, install via Homebrew:
388 477
398 487
399 Then run `claude --version` to confirm: the command prints a version number such as `2.1.211 (Claude Code)`. If the shell reports `claude` isn't found, open a new terminal window and retry: the session you installed from keeps its old `PATH`.488 Then run `claude --version` to confirm: the command prints a version number such as `2.1.211 (Claude Code)`. If the shell reports `claude` isn't found, open a new terminal window and retry: the session you installed from keeps its old `PATH`.
400 489
4012. **Retry after a few minutes**: the issue is often temporary. Wait and try the original command again.
402
403### `command not found: claude` after installation490### `command not found: claude` after installation
404 491
405The install finished but `claude` doesn't work. The exact error varies by platform:492The install finished but `claude` doesn't work. The exact error varies by platform:
415 502
416Otherwise, see [Verify your PATH](#verify-your-path) for the fix on each platform.503Otherwise, see [Verify your PATH](#verify-your-path) for the fix on each platform.
417 504
505### `permission denied` when adding to your PATH
506
507If the `echo` command that adds `~/.local/bin` to your PATH prints `zsh: permission denied: /Users/you/.zshrc` or `bash: /home/you/.bashrc: Permission denied`, your user can't write to that file and nothing was saved. In your terminal, check who owns the file, using your shell's file name in place of `~/.zshrc`:
508
509```bash theme={null}
510ls -l ~/.zshrc
511```
512
513The third field of the output is the owner.
514
515* **The owner is another user, such as `root`**: take ownership with `sudo chown $(whoami) ~/.zshrc`, which requires administrator rights.
516* **The owner is you**: the file is read-only. Make it writable with `chmod u+w ~/.zshrc`.
517
518Then run the two PATH commands for your shell in [Verify your PATH](#verify-your-path) again.
519
418### `curl: (56) Failure writing output to destination`520### `curl: (56) Failure writing output to destination`
419 521
420The `curl ... | bash` command downloads the script and pipes it to Bash for execution. This error, and the related `curl: (23) Failure writing output to destination`, means Bash did not receive the complete script. Exit code 56 indicates the download itself was interrupted, and exit code 23 indicates curl could not write what it received to the pipe, usually because Bash exited early.522The `curl ... | bash` command downloads the script and pipes it to Bash for execution. This error, and the related `curl: (23) Failure writing output to destination`, means Bash did not receive the complete script. Exit code 56 indicates the download itself was interrupted, and exit code 23 indicates curl could not write what it received to the pipe, usually because Bash exited early.
432 534
433If Homebrew installs an older Claude Code version than you expect, the same stale index is usually the cause. The `claude-code` cask tracks the stable channel and is typically about one week behind the latest release; for the newest version run `brew install --cask claude-code@latest` instead. See [Configure release channel](/docs/en/setup#configure-release-channel) for the difference between the two casks.535If Homebrew installs an older Claude Code version than you expect, the same stale index is usually the cause. The `claude-code` cask tracks the stable channel and is typically about one week behind the latest release; for the newest version run `brew install --cask claude-code@latest` instead. See [Configure release channel](/docs/en/setup#configure-release-channel) for the difference between the two casks.
434 536
537<h3 id="cask-is-not-installed">
538 `Cask 'claude-code@latest' is not installed`
539</h3>
540
541Homebrew offers two casks, `claude-code` and `claude-code@latest`. Running `brew upgrade --cask claude-code@latest` when that cask isn't the one installed prints `Error: Cask 'claude-code@latest' is not installed.` To see which cask you have, run this in your terminal:
542
543```bash theme={null}
544brew list --cask | grep claude-code
545```
546
547Upgrade the cask it prints. If it prints nothing, neither cask is installed.
548
435### TLS or SSL connection errors549### TLS or SSL connection errors
436 550
437Errors such as these mean the TLS handshake failed:551Errors such as these mean the TLS handshake failed:
441* PowerShell's `Could not create SSL/TLS secure channel`555* PowerShell's `Could not create SSL/TLS secure channel`
442* PowerShell's `Could not establish trust relationship for the SSL/TLS secure channel`556* PowerShell's `Could not establish trust relationship for the SSL/TLS secure channel`
443 557
558For `CRYPT_E_NO_REVOCATION_CHECK` or `CRYPT_E_REVOCATION_OFFLINE`, go to step 4.
559
444**Solutions:**560**Solutions:**
445 561
4461. **Update your system CA certificates**:5621. **Update your system CA certificates**:
453 569
454 On macOS, the system curl uses the Keychain trust store; updating macOS itself updates the root certificates.570 On macOS, the system curl uses the Keychain trust store; updating macOS itself updates the root certificates.
455 571
4562. **On Windows, enable TLS 1.2** in PowerShell before running the installer:5722. **In Windows PowerShell 5.1, enable TLS 1.2**:
457 ```powershell theme={null}573 ```powershell theme={null}
458 [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12574 [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
575 ```
576 Then run the installer in the same window:
577 ```powershell theme={null}
459 irm https://claude.ai/install.ps1 | iex578 irm https://claude.ai/install.ps1 | iex
460 ```579 ```
461 580
509 628
510The installer couldn't reach the download server. This typically means `downloads.claude.ai` is blocked on your network. See [Check network connectivity](#check-network-connectivity).629The installer couldn't reach the download server. This typically means `downloads.claude.ai` is blocked on your network. See [Check network connectivity](#check-network-connectivity).
511 630
631### The connection dropped while downloading the update
632
633The 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.
634
635```text theme={null}
636The connection dropped while downloading the update (attempt 3/3: aborted). Check your network — proxies sometimes cut off large downloads.
637```
638
639The 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.
640
641A 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.
642
643A proxy or gateway can close a long transfer before it finishes, and the Claude Code binary is a large download.
644
645**What to do:**
646
647* 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.
648* If your network requires a proxy, set `HTTPS_PROXY` before running the installer or `claude update`. See [Check network connectivity](#check-network-connectivity).
649* 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).
650* Run `claude doctor` from your shell for installation diagnostics
651
512### Wrong install command on Windows652### Wrong install command on Windows
513 653
514If you see `'irm' is not recognized`, `The token '&&' is not a valid statement separator`, `A parameter cannot be found that matches parameter name 'fsSL'`, or `'bash' is not recognized as the name of a cmdlet`, you copied the install command for a different shell or operating system. If the command prints the script's text instead of installing anything, you ran only part of it.654If you see `'irm' is not recognized`, `The token '&&' is not a valid statement separator`, `A parameter cannot be found that matches parameter name 'fsSL'`, or `'bash' is not recognized as the name of a cmdlet`, you copied the install command for a different shell or operating system. If the command prints the script's text instead of installing anything, you ran only part of it.
648 788
6493. **Use a larger instance** if possible. Claude Code requires at least 4 GB of RAM.7893. **Use a larger instance** if possible. Claude Code requires at least 4 GB of RAM.
650 790
791### Installation was killed before it could finish
792
793The 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:
794
795```text theme={null}
796Installation was killed before it could finish (exit code 137). This usually means the system ran out of memory.
797Claude Code needs roughly 512MB of free memory to install. Free up memory, then run this script again.
798```
799
800For 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.
801
802**What to do:**
803
804* Stop other processes to free memory, then rerun the installer
805* Add swap space or move to a larger instance. See [Install killed on low-memory Linux servers](#install-killed-on-low-memory-linux-servers) for the swap-file commands.
806
651### Install hangs in Docker807### Install hangs in Docker
652 808
653When installing Claude Code in a Docker container, installing as root into `/` can cause hangs.809When installing Claude Code in a Docker container, installing as root into `/` can cause hangs.