Skip to content

All Claude Code Commands

Slash commands 118

Everyday

/help
Shows all commands.
/clear [name]
Starts a fresh chat.
/compact [instructions]
Shrinks the chat to free up space.
/exit
Quits Claude Code.
/init
Creates a CLAUDE.md for your project.
/memory
Edits your CLAUDE.md files.
/model [model]
Switches the AI model.
/resume [session]
Opens an old chat.
/rewind
Goes back to an earlier point.
/diff
Shows what changed in your files.
/plan [description]
Plans first, edits later.
/status
Shows your version, model and account.
/usage
Shows your usage and limits.

Conversation and context

/btw [question]
Asks a quick side question.
/branch [name]
Tries a different direction from here.
/fork [prompt]
Copies the chat to a background session.
/context [all]
Shows what's using up space.
/autocompact [auto|<tokens>]
Sets when the chat shrinks itself.
/copy [N]
Copies Claude's last reply.
/export [filename]
Saves the chat as a text file.
/recap
Sums up the session in one line.
/rename [name]
Renames the session.
/goal [condition|clear]
Keeps working until a goal is met.
/cd <path>
Moves to another folder.
/add-dir <path>
Gives access to another folder.
/focus
Shows only the final answer.
/insights
Shows how you use Claude Code.

Models and permissions

/effort [level|auto|status]
Sets how hard Claude thinks.
/fast [on|off]
Turns fast mode on or off.
/advisor [model|off]
Lets Claude ask a second model.
/output-style [style]
Changes how replies look.
/permissions
Sets what Claude can do without asking.
/sandbox
Turns sandbox mode on or off.
/auto-mode-setup
Sets up auto mode.
/fewer-permission-promptsSkill
Asks you less often.
/voice [hold|tap|off]
Turns voice typing on or off.

Code review and testing

/code-review [level] [--fix] [PR]Skill
Checks your code for bugs.
/review [level] [--fix] [PR]
Same as /code-review.
/security-review
Checks your changes for security issues.
/ultrareview [PR or branch]
Runs a deep review in the cloud.
/autofix-pr [prompt]
Fixes your pull request when checks fail.
/simplify [target]Skill
Cleans up your new code.
/verifySkill
Runs your app to check a change works.
/runSkill
Opens your app to see a change.
/run-skill-generatorSkill
Teaches /run how to start your app.
/batch <instruction>Skill
Makes big changes across your code.

Agents and background work

/agents
Shows how to set up subagents.
/list-agents
Lists agents Claude can message.
/subtask <task>
Starts a helper in the background.
/background [prompt]
Sends this chat to the background.
/tasks
Shows background work.
/stop
Stops a background session.
/loop [interval] [prompt]Skill
Repeats a prompt on a timer.
/schedule [description]
Schedules tasks in the cloud.
/deep-research <question>Workflow
Researches a topic and writes a report.
/workflows
Shows running workflows.
/teleport
Brings a cloud session here.
/remote-control
Continue this chat on claude.ai or your phone.
/remote-env
Picks your default cloud setup.
/desktop
Continues in the desktop app.

Settings and setup

/config [key=value]
Opens settings.
/theme
Changes the colors.
/color [color|default]
Changes the prompt bar color.
/statusline
Sets up the status line.
/keybindings
Edits your shortcuts.
/terminal-setup
Makes Shift + Enter add a new line.
/tui [default|fullscreen]
Switches the screen layout.
/scroll-speed
Changes the scroll speed.
/hooks
Shows your hooks.
/update-config [request]Skill
Changes settings in plain English.
/privacy-settings
Changes your privacy settings.
/doctorSkill
Finds and fixes setup problems.
/debug [description]Skill
Helps find a problem in Claude Code.
/heapdump
Saves a memory report.
/restart
Restarts Claude Code.
/release-notes
Shows what's new.
/import [codex|gemini|cursor]
Brings your setup from Codex, Gemini or Cursor.
/powerup
Teaches features with quick lessons.

Connections and add-ons

