how to build

Guide · 2 of 8

Get Claude Code

Claude Code is an agent that lives in your terminal. You tell it what you want in plain words. It reads your files, writes code and runs commands, and it asks before it does anything big. By the end of this page it will be installed, logged in, and it will have built a small web page for you.

You need

1. Install it

One command installs Claude Code. It also keeps itself up to date after that.

Mac

  1. Paste this into your terminal and press Enter.
    curl -fsSL https://claude.ai/install.sh | bash

    You should see: nothing for a while. The installer prints nothing while it downloads. Wait for the prompt to come back, then read the last few lines.

If you use Homebrew, brew install --cask claude-code also works. That version does not update itself; run brew upgrade claude-code now and then.

Windows

WSL (Ubuntu), recommended: open Ubuntu and run the same command as Mac and Linux.

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

    You should see: nothing for a while. It prints nothing while it downloads. Wait for the prompt to come back.

PowerShell: install Git for Windows first (see chapter 1), so Claude Code can run its commands. Then run:

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

From the old Command Prompt (CMD) instead, run:

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

winget install Anthropic.ClaudeCode also works, but that version does not update itself.

Linux

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

    You should see: nothing for a while. The installer prints nothing while it downloads. Wait for the prompt to come back.

  1. Close the terminal and open a new one. The new terminal is the one that knows about claude.
  2. Check the install:
    claude --version

    You should see: a version number followed by (Claude Code), like 2.1.316 (Claude Code). Your number will be different. That is fine.

2. Pick a plan and log in

Claude Code needs an account that includes it. These work:

The free Claude plan does not include Claude Code. If you are starting out, Pro is the entry plan. At the time of writing (November 2026) Pro was US$20 a month. Prices change, so check claude.com/pricing.

  1. Make a folder for a first test project and move into it.
    mkdir ~/code/hello
    cd ~/code/hello
  2. Start Claude Code.
    claude

    You should see: Claude Code asks you to log in, and your web browser opens a Claude page.

  3. Log in in the browser with the account that has the plan. Approve the request. Then go back to the terminal.

    You should see: a welcome message and a box where you can type. It may ask if you trust the files in this folder. You made the folder, so say yes.

3. Your first session

Commands that start with a slash, like /help, are for Claude Code itself. Everything else you type is a message to the agent. Write to it the way you would message a friend who codes.

  1. Ask for something small. Type this and press Enter:
    Make an index.html that says Hello and shows today's date. Keep it to one file.

    You should see: Claude Code says what it plans to do, then asks permission to create index.html. Read what it wants to do. Then say yes.

  2. Look at the page. Open a second terminal, go to the folder, and open the file in your browser.
    cd ~/code/hello

    Mac

    open index.html

    Windows

    In WSL (Ubuntu):

    explorer.exe index.html

    In PowerShell:

    start index.html

    Linux

    xdg-open index.html

    You should see: a web page with "Hello" and today's date. You described it, and there it is.

  3. Back in Claude Code, set up its memory file:
    /init

    You should see: it looks around the folder and writes a file called CLAUDE.md. Claude Code reads this file at the start of every session. It is where the rules of a project go: what it is, how to run it, what not to touch. You can edit it yourself any time.

  4. Ask it a question:
    What does this project do?

    You should see: a short, plain answer about your Hello page. Questions are safe. It only reads.

  5. Make a tiny change:
    Make the background dark blue and the text white.

    You should see: it shows the change it wants to make to index.html and asks first. Say yes. Then reload the page in your browser. It is blue now.

Permission modes (Shift+Tab)

Press Shift + Tab in the box. Each press moves to the next mode. The line under the box tells you which one you are in.

Commands worth knowing

From the terminal, before you start it:

  1. Pick up where you left off last time in this folder:
    claude -c

    You should see: your last conversation, ready to continue.

  2. Choose from older sessions:
    claude -r

From here on, hand it the commands

You now have a program that knows the terminal, git, GitHub and Cloudflare far better than most people. The rest of this guide still shows the commands, folded away under "By hand", for when you are curious. You do not have to learn them. Say what you want in plain words, read what it asks to run, say yes. After a few projects you will know the commands anyway, just from watching.

4. Limits

Every plan has two limits on how much you can use it.

Hitting one feels like this. You are in the middle of something. Claude Code tells you that you have hit your limit. It stops working until the limit resets. Your files are fine, and nothing is lost. You just have to wait, or upgrade your plan.

Long conversations use more than short ones, because the agent rereads the whole conversation each turn. Two habits help you spend less:

Other ways in

Want a second explanation? Anthropic has a free course, Claude Code 101, at academy.claude.com.

If it didn't

What you just did

You installed Claude Code and logged in with a plan. You had it build a page, wrote its memory file with /init, asked it a question and changed the page. You know the three permission modes and what the limits feel like.