Claude Code Cheat Sheet

Everything you need in one place — Commands, Shortcuts, Features & Tips. Opus 4.7, Auto Mode, Computer Use in the CLI.
v2.1.101 — April 2026
Keyboard Shortcuts

Essentials

EnterSend message / confirm EscCancel current input Esc EscRewind / summary menu Ctrl+CCancel input or generation Ctrl+DExit Claude Code Shift+TabCycle permission modes Ctrl+BSend task to background

Navigation & Display

Ctrl+RSearch history Ctrl+LClear screen (keeps conversation) Ctrl+OFullscreen transcript — cycles views NEW Ctrl+TShow/hide task list Ctrl+SStash current prompt ↑/↓Navigate command history ←/→Cycle tabs / footer

Editing & Model

\ + EnterMulti-line input Ctrl+GOpen in external editor Ctrl+VPaste image (screenshots, diagrams) Ctrl+KDelete to end of line Ctrl+UDelete from cursor to beginning Ctrl+YPaste deleted text Ctrl+_Undo last action Alt+B / Alt+FMove back / forward one word Option+PModel selector Option+TToggle thinking (adaptive on Opus 4.7) Alt+OToggle fast mode ?Show all shortcuts Space (hold)Push-to-talk (if /voice enabled) Alt+YCycle paste history (after Ctrl+Y) Ctrl+JNewline (control sequence) Option+EnterNewline (macOS) Ctrl+X Ctrl+KKill all background agents (×2 to confirm) Ctrl+X Ctrl+EOpen in external editor (alias Ctrl+G)

Vim mode NEW

vVisual mode — character selection VVisual-line mode — line selection EscBack to normal mode (improved)

Quick Prefixes

/Slash command or skill !Bash mode — run a shell command @Autocomplete file/folder/agent

Confirmation Dialogs

Y / EnterConfirm N / EscDeny Ctrl+EToggle permission explanation Ctrl+DToggle permission debug info
Tip: /terminal-setup for Shift+Enter. /keybindings to customize. Contexts: Global, Chat, Confirmation, Transcript, etc. (17 contexts). Flicker-free rendering (alt-screen) is the default since v2.1.89. Set CLAUDE_CODE_NO_FLICKER=0 to revert.
Slash Commands

Session & Context

/clearReset the conversation (alias: /reset, /new)
/compact [focus]Compact with optional focus
/resume [session]Resume by ID or name (alias: /continue)
/rewindGo back to a checkpoint (alias: /checkpoint)
/rename [name]Rename the session
/branch [name]Branch the conversation (alias: /fork)
/export [file]Export conversation as text
/copy [N]Copy response N to clipboard
/costCosts + tokens + per-model & cache-hit breakdown (subscribers) NEW
/contextColor-coded context consumption grid
/tasksList and manage background tasks

Model & Configuration

/model [name]Switch model (sonnet, opus, haiku) — Opus 4.7 available NEW
/effort [level]Interactive slider — low/medium/high/xhigh/max/auto NEW
/fast [on|off]Toggle fast output mode (Opus 4.6, 1M context)
/focusCondensed view: last prompt + tool summary + response NEW
/tuiFlicker-free fullscreen rendering (alt-screen) NEW
/configConfig panel (includes Editor mode, replaces /vim) (alias: /settings)
/permissionsManage perms + Recent tab (retry with r) NEW (alias: /allowed-tools)
/mcpManage MCP servers & OAuth
/hooksView configured hooks
/themeChange theme + custom JSON editor (~/.claude/themes/)
/color [color]Prompt bar color
/sandboxToggle sandbox mode
/vimRemoved in v2.1.92/config → Editor mode REMOVED
/tagRemoved in v2.1.92 → AI-generated session titles REMOVED

Project & Analysis

