Video Lesson: Create a custom slash command in Claude Code

Create a custom slash command in Claude Code

This is premium content

Only available to enrolled or University students.
Join today to unlock all lessons in this course.

Create a custom slash command in Claude Code

Learn how to create global and project specific custom slash commands in Claude Code for reusable prompts.

Lesson Content

In Claude Code, you can create custom "slash commands". Think of slash commands as snippets of text that you want to reuse in the future to save time.

If you notice yourself typing the same prompt over and over again, it's a great candidate for a slash command.

We can place custom slash commands in one of two places:

  • ~/.claude/commands/ - global directory shared across all projects

  • .claude/commands/ - local directory only available to the current project

Within this directory, create a markdown file named after the command you want to create.

A common task I repetitivel...

Premium content

Enroll to unlock the full content and all course materials.

👋
Maggie

Log in to start chatting!

Maggie

Hey, I'm Maggie! 👋

Ask me anything.

Want to chat with Maggie?

Enroll in this course for AI tutor access.

Comments

Join the discussion!

Comments

Want to comment on this lesson?

Enroll in this course to leave comments.