Claude Code slash commands worth knowing, in the order you need them
Type / in Claude Code and a long menu appears. Nobody needs all of it. These are the commands that earn their keep, grouped by the moment you reach for them, with what each one does in a sentence.
How the menu behaves
- Type
/to see what is available, or/plus a few letters to filter. Press Enter on the highlighted suggestion to run it. - A command is only recognized at the start of your message. Whatever follows the name becomes its arguments.
- If you misspell one, nothing is highlighted. You can pick a close match with Tab or the arrow keys, but Enter sends your text as typed and you get
Unknown command. - If you send a command while Claude is still answering, it waits until the answer finishes. A few run immediately instead, such as
/status,/tasksand/usage. - Not every command shows for everyone. As we read the docs, availability depends on your platform, plan and setup. A command you don't see may simply not exist for you.
- Your own skills and the prompts from your MCP servers show up in the same menu, so the list on your machine is longer than anyone else's.
First session in a project
/initgenerates a starterCLAUDE.mdfor the project. Treat it as a first draft and trim it./memorylets you edit yourCLAUDE.mdfiles, turn auto memory on or off and look at what it saved. See CLAUDE.md vs auto memory./mcpmanages MCP server connections, including signing in to the ones that need it./permissionsopens your allow, ask and deny rules. A good starting set is in the permissions starter./configopens Settings: theme, model, output style and other preferences. If you remember a separate vim command, the docs say vim editing now lives in/configunder Editor mode./doctorruns a setup checkup for install, settings, extensions andCLAUDE.mdproblems and proposes fixes that Claude applies only after you confirm.
During a task
/planenters plan mode from the prompt. Add a description and it starts on that task straight away, for example/plan fix the login bug. More on modes in permission modes./modelswitches the model and saves it as your default for new sessions. In the picker, s on a row switches for the current session only./effortsets how much reasoning the model applies, fromlowup, orauto./effort statusprints the current level./add-dir <path>gives Claude file access to another directory for this session. As we read it, most.claude/configuration is not picked up from the added directory./goalkeeps Claude working across turns until a condition you wrote is met. See the goal guide.
When the conversation gets long
/contextdraws how full the context window is and suggests what to trim./compactsummarizes the conversation to free space. You can add focus instructions, for example/compact keep the API decisions. What survives is covered in what survives a compact./clearstarts a new conversation with empty context while keeping project memory. Pass a name to label the old one in the resume list./newand/resetdo the same./usageshows session cost, your plan limits and activity./costand/statsare aliases. Ways to spend less are in reduce token usage.
A question that should not clutter the chat
/btwasks a side question about the session without adding it to the conversation history. Run it with no question to browse earlier side answers./taskslists background work in the current session, including subagents that have finished.
Working in parallel
/backgrounddetaches the whole session to run as a background agent and frees your terminal. Monitor it withclaude agents./forkcopies the conversation into a new background session and lets you keep working in this one./branchinstead switches you into a copy so you can try another direction; the original stays available through/resume./batchplans a large codebase-wide change, and after you approve the plan runs each independent piece in its own worktree. It spends a lot more than a normal task, so start small. Related: worktrees and parallel sessions./looprepeats a prompt on a schedule while the session stays open. See the loop guide.
Before you ship
/diffshows what changed in your working tree, including Claude's edits./code-reviewchecks the current diff for correctness bugs, and--fixapplies the findings. Give it a pull request number to review that instead./reviewis an alias./security-reviewchecks the changes on your branch for security problems such as injection or exposed data. It needs anoriginremote.
Between sessions
/resumereopens an earlier conversation by name or ID, or shows the picker./renamenames the current session, or generates a name from the conversation if you give none./exportwrites the conversation as plain text to a file or your clipboard./copycopies the last reply, or the Nth-latest with a number, and offers a picker for code blocks.
When something is wrong
/rewindrolls the code and the conversation back to an earlier point./undoand/checkpointare aliases. Details in undoing changes with rewind./debugturns on debug logging for the session and reads the log to diagnose a runtime problem. Logging starts from that point, not before./doctoragain, for setup and install trouble. See also debugging your configuration./feedbacksends a bug report with the session context attached, after a consent step.
Look and feel
/themechanges the color theme, with an auto option that follows your terminal./statuslinesets up the line at the bottom. See the status line guide./tuiswitches the renderer, and/focushides everything but your last prompt, a tool summary and the answer. Both are in the fullscreen guide./terminal-setupinstalls a Shift+Enter newline in some terminals. See terminal setup.
Five to learn first
If you only memorize a few: /clear between unrelated tasks, /context to see what is filling the window, /rewind when an edit went wrong, /btw for quick questions, and /doctor when something feels off. The shortcut equivalents are in keyboard shortcuts worth learning.
All the guides are in the guides index, and unfamiliar words are in the glossary. This follows Anthropic's commands reference as we read it in October 2026, shortened on purpose. We are not affiliated with Anthropic. We wrote this from the documentation and have not run every command on every setup. Commands, aliases and version limits change, and where this page and the documentation disagree, the documentation wins. Run /help or type / to see what your own copy offers.
See also: Claude Code in VS Code.
The free loop-stop skill gives long tasks a limit and a stop rule. If you want a second pair of eyes on your CLAUDE.md and settings, the Tune-Up Kit is a checklist for exactly that.