claudeBenutzer09
1

Slash Commands

Claude Code’s built-in slash commands: how to find them, pass arguments, and pick the right one for context, sessions, configuration, diagnostics, and review.

Beginner 15 min

Slash commands drive Claude Code from inside the session: switch models, free up context, set permissions, kick off a workflow. A command is only recognized at the start of your message — whatever follows becomes its arguments. This module shows how to find the built-in commands and when each one fits.

Finding commands

Type / and you see every command available to you; a few letters after it filter the list. Send a command while Claude is still answering and it queues up behind the current turn — the exceptions are /status , /tasks and /usage , which run straight away without interrupting the response.

New to Claude Code? /powerup launches interactive lessons with animated demos right inside the CLI.

Text after the command name is passed through as its arguments, as in /compact focus on the API layer or /rename auth-refactor . Skills are the exception to the one-command-at-the-start rule: since v2.1.199, /skill-a /skill-b do XYZ loads every skill named up front — up to six — and hands the trailing text to each of them.

/compact focus on the payment service

Which command when

The built-in commands line up along the course of a session: setting up, working on the code, shipping the change. Knowing the groups lets you find the right command without memorizing the whole list.

Context management governs how much of the conversation Claude still sees. /context shows what is filling the window as a colored grid, /compact summarizes it to free space, and /clear starts a fresh conversation without losing project memory.

  • /context — draws context window usage as a colored grid
  • /compact — summarizes the history to free space; say what should survive: /compact keep the migration plan, drop the debugging
  • /clear — starts from nothing, project memory stays

Session tools manage the work itself. /resume returns to an earlier conversation, /rename gives it a findable name, /branch branches it at this point, and /fork copies it into a background session while you keep working here.

  • /rename my-feature — gives the session a name you will find again
  • /resume — returns to an earlier conversation
  • /branch — branches the conversation so you can test an alternative without giving up where you are
  • /rewind — goes back to an earlier checkpoint; /undo is the same thing under another name
  • /export — files the conversation away as text, to a file or the clipboard
  • /recap — sums the session up in one line; after a longer break that also happens on its own

Configuration steps in mid-session. /model switches the model, /effort the reasoning depth, /permissions sets your approval rules, and /config opens the settings — since v2.1.181 also directly as /config key=value , without opening the interface.

  • /model — switches the model, optionally through aliases such as best or opusplan
  • /effort — sets reasoning depth: low, medium, high, xhigh, max (this session only), or auto
  • /permissions — decides what Claude may do without asking
  • /config — opens the settings
  • /theme — creates and switches between named custom color themes; they live as JSON in ~/.claude/themes/ and can be hand-edited too
  • /tui — switches between classic and flicker-free fullscreen rendering mid-conversation; the same choice exists as the tui setting
  • /focus — hides everything but the prompt, the tool summary, and the answer
  • /fewer-permission-prompts — reads your recent transcripts for common read-only Bash and MCP calls and proposes an allowlist for .claude/settings.json from them

Diagnostics help when something is stuck. /doctor checks the installation, reports what it found first and asks before changing anything; /status shows the state of the session including background work; and /debug turns on logging and reads it back.

  • /cost — alias for /usage: session cost, plan limits, and activity
  • /usage-credits — views and manages the credits on your account; called /extra-usage until v2.1.144, and the old name still works
  • /status — opens settings on the Status tab: version, model, account, connectivity
  • /doctor — checks the setup for broken installs, PATH problems, and unparseable settings, asking before it changes anything
  • /diff — shows uncommitted changes and per-turn diffs in an interactive viewer

Pre-ship reviews check the work before it leaves your branch. /diff shows what changed, /code-review hunts correctness bugs in the diff and applies them with --fix , /security-review looks for security holes, and /review gives a GitHub pull request one fast read-through.

  • /code-review — hunts correctness bugs in the current diff and reports without touching files; steer the level with /code-review high for breadth or /code-review low for fewer but higher-confidence findings, --comment posts them as inline comments on the GitHub PR, and --fix applies them. Until v2.1.147 the command was called /simplify; since v2.1.154 /simplify is its own thing again, a cleanup-only review with no bug hunting
  • /code-review ultra — sends the same review to a cloud sandbox as a multi-agent run; with no argument it takes your branch, with a number like /code-review ultra 123 the matching GitHub PR. /ultrareview is an alias
  • /review — gives a GitHub pull request one fast, read-only pass
  • /security-review — examines the branch’s pending changes for security vulnerabilities
/context
/compact keep the auth refactor plan
/model opus
/effort high
/cost
/code-review high
/code-review --comment