/initCreate CLAUDE.md for the project
/memoryEdit CLAUDE.md & memory, toggle auto-memory
/add-dir <path>Add a working directory
/diffInteractive diff of changes
/reviewCode review (deprecated → code-review plugin)
/security-reviewScan for vulnerabilities
/insightsHTML usage analysis report
/statsVisualize daily usage, streaks, preferences
/ultraplanCloud drafting, browser review, local/remote exec NEW
/pr-comments [PR]GitHub PR comments
/autofix-prFix a PR from the terminal or web NEW
/plan [desc]Enter plan mode with optional description
/simplifyAnalyze code for reuse, quality, efficiency
/batch [task]Parallel changes in worktrees
/debug [desc]Session troubleshooting

Extensions & Plugins

/pluginManage plugins (auto-resolve deps) NEW
/reload-pluginsReload skills/agents/MCP without restart
/agentsTabs: Running (● N) + Library NEW
/skillsList sorted by token cost NEW
/chromeConfigure Claude in Chrome
/ideManage IDE integrations

Advanced & Remote

/loop [interval]Repeat — omit interval for self-pacing NEW
/scheduleCloud-scheduled tasks
/btwQuick question without tools or history
/voicePush-to-talk voice dictation
/teleportResume a web session locally
/desktopTransfer to Desktop app
/remote-controlMake session accessible from claude.ai
/remote-envConfigure default remote environment

System & Account

/helpHelp and command reference
/doctorCheck installation and auth
/statusVersion and account info
/usagePlan limits and rate limits
/extra-usageConfigure extra usage
/feedbackSubmit a report (alias: /bug)
/release-notesInteractive version picker NEW
/powerupAnimated lessons to learn Claude Code NEW
/team-onboardingGenerate a ramp-up guide for a teammate NEW
/login / /logoutLogin / Logout
/upgradeUpgrade to higher plan
/privacy-settingsPrivacy settings
/keybindingsOpen keybindings file
/terminal-setupConfigure terminal keybindings
/statuslineConfigure status line + refreshInterval NEW
/install-github-appInstall the GitHub Actions app
/install-slack-appInstall the Slack app via OAuth
/exitExit (alias: /quit)
/mobileQR code for mobile app (alias: /ios, /android)
/passesShare a free week of Claude Code
/stickersOrder Claude Code stickers
🚀 CLI Launch Flags

Session Startup

claudeInteractive session
claude "query"Start with an initial prompt
claude -p "query"Print mode — output and exit
claude -cResume last conversation
claude -r "id"Resume by name or ID
claude -n "name"Name the session
claude -w branchIsolated git worktree

Model & Reasoning

--model sonnetChoose the model (sonnet/opus/haiku)
--model opus[1m]Opus + 1M context (native on Opus 4.7)
--model claude-opus-4-7Opus 4.7 — adaptive thinking NEW
--effort xhighEffort level xhigh (100K tokens) NEW
--effort {low..max,auto}low / medium / high / xhigh / max / auto
--fallback-modelFallback model if overloaded

Context & Directories

--add-dir ../pathAdditional directories
--bareSkip hooks, plugins, MCP, CLAUDE.md
--verboseDetail for each turn
--debug "api,hooks"Debug by categories
--chrome / --no-chromeEnable/disable Chrome
--ideAuto-connect IDE at startup

Permissions

--permission-mode planRead-only mode
--permission-mode autoAI classifies permissions
--allowedToolsAuto-approved tools
--disallowedToolsTools removed from context
--toolsRestrict built-in tools
--enable-auto-modeUnlock Auto in Shift+Tab
--permission-prompt-toolMCP tool for permissions (headless)
--dangerously-skip-permissionsEquivalent of bypassPermissions

Output & Formats

--output-format jsonStructured JSON output
--output-format stream-jsonReal-time streaming JSON
--input-formatInput format (text, stream-json)
--include-partial-messagesInclude partial streaming events
--json-schema '{}'Force an output schema
--max-turns 5Limit agentic turns
--max-budget-usd 2Spending limit

System Prompt

--system-prompt "text"Override the system prompt
--system-prompt-fileLoad from a file
--append-system-promptAppend text to the prompt
--append-system-prompt-fileAppend from a file

Advanced & Remote

