Scroll AI Now

Claude Code slash commands: the ones worth knowing

The built‑in Claude Code slash commands worth learning first, how to write your own command, and when a skill is the better choice. Checked in the docs.

Short answerStart with /clear, /compact, /context, /model, /usage and /permissions to steer a session. Use /init and /memory for project instructions, /plan before big changes, and /code‑review before you merge. For your own command, write a skill. The Claude Code skills page says "Custom commands have been merged into skills".

What are Claude Code slash commands?

Slash commands are short instructions you type inside a Claude Code session. They change the model, clear context, review code and more. Type / to see the menu, or type / plus a few letters to filter it.

The Claude Code commands page sets one rule to remember: "A command is only recognized at the start of your message". Any text after the command name becomes its arguments.

At the terminal prompt, you can also open one message with several skills. The same page says "Up to six skills can be chained".

Not everyone sees the same menu. The commands page says "Availability depends on your platform, plan, and environment". Its examples: /desktop appears only on macOS and x64 Windows when you sign in with a Claude subscription, and /upgrade does not appear on Enterprise plans.

We checked the Claude Code commands page on 27 November 2026. Check that page before you rely on any row below.

Which built-in slash commands are worth knowing first?

These commands steer a session from day to day. The middle column summarizes the Claude Code commands page in our own words. The last column is our suggestion for when to use each one.

CommandWhat it does (commands page)Use it when
/clearOpens a fresh conversation with empty context. /resume brings the old one back. Aliases: /reset, /new.You move to an unrelated task.
/compactFrees up room by summarizing what has happened so far. You can add focus instructions.A long task must continue but context is filling up.
/contextDraws context usage as a colored grid, with suggestions for what is heavy.You want to see what is using up the context.
/usageReports what the session cost, your plan limits and activity stats. /cost and /stats are aliases.You watch spend or plan limits.
/modelChanges the model, and the choice becomes your default for future sessions. In the picker, press s to change it for this session only.A task needs a different model.
/effortSets the "effort level: low to xhigh, max, or auto". Max lasts for the session only.A hard problem needs more effort, or a quick one needs less.
/planEnters plan mode, optionally with a task, such as /plan fix the auth bug.Before a change you would hate to undo by hand.
/initSets up the project with a CLAUDE.md guide.You start in a new repository.
/memoryOpens your CLAUDE.md files for editing and switches auto memory on or off.You want to change standing instructions.
/permissionsManages allow, ask and deny rules for tools.You want fewer prompts for safe actions, or to block risky ones.
/rewindTakes the conversation, the code, or both back to an earlier point. Aliases: /checkpoint, /undo.Claude went the wrong way.
/btwAsks a side question that is not added to the conversation.A quick question would clutter the main task.
/exportSaves the conversation as plain text, to a file or the clipboard.You need a record of the session.

Three more cover tools you add. /mcp manages MCP server connections and OAuth, /hooks shows your hook configurations, and /skills lists your skills. Our guide to Claude Code hooks explains what hooks do.

Which commands review code before you merge?

So they work as a set. In its /simplify row, the commands page says "Use /code‑review to find bugs". Since /security‑review flags auth issues and data exposure, run it too when a change touches logins or customer data.

Which commands are really bundled skills?

The commands page says "Most are built‑in commands whose behavior is coded into the CLI". Rows marked Skill are bundled skills. The page describes those as "a prompt handed to Claude".

In the table we checked, these rows carry the Skill mark:

Before you run /batch, know that each subagent opens a PR or reports what happened. It also needs a git repository or a WorktreeCreate hook. The commands page pitches it for "large‑scale changes across a codebase".

The commands page adds that "MCP servers can expose prompts that appear as commands", so connected servers may add entries to your menu.

How do you make your own slash command?

Write a skill. The Claude Code skills page says "Custom commands have been merged into skills". The skills page says the frontmatter name field is the "Command name shown in the / menu" and "Defaults to the directory name".

  1. Create a folder in your project: .claude/skills/changelog/. For a personal folder, ~/.claude/skills/changelog/, the skills page gives the scope as "All your projects on this machine, but not Cowork or cloud sessions".
  2. Inside it, create a file named SKILL.md. Start it with a short YAML frontmatter block.
  3. Add a description line. The skills page says "Claude uses this to decide when to apply the skill".
  4. Add disable-model-invocation: true if only you should start it. The skills page says that with it, "Claude can't invoke the skill on its own". It suggests this for workflows with side effects or timing you want to control.
  5. Under the frontmatter, write the steps in plain English. Put $ARGUMENTS where the text you type after the command should go.
  6. Type /changelog followed by your text to run it. /skills shows the skills Claude Code has found.

