Skip to content
Mia Automation
NLEN Sign in Put Mia to workGet started

How to Install Claude Code on a Mac

One Terminal command installs Claude Code on a Mac, and on our Apple silicon test Mac it took 17 seconds. What several install guides get wrong is the next step. They say the installer adds itself to your shell config; in our test with version 2.1.322 it didn't. It printed a PATH warning, and a new Terminal window said "claude not found" until we added the line it suggested. Below: the install, how to check whether you need that line, Homebrew and npm, and how to remove it again.

Claude in practiceUpdated 6 min read

Tested by us on 11 November 2026.

What you need

  • macOS 13 or newer, on Apple silicon or Intel, with at least 4 GB of memory, according to Anthropic's system requirements.
  • An internet connection while you work.
  • A paid account: Claude Pro, Max, Ultra, Team or Enterprise, or a Console account with API credit. The free claude.ai plan doesn't include Claude Code.
  • No admin password, no Homebrew and no Node.js. Our test Mac had neither installed.
Animated flow of our test: the install command takes 17 seconds, creates a link at ~/.local/bin/claude, a new zsh window says claude not found, adding a PATH line to ~/.zshrc fixes it, and a new window prints 2.1.322 (Claude Code)
The five steps as they happened on our Mac.

Install Claude Code in four steps

  1. Open Terminal

    Press Command and Space, type Terminal and press Enter. The window opens in your home folder, and the prompt usually ends in %, which means your shell is zsh, the default on current Macs.

  2. Run the installer

    Paste this line and press Enter. It shows no progress while it downloads, so give it a moment: ours took 17 seconds.

    bash
    curl -fsSL https://claude.ai/install.sh | bash
  3. Add the folder to your PATH

    Read the end of the output. If it warns that ~/.local/bin is not in your PATH, check it with the first line below, from Anthropic's troubleshooting guide. No output means you need the fix: run the other two lines once, for zsh. Running them twice adds the line twice.

    bash
    echo $PATH | tr ':' '\n' | grep -Fx "$HOME/.local/bin"
    echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
    source ~/.zshrc
  4. Open a new window and check

    Close Terminal and open a new window, then type claude --version. We got 2.1.322 (Claude Code). Now go to a project folder and type claude to sign in.

    bash
    claude --version
macOS Terminal output: the installer reports version 2.1.322 at ~/.local/bin/claude with a setup note that ~/.local/bin is not in PATH, claude doctor shows native 2.1.322 on darwin-arm64 with auto-updates enabled, which claude first returns not found and after the PATH line returns the path and version (opens at full size)
Output from our test, captured from the Mac and laid out as a Terminal window for this page; shortened where marked. The temporary home folder is shown as ~.

How we tested it

We ran the installer on a Mac with macOS 27.2 on Apple silicon, sending the commands over a remote connection rather than typing in Terminal.app, and read back the output. To leave the owner's own setup untouched, we pointed HOME at a temporary folder and deleted it afterwards. That temporary home had no ~/.zshrc, so there was nothing that could already contain the PATH line. On a Mac where another tool has added ~/.local/bin to your ~/.zshrc, claude may work straight away; the check in step 3 tells you. Anthropic's troubleshooting guide describes the same manual step, which matches what we saw.

Test on November 11, 2026. claude doctor runs without signing in.
CheckResult
Time to install17 seconds
Version2.1.322 (Claude Code), platform darwin-arm64
Where it went~/.local/bin/claude, a link to ~/.local/share/claude/versions/2.1.322
claude in a new zsh window, before the PATH lineclaude not found
After the PATH line, in a new windowFound, version 2.1.322
claude doctorNative install, auto-updates enabled, channel latest, 2 warnings: PATH and not signed in

Native installer, Homebrew or npm?

All three put the same program on your Mac; they differ in how updates arrive. Our Mac had neither Homebrew nor Node.js, so we tested only the native installer. The Homebrew and npm commands below are Anthropic's, not ours.

From the Claude Code setup documentation, checked November 11, 2026.
MethodCommandUpdatesChoose it when
Native installercurl -fsSL https://claude.ai/install.sh | bashAutomatic, in the backgroundYou want the simplest setup that keeps itself current
Homebrewbrew install --cask claude-codeManual with brew upgrade claude-code. The claude-code cask is about a week behind; claude-code@latest gets new versions on day oneYou manage everything with Homebrew and prefer a tested version
npmnpm install -g @anthropic-ai/claude-codeUpgrade with npm install -g @anthropic-ai/claude-code@latestYou already work with Node.js 22 or newer. Never use sudo with it

We'd pick the native installer, for reasons we saw in the test: it needed nothing else on a Mac without Homebrew or Node.js, it took 17 seconds, and claude doctor reported auto-updates switched on from the start. With Homebrew or npm you upgrade by hand.

If it goes wrong

What you seeWhat's going onFix
zsh: command not found: claude~/.local/bin isn't in your PATH yetRun the PATH line from step 3, then open a new window
Still not found after the PATH lineThe old window doesn't see the change, or you use bash instead of zshOpen a new window. In bash, add the same line to ~/.bash_profile
claude runs an old versionA second install, for example from npm or Homebrew, comes first in your PATHRun which -a claude and remove the one you don't use
Doctor warns Not signed in to claude.aiNormal before your first sessionType claude in a project folder and sign in in the browser

Remove it again

bash
rm -f ~/.local/bin/claude
rm -rf ~/.local/share/claude

Uninstall commands for a native installation, from Anthropic's setup page. Your settings in ~/.claude stay unless you delete that folder too.

Using Windows as well? The steps there differ in one place, the PATH fix, which you do in PowerShell. See installing Claude Code on Windows. Once it runs, set up a CLAUDE.md file so Claude Code knows your project's rules from the first session.

Questions

Can I install Claude Code on a Mac without Homebrew?

Yes. The native installer needs only Terminal and curl, which every Mac has. Our test Mac had no Homebrew at all.

Does Claude Code work on Apple silicon?

Yes. We installed it on Apple silicon and claude doctor reported the platform as darwin-arm64. Intel Macs are supported too, according to the system requirements.

Is Claude Code free on a Mac?

Installing it is free. Using it needs a paid Claude plan (Pro or higher) or a Console account with API credit.

Is there a Claude Code app for Mac?

Yes. The Claude desktop app for macOS has a Code tab with Claude Code built in, so you don't need Terminal at all. A paid plan is still required.

Sources