promptgarden ๐ŸŒฑ
๐ŸŒ ES
Guideโ—โ—‹โ—‹5 min ยท +20 XP

Installing Claude Code (Step by Step)

Get Claude Code running in a few minutes - open a terminal, run one command, done.

What you need

  • A terminal (PowerShell, CMD, Bash, or Zsh)
  • A Claude account (Pro, Max, Team, or Enterprise) or a Claude Console account
  • No Node.js required for the recommended install method - only needed if you install via npm instead

Installing

The recommended method is the native installer, which needs no Node.js:

  • macOS/Linux/WSL: curl -fsSL https://claude.ai/install.sh | bash
  • Windows PowerShell: irm https://claude.ai/install.ps1 | iex
  • Windows CMD: curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd

Alternatively via npm (requires Node.js 22 or later as of version 2.1.198):

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

First start

In your terminal, move into your project folder and start Claude Code:

cd /path/to/your/project
claude

On first run you'll be prompted to log in through your browser. Later, you can switch accounts inside a session with /login. Once logged in, your credentials stay saved.

Windows notes

Claude Code runs natively on Windows without needing WSL, and you don't need Administrator rights. Git for Windows is optional: if it's installed, Claude Code uses Git Bash for the Bash tool; without it, Claude Code falls back to the PowerShell tool. WSL 2 is also optional and only needed if you want the sandboxing feature.

EXAMPLE

claude --version # verify the install claude doctor # a more detailed check of your install and config

QUICK QUIZ

Which requirement applies only to the npm install method for Claude Code, not the native installer?

SOURCES

RELATED TOPICS

Claude Code: Anthropic's CLI Agent โ—โ—โ—‹CLAUDE.md / AGENTS.md: Give Your Agent Memory & Rules โ—โ—โ—‹Which Model, Which Plan? โ—โ—‹โ—‹