Little Might
The Claude Code Cheat Sheet

The Claude Code Cheat Sheet

An up-to-date Claude Code cheat sheet covering install, login, permission modes, sandboxing, models, CLAUDE.md, skills, hooks, plugins, MCP, and the…

Mar 25, 2026

6 min read

Updated Apr 13, 2026

Claude Code now spans the terminal, VS Code, JetBrains, desktop, browser, Slack, and cloud sessions. That makes old one-surface cheat sheets feel wrong fast.

This is the version I actually want handy now: install, login, permission modes, sandboxing, model picks, commands, and the workflow patterns that still hold up on April 13, 2026.


Start Here

Start here

Most sessions

sonnet

The default day-to-day pick. Claude Code currently maps the alias to Sonnet 4.6.

Hard problems

opus

Use for architecture, deep debugging, migrations, and tasks that are expensive to get wrong. Claude Code currently maps the alias to Opus 4.6.

Two current facts worth locking in:

  • Claude Code is no longer just a terminal + API key tool. Official docs now support Claude subscriptions, Anthropic Console logins, and Bedrock, Vertex, or Foundry auth.
  • Permission modes are now a first-class concept. Think in terms of default, acceptEdits, plan, auto, dontAsk, and bypassPermissions, not the older “just skip permissions” mental model.

Install and Launch

The official install path now starts with the native installer, not npm install -g.

# macOS, Linux, WSL
curl -fsSL https://claude.ai/install.sh | bash

# Homebrew stable channel
brew install --cask claude-code

# Homebrew latest channel
brew install --cask claude-code@latest

# Windows PowerShell
irm https://claude.ai/install.ps1 | iex

# Start a session in your project
cd your-project
claude

On first launch Claude opens a browser login flow. The official docs say you can authenticate with:

Claude Pro / MaxClaude for Teams / EnterpriseAnthropic ConsoleBedrockVertexFoundry

If you still use ANTHROPIC_API_KEY, that still works in the terminal CLI. Important nuance: if the key is set, it can take precedence over your subscription login once approved.


CLI Basics

# Start an interactive session
claude

# Start interactive with an opening task
claude "Audit this repo for dead code and suggest deletions"

# Print a one-shot answer and exit
claude -p "Explain the auth flow in this project"

# Start in plan mode
claude --permission-mode plan "Design the migration before touching code"

# Unlock auto mode in the Shift+Tab cycle
claude --enable-auto-mode

# Start a remote web session
claude --remote "Fix the login bug"

# Pull a web session back into your terminal
claude --teleport

# Resume a prior session
claude --resume

Important distinction: claude "task" opens a normal interactive session. claude -p "task" is the better fit for scripts, piping, CI, and one-shot runs.


Supported Models

Claude Code lets you choose aliases or pin full model names. The aliases are the easiest way to stay current; pin exact names only when reproducibility matters more than freshness.

ModelWhat it points to nowBest for
sonnetLatest Sonnet model, currently Sonnet 4.6Daily coding tasks, normal implementation loops
opusLatest Opus model, currently Opus 4.6Deep analysis, architecture, migrations, hard bugs
haikuLatest Haiku modelLightweight tasks and simpler asks
opusplanUses opus in plan mode, then sonnet for executionBig tasks where planning quality matters more than execution cost
sonnet[1m]Sonnet with 1M-token contextLong sessions or giant repos
opus[1m]Opus with 1M-token contextExpensive but useful when context is the bottleneck

Model aliases always move forward. If you need stability, pin the full model name instead of relying on sonnet or opus.

# Explicit alias
claude --model opus "Review this migration plan for failure modes"

# Switch during a session
/model sonnet

Effort Levels

Claude Code supports effort controls directly in-session.

Low

Keep it moving

Scoped cleanup, quick edits, and low-risk work.

Medium

Normal default

Good balance for most real coding sessions.

High

Real thinking work

Architecture, deep debugging, and thorny changes.

Max

Only when it matters

Current-session only, and the docs say it requires Opus 4.6.

/effort high
/effort auto

Permission Modes

This is the biggest conceptual shift in Claude Code right now.

The docs define six permission modes:

defaultacceptEditsplanautodontAskbypassPermissions

Default

Normal guardrails

Claude asks when it needs elevated actions. Good starting point for most people.

Accept edits

Auto-approve file edits

Claude can edit files without asking, but terminal commands still prompt.

Plan

Think first

Read, inspect, and produce a plan without editing files or running commands.

Auto

Autonomous with checks

Runs actions with background safety checks. You have to opt in with —enable-auto-mode.

# Start in plan mode
claude --permission-mode plan

# Start in bypass mode
claude --permission-mode bypassPermissions

# Shortcut form
claude --dangerously-skip-permissions

During a session, Shift + Tab cycles permission modes. The docs say the default cycle is default -> acceptEdits -> plan, with optional auto and bypassPermissions added only if you explicitly enable them.


Sandboxing

