Opens in a new tab

Guide

How to Install Claude Code on Mac, Windows and Linux

One command to install, one to start. Here's the whole setup, including the Windows details that trip people up.

A computer screen full of terminal output
Photo: Lukas / Unsplash
On this page
  1. Before you start
  2. Step 1: Install
  3. Step 2: Check that it worked
  4. Step 3: Start it and log in
  5. Windows: native or WSL?
  6. Keeping it updated
  7. Prefer not to use the terminal?
  8. Uninstall

DGTULS may earn a commission when you purchase through links on our site. This never affects our ratings or which products we recommend.

Checked against Anthropic’s docs on October 18, 2026.

Claude Code is Anthropic’s coding agent. It runs in your terminal, reads your project, edits files and runs commands. This guide follows Anthropic’s official setup docs (Claude Code setup).

Before you start

You need a paid account. Claude Code requires a Claude Pro, Max, Team or Enterprise plan, or an Anthropic Console account. The free Claude plan doesn’t include it (setup docs). Claude Pro costs $20/month billed monthly (Prices checked on October 18, 2026; source).

System requirements (setup docs):

  • macOS 13.0 or later
  • Windows 10 1809 or later, or Windows Server 2019 or later
  • Ubuntu 20.04+, Debian 10+ or Alpine Linux 3.19+
  • 4 GB of RAM or more, on an x64 or ARM64 processor
  • An internet connection
  • Bash, Zsh, PowerShell or CMD
  • A country where Anthropic’s services are available

Step 1: Install

Open a terminal and run the command for your system.

macOS, Linux or WSL:

Prompt
curl -fsSL https://claude.ai/install.sh | bash

Windows PowerShell:

Prompt
irm https://claude.ai/install.ps1 | iex

Windows CMD:

Prompt
curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd

The installer doesn’t show progress while it downloads. Wait for it to finish. You don’t need to run it as Administrator on Windows.

Prefer a package manager? brew install --cask claude-code (Homebrew) or winget install Anthropic.ClaudeCode (WinGet) also work. These don’t update automatically, so you’ll need to upgrade them yourself.

Step 2: Check that it worked

Open a new terminal window and run:

Prompt
claude --version

You should see a version number. If your terminal says claude isn’t found, the install folder isn’t on your PATH yet. Anthropic’s troubleshooting page walks through the fix.

For a fuller check, run claude doctor. It prints install and settings diagnostics without starting a session.

Step 3: Start it and log in

Go to a project folder and start Claude Code:

Prompt
cd your-project
claude

On first run, it asks you to log in. Follow the browser prompts with your Claude account.

Windows: native or WSL?

You can run Claude Code natively on Windows or inside WSL (setup docs):

  • Native Windows fits Windows projects and tools. Installing Git for Windows is optional but recommended: with it, Claude Code uses Git Bash for shell commands. Without it, Claude Code uses PowerShell.
  • WSL 2 fits Linux toolchains, and it supports sandboxed command execution. Install and run claude inside the WSL terminal, not from PowerShell.

Common mix-up: if you see The token '&&' is not a valid statement separator, you’re in PowerShell, so use the PowerShell command. If you see 'irm' is not recognized, you’re in CMD, so use the CMD command.

Keeping it updated

The native install updates itself in the background. Updates take effect the next time you start Claude Code. To update right away:

Prompt
claude update

You can choose the stable channel, which is about a week behind and skips releases with major regressions, using /config.

Prefer not to use the terminal?

The Claude desktop app includes Claude Code, so you don’t need to install the CLI separately. There are also extensions for VS Code and JetBrains IDEs, and a web version at claude.ai/code (Claude Code overview).

Uninstall

For a native install on macOS, Linux or WSL:

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

Homebrew: brew uninstall --cask claude-code. WinGet: winget uninstall Anthropic.ClaudeCode. To remove settings and history too, see the uninstall section of the docs. That step deletes your saved settings.

Our take

The install itself takes a minute. What trips people up is the paid-plan requirement and, on Windows, the shell setup. Our advice: start Claude Code in a small test project first, and read what it wants to change before you approve it.

Visit Claude Code


Essential cookies keep DGTULS working and are always on. Optional cookies help us measure traffic and show ads. Accept, reject or choose which ones to allow. Learn more in our Cookie Policy, Privacy Policy and Terms of Use.