Skip to main content
Claudebeginner

Update Claude Code: claude update and Every Install Method

Update Claude Code with claude update, brew, winget or npm, check your version with claude --version, and stop or pin auto-updates.

6 min readUpdated October 2026

The fastest way to update Claude Code is one command:

claude update

(claude upgrade is an alias; the CLI describes it as "Check for updates and install if available.") Whether you actually need to run it depends on how you installed.

Which Install Do You Have?

Run claude doctor. On a native install it reports Running: native (2.1.x), Auto-updates: enabled, Auto-update channel: latest and Last update attempt: success.

Install methodAuto-updates?How to update
Native installer (recommended)Yes, in the backgroundclaude update to apply immediately
HomebrewNobrew upgrade claude-code or brew upgrade claude-code@latest
WinGetNowinget upgrade Anthropic.ClaudeCode
npmYes, if the global directory is writablenpm install -g @anthropic-ai/claude-code@latest
apt / dnf / apkNosudo apt update && sudo apt upgrade claude-code, sudo dnf upgrade claude-code, apk update && apk upgrade claude-code

For native installs, updates download in the background and take effect the next time you start Claude Code, so a running session keeps its old version until you restart it.

Check Your Version

claude --version

This prints a version number like 2.1.x (Claude Code). If you see command not found, see claude command not found.

Update by Install Method

Native installer

claude update

Anthropic's docs say a successful update reports Successfully updated from <old version> to version <new version>, and an up-to-date install reports Claude Code is up to date (<version>). On macOS and Linux the launcher is ~/.local/bin/claude, a symlink into ~/.local/share/claude/versions/. If you replaced that launcher with your own script, updates still install new versions but your launcher decides which one runs; delete ~/.local/bin/claude and run claude update to let Claude Code manage it again.

Homebrew

brew upgrade claude-code            # stable cask
brew upgrade claude-code@latest     # latest cask
brew cleanup                        # reclaim old versions

claude-code tracks the stable channel (about a week behind). claude-code@latest tracks the latest channel.

Advertisement

WinGet

winget upgrade Anthropic.ClaudeCode

Close all Claude Code sessions first: Windows locks the running executable and the upgrade may fail. If it says no newer version is available but Claude Code announced one, the package may not have propagated yet; try again later.

npm

npm install -g @anthropic-ai/claude-code@latest

Do not use sudo. If the global directory is not writable, see permission errors.

Let Homebrew or WinGet update themselves

Set the CLAUDE_CODE_PACKAGE_MANAGER_AUTO_UPDATE environment variable to 1 and Claude Code runs the package-manager upgrade in the background when a new version ships, then prompts you to restart. It targets only the Claude Code package.

Choose a Channel or Pin a Version

In settings.json:

{
  "autoUpdatesChannel": "stable",
  "minimumVersion": "2.1.100"
}
  • autoUpdatesChannel: "latest" (default) or "stable".
  • minimumVersion: a floor; background updates and claude update will not install anything below it, so switching to stable does not downgrade you.

To install an exact version with the native installer:

curl -fsSL https://claude.ai/install.sh | bash -s 2.1.89

On Windows PowerShell: & ([scriptblock]::Create((irm https://claude.ai/install.ps1))) 2.1.89. Confirm with claude --version.

Stop Auto-Updates

{
  "env": {
    "DISABLE_AUTOUPDATER": "1"
  }
}

Run claude doctor afterward; the Auto-updates line should read disabled (set by env: DISABLE_AUTOUPDATER). This only stops the background check. claude update and claude install still work. Set DISABLE_UPDATES to block every update path.

When the Update Fails

  • Nothing happens or "up to date" after a release. Your channel may be stable, which lags by about a week.
  • Permission errors on npm. See Claude Code permission errors.
  • Still the old version after updating. Restart the session, and check you do not have two installs: which -a claude.
  • Installation is broken. See installation errors, or uninstall and reinstall.

Next Steps

Frequently Asked Questions

Find answers to common questions

Run claude update (alias claude upgrade). It checks for a newer version and installs it. Native installs also update themselves in the background, and the new version takes effect the next time you start Claude Code. Homebrew, WinGet, apt, dnf, apk and npm installs update with their own tools.

Run claude --version. It prints a number such as 2.1.x (Claude Code). claude doctor also shows the running version, install method, update channel and the result of the last update attempt.

Per Anthropic's docs, an update reports Successfully updated from <old version> to version <new version>, and an up-to-date native install reports Claude Code is up to date (<version>). Installs managed by Homebrew, WinGet or apk report Claude is up to date! instead.

Run brew upgrade claude-code, or brew upgrade claude-code@latest if you installed the latest-channel cask. Homebrew installs do not auto-update. Run brew cleanup occasionally because Homebrew keeps old versions on disk.

Run winget upgrade Anthropic.ClaudeCode. Close every running Claude Code session first, because Windows locks the executable and the upgrade can fail while it is running.

Run npm install -g @anthropic-ai/claude-code@latest. Anthropic advises against npm update -g, which respects the semver range from the original install and may not move you to the newest release.

Set DISABLE_AUTOUPDATER to "1" in the env block of settings.json. That only stops the background check; claude update still works. To block every update path, including manual ones, set DISABLE_UPDATES instead.

autoUpdatesChannel accepts "latest" (the default, new releases immediately) or "stable" (typically about a week old, skipping releases with major regressions). A newly launched model can need a version newer than the stable channel serves.

Anthropic documents a known issue where Claude Code can announce an update before the new version reaches Homebrew, WinGet or the Linux repositories. Wait and retry later. On WinGet, also close running sessions.

Pass a version to the native installer, for example curl -fsSL https://claude.ai/install.sh | bash -s 2.1.89, then confirm with claude --version.