--remote "task"Remote session on claude.ai
--remote-controlEnable remote control
--tmuxWorktree + tmux pane
--teammate-modeAgent teams: auto/in-process/tmux
--agent nameRun as agent
--agentsDefine agents via JSON
--from-pr 42PR resume: GitHub, GitLab, Bitbucket, GH Enterprise NEW
--fork-sessionFork while keeping context
--teleportResume a web session
--mcp-configLoad MCP servers
--strict-mcp-configUse ONLY these MCP servers
--plugin-dirLoad plugins from a directory
--settingsCustom JSON settings file
--init / --init-onlyRun init hooks (and exit)
--maintenanceRun maintenance hooks and exit
--disable-slash-commandsDisable skills and commands
--no-session-persistenceDisable persistence (print)
--session-idSpecific session UUID
--agentsDefine dynamic agents via JSON
--channelsMCP notifications to listen to (research preview)
--setting-sourcesSetting sources to load (user, project, local)
--betasBeta headers for API requests

CLI Subcommands

claude updateUpdate
claude auth loginLogin (--email, --sso, --console, --third-party) NEW
claude auth statusAuth status (JSON or --text)
claude auth logoutSign out the account
claude agents [list|run]List and run agents
claude mcp add/list/removeManage MCP servers
claude mcp add-from-claude-desktopImport from Desktop app
claude mcp add-jsonAdd from a JSON blob
claude mcp serveExpose Claude Code as an MCP server
claude plugin [install|list|marketplace]Manage plugins & marketplaces
claude auto-mode defaultsDefault auto-mode rules
claude auto-mode configEffective config with settings
claude bedrock setupInteractive Bedrock wizard NEW
claude vertex setupInteractive Vertex AI wizard NEW
🔌 The Big 5 — Claude Code Extension System

1. CLAUDE.md — System Prompt

ManagedEnterprise policy, highest priority
Project./CLAUDE.md or ./.claude/CLAUDE.md
User~/.claude/CLAUDE.md

Imports: @docs/standards.md (max 5 levels)

Size: Keep < 200 lines, @path to split

2. Rules — Scoped Rules

Files in .claude/rules/*.md, activated by glob:

paths: ["src/**/*.tsx"] MUST use TanStack Query. SHOULD prefer named exports.

Placement based on consumer. MUST/SHOULD/MAY

3. Custom Commands — Shortcuts

Create in .claude/commands/name.md/name

$ARGUMENTS, $0, $1 for arguments

Live context: !`git diff` (executed before prompt)

4. Skills — Complex Workflows

Directory .claude/skills/name/SKILL.md

descriptionAuto-discovery trigger (1536 chars) NEW
context: forkIsolated sub-agent (no context pollution)
paths: "*.ts"Activate by file type
effort: highForce extended thinking
user-invocabletrue = /command, false = Claude only
allowed-toolsRestrict tools used by the skill
modelPer-skill model override

Progressive disclosure: SKILL.md < 500 lines, [ref](references/). /skills sorts by token cost NEW.

Builtin: code-review, security-review, simplify, init, deslopify, loop, claude-api, session-start-hook.

5. Sub-agents — Parallel Specialists

Create in .claude/agents/name.md

modelModel (inherited by default)
toolsRestrict tools
isolation: worktreeSeparate git worktree
memory: projectPersistent memory (user/project/local)
permissionModeDedicated permission mode
descriptionCriteria for Claude to invoke
effortSub-agent effort level

Invoke: @"name (agent)" | --agent name | SendMessage to: <id>

Builtin: Explore (Haiku), Plan, general-purpose, claude-code-guide, statusline-setup, code-reviewer.

6. MCP + Plugins

MCP: Integrations via .mcp.json. Tools: mcp__server__tool. OAuth RFC 9728 (Protected Resource Metadata) NEW.

# Add / List / Remove claude mcp add playwright -- npx @playwright/mcp claude mcp list claude mcp remove playwright # Import from Claude Desktop / JSON claude mcp add-from-claude-desktop claude mcp add-json '{"cmd":"..."}' # MCP server exposed by Claude Code claude mcp serve # Debug claude --mcp-debug

