AI Guides › Step-by-step guides
By Nigel Guy · 7 min read
Most people meet a chat window first, so they treat Claude Code as a smarter chat window. They ask for a whole app, paste the answer into a file, hit an error, paste the error back, and repeat. It feels like progress while you do not understand a word of what is landing on your machine.
Claude Code works differently. It runs in your terminal, reads the files in the folder you start it in, makes edits, runs commands, reads the output and tries again. The catch is that it stops when the work looks finished. Unless you give it a way to check, you are the checker.
The rule: start in one empty folder, give Claude one small job, and tell it the check that proves the job is done, so it runs the check itself instead of you pasting errors back.
You need:
Claude Code also exists as a desktop app, in VS Code and in a browser at claude.ai/code. This guide covers the terminal version, because it is the one the official quickstart walks through.
Open a terminal and run the line for your system.
| System | Command |
|---|---|
| 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 |
| Homebrew | brew install --cask claude-code |
| WinGet | winget install Anthropic.ClaudeCode |
Beginner trap: the PowerShell and CMD commands are not interchangeable. PowerShell's prompt starts with PS C:\; CMD's does not. If you see "The token '&&' is not a valid statement separator", you pasted the CMD line into PowerShell.
On native Windows, Git for Windows is recommended but optional. Without it, Claude Code uses PowerShell for its shell commands.
The native installer updates itself in the background. Homebrew and WinGet installs do not, so you run brew upgrade claude-code or winget upgrade Anthropic.ClaudeCode yourself.
Open a new terminal window and run:
claude --version
You should see a version number followed by "(Claude Code)". If your shell says the command is not found, the install folder is not on your PATH yet. Anthropic has a "Troubleshoot installation" page for exactly that. You can also run claude doctor, which prints read-only diagnostics without starting a session.
Do not point your first session at a folder full of important files. Make a new one:
mkdir first-build
cd first-build
claude
On first use you are prompted to log in. Follow the browser prompts with your Claude account. To switch account later, type /login inside the session. If you have an ANTHROPIC_API_KEY environment variable set, Claude Code asks you to approve that key instead of opening the browser, which bills the API rather than your plan, so be sure that is what you want.
Claude Code asks before it acts, depending on its permission mode. In the strictest mode (default) it can read freely but asks before edits and commands. Anthropic's docs say that from version 2.1.283, interactive terminal sessions start in auto mode, where a second model reviews actions instead of you and most file edits and commands go ahead without a prompt. Earlier versions started in auto mode only on Pro, Max and Team. Your settings or organisation can change the starting mode.
What this means for you: look at the mode shown on screen. Press Shift+Tab to cycle modes. For a first session in an empty folder, either is fine. In a folder you care about, choose the mode where you approve things yourself until you trust the pattern.
A good first prompt names the job, the constraints and the check. Replace the bracketed parts with your own.
You are helping a beginner build their first small project. I am not a developer, so explain anything technical in plain English.
Goal: build [A_SMALL_THING_E.G._A_TIP_CALCULATOR_WEB_PAGE] in this empty folder.
A good result is: [WHAT_YOU_WILL_SEE_WHEN_IT_WORKS, E.G._TYPE_A_BILL_AND_GET_THE_TIP_AND_TOTAL].
Constraints:
- Use [LANGUAGE_OR_FORMAT_E.G._PLAIN_HTML_AND_JAVASCRIPT, OR "YOUR_CHOICE_BUT_KEEP_IT_SIMPLE"].
- No extra libraries or accounts. Keep it to as few files as possible.
- Do not touch anything outside this folder.
Order of work:
1. Tell me your plan in five lines or fewer, and wait for my go-ahead.
2. Build it.
3. Check it: [THE_CHECK_E.G._RUN_THREE_EXAMPLE_CALCULATIONS_AND_SHOW_ME_THE_OUTPUT].
4. Tell me which files you made, how to open or run it, and anything you were unsure about.
If anything I have not specified would change the result, ask me before guessing. Before you answer, check that your plan has a way of proving it works.
You fill in: the thing to build, what "working" looks like, the language preference (or leave it to Claude) and the check you want run. The "wait for my go-ahead" line is deliberate. It keeps you in the plan before anything is written, which Anthropic's best-practice page recommends for anything you are unsure about.
Read the five-line plan. If it mentions something you did not want (a framework, an account, a database), say so now. Then reply "go ahead". When Claude asks permission to create a file or run a command, read what it is about to do before approving. Open the result as it tells you.
Use these in order:
/rewind) to restore earlier code and conversation. Checkpoints only track edits made through Claude's file tools, not changes made by commands, and they are not a replacement for git./clear and send a better first prompt that includes what you learned.claude --continue resumes the latest conversation in that folder./help lists them, and /clear and /exit cover most of your first day./init later if you want a starter CLAUDE.md file, the file Claude reads at the start of each conversation.sudo npm install -g. Anthropic warns against it. The native install above does not need it.