Worked example. A release notes command could hold these lines in SKILL.md:

Typing /changelog 2.4 puts 2.4 where $ARGUMENTS sits. For single arguments by position, the skills page offers $0 for the first and $1 for the second. An optional argument‑hint field shows a hint such as [issue‑number] while you type.

Pick a name nothing else uses. The skills page's name table says that in a local terminal session, a skill named after a built‑in command replaces it, but not its aliases. Its example: "A project usage skill replaces /usage". The same table says "A project code‑review skill replaces /code‑review".

For a fuller walk through of the file, see how to write an agent skill.

Do old .claude/commands files still work?

Yes. The skills page says your existing .claude/commands/ files "keep working", and that "Claude can invoke them without you typing the command".

To move one, the page's example takes .claude/commands/deploy.md to .claude/skills/deploy/SKILL.md. You still type /deploy.

If a skill and a commands file share a name, the table on the skills page says the skill is the one that runs.

When is a skill better than a plain command?

The skills page says to "convert a command that needs more than one file to a skill", since a skill folder can hold supporting files. Use this table to pick the setup.

Your situationSet it up asReason (skills page)
You start it yourself, at a moment you choose, like a deploySkill with disable-model-invocation: true"Claude can't invoke the skill on its own"
You want Claude to use it whenever it fitsSkill with a clear description and default settings"By default, both you and Claude can invoke any skill"
Background knowledge nobody should typeSkill with user‑invocable: falseIt is hidden from the / menu.
Long reference notes or templatesSkill folder with supporting filesClaude can reach "detailed reference material only when needed".
You keep pasting the same checklistSkill"Create a skill when you keep pasting the same instructions, checklist, or multi‑step procedure into chat"
A short fact every session needsCLAUDE.md, edited with /memoryA skill fits when a CLAUDE.md section "has grown into a procedure rather than a fact".

The cost angle: the skills page says "a skill's body loads only when it's used", so long reference material "costs almost nothing until you need it".

For ready‑made ideas, see our list of the best Claude Code skills.

What can a custom command reach, and how do you limit it?

A skill tells Claude what to do with your files and tools. Read any skill before you run it, and keep its reach small.

New to the tool? Start with our guide to Claude Code for non developers.

A short routine with these commands

  1. New repository: run /init, then /memory to adjust the instructions.
  2. Before a big change: /plan with the task in one line.
  3. Mid session: /context to see usage, /compact with a focus when it grows, /clear when you switch tasks.
  4. When it goes wrong: /rewind to an earlier point.
  5. Before merging: /code‑review, then /security‑review on changes that touch logins or customer data.
  6. Once a week: /usage for spend, and /skills to prune. In /skills, the t key sorts the list by token count.

Want new skills to turn into your own commands? See today's agent skills in the feed. Scroll AI Now is a free learning feed, and it does not run your agents for you.

Questions

Are custom slash commands deprecated in Claude Code?

Not removed. The skills page says custom commands "have been merged into skills" and existing .claude/commands/ files "keep working". It says to "convert a command that needs more than one file to a skill".

Why can't I see a command that a guide mentions?

The commands page says "Availability depends on your platform, plan, and environment". For example, /upgrade does not appear on Enterprise plans.

What is the difference between /clear and /compact?

/clear starts a new conversation with empty context, and /resume can bring the old one back. /compact keeps the same conversation but summarizes it to free up room.

Can Claude run my custom command without me typing it?

Yes, by default. The skills page says "By default, both you and Claude can invoke any skill". Set disable-model-invocation: true to keep it manual.

How many skills can I use in one message?

At the terminal prompt, the commands page says "Up to six skills can be chained" at the start of one message. The text after them goes to each as arguments.

Try it in your browser

Today's AI news, one card per swipe.
Free to start.

Open the web app