Learn Claude Code: Free 24-Lesson Course for Beginners

Claude Code, from first install to your own agent

24 sessions of 15 minutes each. Read for 3 minutes, practise for 10, then prove it to yourself with a 2-minute checkpoint. At one session a weekday, you finish in about five weeks.

0 of 24 done

Before you start

Open one session at a time. Each one has the same three parts: Learn (3 minutes), Do (10 minutes) and a checkpoint (2 minutes). Tick the checkpoint when you can do it without looking. Your progress is saved in this browser.

If a session runs long, stop at 15 minutes and finish it next time. Short, regular sessions stick better than long ones.

You need:

  • A paid Claude plan (Pro, Max, Team or Enterprise) or an Anthropic Console account. The free Claude.ai plan does not include Claude Code.
  • A computer running macOS, Linux or Windows, with a terminal you can open.
  • A small practice project. If you have none, Session 3 shows you how to have Claude create one.
  • Git installed (needed from Session 6 onward).

Claude Code changes often. If a command here doesn't match what you see, check the official docs or type /help inside Claude Code.

Phase 1: Foundations

Sessions 1–6. Install Claude Code, ask it about a project, let it edit files safely, and commit your work.

1Install and sign in15 min
Learn

Claude Code is an agentic coding tool. It reads your project, edits files and runs commands for you, always inside the folder you start it in. It runs in the terminal, in VS Code and JetBrains, in the Claude desktop app and in the browser. This course uses the terminal because every other surface builds on it.

Do
  1. Install it. On macOS or Linux 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) also work.
  2. Confirm it worked: claude --version.
  3. Open a terminal in your practice project folder and type claude. Sign in with your Claude account when the browser opens.
  4. Type /help and skim the list of commands.
  5. Exit with exit or Ctrl+D.
2Ask before you build15 min
Learn

The best first move in any project is to ask questions. Claude reads files as it needs them, so you never have to paste code in by hand.

Do
  1. Start claude in your project.
  2. Ask: what does this project do?
  3. Ask: explain the folder structure, then where is the main entry point?
  4. Ask one follow-up about something you didn't understand.
  5. Watch which files Claude opens; this shows you how it explores.
3Your first edit15 min
Learn

You describe the change in plain words. Claude finds the code, proposes the edit, and shows you a diff before it writes anything.

Do
  1. No project yet? Ask: create a small Python to-do list app in this folder with a README.
  2. Otherwise ask for a small change, such as add a --help message to the CLI or fix the typos in the README.
  3. Read each proposed diff before you accept it.
  4. Ask Claude to run the program and show you the result.
4Permissions and staying in control15 min
Learn

Permission modes decide how much Claude may do without asking. Press Shift+Tab to cycle through them; the current mode shows near the prompt. Newer versions default to auto mode, where a safety check approves routine actions and stops risky ones. Plan mode lets Claude read and plan but not change anything.

Do
  1. Press Shift+Tab a few times and note each mode name.
  2. Give Claude a task, then press Esc part-way through to interrupt it. Redirect it with a new instruction.
  3. Press Esc twice to open rewind, and roll back the last change.
  4. Type /permissions to see what is allowed and denied.
5Prompt shortcuts15 min
Learn

