Claude Code Kit

Claude Code Slash Command Builder

Fill in the frontmatter and prompt, then copy or download the file. Output updates as you type.

Command

Save as

The context and agent fields are documented for skills. They may not apply to files in the older commands folder. unverified

Frontmatter fields

FieldWhat it does
descriptionWhat the command does. Claude reads it to decide when to use the skill on its own.
argument-hintText shown in autocomplete, like [issue-number].
allowed-toolsTools pre-approved while the command runs. Space or comma separated, patterns allowed.
modelOverride the session model for this command.
disable-model-invocationtrue means Claude never runs it by itself.
user-invocablefalse hides it from the / menu so only Claude can use it.
context and agentcontext: fork runs it in a subagent. agent picks the type.
argumentsNamed positional arguments, usable as $name in the body.

Placeholders

Where files go

.claude/commands/name.md or .claude/skills/name/SKILL.md in a project, and the same under ~/.claude/ for all projects. Commit project files so the team shares them.

Checked against code.claude.com/docs/en/skills on 2026-10-20. The docs now lead with skills. unverified: whether every frontmatter field applies to files in .claude/commands.

FAQ

How do I create a custom slash command in Claude Code?

Create a markdown file at .claude/commands/name.md (project) or ~/.claude/commands/name.md (personal). The file name becomes /name. The body is the prompt.

What is the difference between a command and a skill?

A skill lives in a folder as .claude/skills/name/SKILL.md and can ship extra files such as scripts. Both can be invoked with /name. Skills also let Claude load them on its own based on the description. Check the skills docs for current behavior of the older commands folder.

How do I pass arguments to a slash command?

Use $ARGUMENTS for everything typed after the command name, or $0, $1, $2 for single positions. A skill can also declare named arguments in frontmatter and use $name.

How do I stop Claude from running a command by itself?

Set disable-model-invocation: true in the frontmatter. Then only you can run it with /name. Use it for deploys, commits, and anything with side effects.

How do I run a shell command inside a slash command?

Put the command in backticks after an exclamation mark, like !`git diff`. It runs before Claude sees the prompt and its output is inserted. Add the command to allowed-tools.