Brew Install Claude Code

Quick answer. Install the Claude Code CLI with Homebrew:

brew install --cask claude-code@latest

This is the recommended path for developers. Most developers already have Homebrew. However, before you can work on a real project with Claude Code, you'll need to set up a development environment. The easiest way is the free app Set Up Your Mac for Claude Code, which installs Homebrew (if needed), configures your development environment, adds Claude Code for you and verifies it works. ✓ Every command verified on macOS 26.5, 2026-06-26, arm64.

Download the app "Set Up Your Mac for Claude Code"

This page covers the Claude Code CLI, the command-line coding tool you run with the claude command. The claude cask (the same name without -code) is the graphical Claude Desktop app; see Claude Code vs Claude Desktop. To install the CLI, the Homebrew cask is claude-code.

This page edits or assumes a developer environment. The Homebrew installation script prompts for a password (it uses sudo for directory creation and permission changes. If you don't have Homebrew yet, set up the environment first — see Prerequisites for Claude Code, or let the app above install Homebrew and Claude Code for you.

Install

brew install --cask claude-code@latest

Homebrew is on version 6.0.0; brew install shows a summary and asks for confirmation before it proceeds.

Release channels

Two casks track two channels:

Install one, not both, or you'll have two copies of Claude Code that conflict on PATH.

Update

Homebrew installs with "do not auto-update." Upgrade manually when you want a new version:

brew upgrade claude-code@latest

You can have Claude Code run the Homebrew upgrade for you. Set CLAUDE_CODE_PACKAGE_MANAGER_AUTO_UPDATE=1 in your shell environment. For the full update flow or fixing a version that won't change, see Update Claude Code.

Uninstall

brew uninstall --cask claude-code@latest

To also remove the preferences and support files Claude Code leaves behind, add --zap:

brew uninstall --cask --zap claude-code@latest

Use plain claude-code in these commands if you installed the stable channel instead.

Download the app "Set Up Your Mac for Claude Code"

Sources

Command verification

Every command on this page was executed top-to-bottom on a clean macOS 26.5 (arm64) system on 2026-06-26.

CommandStatusResolved version
brew install --cask claude-code@latestpass
brew install --cask claude-code@latestpass
brew upgrade claude-code@latestpass
brew uninstall --cask claude-code@latestpass
brew uninstall --cask --zap claude-code@latestinfo

Verification run 20260626T231312Z.