← Back to all free guides

The Claude Code
Commands I Use

You commented SLASH, so here it is. My 13 favorite Claude Code commands, grouped by when I reach for each one. Save this page and come back to it.

Type / in Claude Code and you get a menu of commands. Most people use two of them. Here are the ones I use every day, with what each does and exactly what to type. Anything in [brackets] is optional.

Commands change fast, so if one looks different on your screen, check Anthropic’s full commands list.

Everyday Essentials

01

Make it remember

Opens your CLAUDE.md files so you can edit the facts, preferences and rules Claude carries into every future session. You can also turn auto memory on or off here and see what it saved.

Type this
/memory

02

Switch models

Switches the model and saves it as your default. Go up for a big refactor, down for quick edits. With no model name it opens a picker, and the left and right arrows adjust effort on models that support it.

Type this
/model [model]

03

Undo a wrong turn

Rolls the conversation, the code, or both back to an earlier checkpoint. When Claude goes down the wrong path, don’t argue with it. Rewind to a clean point and start fresh. /undo does the same thing.

Type this
/rewind
Power Moves

04

Plan before it touches anything

Puts Claude in plan mode, so it maps out the work before changing anything and you approve the plan first. Add a description to start on that task right away. I use it before anything big or risky.

Type this
/plan [description]

05

Set a finish line

Give Claude a condition, like all tests passing, and it keeps working turn after turn until a separate checker confirms it’s met. Make the condition something Claude can prove in the chat, like a test result.

Type this
/goal [condition]

Want to actually walk away? Run it in auto mode. In manual mode Claude still stops to ask before commands you haven’t approved. Type /goal clear to stop early. (How goals work)

06

Build your own helpers

Subagents are specialists with their own instructions that Claude hands work to. In current versions, /agents just reminds you to ask Claude to create or manage them, so I skip it and paste this instead.

Type this
/agents
Create A Subagent
Create a new project subagent for me in .claude/agents/. What I want it to do: [describe the job, e.g. "review every change I make for bugs and missing tests before I commit"] Steps: 1. Ask me up to 3 questions if anything about the job is unclear. 2. Pick a short lowercase-hyphen name, like code-checker. 3. Write the agent file with a one-line description that says exactly when to use it, the tools it needs (read-only unless the job requires edits), and clear step-by-step instructions. 4. Tell it what to hand back: a short summary first, then details, with file paths and line numbers. 5. Show me the full file before you save it. Rules: keep its tool access as narrow as the job allows, never let it delete files or push code, and tell me how to call it when you're done.

07

Send it to the background

Detaches the session so it keeps working as a background agent and your terminal is free. Add a prompt to give it one last instruction first. Check on it later with claude agents. /bg works too.

Type this
/background [prompt]
Context And Cost Control

08

See what’s filling the window

Shows your context window as a colored grid, plus tips when something like a big memory file is eating space. Check it before Claude starts forgetting things.

Type this
/context

09

Free up space

Summarizes the conversation so far so you can keep going without starting a new chat. Add a short note to tell it what to keep, like /compact keep the API decisions.

Type this
/compact [instructions]

10

Know where you stand

Shows session cost, plan usage limits and activity stats in one place. On Pro, Max, Ultra, Team and Enterprise it also breaks down what counts against your limits. /cost and /stats open the same screen.

Type this
/usage
Safety And Automation

11

Try a risky idea safely

Makes a branch of the conversation at this point and switches you into it. If the idea flops, use /resume to go back to the original, right where you left it.

Type this
/branch [name]

12

Check security before you ship

Reviews the changes on your current branch against your main branch on GitHub (or wherever your origin remote points) for problems like injection, auth issues and data exposure. Run it right before you merge.

Type this
/security-review

13

Put a check on repeat

Runs a prompt again and again while your session stays open, like /loop 5m check if the deploy finished. Leave out the interval and Claude picks its own pace.

Type this
/loop [interval] [prompt]
My Daily Flow

Here’s how they chain together in a real session. I open with /plan and approve the plan. Then I set a /goal in auto mode and go do something else.

When I come back, I glance at /context and run /compact if it’s getting full. If Claude wandered, /rewind. Before I merge, /security-review, and /usage tells me what the session cost. Save this page and go build something.