Transports: stdio | http | sse | ws

Size override: anthropic/maxResultSizeChars up to 500K/tool NEW

Plugins: Skills + agents + hooks + MCP + bin/ on PATH NEW. Auto-resolution of dependencies.

/plugin install name@marketplace

🖥 Computer Use — now in the CLI NEW

Claude sees and controls your desktop: screenshots, clicks, typing, scrolling, drag & drop. Since v2.1.86, available in the CLI (not just Desktop). macOS and Windows Desktop — Linux not supported. Multi-monitor. Pro/Max only. Enabled in Settings > General > Computer Use.

Security: request_access required. Allowlist per app. Screenshots filtered by compositing — only authorized apps are visible. systemKeyCombos separate grant.

Use: open a native app, click the UI, test changes, verify on iOS/macOS/GUI-only apps.

27 tools: screenshot, left_click, type, key, scroll, zoom, computer_batch (sequence in 1 call), open_application, mouse_move, double_click, right_click, left_click_drag, read/write_clipboard, wait, switch_display, etc.

👁 Monitor tool NEW

Built-in tool (v2.1.98) to spawn background watchers — tail logs, watch CI, auto-fix crashes. Each stdout line = notification in the conversation. Replaces Bash sleep loops. Pairs with /loop self-pacing.

Where to put what? Commands = you invoke  |  Skills = Claude invokes  |  Agents = separate context  |  MCP = external integrations  |  Computer Use = desktop control  |  Monitor = background watchers
🛡 Permission Modes
ModeBehavior
DefaultAsks permission for every tool
acceptEditsAuto-approves edits, asks for Bash
PlanRead-only. Explores & understands. Writes nothing.
AutoAI classifies (fast + thinking path). Max + Opus 4.7 NEW
dontAskSkip prompts, ignore non-approved tools
bypassSkip all checks (containers only)
Normal Auto-Accept Plan Auto

Shift+Tab to cycle. --enable-auto-mode to unlock Auto. See Row 5 for classifier details.


Pro workflow: Plan Mode to explore → Normal to implement → Auto for long runs → Rewind if needed.


Pre-approve Tools

// .claude/settings.json "allow": ["Read", "Bash(git *)", "Bash(npm run *)"] "ask": ["Bash(npm publish *)"] "deny": ["Bash(rm -rf *)"]

Order: denyaskallow (first match wins)

