Install Claude Code: one command, four sticking points

By Marco Kohns, Co-founder of ENLIX, lecturer in AI and growth

· 11 min read

Installing Claude Code is a single command, and it is not your problem. We measured it on 30 September 2026 in a freshly built Ubuntu 24.04 container: 16.6 seconds from the command to the finished message, exit code 0, version 2.1.285.

The short answer: run the native installer for your system, then open a NEW terminal window and check with claude --version. What actually holds people up comes after that, and it is four things: your PATH, the question of administrator rights on Windows, the Node version on the npm route, and the plan you need. Three of the four are answered incorrectly in the most widely read step-by-step guides.

How do you install Claude Code?

With one command that differs only by system. The native installer is the route Anthropic recommends, because it keeps itself up to date afterwards.

SystemCommand
macOS, Linux, WSLcurl -fsSL https://claude.ai/install.sh | bash
Windows PowerShellirm https://claude.ai/install.ps1 | iex
Windows CMDcurl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd
macOS with Homebrewbrew install --cask claude-code
Windows with WinGetwinget install Anthropic.ClaudeCode

All five appear in Anthropic's setup documentation. One difference is worth knowing before you choose: a native installation updates itself in the background, Homebrew and WinGet do not. Installing through a package manager means updating by hand later with brew upgrade claude-code or winget upgrade Anthropic.ClaudeCode.

Two error messages on paste mean only that you are in the wrong shell. If Windows says The token '&&' is not a valid statement separator, you are in PowerShell and pasted the CMD command. If it says 'irm' is not recognized as an internal or external command, it is the other way round. Your prompt shows PS C:\ in PowerShell and C:\ without the PS in CMD.

What actually happens during the install?

One download, one file and one line in your shell configuration. We ran the documented command in an empty container and then looked at what was written to disk.

The install script itself is 9,704 bytes. It downloads a single binary of 240,327,864 bytes, roughly 229 MiB, and stores it at ~/.local/share/claude/versions/2.1.285, with a symlink pointing at it from ~/.local/bin/claude. The installer then writes one line into three files, .bashrc, .profile and .zshrc, and it is the same line every time:

. "$HOME/.local/bin/env"

That is the whole footprint. No system directories, no elevated rights, no background service. Which is exactly why the install does not take a minute.

Install duration, measured

Native installer16.6 snpm install -g6.5 s

One run per route on one machine. That is too little to rank the two routes against each other; what it shows is the order of magnitude. Both deliver the same binary.

Install duration, measured
Native installer16.6 s
npm install -g6.5 s
Measured install duration per route, one run each on the same machine within the same minute.Source: Own measurement, Ubuntu 24.04, x86_64, 30 September 2026

The point of these numbers is not which route is faster. The point is that the step most guides are built around finishes in under half a minute. The time goes somewhere else.

Why can your terminal not find claude afterwards?

Because your shell reads the line the installer wrote only when it next starts. This is the most common sticking point after a successful install, and it looks like a failure even though everything worked.

We reproduced it in the same run. A shell that has not read the configuration files reports:

$ command -v claude
claude: NOT FOUND

The same shell, after reading exactly the file the installer registered:

$ . "$HOME/.local/bin/env"
$ command -v claude
/root/.local/bin/claude

The file ~/.local/bin/env contains nothing more than a check for whether ~/.local/bin is already on the PATH, and prepends the directory if it is not. So the rule is: open a new terminal window after installing instead of carrying on in the old one. On Windows that means a new PowerShell or CMD window. If the message survives that, the install directory is not on your PATH, and Anthropic's PATH fix covers the rest.

Do you need administrator rights on Windows?

No. Anthropic's documentation states it plainly for the native Windows install: "You do not need to run as Administrator" (Anthropic, Advanced setup).

This is worth stating because widely read guides claim the opposite and have their readers start PowerShell as an administrator on purpose. The advice is not merely unnecessary, it creates a follow-on problem: an elevated PowerShell runs under a different user profile, the install then sits in a different home directory, and calling claude later from an ordinary window finds nothing. One unnecessary instruction produces a hunt for a fault that does not exist.