Permission modes and sandboxing are separate.

  • Permission mode decides when Claude asks.
  • Sandbox mode decides what shell commands are allowed to do.

Current Claude Code docs expose sandboxing in supported environments and a /sandbox command to toggle it. If you need Bash commands constrained, use sandboxing plus permission rules instead of relying on prompts alone.

/sandbox
/permissions

The useful mental model: permissions are about approval policy, sandboxing is about blast radius.


Commands Worth Memorizing

Session

Core flow

  • /clear
  • /compact [focus]
  • /resume [session]
  • /rename [name]
  • /rewind
  • /diff

Context

Files and memory

  • /init
  • /memory
  • /add-dir <path>
  • /context
  • /copy [N]
  • /export [file]

Workflow

What I’d actually use

  • /plan [task]
  • /loop [interval] [prompt]
  • /schedule [task]
  • /tasks
  • /autofix-pr
  • /ultraplan <prompt>

Config

Modes and tools

  • /model
  • /effort
  • /permissions
  • /sandbox
  • /plugin
  • /mcp

The Flags That Matter

--model <alias|name>                Pick a model or pinned version
--permission-mode <mode>            default | acceptEdits | plan | auto | dontAsk | bypassPermissions
--enable-auto-mode                  Add auto mode to the Shift+Tab cycle
-p, --print                         One-shot output without interactive mode
--output-format <format>            text | json | stream-json
--resume                            Resume a session
--remote                            Start a web session on claude.ai/code
--remote-control                    Let the same session be controlled from claude.ai
--teleport                          Pull a web session back into your terminal
--plugin-dir <path>                 Load plugins from a directory for this session
--settings <json-or-path>           Load extra settings
--dangerously-skip-permissions      Start in bypassPermissions mode

The two launch-time flags I’d keep on the tip of my tongue are --permission-mode and --model.


CLAUDE.md, Skills, Plugins, Hooks, MCP

CLAUDE.md

Project memory

Loaded automatically. Use it for repo conventions, build commands, architecture rules, and review checklists.

Skills

Reusable workflows

Claude Code now treats bundled and custom command-style workflows as skills. Good for repeatable jobs.

Plugins

Real extensions

Managed through /plugin. This is where code review, feature-dev, and other installable extensions now live.

Hooks + MCP

Automation + tools

Hooks run shell commands around Claude events. MCP connects external systems like GitHub, Jira, Drive, or your own tooling.

Minimal CLAUDE.md I’d Actually Start With

# Project

## Stack
- Astro 5
- TypeScript
- Tailwind 4

## Commands
- Dev: `pnpm dev`
- Build: `pnpm build`
- Test: `pnpm test`

## Rules
- Propose a plan before touching more than 3 files
- Run targeted tests after edits
- Never edit `.env` or deployment config without asking

MCP Today

Tool search is now enabled by default in Claude Code. That matters because MCP servers no longer have to dump every tool into context up front when the model supports deferred tool references.

/mcp

If you run through a non-first-party proxy, the docs say tool search may be disabled unless you set ENABLE_TOOL_SEARCH explicitly.


Prompt Patterns That Still Work

Don’t say “fix this”

Weak

Fix the billing bug.

Better

Find the root cause of the duplicate Stripe invoice issue, fix it, run the targeted tests, and summarize what changed.

Set the blast radius

Prompt pattern

Only edit files under src/billing/. Do not change copy, schema, or deploy config.

Use plan mode on purpose

Prompt pattern

Start in plan mode. Inspect the current auth flow, propose the fix, the files touched, the risks, and the verification steps before you edit anything.

Tell Claude how to finish

Prompt pattern

When you’re done, show the diff summary, list the commands you ran, and call out anything you could not verify.


Quick Reference

claude                               Start an interactive session
claude -p "task"                     One-shot print mode
claude --resume                      Resume a past session
claude --remote "task"               Start a web session
claude --teleport                    Pull web work back local
claude --permission-mode plan        Inspect and plan only
claude --enable-auto-mode            Add auto mode to the cycle

/plan                                Switch to plan mode
/permissions                         Manage allow/ask/deny rules
/sandbox                             Toggle sandboxing
/model                               Change model
/effort                              Change effort
/plugin                              Manage plugins
/mcp                                 Manage MCP connections
/memory                              Edit CLAUDE.md and auto memory
/diff                                Review changes
/tasks                               View background tasks
/schedule                            Cloud-scheduled tasks

Three Rules I’d Keep

  1. Start with CLAUDE.md, not vibes.
  2. Use plan or acceptEdits deliberately instead of jumping straight to bypass mode.
  3. Review the diff every time, even when the agent feels “obviously right.”
Cathryn Lavery

Written by

Cathryn Lavery

Cathryn went from designing buildings to architecting products. She founded BestSelf, bought it back from private equity in 2024, and rebuilt it AI-native. She's currently building something new in AI. Little Might is where she doesn't have to keep it all in her head.

Related reading