Skip to content
BENIBIX Learn

Claude Code CLI Command vs Slash Command

People think claude doctor and /doctor are the same command typed two ways. They are not. A CLI command is typed in your shell after claude, runs, prints and stops, with no chat. Scripts and CI jobs can run it. A slash command is typed inside a running session and acts on that chat. So claude doctor only reads your install, even when Claude Code will not start, while /doctor runs inside a chat and offers fixes.

AI⌨️ Claude Code

Claude Code CLI Command

A command you type in the shell after claude, outside a chat.

A Claude Code CLI command is a word you type after claude in your shell, such as claude update or claude auth status. It runs, prints its answer and stops, with no chat. That is the difference from a slash command, which you type inside a running session. Most CLI commands install, sign in, check or clean up, or look after background sessions. If you mistype one, Claude Code says the closest match and stops.

Example
Jack wants to know which account his laptop uses. He does not open a chat. He types claude auth status in his shell and reads the answer.
Why it matters
Scripts and CI jobs cannot type into a chat. CLI commands are what they can run.
Full entry
AI⌨️ Claude Code

Claude Code Slash Command

A word that starts with /, like /clear, that steers Claude Code.

A slash command is a word that starts with / and that you type at the start of a message, such as /clear or /model. It steers Claude Code itself, not the task you are working on. Type / to open the menu, then type letters to filter it. Any text after the name goes to the command. Many commands are built in. Skills and plugins add more of their own.

Example
Lucy's chat has grown long and slow. She types /co, sees /compact in the list, picks it, and the chat is squeezed into a short summary.
Why it matters
Most things you change in a session, from the model to the rules, take one slash command.
Full entry

In one line

Claude Code CLI Command
A command you type in the shell after claude, outside a chat.
Claude Code Slash Command
A word that starts with /, like /clear, that steers Claude Code.