command not found: claude
Quick answer.
zsh: command not found: claudemeans the directory holding theclaudebinary isn't on your PATH. The fastest fix is to reinstall with Homebrew soclaudelands on a PATH Homebrew manages:brew install --cask claude-code@latest. For a native install, add~/.local/binto your PATH instead (below). The simplest way to avoid "command not found" problems entirely is the free app Set Up Your Mac for Claude Code, which installs Claude Code on a managed PATH and verifies theclaudecommand works. ✓ Every command verified on macOS 26.5, 2026-06-26, arm64.
This page covers Claude Code, the command-line coding tool you run with the claude command. For the graphical Claude Desktop app, see Claude Code vs Claude Desktop.
This page edits a shell profile. Changing your PATH means editing a shell startup file. If your Mac isn't set up for development, see Prerequisites for Claude Code, or let the app above install Claude Code and set the PATH for you.
zsh: command not found: claude
This error means none of the directories on your PATH holds the claude binary. Which directory is missing depends on how you installed Claude Code: a Homebrew install puts claude on a PATH Homebrew manages, and the native installer puts it in ~/.local/bin.
A new shell only picks up a PATH change after it starts, so first rule out a stale shell — open a new terminal window and run:
claude --version
If a version prints, the install was fine and the old shell hadn't reloaded PATH. If it still says command not found, fix the PATH.
Homebrew install (recommended): reinstalling with Homebrew puts claude on a PATH Homebrew already manages, so this is the fastest fix:
brew install --cask claude-code@latest
Open a new terminal afterward, then run claude --version. See Brew Install Claude Code for the cask details.
Native install: the native installer puts claude in ~/.local/bin. Check whether that directory is on your PATH (no output means it's missing):
echo $PATH | tr ':' '\n' | grep -Fx "$HOME/.local/bin"
If it's missing, add it to ~/.zprofile — the login-shell profile, not ~/.zshrc:
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zprofile
Reload the profile and verify:
source ~/.zprofile
claude --version
A version string means claude is on your PATH.
The version is wrong, not missing
If claude --version runs but reports the wrong version, your PATH is fine — you have conflicting installs, and the shell is launching an old copy first. List every claude on PATH:
which -a claude
More than one line means a conflict. Update Claude Code walks through removing all but one.
Download the app "Set Up Your Mac for Claude Code"
Sources
- Troubleshoot installation — https://code.claude.com/docs/en/troubleshoot-install
- Claude Code setup — https://code.claude.com/docs/en/setup
Command verification
Every command on this page was executed top-to-bottom on a clean macOS 26.5 (arm64) system on 2026-06-26.
| Command | Status | Resolved version |
|---|---|---|
claude --version | pass | 2.1.193 |
brew install --cask claude-code@latest | pass | |
echo $PATH | tr ':' '\n' | grep -Fx "$HOME/.local/bin" | pass | |
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zprofile | pass | |
source ~/.zprofile | pass | |
claude --version | pass | 2.1.193 |
which -a claude | pass |
Verification run 20260626T224533Z.