The second Windows decision is native or WSL, and the documentation gives a clear table:

OptionRequiresSandboxingWhen
Native Windowsnothing, Git for Windows is optionalnot supportedWindows-native projects and tools
WSL 2WSL 2 enabledsupportedLinux toolchains or sandboxed command execution
WSL 1WSL 1 enablednot supportedwhen WSL 2 is unavailable

Decide by where your projects sit. If you work in WSL anyway, install there with the Linux command and start claude there too, not from PowerShell. Git for Windows is optional on the native route and has exactly one consequence: without it, Claude Code runs shell commands through PowerShell; with it, through Git Bash.

curl or npm: does it make a difference?

Not to the file that ends up on your disk. We checked that rather than assuming it: we installed both routes in the same environment and compared the checksums.

$ sha256sum ~/.local/share/claude/versions/2.1.285
33dad1ec615a2e08cc78b494f05c110e49916de2c79d78ec8799ebf46b233d29

$ sha256sum .../claude-code-linux-x64/claude
33dad1ec615a2e08cc78b494f05c110e49916de2c79d78ec8799ebf46b233d29

Both files are 240,327,864 bytes and identical byte for byte, cmp reports no difference, and both print 2.1.285 (Claude Code). The npm route pulls the same native binary in through a per-platform optional dependency, and the installed binary does not itself invoke Node.

So the difference is not in what you get, it is in what you maintain afterwards:

Native installernpm
Node.js requirednoyes, Node 22 or later since v2.1.198
Updates itselfyes, in the backgroundyes, when the npm directory is writable
Manual updateclaude updatenpm install -g @anthropic-ai/claude-code@latest

From the command to a running session

step you do yourself

Native installer

  1. paste the command
  2. installer downloads the binary
  3. installer writes the PATH line
  4. open a new terminal
  5. check claude --version

3 of 5 steps need you

npm

  1. install Node 22
  2. paste the command
  3. npm downloads the same binary
  4. npm sets the path itself
  5. check claude --version

3 of 5 steps need you

Derived from two of our own runs on 30 September 2026. The npm route costs one step more, and it is the one that has to happen first.

The figure "Node.js 18 or higher", which appears in widely read guides, is out of date. On an older Node version the install does not actually break: npm prints an EBADENGINE warning, the install completes, and claude still runs, because the binary does not use your Node at runtime.

One thing the npm route gets wrong if you follow a common recommendation. Anthropic's documentation warns explicitly: "Do NOT use sudo npm install -g as this can lead to permission issues and security risks." That exact command appears as advice for Linux in step-by-step guides.

Which Anthropic plan do you need?

A paid one. The documentation is unambiguous here: Claude Code requires a Pro, Max, Team, Enterprise or Console account, and the free claude.ai plan does not include access to Claude Code. Finding that out after the install means the evening is already spent.

Signing in happens at first start: you run claude and follow the browser prompts. If the ANTHROPIC_API_KEY environment variable is set, Claude Code asks once to approve that key instead of opening a browser. Beyond that, Claude Code runs through Amazon Bedrock, Google Cloud and Microsoft Foundry.

What the usage costs you at the end of the month depends less on the plan than on how you work. The Claude Code cost calculator works that through with your own numbers.

How do you know the install holds?

Two commands, of which the second says more than the first. claude --version prints a version number such as 2.1.285 (Claude Code). That proves the file is found, and nothing else.

claude doctor checks the installation without starting a session and prints read-only diagnostics. From our run:

Running: native (2.1.285)
Platform: linux-x64
Path: /root/.local/share/claude/versions/2.1.285
Config install method: native
Search: OK (/usr/bin/rg)
Auto-update channel: latest
No installation issues found.

Three lines matter. Config install method shows which route installed it, which settles the question of two parallel installations at once. Search shows whether ripgrep is found, because without ripgrep the project search stops working. And Auto-updates shows whether you will keep getting current versions or are frozen where you are.

What if it still sticks?

Three cases cover most of it, and all three have a documented cause rather than a mystery.

