ClaudeDetails
ChangelogGuidesClaude CodeModelsMCPPromptsToolsLearning Paths
ChangelogGuidesClaude CodeModelsMCPPromptsToolsLearning Paths

On this page

What you need before startingStep 1: Install Claude CodeStep 2: Log inStep 3: Start your first sessionStep 4: Ask questions about your codebaseStep 5: Make your first code changeStep 6: Use Git conversationallyFAQ
Home/Guides/Claude Code
Claude CodeBEGINNER

Claude Code Quickstart: Install, Log In, and Make Your First Code Change

Last verified August 9, 2026·4 min read

This guide walks through getting started with Claude Code, Anthropic's terminal-based coding tool. It covers installing Claude Code on macOS, Linux, Windows, and WSL using the native installer, Homebrew, or WinGet, then logging in with a Claude subscription, Console account, or enterprise cloud provider. From there it shows how to start a session in a project directory, ask questions about a codebase, make a first code change with permission modes, and use Git conversationally. It is based on Anthropic's official quickstart documentation.

What you need before starting

Before installing Claude Code, make sure you have:

  • A terminal or command prompt open (Anthropic's docs link to a terminal guide if you've never used one)
  • A code project to work with
  • A Claude subscription (Pro, Max, Team, or Enterprise), a Claude Console account, or access through a supported cloud provider

This quickstart covers the terminal CLI, but Claude Code is also available on the web, as a desktop app, in VS Code and JetBrains IDEs, in Slack, and in CI/CD with GitHub Actions and GitLab.

Step 1: Install Claude Code

The native install is the recommended method.

macOS, Linux, WSL:

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

Windows PowerShell:

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

Windows CMD:

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

A few Windows-specific notes from the docs:

  • If you see The token '&&' is not a valid statement separator, you're in PowerShell, not CMD. If you see 'irm' is not recognized as an internal or external command, you're in CMD, not PowerShell. Your prompt shows PS C:\ in PowerShell and C:\ without the PS in CMD.
  • Git for Windows is recommended on native Windows so Claude Code can use the Bash tool. Without it, Claude Code uses PowerShell as the shell tool instead. WSL setups don't need Git for Windows.

Native installations automatically update in the background.

Homebrew

bash
brew install --cask claude-code

Homebrew offers two casks: claude-code tracks the stable channel (typically about a week behind, and it skips releases with major regressions), while claude-code@latest tracks the latest channel. Homebrew installs do not auto-update — run brew upgrade claude-code or brew upgrade claude-code@latest depending on which cask you installed.

WinGet

powershell
winget install Anthropic.ClaudeCode

WinGet installs also do not auto-update; run winget upgrade Anthropic.ClaudeCode periodically.

You can also install with apt, dnf, or apk on Debian, Fedora, RHEL, and Alpine.

To verify the install:

bash
claude --version

The command prints a version number followed by (Claude Code).

Step 2: Log in

Claude Code requires an account. Start an interactive session and you'll be prompted to log in on first use:

bash
claude

For subscription or Console accounts, authentication completes in your browser. If you've set the ANTHROPIC_API_KEY environment variable, Claude Code skips the login prompt and asks you to approve the key instead. To switch accounts or re-authenticate later, type /login inside a running session.

Supported account types:

  • Claude Pro, Max, Team, or Enterprise (recommended)
  • Claude Console (API access with pre-paid credits; on first login, a "Claude Code" workspace is automatically created in the Console for centralized cost tracking)
  • Amazon Bedrock, Google Cloud's Agent Platform, or Microsoft Foundry
  • A self-hosted Claude apps gateway, if your organization runs one — the admin pre-configures the gateway URL and /login opens on the Cloud gateway screen for corporate SSO

Once logged in, credentials are stored and you won't need to log in again.

Step 3: Start your first session

Open your terminal in a project directory and start Claude Code:

bash
cd /path/to/your/project
claude

You'll see the Claude Code prompt with the version, current model, and working directory shown above it. Type /help for available commands or /resume to continue a previous conversation.

Step 4: Ask questions about your codebase

A good first prompt is a codebase question:

text
what does this project do?

Claude analyzes your files and provides a summary. Other examples from the docs:

text
what technologies does this project use?
text
where is the main entry point?
text
explain the folder structure

You can also ask Claude about its own capabilities, such as what can Claude Code do?, how do I create custom skills in Claude Code?, or can Claude Code work with Docker?.

Note that Claude Code reads your project files as needed — you don't have to manually add context.

Step 5: Make your first code change

Try a simple task:

text
add a hello world function to the main file

Claude Code will find the appropriate file, show you the proposed changes, ask for approval before changing files (depending on your permission mode), and make the edit.

Whether Claude asks first depends on your permission mode. In default mode, Claude asks for approval before each change. Press Shift+Tab to cycle through modes: acceptEdits auto-approves file edits, and plan lets Claude propose changes without editing. Some accounts also have an auto mode that runs a background safety check and blocks risky actions, returning to prompts only after repeated blocks.

Step 6: Use Git conversationally

Claude Code handles Git operations through plain-language prompts:

text
what files have I changed?
text
commit my changes with a descriptive message

You can also prompt for more complex Git operations, such as creating branches. (The source page continues beyond this point; consult Anthropic's full quickstart for the remaining steps.)


claudedetails.com is an independent publication and is not affiliated with, endorsed by, or sponsored by Anthropic. "Claude" is a trademark of Anthropic, PBC, used here for identification purposes only. Drafts are AI-assisted and reviewed by a human editor before publishing. Product details can change — always confirm specifics on Anthropic's own site before making decisions based on this post.

FAQ

How do I install Claude Code?

The recommended method is the native installer: on macOS, Linux, or WSL run `curl -fsSL https://claude.ai/install.sh | bash`; on Windows PowerShell run `irm https://claude.ai/install.ps1 | iex`. Homebrew (`brew install --cask claude-code`) and WinGet (`winget install Anthropic.ClaudeCode`) are also supported, as are apt, dnf, and apk on Debian, Fedora, RHEL, and Alpine. Verify with `claude --version`.

Does Claude Code update automatically?

Native installations automatically update in the background. Homebrew and WinGet installations do not auto-update — run `brew upgrade claude-code` (or `brew upgrade claude-code@latest`) or `winget upgrade Anthropic.ClaudeCode` periodically to get the latest features and security fixes.

What account do I need to use Claude Code?

You can log in with a Claude Pro, Max, Team, or Enterprise subscription (recommended), a Claude Console account with pre-paid API credits, an enterprise cloud provider (Amazon Bedrock, Google Cloud's Agent Platform, or Microsoft Foundry), or a self-hosted Claude apps gateway if your organization runs one. Credentials are stored after first login.

Does Claude Code ask permission before editing my files?

It depends on your permission mode. In default mode, Claude asks for approval before each change. Press Shift+Tab to cycle modes: acceptEdits auto-approves file edits, and plan lets Claude propose changes without editing. Some accounts also have an auto mode that runs a background safety check and blocks risky actions.

ClaudeDetails
GuidesModelsMCPPromptsToolsLearning PathsRSS

claudedetails.com is an independent publication and is not affiliated with, endorsed by, or sponsored by Anthropic. "Claude" is a trademark of Anthropic, PBC, used here for identification purposes only. Drafts are AI-assisted and reviewed by a human editor before publishing. Product details can change — always confirm specifics on Anthropic's own site before making decisions based on this post.