Claude Code is an AI-powered coding assistant that operates directly within your terminal. It reads through your codebase, proposes corrections, builds new functionality, executes tests, and manages files by working with your project locally.
This guide covers installation methods, authentication setup, terminal and IDE configuration, and launching your first session. Users can install via native installers, package managers, or npm, with authentication through OAuth or API keys. The tool works with any terminal but offers enhanced features with Warp and IDE extensions for VS Code and JetBrains.
Claude Code Getting Started is the quickest way to bring an AI coding assistant into your terminal. This guide walks through installation, the interactive REPL, permission modes, planning mode, and initializing your first project.

Claude Code Getting Started: What You’ll Learn
In this guide to Claude Code Getting Started, you’ll work through practical, hands-on steps with real examples, explained from the ground up so you can apply it immediately in your own projects.
Understanding Claude Code
Claude Code is an AI-powered coding assistant that operates directly within your terminal, the text-based interface where developers enter commands. Rather than navigating through graphical menus, you simply describe what you need in natural language, and Claude can read through your codebase, propose corrections, build out new functionality, execute tests, and manage files, all by working with your project on your local machine.
Essential Terminology for Terminal Beginners
- Terminal (also referred to as console or command line): a text-based window where you type commands instead of clicking icons. On macOS this is Terminal.app; on Windows it’s Windows Terminal or PowerShell.
- CLI (Command Line Interface): software you operate through typed commands rather than a graphical interface. Claude Code is a CLI application.
- Slash command: a quick shortcut beginning with
/(such as/helpor/config) that triggers a particular action inside Claude Code. - OAuth: a secure login flow that launches your browser so you can sign in without pasting credentials into the terminal.
- API key: a secret token that allows a program to authenticate with a service. It serves as an alternative to OAuth when connecting Claude Code.
- IDE (Integrated Development Environment): a code editor with built-in developer tools. VS Code, IntelliJ IDEA, and PyCharm are well-known examples.
Before you can use any slash command or build a workflow, Claude Code needs to be installed and running on your machine. This lesson guides you through the installation process, authentication setup, choosing the right terminal and IDE configuration, and launching your first session.
System Requirements
Claude Code supports macOS 13+, Ubuntu 20.04+ (along with other modern Linux distributions), and Windows 10 1809+ (natively or through WSL). A minimum of 4 GB of RAM is required, with 8 GB recommended for smooth operation. An active internet connection is needed at all times.
You’ll also need a qualifying Anthropic account, specifically a Pro, Max, Team, Enterprise, or Console plan. The free Claude.ai tier does not include Claude Code access. Alternatively, you can supply an API key from the Anthropic Console or connect through Amazon Bedrock, Google Vertex AI, or Microsoft Foundry.
On Windows, when Git for Windows is installed, Claude Code uses Git Bash for the Bash tool. The PowerShell tool is being rolled out gradually as an additional option alongside Bash. Set CLAUDE_CODE_USE_POWERSHELL_TOOL=1 to enable it or 0 to disable it.
Installing the CLI
The preferred way to install Claude Code is the native installer, which handles background auto-updates so you are always on the latest version without any manual steps.
For macOS or Linux (including WSL):
curl -fsSL https://claude.ai/install.sh | bashFor Windows via PowerShell:
irm https://claude.ai/install.ps1 | iexFor Windows via CMD:
curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmdAlternative installation methods are available but require manual updates. Via Homebrew: brew install --cask claude-code (stable channel) or brew install --cask claude-code@latest (latest channel). Via WinGet: winget install Anthropic.ClaudeCode. Via npm: npm install -g @anthropic-ai/claude-code (requires Node.js 18+). On Linux, system package managers also work: sudo apt install claude-code (Debian/Ubuntu), sudo dnf install claude-code (Fedora/RHEL), or apk add claude-code (Alpine).
After you install Claude Code, verify the installation before you start a real session:
claude --versionFor a thorough check after you install Claude Code, run claude doctor. It validates your setup, MCP servers, and settings, and it is the fastest way to confirm the install Claude Code step completed correctly on your machine.
You can control the update channel through /config. Choose between latest (newest features) and stable (tested releases, approximately one week behind).
Authentication
When you run claude for the first time, it automatically launches your browser for OAuth authentication. Sign in with your Anthropic account and you’re all set.
If you’re using an API key instead, set the environment variable before launching:
export ANTHROPIC_API_KEY=sk-ant...For enterprise or cloud provider setups, use the corresponding environment variables:
- Amazon Bedrock:
CLAUDE_CODE_USE_BEDROCK=1 - Google Vertex AI:
CLAUDE_CODE_USE_VERTEX=1 - Microsoft Foundry:
CLAUDE_CODE_USE_FOUNDRY=1
Your credentials are stored securely in the macOS Keychain on Mac, or in ~/.claude/.credentials.json (mode 0600) on Linux and Windows.
To switch accounts or re-authenticate at any time, use /logout. You can also explicitly trigger authentication with claude auth login. It opens the browser OAuth flow, or if the browser can’t open, prints a URL you can paste into any browser and then paste the authorization code back into the terminal. Additional options include claude auth login --email to pre-fill your email, claude auth login --sso for SSO-enabled organizations, and claude auth login --console for API key authentication through the Anthropic Console.
Your Terminal: Warp Recommended
Claude Code works in any terminal: Terminal.app, iTerm2, Windows Terminal, Alacritty, Kitty, Ghostty, and more. But for the best experience, we recommend Warp.
Warp has an official Claude Code plugin that provides native desktop notifications when Claude completes a task, needs your input, or requests permissions. This is especially useful for long-running operations where you switch to another window.
To set up the Warp plugin, run these commands inside Claude Code after installation:
/plugin marketplace add warpdotdev/claude-code-warp
/plugin install warp@claude-code-warpRestart Claude Code after installation to activate the plugin. You’ll get native OS notifications for task completions, idle states, and permission requests, no more checking back manually.
By default, Claude Code only sends desktop notifications in Ghostty, Kitty, and iTerm2. In any other terminal, set preferredNotifChannel to "terminal_bell" to ring the terminal bell instead, or configure a Notification hook for a custom sound. Shift+Enter for a newline also works without setup in most terminals; in VS Code, Cursor, Devin Desktop, Alacritty, and Zed, run /terminal-setup once to write that keybinding.
By default, Claude Code uses the terminal’s alternate screen for a fullscreen rendering experience. If you prefer to keep the conversation in your terminal’s native scrollback (useful for screen readers, terminal multiplexers, or piping output), set CLAUDE_CODE_DISABLE_ALTERNATE_SCREEN=1 before launching.
IDE Extensions
Claude Code started as a CLI tool, but it now has official extensions for major editors. You can use both: the CLI for heavy terminal work and the extension for in-editor convenience.
VS Code is the most mature integration. Install it from the VS Code Marketplace or run code --install-extension Anthropic.claude-code. It gives you a native graphical interface, visual diff review, file references, conversation history, and the ability to run multiple conversations in tabs.
JetBrains has an official plugin in beta, available in the JetBrains Marketplace for IntelliJ IDEA, WebStorm, PyCharm, and other JetBrains IDEs. It orchestrates the CLI with the IDE’s diff viewer for a seamless experience.
Cursor, Devin Desktop (renamed from Windsurf in v2.1.162), and Kiro are VS Code forks that support the VS Code extension and the integrated terminal. In VS Code, Cursor, and Devin Desktop, /terminal-setup turns off the integrated terminal’s GPU acceleration (to prevent garbled text) and adjusts its scroll sensitivity for smoother fullscreen scrolling, and /ide and /scroll-speed use the new Devin Desktop label too.
Beyond IDE extensions, there’s also a Desktop App for macOS and Windows (not available on Linux; use the CLI instead) that provides visual diffs, live app preview, and autonomous background agents, no terminal needed. And Claude Code on the Web (claude.ai/code) is a research preview that runs on cloud VMs, so you can work from any browser without any local setup.
Your First Session
Navigate to any project directory and launch Claude Code:
cd my-project
claudeYou’ll see a welcome message and a prompt. Just type what you want Claude to do in plain English. You can also paste images with Ctrl+V. A “Pasting…” hint appears in the footer while the image is being read from the clipboard:
What files are in this project and what does it do?Claude will read your files, analyze the structure, and give you a summary. From here, you can ask it to make changes, fix bugs, run tests, or explain code. When Claude needs to perform actions like editing files or running commands, it will ask for your permission first.
That’s it. You’re ready. Head to the next module to learn the slash commands that make Claude Code truly powerful.
Choosing the Right Installation Method
There are several ways to install Claude Code, and the right choice depends on your operating system, how you manage packages, and whether you want automatic updates. The native installer is the recommended path for most users because it handles background updates and avoids the version drift that comes with package managers. When you install Claude Code through the native installer, the binary lands in a stable location and a small update service keeps it current without any action on your part.
Homebrew on macOS is a good fit if you already manage your developer tools through brew. The command brew install --cask claude-code pulls the stable channel, while brew install --cask claude-code@latest tracks the newest releases. The tradeoff is that Homebrew does not auto-update Claude Code the way the native installer does, so you have to remember to run brew upgrade on a regular cadence. For teams that pin versions in a Brewfile, this manual control is actually a benefit rather than a drawback.
npm is the most cross-platform option, but it requires Node.js 18 or newer. If you install Claude Code through npm with npm install -g @anthropic-ai/claude-code, watch out for global-prefix permission errors (EACCES) on macOS and Linux, which are the single most common install Claude Code failure reported by npm users. Fixing the npm global prefix, running the install with a node version manager such as nvm, or switching to the native installer resolves this cleanly.
Linux distribution package managers such as apt, dnf, and apk are convenient on servers and inside container images, and WinGet with winget install Anthropic.ClaudeCode is the natural choice on Windows for users who live in the package-manager ecosystem. Each of these methods works, but like Homebrew they require manual updates, so pick them only when you have a specific reason to prefer them over the native installer. In CI and Docker images, pinning a version through a package manager is often preferable because it makes builds reproducible.
| Method | Best for | Auto-updates | Main caveat |
|---|---|---|---|
| Native installer | Most users | Yes | Newest path; recommended default |
| Homebrew | macOS brew users | No | Run brew upgrade manually |
| npm | Cross-platform, Node shops | No | Global-prefix permissions; Node 18+ |
| WinGet | Windows package users | No | Manual upgrades |
| apt / dnf / apk | Linux servers, containers | No | Good for pinned CI images |
Whichever path you choose, the install Claude Code workflow ends the same way: a claude binary on your PATH that you launch from inside a project directory. If you later switch methods, uninstall the old one first so that you do not end up with two binaries that update on different schedules and disagree about which features are available.
Troubleshooting Common Installation Problems
Most install Claude Code failures fall into a small number of categories, and each one has a known fix. Working through them in order gets almost every environment running in a few minutes. The first check is always the PATH: after you install Claude Code, open a fresh terminal and run which claude (or where claude on Windows) to confirm the shell can resolve the binary. A stale shell session that has not picked up the new PATH is the most common reason a freshly installed binary reports command not found.
command not found after install
If the shell cannot find claude right after you install Claude Code, the binary is on disk but your shell has not re-read its configuration. Open a new terminal window, or run hash -r (bash) / rehash (zsh) to clear the command cache. On macOS with Homebrew, run brew --prefix claude-code to confirm the install location, then make sure that prefix is on your PATH inside ~/.zshrc or ~/.bash_profile.
npm EACCES permission errors
When you install Claude Code globally through npm and see EACCES: permission denied inside /usr/local/lib/node_modules or /opt/homebrew/lib/node_modules, the npm global prefix is owned by root. Two fixes work: configure npm to use a prefix inside your home directory with npm config set prefix ~/.npm-global and add that to PATH, or switch to the native installer which sidesteps npm entirely. Avoid the temptation to run sudo npm install -g; it papers over the problem and often creates file-ownership conflicts later.
Node version too old
The npm package needs Node.js 18 or newer. Run node --version to check. If you are on an older LTS, install Claude Code after upgrading Node through nvm (nvm install --lts) or your system package manager. On the native installer path, Node is not required at all, which is one reason it is the recommended method on machines that do not otherwise need Node.
Corporate proxies and self-signed certificates
Inside corporate networks, the install Claude Code step can fail with TLS certificate errors because a filtering proxy re-signs traffic. For the npm path, set NODE_EXTRA_CA_CERTS to your corporate root certificate. For the native installer script fetched over curl, the proxy has to be allowed, or you download the install script through an approved channel and run it locally. Never disable certificate verification in production; route the install through an approved proxy instead.
Windows execution policy blocked the PowerShell installer
The PowerShell installer (irm https://claude.ai/install.ps1 | iex) can be blocked by a restricted execution policy. Check with Get-ExecutionPolicy -List. If your user scope is Restricted, set it to RemoteSigned for your user only with Set-ExecutionPolicy -Scope CurrentUser RemoteSigned, then re-run the install Claude Code command. This is a user-scoped change and does not require an administrator shell.
Verifying Your Installation with claude doctor
After you install Claude Code, the single best verification step is claude doctor. It validates the install itself, the MCP servers in your configuration, and the settings files that govern behavior. Run it in any directory; it does not need a project to inspect. A clean claude doctor report means every downstream feature, from slash commands to IDE extensions, has a sound base to build on.
The report covers four areas in order. First, the binary itself: version, install method, update channel, and whether a newer version is available. Second, authentication: whether credentials are present, what type (OAuth, API key, Bedrock, Vertex, or Foundry), and whether the stored token is still valid. Third, MCP servers: each configured server is pinged and its tool list is checked, with a warning if a server fails to start or returns no tools. Fourth, settings: the user-level and project-level settings files are parsed and any malformed entries are flagged.
Common claude doctor warnings and what to do about them: an MCP server that fails to start usually points at a wrong command path or a missing runtime such as Python or Node for that server; a stale credential warning means it is time to run /login again; a settings parse error points at a syntax mistake in settings.json that would otherwise silently break feature flags. Treat claude doctor as the first step whenever something feels off after you install Claude Code, before you chase the symptom itself.
Authentication Security Deep Dive
When you install Claude Code, the authentication step decides how credentials are stored, rotated, and shared across a team, and the defaults are safe but worth understanding. OAuth is the default for individual accounts: running claude with no environment variables launches a browser flow that stores a refresh token in the OS keychain on macOS or in ~/.claude/.credentials.json with mode 0600 on Linux and Windows. Neither location is world-readable, and the token is refreshed automatically.
An API key is the alternative when a browser flow is impractical, such as on a headless server or inside CI. Set ANTHROPIC_API_KEY in the environment and the OAuth flow is skipped. The risk with an API key is leakage: it is a long-lived secret, so treat it like any other credential, load it from a secrets manager rather than hard-coding it, and rotate it on a schedule. For team setups, prefer SSO through claude auth login --sso over shared API keys, because SSO ties access to individual identities and is revocable per person.
For cloud-provider routing, the three flags CLAUDE_CODE_USE_BEDROCK=1, CLAUDE_CODE_USE_VERTEX=1, and CLAUDE_CODE_USE_FOUNDRY=1 shift traffic to Amazon Bedrock, Google Vertex AI, and Microsoft Foundry respectively. Authentication then follows the provider’s SDK chain (AWS signature, Google Application Default Credentials, Azure identity), which means credentials never touch ~/.claude at all. This is the most secure option for enterprises that already centralize cloud credentials, and it is worth setting up right after you install Claude Code if your organization mandates a specific provider.
To rotate or switch accounts, /logout clears the stored credential and the next claude run re-authenticates. For a full reset, removing ~/.claude/.credentials.json is enough on Linux and Windows; on macOS, delete the keychain entry through Keychain Access. None of these steps require you to reinstall Claude Code; the binary is independent of the credential store.
Updating, Reinstalling, and Uninstalling
Keeping the tool current matters because features and security fixes ship on a rolling cadence. With the native installer, updates land in the background and you rarely think about them. With every other install Claude Code method, you own the update step. For Homebrew, brew upgrade claude-code pulls the latest; for npm, npm update -g @anthropic-ai/claude-code; for WinGet, winget upgrade Anthropic.ClaudeCode; and for Linux packages, the distribution’s standard upgrade command.
The update channel is controlled through /config once the binary is running. The latest channel tracks the newest release, and stable trails it by roughly a week with extra soak time. Teams that value predictability over new features usually pin stable; individual users who want the newest slash commands and hooks usually pick latest. You can switch channels at any time without reinstalling.
Reinstalling is rarely necessary, but when a binary behaves oddly after an interrupted update, a clean reinstall fixes it. Uninstall first: brew uninstall claude-code, npm uninstall -g @anthropic-ai/claude-code, or the distribution’s remove command. Then remove the per-user data directory only if you want a totally fresh start, since ~/.claude holds CLAUDE.md files, settings, and conversation history you may want to keep. Finally, install Claude Code again through whichever method you prefer and run claude doctor to confirm the clean state.
Uninstalling completely, for example when you leave a machine, is the reverse: remove the binary through the package manager, clear ~/.claude if you do not want to leave conversation history behind, and revoke the OAuth grant or API key through the Anthropic Console or your cloud provider. A full uninstall leaves no credential behind, which is the correct end state for a shared or decommissioned machine.
Installing Claude Code in CI and Container Images
Installing Claude Code inside a CI runner or a container image follows the same steps as a local install, with two extra constraints: the environment is headless, and the install has to be reproducible across runs. The cleanest pattern in a Dockerfile is to install Claude Code from a pinned version of the npm package or the Linux distribution package, then set ANTHROPIC_API_KEY from a build-time secret rather than baking it into the image. Pinning the version is what makes the build reproducible; a floating latest tag in CI is a recipe for a build that passes one day and fails the next for no obvious reason.
For authentication in CI, use an API key loaded from the secret store the CI provider exposes (GitHub Actions secrets, GitLab CI variables, AWS Secrets Manager). The key’s scope should be the narrowest that still does the job, and it should be rotated on a schedule. Because CI runs are ephemeral, there is no need for the OAuth flow; the environment variable is the whole story. If you install Claude Code in CI and then run it with claude -p in print mode, a single invocation consumes tokens, emits a result, and exits, which fits the CI model exactly.
Caching the install layer across CI runs saves meaningful time. Because the binary changes infrequently, putting the install Claude Code step in a layer that is cached (Docker layer cache, or the CI provider’s dependency cache) means most runs skip the download. The cache key should include the pinned version so a version bump invalidates the cache exactly once. Avoid caching ~/.claude itself in CI, since it holds session state you do not want to persist across unrelated runs.
Headless calls usually want structured output. Pair claude -p with --output-format json so the CI step can parse the result and decide whether to pass or fail. A typical pipeline step runs a review or analysis command over the diff, parses the JSON, and fails the build if the result includes a blocking finding. This is the same pattern teams use for linters and test runners, and it slots into existing CI with no special handling beyond installing the binary and setting the key.
A Worked Example: First Install on a Fresh macOS Machine
Walking through a real install Claude Code session on a brand-new Mac illustrates how the pieces fit together. Start by opening Terminal.app. If you have never used the terminal before, run xcode-select --install once to install the command-line tools, which the native installer relies on for curl. This is a one-time setup step that takes a few minutes.
Next, run the native installer command: curl -fsSL https://claude.ai/install.sh | bash. The script downloads the binary for your architecture (Apple silicon or Intel), places it on your PATH, and starts the background update service. When it finishes, open a fresh terminal window so the new PATH takes effect, then run claude --version to confirm the binary resolves. If you see a version number, the install Claude Code step succeeded; if you see command not found, close the terminal entirely and open a new one, because the old shell session has a stale PATH.
Now run claude doctor. It should report a clean install, no MCP servers configured yet (which is expected on a fresh machine), and prompt you to authenticate. Run claude in any directory to trigger the OAuth flow: a browser window opens, you sign in with your Anthropic account, and the credential is stored in the macOS Keychain. From here, cd into a real project directory and run claude again to start your first session.
Inside that first session, run /init to generate a starter CLAUDE.md, then ask the assistant to summarize the project. This two-step routine, install Claude Code then initialize project memory, is the onboarding motion you will repeat on every new machine and every new project. The whole sequence, from opening Terminal to a working first session, takes about five minutes on a fresh Mac, and most of that is the command-line tools download.
If anything in this walkthrough fails, map the symptom back to the troubleshooting section above. A command not found is a PATH issue, an authentication error is a credential or network issue, and a doctor warning points at the specific subsystem to inspect. The install Claude Code workflow is designed so that each failure has a clear diagnostic path, which is why claude doctor is worth running before anything else when something feels wrong.
Managing Multiple Claude Code Versions
Most users run one version of Claude Code, but a few workflows benefit from keeping more than one around. A maintainer of a plugin may need to test against the stable channel and the latest channel in the same week; a team migrating from npm to the native installer may overlap both for a transition period; a CI matrix may pin several versions to verify backward compatibility. Whatever the reason, the install Claude Code toolchain supports side-by-side setups when you are deliberate about it.
The cleanest pattern is one install method per version. Put the stable channel on the native installer and the latest channel on npm, each resolving to a different binary location, then call each one by its full path or alias it in your shell. Mixing two versions through the same install method is fragile, because the second install overwrites the first, and you lose the version you wanted to keep. The install Claude Code step is designed for a single active binary per method, so plan around that constraint rather than fighting it.
For per-project version pinning, the most reliable approach is to record the version in the project’s CLAUDE.md and let a teammate install Claude Code at that version through whichever method the project standardizes on. The binary itself does not enforce a per-directory version, so the pinning is conventional rather than automatic. A pre-session check that runs claude --version and compares it to the version recorded in CLAUDE.md is a lightweight way to catch drift before it causes a confusing session.
Downgrading is the case that catches people out. If a new version introduces a behavior you cannot accept, the fix is to uninstall the current version and install Claude Code at the specific older version you want, which the npm method supports by version (npm install -g @anthropic-ai/claude-code@<version>). The native installer does not pin to an arbitrary older version easily, so teams that need deterministic downgrades usually keep npm as the install method for the version they control. Documenting the working version in CLAUDE.md means anyone on the team can reproduce the exact environment.
In practice, running multiple versions is rare and worth avoiding when you can. The update channels exist precisely so you do not have to manage versions by hand: stable gives you predictability, latest gives you new features, and switching between them through /config is a single command. Reserve the side-by-side install Claude Code setup for the cases that genuinely need it, and keep the common path simple.
Pro Tips
- Run
/initon every new project. It generates aCLAUDE.mdthat gives Claude persistent context about your codebase. This single step dramatically improves response quality across sessions. - Be specific in your prompts. Instead of “fix the bug”, say “the login form on /auth returns a 500 error when the email field is empty. Find and fix the cause”. Specificity narrows Claude’s search space and produces better results.
- Use
/clearbetween unrelated tasks. Claude Code’s context window is finite. Clearing the conversation prevents unrelated context from bleeding into your next task. - Review every file diff before accepting. Claude Code always shows you what it plans to change. Make this a habit. It catches misunderstandings early and keeps you in control.
- Keep Claude Code updated. After you install Claude Code, new features and fixes ship frequently. Run
npm update -g @anthropic-ai/claude-coderegularly if you used npm, or check the version with/status. The install Claude Code step is just the start; staying current is what keeps the workflow smooth.
Hands-On Challenge: Set Up Your First Claude Code Session
Task: Install Claude Code, initialise a project, and have Claude create a simple “Hello World” application from scratch.
Steps
- Install Claude Code globally via npm:
npm install -g @anthropic-ai/claude-code - Create a new directory for your project and
cdinto it - Launch Claude Code and run
/initto generate a starterCLAUDE.md - Ask Claude to “create a simple Node.js script that prints Hello World and includes a README”
- Review the files Claude generates and ask one follow-up question (e.g., “add a command-line argument for a custom greeting”)
Expected Outcome
You should have a working index.js (or equivalent) that runs without errors, a populated CLAUDE.md in the project root, and a README describing the project.
Hint: If Claude asks for permission to run commands, type
yto allow. You can always type/helpto see available commands at any time.
Knowledge Check: Getting Started with Claude Code
Test your understanding with these quiz questions. Try to answer each question before revealing the answer.
1. What are the two primary modes of the Claude CLI?
- Online and offline mode
- Interactive REPL (claude) and Print mode (claude -p)
- GUI and terminal mode
- Single and batch mode
Correct Answer: B. Interactive REPL is the default conversational mode. Print mode (-p) is non-interactive, scriptable, pipeable. It exits after one response.
2. How do you pipe a file into Claude and get JSON output?
- claude
--fileerror.log--json - cat error.log | claude -p
--output-formatjson “explain this” - claude < error.log
--formatjson - claude -p
--inputerror.log--json
Correct Answer: B. Pipe content via stdin to print mode (-p) and use
--output-formatjson for structured output.
3. What are the six permission modes in Claude Code?
- read, write, execute, admin, root, sudo
- default, acceptEdits, plan, auto, dontAsk, bypassPermissions
- safe, normal, elevated, admin, unrestricted, god
- view, edit, run, deploy, full, bypass
Correct Answer: B. The six modes are: default (prompts), acceptEdits (auto-accepts file edits), plan (read-only analysis), auto (background classifier decides), dontAsk (auto-denies unless pre-approved), bypassPermissions (skips all checks).
4. How do you activate planning mode?
- Only via /plan command
- Via /plan, Shift+Tab/Alt+M,
--permission-modeplan flag, or default config - Via
--planningflag only - Planning is always on
Correct Answer: B. Planning mode can be activated via /plan command, Shift+Tab/Alt+M keyboard shortcut,
--permission-modeplan CLI flag, or as a default in config.
5. What does the /init command do?
- Initializes a new Claude Code project from scratch
- Generates a template CLAUDE.md based on your project structure
- Resets all memory to defaults
- Creates a new session
Correct Answer: B. /init analyzes your project and generates a template CLAUDE.md with suggested rules and standards. It is a one-time bootstrapping tool.
Test Your Knowledge
Additional Resources
| Resource | Type | Link |
|---|---|---|
| Claude Code: Installation Guide | Official Docs | code.claude.com/docs/en/install |
| Claude Code: Quickstart | Official Docs | code.claude.com/docs/en/quickstart |
| Claude Code: Interactive Mode | Official Docs | code.claude.com/docs/en/interactive-mode |
| Claude Code: CLI Reference | Official Docs | code.claude.com/docs/en/cli-reference |
| Anthropic API Keys | Console | console.anthropic.com |
| Claude Code Changelog | GitHub | CHANGELOG.md |
How long does it take to get productive?
Most developers are productive within a single session. Claude Code Getting Started is deliberately gentle: install, open a project, ask a question, and approve a small change in planning mode.
Can I undo what the assistant changes?
Yes. Because it edits files in your real project, your version control is your safety net. Commit before large changes and review diffs like any pull request.
Does it work with my language or framework?
It works with whatever is in your project folder, since it reads your actual files rather than relying on a fixed list of supported stacks.
Claude Code Getting Started: Frequently Asked Questions
What does it actually do?
Claude Code is a command-line AI assistant that reads the files in your project directory and helps you write, review, and edit code with full awareness of your actual codebase, rather than working from pasted snippets alone.
How do I install it and start my first session?
Install the CLI, then open a terminal inside a real project folder before launching it. The assistant only sees the directory you run it from. Your first prompt can simply ask it to summarise the project to confirm it can read your files.
What is planning mode and when should I use it?
Planning mode has the assistant propose a plan before touching any files, so you can review and approve the approach first. Use it for anything non-trivial; it turns a black-box edit into a reviewable proposal while you build trust in the tool.
Why should I record build, test, and lint commands in project memory?
Once those commands are recorded, the assistant can run them itself after making a change, catching mistakes early and handing you a change that is already verified instead of one you have to debug from scratch.
Is it safe to let it make changes directly to my codebase?
Yes, if you commit before big changes and treat every edit as a reviewable diff. Avoid jumping straight to permissive modes before you understand how it behaves on your specific codebase.
Claude Code Getting Started gives you a solid, repeatable workflow. Bookmark this Claude Code Getting Started guide and revisit the steps whenever you need them.

Your First Session: A Quick Walkthrough
Once the CLI is installed, open a terminal inside a real project folder and launch it. The assistant reads the files in that directory, so it can answer questions about your actual code from the very first prompt instead of working in the abstract.
Start by asking it to summarise the project. A request like “explain what this repository does and how the main pieces fit together” gives you a fast orientation and confirms the assistant can see your files. This is also a safe, read-only way to check that permissions are set the way you expect.
For your first real change, switch to planning mode. Describe the outcome you want, review the plan the assistant proposes, and approve it before any file is touched. Planning mode turns a black-box edit into a reviewable proposal, which is exactly what you want while you are still building trust in the tool.
After the change lands, ask the assistant to run your test and lint commands. If you recorded those commands in your project memory, it will know how to verify its own work, catch mistakes early, and hand you a change that is ready to review rather than one you have to debug from scratch.
Claude Code Getting Started: Common Mistakes to Avoid
Even developers who read the docs carefully make a handful of predictable mistakes the first week they use Claude Code. Watching for these early saves real frustration later.
- Running
claudeoutside a real project directory, then wondering why it has no context. Claude Code reads whatever folder you launched it in, socdinto your project first. - Skipping
/initon a new project and re-explaining the same tech stack and conventions every session instead of lettingCLAUDE.mdpersist that context. - Jumping straight to
bypassPermissionsmode to avoid approval prompts, which removes the safety net before you have learned how Claude behaves on your codebase. - Letting one session sprawl across unrelated tasks instead of running
/clearbetween them, which lets stale context from an earlier task bleed into unrelated work.
Claude Code Getting Started: Best Practices
- Install the CLI globally and run it inside a real project folder so it can read your code and configuration.
- Start in planning mode for non-trivial tasks so you can review the approach before any files change.
- Use the most permissive mode you are comfortable with to cut prompts, but keep destructive actions gated.
- Create a CLAUDE.md early so the assistant remembers project conventions across sessions.
- Keep each session focused on one task; start a fresh session when you switch context.