/mcp
Manages your connected tools.
/plugin [subcommand]
Installs and manages plugins.
/reload-plugins
Reloads plugins.
/skills
Lists your skills.
/reload-skills
Reloads skills.
/skill-doctor
Shows which skills cost the most.
/ide
Connects to your code editor.
/chrome
Sets up Claude in Chrome.
/claude-in-chrome [task]Skill
Does a task in your Chrome browser.
/install-github-app
Adds the Claude GitHub app.
/install-slack-app
Adds the Claude Slack app.
/web-setup
Connects GitHub for cloud sessions.
/setup-bedrock
Sets up Amazon Bedrock.
/setup-vertex
Sets up Google Cloud.
/artifacts
Lists your artifacts.
/design [brief]Skill
Designs screens and pages.
/design consent
Gives or removes Claude Design access.
/design-login
Signs in for /design-sync.
/design-sync [hint]Skill
Uploads your design system.
/slides [brief]Skill
Makes a slide deck.
/dataviz [request]Skill
Helps with charts.
/claude-apiSkill
Loads the Claude API docs.
/artifact-capabilitiesSkill
Shows what artifacts can do.
/artifact-diagrammingSkill
Helps draw diagrams.
/plugin-authoring
Helps you write a mod.
/workflow-authoringSkill
Helps you write workflows.
/mobile
Shows a QR code for the Claude app.

Account and usage

/login
Signs in.
/logout
Signs out.
/cost
Same as /usage.
/stats
Same as /usage.
/usage-credits
Adds usage credits.
/rate-limit-options
Shows options when you hit a limit.
/upgrade
Upgrades your plan.
/passes
Shares a free week with friends.
/team-onboarding
Writes a guide for your team.
/feedback [report]
Sends feedback.
/bug [report]
Reports a bug.
/radio
Plays lo-fi radio.
/stickers
Orders stickers.

Terminal commands 36

Start and resume

claude
Starts Claude Code.
claude "query"
Starts with your first message.
claude -p "query"
Asks once and exits.
cat file | claude -p "query"
Sends a file with a question.
claude -c
Continues your last chat.
claude -c -p "query"
Continues with one question.
claude -r "<session>" "query"
Opens a chat by name or ID.
claude import [source]
Brings your setup from another tool.

Install and account

claude update
Updates Claude Code.
claude install [version]
Installs a specific version.
claude doctor
Checks your setup.
claude auth login
Signs in.
claude auth logout
Signs out.
claude auth status
Shows if you're signed in.
claude setup-token
Makes a token for scripts.
claude purge [path]
Deletes a project's history.

Background sessions

claude agents
Shows background sessions.
claude attach <id|name>
Opens a background session.
claude logs <id|name>
Shows a session's output.
claude stop <id>
Stops a background session.
claude respawn <id>
Restarts a background session.
claude rm <id>
Removes a background session.
claude daemon status
Shows the background helper's status.
claude daemon logs
Shows the background helper's log.
claude daemon run
Runs the background helper here.
claude daemon stop --any
Stops the background helper.

Tools and add-ons

claude mcp
Manages MCP servers.
claude mcp login <name>
Signs in to an MCP server.
claude mcp logout <name>
Signs out of an MCP server.
claude plugin
Manages plugins.
claude auto-mode defaults
Shows the auto mode rules.
claude auto-mode reset
Resets auto mode.
claude ultrareview [target]
Runs a deep code review.
claude remote-control
Use Claude Code from claude.ai or your phone.

For admins

claude gateway
Starts a company gateway (admins).
claude self-hosted-runner
Runs cloud sessions on your own servers.

Flags 78

Everyday

--continue, -c
Continues your last chat.
--resume, -r
Opens an old chat.
--print, -p
Prints the answer and exits.
--model
Picks the model.
--effort
Sets how hard Claude thinks.
--permission-mode
Starts in a permission mode.
--name, -n
Names the session.
--add-dir
Gives access to more folders.
--version, -v
Shows the version.
--worktree, -w
Works in a separate copy of your code.
--bg, --background
Runs in the background.
--safe-mode
Starts with all add-ons off.

Permissions and tools

