How to install Claude Code on macOS, Linux, or Windows

Install Claude Code on macOS, Linux, WSL, or Windows, verify the command, sign in, and run a safe first task inside a Git repository.

A hand-drawn Claude Code installation path from official source and platform choice through verification, login, project, and review.

From official source to reviewed change

A six-step path through source verification, platform choice, installation, command verification, login, and review.

  1. Source
  2. platform
  3. install
  4. verify
  5. login
  6. review

Better Design

On this page

Direct answer

To install Claude Code, open Anthropic's current setup page and choose the command for your operating system. The recommended native installer is curl -fsSL https://claude.ai/install.sh | bash on macOS, Linux, or WSL. Windows uses a separate PowerShell command on the same official page. Run claude --version, start claude inside a Git repository, and complete the browser sign-in.

Key takeaways

  • Use the current code.claude.com setup page as the source for every installer command.
  • Anthropic recommends its native installer and also documents Homebrew, WinGet, and Linux package-manager paths.
  • Verify the installed command with claude --version before opening a project.
  • Claude subscriptions, Console accounts, and supported cloud providers use different authentication and billing paths.
  • Start Claude Code inside the smallest relevant Git repository and review every command, edit, test result, and diff.

What Claude Code installs

Claude Code is Anthropic's agentic coding tool for terminal and development workflows. The terminal command can inspect project files, propose edits, run commands, and work with Git. It also appears through editor, desktop, web, and automation surfaces. This guide covers the local terminal installation because that matches the install Claude Code search intent.

Claude Code quickstart

Claude Code CLI install terms explained

People use several names for the same local setup. A Claude Code CLI install, Claude Code CLI installation, or Claude CLI install means installing the claude terminal command. The terms claude-cli and Claude Code terminal usually point to that interface. Claude Code console can instead mean a Console account, which is an authentication and billing path. A search for Claude Code downloader Windows should lead to Anthropic's official options, not an unknown download site.

Check the current system requirements

Check your platform first. Anthropic currently lists macOS 13 or later and Windows 10 version 1809 or later. It also lists several supported Linux distributions. The baseline includes 4 GB of memory, an x64 or ARM64 processor, internet access, and a supported country. Native installers include their own runtime, so a new installation does not need Node.js. Check the official setup page because supported versions can change.

macOS
version 13.0 or later.
Windows
Windows 10 version 1809 or later, or Windows Server 2019 or later.
Linux
current documentation lists Ubuntu 20.04+, Debian 10+, and Alpine Linux 3.19+.
Hardware
at least 4 GB of memory on x64 or ARM64.
Shell
Bash, Zsh, PowerShell, or CMD.

Current system and installation reference

Verify the installer source before you paste a command

Search results can show unsafe or outdated commands. This Claude Code installation guide uses code.claude.com as its primary source. Open that site directly and follow its installer link. Confirm the full domain and command before you run it. Before installing Claude Code, apply your organization's review policy to any command that sends a downloaded script to a shell.

Install Claude Code on macOS, Linux, or WSL

Open a terminal and use Anthropic's current setup page. The curl command to install Claude Code is the recommended native option for macOS, Linux, and WSL. Copy the exact command from the official page. The installer places the claude executable in the documented local binary directory. Open a new terminal when the current shell does not see the updated path. Then run claude --version.

Homebrew and Linux package-manager options

On macOS, Anthropic documents brew install --cask claude-code for the stable release channel. Homebrew installations need an explicit brew upgrade later. The advanced setup page also documents apt, dnf, and apk options for supported Linux distributions. Use one installation method so another claude binary does not hide the version you intended to run.

Install Claude Code on Windows

Native Windows supports PowerShell and CMD installers. In PowerShell, copy the current irm command from Anthropic's setup page. Anthropic documents a separate install.cmd command for CMD. WinGet users can run winget install Anthropic.ClaudeCode. Do not run the terminal as Administrator unless your own managed environment requires it.

  • Native Windows suits projects that use Windows-native tools and paths.
  • WSL 2 suits Linux toolchains and supports Claude Code command sandboxing.
  • Git for Windows is optional on native Windows and enables the Bash tool.
  • Without Git Bash, Claude Code can use PowerShell for shell commands.

Verify the Claude Code CLI installation

Complete the Claude Code install by running claude --version. A working installation prints a version followed by Claude Code. If the command is missing, reopen the terminal and follow the path instructions printed by the installer. On macOS and Linux, the native binary normally lives under ~/.local/bin. On Windows, the equivalent directory is under the current user's profile.

Sign in to Claude Code

Run claude after verification. The first session opens a browser login for a Claude subscription or Console account. Anthropic also documents Amazon Bedrock, Google Cloud's Agent Platform, Microsoft Foundry, and managed gateway access. If ANTHROPIC_API_KEY is already set, Claude Code asks you to approve that key instead. Use /login later when you need another account.

Authentication methods and account types

Start the first session inside a Git project

Open the intended repository. Confirm git status, and then run claude. Begin with a read-only orientation request. Ask it to identify the entry point, test command, and one relevant module. After you confirm that understanding, give one bounded task with a visible result and a verification command.

  1. State one outcome that a person or automated check can observe.
  2. Name the files or product area in scope.
  3. Provide the error, screenshot, acceptance criteria, or expected behavior.
  4. Name the test, type check, lint, build, or manual flow to run.
  5. Review the commands, changed files, output, and final diff before committing.

Choose a permission mode you can review

Default mode asks for approval before each change. Plan mode lets Claude propose work without editing. An edit-accepting mode can reduce prompts after you understand the plan and repository. Start with the narrowest mode and working directory that can finish the task. Sandbox availability differs between native Windows and WSL 2, so check the current platform table.

Add design context before interface changes

An installed coding agent does not know the product's visual rules by default. Give interface tasks the owned design system, interaction guidance, content patterns, required states, and review criteria. Better Design can provide that context to Claude Code through MCP. The developer still needs to run the interface and review the rendered result.

Install Better Design for Claude Code

Fix common installation problems

A missing command often signals a PATH problem. The terminal might also need to restart. A PowerShell command entered in CMD produces a different error because those shells use different syntax. Corporate proxies and certificate inspection can block installer downloads or browser callbacks. Match the exact message to Anthropic's current troubleshooting page instead of trying unrelated commands.

Installation and authentication troubleshooting

Frequently asked questions