A few shortcuts make you much faster. @ followed by a file name points Claude at that exact file. ! at the start of a line runs a shell command directly. You can paste a screenshot or drag in an image. Shift+Enter adds a new line without sending (if it doesn't, run /terminal-setup).

Do

Use each shortcut once in your project. Paste a screenshot of an error or a web page and ask Claude what it shows.

6Git through conversation15 min
Learn

Claude handles Git in plain language: branches, commits with good messages, and resolving merge conflicts.

Do
  1. Ask: create a new branch called feature/practice.
  2. Ask for a small change, then: commit this with a descriptive message.
  3. Ask: show me what changed in the last 3 commits.
  4. If you use GitHub with the gh CLI installed, ask: open a pull request for this branch.

Phase 2: Everyday workflows

Sessions 7–12. Work the way experienced users do: plan first, give Claude a way to check its own work, and keep each session clean.

7Prompts that get good results15 min
Learn

Claude does its best work when you say what done looks like. Compare fix the login bug with users get logged out after 5 minutes; find the cause, fix it, and add a test that proves it. The second names the symptom, the goal and how to check it.

Do
  1. Write a vague prompt for a small task and note the result.
  2. Rewrite it with three parts: context (what is happening), goal (what you want) and check (how Claude proves it worked).
  3. Run it and compare.
8Plan before code15 min
Learn

For anything bigger than a one-file change, use this loop: explore, plan, code, commit. Plan mode (press Shift+Tab until it shows) keeps Claude read-only while it investigates and proposes a plan.

Step 2 is where you save the most time: fixing a plan is far cheaper than fixing finished code.

Do
  1. Switch to plan mode.
  2. Ask for a medium feature, such as add due dates to tasks, with sorting by due date.
  3. Read the plan. Push back on one step you would change.
  4. Approve it, let Claude build it, then ask for a commit.
9Manage context15 min
Learn

Everything in a session (your messages, files read, command output) fills Claude's context window. A crowded context makes answers slower and less focused. /context shows what's using space. /compact summarises the conversation so far and frees room. /clear starts fresh; use it whenever you switch to an unrelated task.

Do

Run /context after a long task. Then run /compact, run /context again and compare. Finish with /clear.

10Pick up where you left off15 min
Learn

Sessions are saved, so you can come back to them. claude --continue (or claude -c) reopens your most recent session in this folder. claude --resume or /resume lets you pick an older one. /rename gives a session a name you'll recognise later.

Do

Name your current session, exit, then reopen it with --continue. Open a different past session with /resume.

11Tests and debugging15 min
Learn

Tests give Claude a way to check itself, so it can keep going until the work is right. Two useful patterns: write the tests first and ask Claude to make them pass, or paste an error and ask for the root cause before any fix.

Do
  1. Ask: write tests for the add-task function; don't change the function yet.
  2. Review the tests, then: now make all tests pass.
  3. Break something on purpose, run it, and paste the error with: find the root cause first, then fix it.
12Your editor, models and effort15 min
Learn

Claude Code also runs inside VS Code and JetBrains, where you see diffs inline. /model switches models: lighter ones are faster and use less of your plan, stronger ones are better at hard problems. The same menu sets the effort level, which trades speed for deeper thinking.

Do
  1. If you use VS Code, install the Claude Code extension from the Marketplace and repeat Session 3 there.
  2. In the terminal, run /model and look at the options.
  3. Ask one quick question on a fast model and one design question on a stronger model; compare.
  4. Run /usage to see what is drawing on your plan limits.

Phase 3: Customization

Sessions 13–18. Teach Claude Code your project's rules, give it reusable workflows, and connect it to outside tools.

Rule of thumb: advice goes in CLAUDE.md, repeatable tasks become skills, outside data comes through MCP, and anything that must happen every time is a hook.

13CLAUDE.md, the project memory15 min
Learn

CLAUDE.md is a file of standing instructions that Claude reads at the start of every session: build commands, code style, things to avoid. A project one lives in the repo root and is shared with your team; a personal one lives at ~/.claude/CLAUDE.md and applies everywhere.

Do
  1. Run /init to have Claude draft a CLAUDE.md from your project.
  2. Cut it down to the rules that matter. Short beats long: every line uses context in every session.
  3. Add one rule, such as always run the tests before committing, then start a new session and check that Claude follows it.
14Settings and permission rules15 min
Learn

settings.json files control how Claude Code behaves. There are three levels: personal, project shared and project local. Allow and deny rules stop Claude from asking about safe commands and block dangerous ones.

Do
  1. Run /config and browse the settings.
  2. Use /permissions to allow your test command (for example npm test) and deny something you never want run.
  3. Open .claude/settings.json and find the rules you just made.
15Skills, your reusable workflows15 min
Learn

A skill is a folder with a SKILL.md file of instructions for a task you repeat, such as writing release notes or reviewing a pull request your team's way. Claude loads it when the task matches, or you run it by name as a slash command.

Do
  1. Ask Claude: create a skill in .claude/skills that writes a changelog entry from my recent commits.
  2. Read the SKILL.md it made and tighten the instructions.
  3. Make a commit, then run your skill by name.
16Connect tools with MCP15 min
Learn

MCP (Model Context Protocol) servers connect Claude Code to outside tools such as issue trackers, databases, browsers and design files. Once a tool is connected, Claude can read your tickets or query your data directly.

Do
  1. Pick one tool you use (GitHub, Sentry, a database) and find its MCP server in the MCP docs.
  2. Add it with claude mcp add as the docs show.
  3. Run /mcp to confirm it's connected.
  4. Ask Claude something that needs it, such as summarise my open issues.
17Hooks, the automatic rules15 min
Learn

Hooks are shell commands that run automatically at set moments: before Claude uses a tool, after it edits a file, when it finishes. Unlike instructions in CLAUDE.md, hooks always run. Common uses are auto-formatting, blocking edits to protected files and desktop notifications.

Do
  1. Run /hooks to see the events available.
  2. Ask Claude: add a hook that runs the formatter after every file edit.
  3. Make an edit and confirm the formatter ran.
18Plugins, bundles you can share15 min
Learn

A plugin packages skills, subagents, hooks and MCP servers so you can install them in one step, or share your setup with a team. Plugins come from marketplaces, including Anthropic's official one. Only install plugins you trust: they can run code on your computer.

Do
  1. Run /plugin and browse the marketplace.
  2. Install one plugin that fits your work, such as a language server plugin for your language.
  3. Use it in a task, then check /plugin list.

Phase 4: Advanced

Sessions 19–24. Run several agents at once, automate Claude in scripts and CI, and build your own agent.

19Subagents15 min
Learn

A subagent is a specialist Claude that works in its own separate context and reports back a summary. This keeps your main session clean and lets work run side by side. You can define your own, such as a code reviewer or a test writer, each with its own instructions and tool access.

Do
  1. Run /agents and create a code-reviewer subagent that only reads files.
  2. Make a change, then ask: use the code-reviewer agent to review my last commit.
  3. Ask Claude to research two parts of the codebase with subagents at the same time.
20Parallel work with worktrees15 min
Learn

Git worktrees give each Claude session its own copy of the repo, so two sessions can change code without colliding. Start one with claude --worktree. Agent view lets you watch and steer many sessions from one screen.

Do
  1. In one terminal, start a session with --worktree and give it feature A.
  2. In a second terminal, do the same with feature B.
  3. Let both run, then review and merge each branch.
21Headless mode and long-running tasks15 min
Learn

claude -p "your prompt" runs Claude once without the interactive screen and prints the result, so you can use it in scripts and pipes. Inside a session, /goal keeps Claude working until a condition you set is met, and /loop repeats a prompt on a schedule.

Do
  1. Run claude -p "list the TODO comments in this project".
  2. Pipe data in: git diff | claude -p "summarise these changes in 3 bullets".
  3. Try /goal all tests pass on a project with a failing test.
22GitHub Actions and code review15 min
Learn

Claude Code can run in GitHub Actions, where it answers @claude mentions in issues and pull requests, turns issues into pull requests, and reviews code. /code-review reviews your local changes before you push.

Do
  1. Run /code-review on your current branch and act on one finding.
  2. In a GitHub repo you own, run /install-github-app and follow the setup.
  3. Open an issue that says @claude add input validation to the add-task command and watch the pull request appear.
23Claude Code in the cloud15 min
Learn

Claude Code also runs in Anthropic's cloud at claude.ai/code, from a browser or the Claude mobile app, with no local setup. You can hand off long tasks and review the pull request later. Routines run Claude on a schedule or when a GitHub event happens.

Do
  1. Open claude.ai/code, connect a GitHub repo, and give it a small task.
  2. Check on it from your phone in the Claude app.
  3. Set up one routine, such as a weekly dependency check.
24Capstone: build an agent with the Agent SDK15 min
Learn

The Claude Agent SDK, for Python or TypeScript, gives you the same engine as Claude Code as a library. You can build your own agents with custom tools, permissions and hooks.

Do
  1. Follow the Agent SDK quickstart in the language you prefer.
  2. Build a tiny agent that reads a folder of notes and answers questions about them.
  3. Ask Claude Code to help you write it; you now know how to plan, test and commit the work.

After Session 24, keep going with one 15-minute session a week: read the What's new page and try one new feature.

Cheat sheet

Command or keyWhat it doesSession
claudeStart a session in the current folder1
/helpList commands1
exit or Ctrl+DLeave Claude Code1
Shift+TabCycle permission modes, including plan mode4, 8
EscInterrupt Claude4
Esc EscRewind to an earlier point4
@filePoint Claude at a file5
!commandRun a shell command directly5
/contextShow what fills the context window9
/compactSummarise and free context9
/clearStart fresh9
claude -c, /resumeContinue or pick a past session10
/modelSwitch model and effort12
/initDraft a CLAUDE.md13
/permissions, /configAllow and deny rules, and settings14
/mcpCheck MCP connections16
/hooksView and manage hooks17
/pluginBrowse and install plugins18
/agentsCreate and manage subagents19
claude --worktreeStart an isolated parallel session20
claude -p "..."Run once without the interactive screen21
/code-reviewReview local changes22
/doctorDiagnose setup problemsany

Commands checked against the official Claude Code documentation in October 2026; features change often, so see code.claude.com/docs for the latest. A Your Online Business (YOB247) course. Claude and Claude Code are products of Anthropic. This course is independent and is not affiliated with or endorsed by Anthropic.

Your Online Business
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.