claude still runs after uninstalling. Then a second installation exists, or an alias from an older installer. claude doctor shows in Path which file actually runs.

Alpine and other musl-based systems. The documented install command fails there with not found, because Alpine ships neither bash nor curl. The documentation lists bash and curl for the install plus libgcc, libstdc++ and ripgrep at runtime, then USE_BUILTIN_RIPGREP=0 in settings.json.

You want to know the binary is genuine. Every release publishes a manifest.json with SHA256 checksums, signed with an Anthropic GPG key. The fingerprint is 31DD DE24 DDFA B679 F42D 7BD2 BAA9 29FF 1A7E CACE. Installing through apt, dnf or apk gets you that check from the package manager automatically.

Do you get updates automatically?

That depends on which route you took above, and it is the one difference between the install routes that keeps affecting you. Native installations update in the background. Homebrew, WinGet and apt, dnf and apk do not, and need a command from you.

On a native installation you can also choose how quickly new versions reach you. The setting is autoUpdatesChannel and takes two values: latest, the default, gives you new versions as soon as they ship. stable gives you a version that is typically about a week old and skips releases with major regressions. If you use Claude Code for paid work and would rather not be surprised midweek, put this in your settings.json:

{
  "autoUpdatesChannel": "stable"
}

To apply an update immediately without waiting for the background check, run claude update. It reports either Successfully updated from <old> to version <new> or, when there is nothing to do, Claude Code is up to date. Which channel you are on, and when the last update was attempted, both show up in claude doctor.

What comes after the install?

The part that decides the outcome. An installed tool cannot yet know anything about your project, and the work that makes the difference is written down: what belongs in the CLAUDE.md, which rules you give the tool and which steps you keep for yourself.

How we run recurring procedures as versioned skills is in Claude Code Skills. If you want to work in German, Using Claude Code in German covers the answer language and the language of the project file. And how the tool compares with the editor most people try first is in Claude Code vs Cursor.

Frequently asked

How do I install Claude Code on Windows?

Open PowerShell and run `irm https://claude.ai/install.ps1 | iex`, or in the command prompt run `curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd`. Then open a NEW window and check with `claude --version`. Whether you install natively or inside WSL depends on where your projects sit.

Do I need administrator rights to install Claude Code?

No. Anthropic's documentation states it plainly for a native Windows install: "You do not need to run as Administrator." Several widely read guides claim the opposite. An elevated PowerShell runs under a different user profile, so the install ends up in a different home directory, and a later call to `claude` from an ordinary window finds nothing.

Do I need Node.js for Claude Code?

Not for the native installer. Claude Code ships as a standalone binary that does not use Node.js at runtime. Only the npm route needs Node, and since version 2.1.198 the npm package requires Node.js 22 or later according to the documentation. The common claim that Node 18 is enough is out of date.

Why does my terminal say \"command not found\" after installing?

Because the install directory is not on your PATH yet. The installer writes a line into your shell configuration, and your shell reads that file only when it next starts. A new terminal window fixes it in most cases. We reproduced both states in our own run: the same shell reports `claude: NOT FOUND` before, and resolves the binary after.

Which plan do I need for Claude Code?

According to Anthropic's documentation, a Pro, Max, Team, Enterprise or Console account. The free claude.ai plan does not include access to Claude Code. Claude Code also runs through an API provider such as Amazon Bedrock, Google Cloud or Microsoft Foundry.

Written by

Marco Kohns

Co-founder of ENLIX, lecturer in AI and growth

Marco worked as a growth product manager at a Silicon Valley scale-up and has been teaching that way of working ever since. Today he runs ENLIX with Tobias and builds two products of his own on the same systems, which is what the courses open up.

  • Growth product manager at a Silicon Valley scale-up, Series A to B, backed by a16z, General Catalyst and Sapphire, with users in over 100 countries and more than 20,000 cities
  • Peer-reviewed research in the Journal of Business Research on generative AI in growth, with Prof. René Bohnsack. The research began in summer 2022, months before ChatGPT was public
  • Executive education lecturer at Católica-Lisbon, over 10 seminars, more than 1,500 people taught

Keep reading