--allowedTools, --allowed-tools
Tools Claude can use without asking.
--disallowedTools, --disallowed-tools
Tools Claude can't use.
--tools
Limits the built-in tools.
--dangerously-skip-permissions
Skips all permission prompts. Be careful.
--allow-dangerously-skip-permissions
Adds skip-permissions to Shift + Tab.
--permission-prompts
Sets who answers prompts in print mode.
--permission-prompt-tool
Uses a tool to answer prompts.
--restricted
Starts in restricted mode.
--disable-slash-commands
Turns off all commands and skills.
--bare
Starts fast with nothing extra loaded.

Models and output

--fallback-model
Backup model if the main one is busy.
--advisor <model>
Turns on the advisor.
--autocompact <auto|tokens>
Sets when the chat shrinks itself.
--output-format
Output as text or JSON.
--input-format
Input as text or JSON.
--json-schema
Returns JSON in your format.
--max-turns
Limits how many steps Claude takes.
--max-budget-usd
Stops at a spending limit.
--include-partial-messages
Streams partial replies.
--include-hook-events
Includes hook events in the output.
--forward-subagent-text
Includes subagent text in the output.
--prompt-suggestions
Suggests your next prompt.
--replay-user-messages
Echoes your messages back.
--verbose
Shows full details.
--ax-screen-reader
Screen-reader friendly output.
--betas
Turns on API beta features.

System prompt

--system-prompt
Replaces the system prompt.
--system-prompt-file
Replaces the system prompt from a file.
--append-system-prompt
Adds to the system prompt.
--append-system-prompt-file
Adds a file to the system prompt.
--append-subagent-system-prompt
Adds to every subagent's prompt.
--append-subagent-system-prompt-file
Adds a file to every subagent's prompt.
--system-prompt-snapshot
Rebuilds the prompt every time.
--exclude-dynamic-system-prompt-sections
Keeps personal details out of the system prompt.

Agents and sessions

--agent
Uses a specific agent.
--agents
Adds custom subagents.
--teammate-mode
Sets how teammates show up.
--fork-session
Resumes as a new session.
--session-id
Uses a specific session ID.
--no-session-persistence
Doesn't save the session.
--from-pr
Shows sessions for a pull request.
--exec
Runs a command in the background.
--tmux
Opens a tmux session.
--cloud
Starts a cloud session.
--teleport
Brings a cloud session here.
--environment <id>
Uses your own cloud environment.
--ref <branch>
Starts from a branch.
--remote-control, --rc
Lets you control it from your phone or web.
--remote-control-session-name-prefix
Prefix for Remote Control names.
--desktop
Opens the desktop app instead.

Settings and add-ons

--settings
Loads settings from a file.
--setting-sources
Picks which settings to load.
--mcp-config
Loads MCP servers.
--strict-mcp-config
Uses only the MCP servers you pass.
--plugin-dir
Loads a plugin from a folder.
--plugin-url
Loads a plugin from a link.
--channels
Listens for MCP notifications.
--dangerously-load-development-channels
Allows unapproved channels.
--chrome
Turns on Claude in Chrome.
--no-chrome
Turns off Claude in Chrome.
--ide
Connects to your editor on start.
--init
Runs setup hooks first.
--init-only
Runs setup hooks and exits.
--maintenance
Runs maintenance hooks first.
--debug
Turns on debug mode.
--debug-file <path>
Saves debug logs to a file.

Keyboard shortcuts 42

General

Esc
Stops Claude.
Esc Esc
Clears your text, or goes back.
Shift + Tab
Switches permission modes.
Ctrl + C
Stops, or quits if pressed twice.
Ctrl + D
Quits (press twice).
Up / Down arrows
Brings back what you typed before.
Tab
Accepts a suggestion.
Ctrl + R
Searches what you typed before.
Ctrl + O
Shows the full transcript.
Ctrl + T
Shows the task list.
Ctrl + B
Sends tasks to the background.
Ctrl + S
Saves your prompt for later.
Ctrl + G
Writes your prompt in an editor.
Ctrl + V
Pastes an image.
Ctrl + L
Redraws the screen.
Ctrl + Z
Pauses Claude Code.
Ctrl + Enter
Sends queued messages now.
Ctrl + X Ctrl + K
Stops all background helpers.
Left / Right arrows
Moves between tabs.
Option + P
Switches the model.
Option + T
Turns thinking on or off.
Option + O
Turns fast mode on or off.