Syntax: Bash(npm run *), Read(/src/**), WebFetch(domain:x.com), mcp__server__*, Edit(*.ts)

April hardening: Bash escape of flags, /dev/tcp, env-var prefixes; PowerShell auto-approval matches Bash; sandbox.failIfUnavailable.

🔗 Hooks — Automation

Events (26)

EventWhen
SessionStartSession start / resume
SessionEndSession end
UserPromptSubmitBefore Claude processes the message
PostUserPromptSubmitAfter submit — can override sessionTitle NEW
PreToolUseBefore a tool — can block (exit 2)
PostToolUseAfter a successful tool — receives duration_ms NEW
PostToolUseFailureAfter a failed tool
PermissionRequestPermission dialog appears
PermissionDeniedAfter auto-mode denial (retry: true) NEW
StopClaude finishes its response
StopFailureTurn ended by API error
SubagentStartA sub-agent starts
SubagentStopA sub-agent finishes
TeammateIdleA teammate is about to become idle
TaskCreatedTask created via TaskCreate
TaskCompletedTask completed
PreCompactBefore compaction — exit 2 to block
PostCompactAfter compaction
NotificationClaude sends a notification
InstructionsLoadedCLAUDE.md or rules loaded
ConfigChangeA config file changes
FileChangedA watched file changes
CwdChangedWorking directory changes (reload env)
WorktreeCreateWorktree created
WorktreeRemoveWorktree removed
ElicitationMCP server requests input
ElicitationResultResponse to an MCP elicitation

5 Handler Types

commandShell command
httpPOST to an endpoint
promptLLM single-turn (Haiku)
agentMulti-turn sub-agent
mcp_toolDirect MCP tool call NEW
// Conditional auto-format + duration_ms logging "PostToolUse": [{ "matcher": "Write|Edit", "if": "Edit(*.ts)", "hooks": [{ "type": "command", "command": "npx prettier --write $CLAUDE_FILE_PATHS" }] }]

Codes: 0 = success, 2 = block (stderr → Claude), other = error

if field: Filter by tool name AND arguments. E.g.: Bash(git *), Edit(*.ts), mcp__server__tool

Env vars: $CLAUDE_PROJECT_DIR, $CLAUDE_FILE_PATHS, $CLAUDE_TOOL_INPUT, $CLAUDE_SESSION_ID

hookSpecificOutput: {"sessionTitle": "..."} to name the session from a hook NEW

Input Superpowers
SyntaxAction
@fileReference files & folders in context
@"agent"Mention a specific sub-agent
!commandRun a shell. E.g.: ! git status
Ctrl+VPaste screenshots, diagrams, images

Pipe Input

# Analyze logs cat error.log | claude -p "find root cause" # PR review gh pr diff 42 | claude -p "security review" # Commit message git diff --staged | claude -p "conventional commit msg" # Translate cat README.md | claude -p "translate to Spanish"

Multi-directories & Worktrees

# Add directories claude --add-dir ../lib --add-dir ../shared # Isolated worktree claude -w feature # isolated git branch # Worktree + tmux claude -w feature --tmux

Background & Remote

Ctrl+B to send to background. Claude continues while you work.

--remote "task" to launch an agent on claude.ai.

/remote-control to make the session remotely accessible.

Built-in Agent Tools

What Claude can call (used in allowedTools, if, hooks):

FilesystemRead, Write, Edit, NotebookEdit, Glob, Grep
ShellBash, BashOutput, KillBash (+ PowerShell opt-in)
WebWebSearch, WebFetch
Agents & SkillsAgent (Task), Skill, ToolSearch, Monitor NEW
Session / MetaTodoWrite, AskUserQuestion, ExitPlanMode, PushNotification
MCPmcp__<server>__<tool> (auto-prefixed)

Restrict: --tools Read,Edit,Bash(git *) · Disallow: --disallowedTools Bash

Configuration

Hierarchy (decreasing priority)

Enterprise/etc/claude-code/managed-settings.json
CLI ArgsFlags passed at launch
Local.claude/settings.local.json (gitignored)
Project.claude/settings.json (committed)
User~/.claude/settings.json (global)

Config Commands

config listShow all settings config get keyView a value config set key valSet a value config add key valAdd to an array config remove key valRemove from an array

Environment Variables

ANTHROPIC_API_KEYAPI key (overrides subscription)
ANTHROPIC_MODELDefault model
ANTHROPIC_SMALL_FAST_MODELModel for lightweight tasks
CLAUDE_CODE_EFFORT_LEVELEffort level (low…xhigh/max/auto)
CLAUDE_CODE_USE_BEDROCKAmazon Bedrock
CLAUDE_CODE_USE_VERTEXGoogle Vertex AI
CLAUDE_CODE_USE_MANTLEBedrock via Mantle NEW
CLAUDE_CODE_DISABLE_1M_CONTEXTDisable 1M context
CLAUDE_CODE_DISABLE_AUTO_MEMORYDisable auto memory
CLAUDE_CODE_NO_FLICKER1 = alt-screen (default v2.1.89), 0 = classic NEW
CLAUDE_CODE_HIDE_CWDHide cwd in startup logo NEW
CLAUDE_CODE_CERT_STOREbundled to opt out of OS store NEW
CLAUDE_CODE_SUBPROCESS_ENV_SCRUBLinux PID namespace isolation NEW
CLAUDE_CODE_SCRIPT_CAPSPer-session script invocation limits NEW
CLAUDE_CODE_PERFORCE_MODEEdit/Write fail read-only (p4 edit hint) NEW
CLAUDE_CODE_USE_POWERSHELL_TOOLEnable/disable PowerShell tool
ENABLE_PROMPT_CACHING_1H1-hour prompt cache TTL NEW
FORCE_PROMPT_CACHING_5M5-min prompt cache TTL (test) NEW
ENABLE_TOOL_SEARCHEnable ToolSearch on Vertex AI NEW
OTEL_LOG_TOOL_DETAILSEmit full tool details in OpenTelemetry NEW
DISABLE_TELEMETRYOpt-out telemetry
DISABLE_AUTOUPDATERDisable auto updates
DISABLE_UPDATESBlock all update paths NEW
CLAUDE_PROJECT_DIRProject root (injected in hooks)

Settings.json — Key Fields

modelDefault model
effortDefault effort level
permissions.{allow,ask,deny}Permission rules
hooksLifecycle hooks
allowedMcpServersWhitelist MCP servers
deniedMcpServersBlacklist MCP servers
prUrlTemplateCustom code-review URL template NEW
sandbox.failIfUnavailableEnforce sandbox availability NEW
disableSkillShellExecutionBlock shell from skills/commands/plugins NEW
showThinkingSummariesThinking summaries (off in interactive v2.1.86) NEW
statusLine.refreshIntervalRe-run status line every N sec NEW
themeTheme name or custom JSON

Advanced Permissions

// .claude/settings.json { "permissions": { "allow": ["Read", "Bash(git *)"], "ask": ["Bash(npm publish *)"], "deny": ["Bash(rm -rf *)"] }, "allowedMcpServers": ["playwright"], "deniedMcpServers": ["untrusted"] }
📁 File Structure Map

Project Level (.claude/)

CLAUDE.md — Project memory, conventions settings.json — Shared settings (git) settings.local.json — Personal settings (gitignored) commands/ — Project slash commands skills/ — Skills (SKILL.md + references/) agents/ — Project sub-agents rules/ — File-scoped rules .mcp.json — Project MCP config (committable)

Global Level (~/.claude/)

CLAUDE.md — Applies to ALL projects settings.json — Global settings (persisted by /config) commands/ — Personal commands skills/ — Personal skills agents/ — Personal agents rules/ — Global rules themes/ — Custom JSON themes NEW plans/ — Plan files (/plan & /ultraplan) keybindings.json — Custom keybindings ~/.claude.json — User MCP config

Hierarchy (5 levels)

Policy > Organization > User global > User local > Project

Rewind & Checkpoints
Esc EscOpen rewind menu anytime /rewindSame function via command

Rewind Options

OptionEffect
ConversationGo back in chat. Code stays.
CodeRestore files. Conversation stays.
Full RewindRestore conversation AND code.
Limits: Side effects (Bash, deleted files, installed packages) CANNOT be undone. Checkpoints only track file edits by Claude. Use Git.

Context Management

Startup budget ~6K tokens: system prompt, memory, env, MCP, CLAUDE.md, rules, skill descriptions.

Compaction: Auto at ~95% capacity. /compact [focus] triggers manually with a focus area. CLAUDE.md re-read from disk.

"Document & Clear" workflow: Save progress → /clear → Start fresh. Claude reads the summary.

Save tokens: Scoped rules, sub-agents for verbose tasks, --bare, context: fork on skills, opus[1m] (native on Opus 4.7).

Prompt caching: ENABLE_PROMPT_CACHING_1H (1h TTL) — /context shows cache hits (fixed % on Opus 4.7 in April). NEW

/resume: ~67% faster on large sessions (40MB+) since April. NEW

Write tool: +60% speedup in April 2026. MCP startup noticeably quicker. NEW

🤖 Auto Mode NEW

Permission classifier: the AI decides if each tool is safe or risky — no more dialogs for every Bash call.

Availability

Research previewv2.1.83 (Week 13, March 23 2026)
GA on Maxv2.1.92+ (Week 15) with Opus 4.7
Team / EnterpriseSonnet 4.6, Opus 4.6, Opus 4.7

Activation

--enable-auto-modeUnlock at launch Shift+TabCycle to the "Auto" pill /configPersist the setting

Classifier — 2 paths

Fast path: Haiku scans "safe / risky / uncertain". Thinking path: Opus/Sonnet takes over the uncertain cases to cut false positives.

Hook PermissionDenied

"PermissionDenied": [{ "hooks": [{ "type": "command", "command": "./scripts/request-allow.sh" }] }] // stdout {"retry": true} => retry the tool
Default rules: claude auto-mode defaults. Effective config: claude auto-mode config.
No conflict: Plan Mode stays prioritized when both are active (April fix).
🧠 Models & Effort Levels

Available Models

ModelIDNotes
Opus 4.7claude-opus-4-71M context, 64K-128K output, adaptive thinking NEW
Opus 4.6claude-opus-4-6Fast mode with 1M context (April)
Sonnet 4.6claude-sonnet-4-6Fast & balanced, default
Haiku 4.5claude-haiku-4-5-20251001Ultra-fast, exploration, classifier

Adaptive Thinking NEW

On Opus 4.7, extended thinking is decided by the model — no more manual budget_tokens. Inline indicators: "still thinking", "thinking more", "almost done thinking".

Effort Levels

low medium high xhigh max auto
lowSimple questions, exploration
mediumCommon usage
highDefault for API-key / Bedrock / Vertex / Team / Enterprise
xhigh100K tokens — default for Opus 4.7, MRCR v2 = 71% NEW
maxMaximum budget — hard problems
autoResearch preview: classifier decides

Invoke

--effort xhighAt launch /effortInteractive slider (↑↓) NEW "ultrathink"One-shot max effort in the prompt Option+TToggle thinking
🌍 Platforms

CLI

macOSNative installer (npm or curl)
LinuxNative installer — PID namespace isolation NEW
WindowsNative installer (WSL no longer required)

Desktop App NEW

Redesign April 14, 2026:

/desktop from the CLI to transfer a session to the app.

Web — claude.ai/code NEW

Research preview for Pro/Max. Cloud infrastructure, persistent sessions on mobile. /teleport to resume a web session locally.

IDE

VS CodeMultiple agentic extensions at once (Copilot + Claude Code + Codex) NEW
JetBrainsBeta plugin — improved diff viewer
/ideManage active integrations

GitHub & GitLab

/install-github-app — GitHub Actions & Code Review. --from-pr accepts GitHub, GitLab, Bitbucket, GitHub Enterprise. GitHub MCP server (mcp__github__*).

Third-party: "3rd-party platform" option on the login screen. Wizards claude bedrock setup / claude vertex setup.
🎯 Pro Workflow — Getting the Most Out of Claude Code

Starting a Project

1.cd project && claude 2./init to generate CLAUDE.md 3.Edit CLAUDE.md → conventions & commands 4./powerup to discover features NEW 5.Start coding!

Plan → Execute Loop

Shift+Tab × 2 → Plan Mode → Describe the task

Validate → Shift+Tab → Normal or Auto → "implement the plan"

/ultraplan to offload planning to the cloud, review in the browser, execute locally. NEW

Manage Context

/compact [focus]Compact with a focus area /clearUnrelated tasks? Reset opus[1m]Large codebases (native on Opus 4.7) --bareQuick questions, skip startup /focusCondensed view (quick read) NEW

Watchers & Automation

MonitorBackground watcher, tail logs NEW /loopSelf-pacing (omit interval) NEW Hook PostToolUseAuto-format after Edit

Prompting Techniques

Precisecat error.log | claude -p "root cause" Verifiable"After the fix, run npm test" IncrementalBreak into steps, validate each one Correct earlyCtrl+C if wrong direction AdaptiveOn Opus 4.7, let the model decide thinking NEW

Advanced Patterns

Worktreesclaude -w feat --tmux
Multi-dirs--add-dir ../lib
BackgroundCtrl+B
Agent Teams--teammate-mode auto
Remote--remote "task"
Loop/loop 5m /test or self-pacing
Schedule/schedule for cloud cron
Auto ModeMax+Opus 4.7: classifier handles permissions NEW
From PR--from-pr 42 (GitHub/GitLab/Bitbucket)

Headless / CI

claude -p --max-budget-usd 2 \ --max-turns 5 \ --effort xhigh "fix failing test"

OpenTelemetry: tool_use_id, tool_input_size_bytes, command_name, effort attrs NEW

Learning loop: Claude makes a mistake → you correct it → promote to a MUST rule → Claude never repeats it. This is compound learning.
📝 Customize Claude Code — Create Your Extensions

📋 Slash Command — .claude/commands/name.md

--- description: Review staged changes allowed-tools: Read, Bash(git *) model: sonnet disable-model-invocation: true argument-hint: "[focus area]" --- Diff: !`git diff --staged` Review: $ARGUMENTS | $1, $2 positional

You invoke it: /name. Personal: ~/.claude/commands/

🧠 Skill — .claude/skills/name/SKILL.md

--- name: deploy description: "Deploy to production (1536 chars max)" # NEW context: fork # isolated sub-agent paths: "src/**/*.ts" # activate by glob effort: high # force extended thinking user-invocable: true # false = Claude only allowed-tools: Read, Bash(git *) model: sonnet --- Instructions... + [ref](references/guide.md)

Claude decides when to invoke it (auto-discovery via description). /skills sorts them by token cost.

🤖 Sub-agent — .claude/agents/name.md

--- name: security-reviewer description: "Audit code for vulnerabilities" model: sonnet tools: Read, Grep, Glob memory: project # user / project / local isolation: worktree # separate git worktree permissionMode: plan --- You are a security specialist...

Invoke: @"name (agent)" | --agent name | natural language

📐 Rule — .claude/rules/name.md

--- paths: ["src/**/*.tsx", "src/**/*.ts"] --- MUST use TanStack Query for data fetching. SHOULD prefer named exports over default. MAY use inline styles for one-off components.

Auto-loaded when Claude touches a file matching the glob.

🔗 Hook — .claude/settings.json

"hooks": { "PostToolUse": [{ "matcher": "Write|Edit", "if": "Edit(*.ts)", "hooks": [{ "type": "command", "command": "npx prettier --write $FILE" }] }] }

Deterministic — always runs (unlike CLAUDE.md ~80%).

🔌 MCP Server — .mcp.json

# Add via CLI claude mcp add playwright -- npx @playwright/mcp # Or in .mcp.json { "mcpServers": { "pg": { "type": "stdio", "command": "npx", "args": ["@mcp/server-postgres"] }}}
Where to put what? Every conversation → CLAUDE.md | File-scoped → rules/ | Deterministic → hooks | Reusable workflow → commands/ | Complex + refs → skills/ | Parallel task → agents/ | External tool → MCP
💡 Quick Reference — Frequent Combos

Basic Commands

claudeInteractive session
claude -cResume last session
claude -p "query"Non-interactive mode
claude -r "name"Named session
claude --model claude-opus-4-7Opus 4.7 (adaptive thinking)
claude --from-pr 42Resume from a PR
/clearStart from scratch
/compact [focus]Free up context

Models & Effort

opus 4.71M context, adaptive thinking
sonnetFast & balanced (default)
opus[1m]Opus + 1M context
haikuUltra-fast, classifier
--effort xhigh100K tokens, default on Opus 4.7
--effort maxMax budget, hard problems
"ultrathink"One-time max effort

Power Moves

Esc EscRewind — undo
Shift+Tab ×2Plan Mode — read-only
Shift+Tab cycleAuto Mode (Max+Opus 4.7)
Ctrl+BBackground task
/focusCondensed view
/ultraplanCloud plan + local exec
-w feat --tmuxWorktree + tmux
/loop 5m /testRepeat every 5 min
MonitorBackground watcher
/insightsAnalyze your usage
A few April 2026 defaults: flicker-free rendering on by default · thinking summaries off in interactive · OS CA certificate store trusted by default · effort high default on API/Bedrock/Vertex/Team/Enterprise · effort xhigh on Opus 4.7.