Practical guides
How to install and get started with Claude Code: a step-by-step guide
Requirements, installation on macOS, Linux and Windows, first session, plans and VS Code or JetBrains integration: Claude Code according to Anthropic's official documentation.
Claude Code is Anthropic's coding agent: it reads your project, proposes changes and runs commands from the terminal, an IDE, the desktop app or the web. This guide follows the official documentation; every command was checked against it on 2026-10-20. For usage figures and plans, see the Claude Code tool page.
Before you start
- Operating systems: macOS 13.0 or later, Windows 10 1809 or later (or Windows Server 2019), Ubuntu 20.04+, Debian 10+, Alpine Linux 3.19+ (Anthropic).
- Hardware: at least 4 GB of RAM, x64 or ARM64 processor. An internet connection is required.
- Shell: Bash, Zsh, PowerShell or CMD.
- Location: Claude Code is only offered in Anthropic-supported countries.
- Account: a Claude Pro, Max, Team or Enterprise subscription, or a Claude Console account (API with pre-paid credits). The free claude.ai plan does not include Claude Code. Amazon Bedrock, Google Cloud and Microsoft Foundry are also supported.
Install Claude Code
The native installer is Anthropic's recommended method; it updates itself in the background.
macOS, Linux and 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
The installer shows no progress while it downloads. Then open a new terminal. Two alternatives exist, without auto-updates by default:
brew install --cask claude-code
winget install Anthropic.ClaudeCode
The claude-code Homebrew cask follows the stable channel (about a week behind, skipping releases with major regressions); claude-code@latest gets every release as soon as it ships. Signed apt, dnf and apk repositories are also available for Debian, Fedora, RHEL and Alpine.
With npm: the package requires Node.js 22 or later and installs the same native binary. Anthropic advises against sudo npm install -g (permission issues and security risks).
npm install -g @anthropic-ai/claude-code
Windows notes
Claude Code runs natively on Windows or inside WSL. The native install does not need Administrator rights. Git for Windows is optional: when present, Claude Code uses Git Bash for its Bash tool; otherwise it uses PowerShell. Sandboxing (isolated command execution) is only supported with WSL 2. In WSL, install and launch claude from the Linux terminal, not from PowerShell.
Verify the installation
claude --version
The command prints a version number followed by "(Claude Code)". If your shell says claude cannot be found, the install directory is not on your PATH yet. For a fuller check, without starting a session:
claude doctor
Your first session
Move into a project and start the agent:
cd /path/to/your/project
claude
On first use, Claude Code opens your browser to log in; credentials are then stored. If the ANTHROPIC_API_KEY environment variable is set and you approve it, the login step is skipped. With a Console account, a "Claude Code" workspace is created automatically for cost tracking.
Start with simple questions, for example:
what does this project do?
Then a small change. Claude Code shows the edit and asks for approval depending on the session's permission mode; Shift+Tab cycles through the modes.
add a hello world function to the main file
Essential commands, from Anthropic's quickstart:
claude "task"starts a session with an initial prompt (e.g.claude "fix the build error");claude -p "query"answers once, then exits;claude -ccontinues the most recent conversation in the current directory;claude -rlets you pick an older one;- inside a session:
/helplists commands,/resumecontinues a conversation,/loginswitches accounts,/clearclears the history,/exit(or Ctrl+D twice) quits.
Cost and plans
Claude Code is included in Claude's paid plans (Anthropic, verified 2026-10-20):
- Pro: $17/month billed annually ($200 up front), $20 billed monthly;
- Max: from $100/month, with 5x or 20x Pro's usage;
- Team: standard seat at $20/month billed annually ($25 monthly), Premium seat at $100 ($125 monthly), for 2 to 150 people;
- Enterprise: $20 per seat per month billed annually, plus usage at API rates, 20-seat minimum.
With a Console account, usage is billed per token. Anthropic says that across its enterprise deployments the average cost is around $13 per developer per active day and $150-250 per developer per month, staying below $30 per active day for 90% of users (Anthropic). The /usage command shows the session's consumption; for Pro and Max subscribers, usage is included in the plan. To compare these plans with other agents, see our guide Choosing a coding agent by budget.
Integrate Claude Code with your IDE
VS Code and Cursor: the official extension requires VS Code 1.94.0 or later and a paid Claude or Console account, with no API key needed (Anthropic). Open the Extensions view (Cmd+Shift+X on Mac, Ctrl+Shift+X on Windows and Linux), search for "Claude Code" and install. The extension bundles its own copy of the CLI; to run claude in the integrated terminal, install the CLI as well. Other VS Code forks (Devin Desktop, Kiro) use the Open VSX registry.
JetBrains (IntelliJ IDEA, PyCharm, Android Studio, WebStorm, PhpStorm, GoLand): the plugin does not bundle the CLI. Install the CLI first, then the Claude Code plugin from the JetBrains Marketplace, and restart the IDE (Anthropic). Run claude in the integrated terminal, or type /ide in a session started from an external terminal. Cmd+Esc (Mac) or Ctrl+Esc (Windows and Linux) opens Claude Code from the editor.
Update and uninstall
Native installs update themselves. To update right away:
claude update
With Homebrew: brew upgrade claude-code; with WinGet: winget upgrade Anthropic.ClaudeCode. To remove a native install on macOS, Linux or WSL:
rm -f ~/.local/bin/claude
rm -rf ~/.local/share/claude
Going further
- Connect Claude Code to your tools: How to set up an MCP server.
- Compare: Claude Code, Codex or GitHub Copilot, Claude Code vs Codex, Claude Code alternatives.
- Vocabulary: coding agent and context window in the glossary.
Sources
- Claude Code Docs: Advanced setup, verified 2026-10-20
- Claude Code Docs: Quickstart, verified 2026-10-20
- Claude Code Docs: Manage costs effectively, verified 2026-10-20
- Claude Code Docs: Use Claude Code in VS Code, verified 2026-10-20
- Claude Code Docs: JetBrains IDEs, verified 2026-10-20
- Anthropic: Claude pricing, verified 2026-10-20
Key takeaway: Claude Code installs with one command on macOS, Linux and Windows, but needs a paid Claude plan or a Console account; the VS Code extension bundles the CLI, the JetBrains plugin does not.
Spotted an error in this article? Report it · Our corrections policy