Typing

Ctrl + A
Jumps to the start of the line.
Ctrl + E
Jumps to the end of the line.
Ctrl + K
Deletes to the end of the line.
Ctrl + U
Deletes to the start of the line.
Ctrl + W
Deletes the last word.
Ctrl + Y
Pastes what you deleted.
Alt + Y
Cycles through deleted text.
Alt + B
Moves back a word.
Alt + F
Moves forward a word.
Alt + D
Deletes the next word.
Ctrl + _
Undoes your last edit.

New lines

Shift + Enter
New line.
\ + Enter
New line, in any terminal.
Ctrl + J
New line, in any terminal.
Option + Enter
New line (Option set as Meta).

Typed at the start

/
Shows commands.
!
Runs a Terminal command.
@
Mentions a file.
:
Adds an emoji.
?
Shows shortcuts.

Plugin commands 26

commit-commands

Install:/plugin install commit-commands@claude-plugins-official
/commit-commands:commit
Commits your changes.
/commit-commands:commit-push-pr
Commits, pushes and opens a pull request.
/commit-commands:clean_gone
Deletes old local branches.

feature-dev

Install:/plugin install feature-dev@claude-plugins-official
/feature-dev:feature-dev [description]
Builds a feature step by step.

code-review

Install:/plugin install code-review@claude-plugins-official
/code-review:code-review
Reviews a pull request.

pr-review-toolkit

Install:/plugin install pr-review-toolkit@claude-plugins-official
/pr-review-toolkit:review-pr [aspects]
Reviews a pull request in depth.

hookify

Install:/plugin install hookify@claude-plugins-official
/hookify:hookify [behavior]
Stops Claude doing something again.
/hookify:list
Lists your rules.
/hookify:configure
Turns rules on or off.
/hookify:help
Shows hookify help.

claude-md-management

Install:/plugin install claude-md-management@claude-plugins-official
/claude-md-management:revise-claude-md
Saves today's learnings to CLAUDE.md.
/claude-md-management:claude-md-improver
Improves your CLAUDE.md.

claude-code-setup

Install:/plugin install claude-code-setup@claude-plugins-official
/claude-code-setup:claude-automation-recommender
Suggests automations for your code.

claude-security

Install:/plugin install claude-security@claude-plugins-official
/claude-security:claude-security
Scans your code for security issues.

code-modernization

Install:/plugin install code-modernization@claude-plugins-official
/code-modernization:modernize
Modernizes old code.

ralph-loop

Install:/plugin install ralph-loop@claude-plugins-official
/ralph-loop:ralph-loop "PROMPT"
Keeps Claude working until it's done.
/ralph-loop:cancel-ralph
Stops the loop.

frontend-design

Install:/plugin install frontend-design@claude-plugins-official
/frontend-design:frontend-design
Better-looking frontend design.

skill-creator

Install:/plugin install skill-creator@claude-plugins-official
/skill-creator:skill-creator
Creates and tests skills.

playground

Install:/plugin install playground@claude-plugins-official
/playground:playground
Makes an interactive HTML playground.

session-report

Install:/plugin install session-report@claude-plugins-official
/session-report:session-report
Reports your token use.

receipts

Install:/plugin install receipts@claude-plugins-official
/receipts:receipts
Reports what you've done with Claude Code.

project-artifact

Install:/plugin install project-artifact@claude-plugins-official
/project-artifact:project-artifact
Publishes a project status page.

mcp-server-dev

Install:/plugin install mcp-server-dev@claude-plugins-official
/mcp-server-dev:build-mcp-server
Builds an MCP server.

plugin-dev

Install:/plugin install plugin-dev@claude-plugins-official
/plugin-dev:create-plugin [description]
Creates your own plugin.

agent-sdk-dev

Install:/plugin install agent-sdk-dev@claude-plugins-official
/agent-sdk-dev:new-sdk-app [name]
Sets up an Agent SDK app.