Back to Blog

Creating Custom Skills in Claude Code

(edited: March 10, 2026)

Building Your Own Slash Commands in Claude Code

If you use Claude Code regularly, you've probably found yourself typing the same instructions over and over — things like "analyze this repo and give me a summary" or "run the tests and organize the results." Custom Skills let you turn those repetitive tasks into a single /my-skill command.

What Is a Skill?

A Skill is a custom slash command for Claude Code. Create a single SKILL.md file and you can invoke it with /skill-name. Instead of writing long prompts every time, you can templatize your most-used workflows.

Where Do You Put Them?

TEXT
# Available across all projects (personal)
~/.claude/skills/<skill-name>/SKILL.md

# Available only in a specific project
.claude/skills/<skill-name>/SKILL.md

Personal skills work in any repo. Project skills only activate within that repo.

SKILL.md Structure

YAML
---
name: my-skill
description: Explains when this skill should be used
argument-hint: [argument description]
disable-model-invocation: true
allowed-tools: Read, Grep, Glob
---
# Skill Instructions

Perform the task based on $ARGUMENTS.

Key Options

OptionDescription
nameThe name used to invoke it as /name
descriptionDescribes the skill — used by Claude to decide whether to auto-invoke it
argument-hintArgument hint shown in autocomplete
disable-model-invocationIf true, the skill can only be run manually
allowed-toolsRestricts which tools the skill can use

Passing Arguments

YAML
---
name: analyze
---
Please analyze the $ARGUMENTS file.
# /analyze src/main.ts → "Please analyze the src/main.ts file."

Please convert $0 to $1 format.
# /convert data.json csv → "Please convert data.json to csv format."
  • $ARGUMENTS: the full argument string
  • $0, $1, $2: positional arguments

Real-World Example

Here's a skill I built that collects information from a Flutter open-source project and automatically generates a draft blog post.

YAML
---
name: add-flutter-to-blogman
description: Collects Flutter repo info and generates a draft project introduction post
disable-model-invocation: true
allowed-tools: Read, Grep, Glob, Write
---
# Convert a Flutter Project into a Blog Post

Read README.md, pubspec.yaml, and CHANGELOG.md,
then save a project introduction draft as blogman-draft.md.

## Information to Collect

- README.md: description, features, screenshots
- pubspec.yaml: package name, dependencies, version
- CHANGELOG.md: latest changes

## Output

Save to blogman-draft.md

Now, running /add-flutter-to-blogman in any Flutter repo automatically produces a blog post draft.

Tips

  • Read-only skills: Restrict to allowed-tools: Read, Grep, Glob to allow code analysis without letting the skill make any changes.
  • Prevent accidental execution: For risky operations like deployments or deletions, use disable-model-invocation: true so the skill can only be triggered manually.
  • Split out reference docs: If your SKILL.md gets long, you can place separate .md files in the same folder and reference them from the skill.

If there's a Claude Code workflow you keep repeating, turn it into a Skill.

Comments