Skip to content

Plugins — Shareable Extensions

Plugins are self-contained, versioned bundles of skills, agents, hooks, and MCP servers that can be shared across teams and distributed via marketplaces.


ApproachSkill namesBest for
Standalone (.claude/ directory)/helloPersonal, project-specific, quick experiments
Plugins (self-contained directories)/plugin-name:helloSharing with team, distributing, versioned releases

Start with standalone config in .claude/ for quick iteration, then convert to a plugin when ready to share.


my-plugin/
├── .claude-plugin/
│ └── plugin.json # Plugin manifest (metadata)
├── skills/
│ └── hello/
│ └── SKILL.md # Custom skills
├── agents/
│ └── reviewer.md # Custom subagents
├── hooks/
│ └── hooks.json # Event hooks
├── .mcp.json # MCP server configs
├── .lsp.json # LSP server configs (code intelligence)
├── monitors/
│ └── monitors.json # Background monitors
├── bin/ # Executables added to PATH
└── settings.json # Default settings when plugin is enabled

Important: commands/, agents/, skills/, hooks/ go at the plugin ROOT — NOT inside .claude-plugin/.


Terminal window
mkdir my-first-plugin
mkdir my-first-plugin/.claude-plugin
my-first-plugin/.claude-plugin/plugin.json
{
"name": "my-first-plugin",
"description": "A greeting plugin to learn the basics",
"version": "1.0.0",
"author": {
"name": "Your Name"
}
}
FieldPurpose
nameUnique ID and skill namespace. Skills become /my-first-plugin:skill-name
descriptionShown in the plugin manager
versionIf set, updates only come when you bump this. If omitted, every git commit is a new version
authorOptional attribution
Terminal window
mkdir -p my-first-plugin/skills/hello
my-first-plugin/skills/hello/SKILL.md
---
description: Greet the user with a friendly message
---
Greet the user named "$ARGUMENTS" warmly and ask how you can help today.
Terminal window
claude --plugin-dir ./my-first-plugin

Then try:

/my-first-plugin:hello Alex

Terminal window
# Initialize a plugin in your skills directory (auto-loaded)
claude plugin init my-tool
# Creates ~/.claude/skills/my-tool/ — loads automatically as my-tool@skills-dir
# Validate before submitting
claude plugin validate

skills/
code-review/
SKILL.md # Claude invokes this automatically when relevant
agents/
security-reviewer.md # Custom subagent
hooks/hooks.json
{
"hooks": {
"PostToolUse": [{
"matcher": "Write|Edit",
"hooks": [{"type": "command", "command": "npm run lint:fix"}]
}]
}
}
.mcp.json
{
"mcpServers": {
"my-api": {
"command": "node",
"args": ["./bin/mcp-server.js"]
}
}
}
.lsp.json
{
"go": {
"command": "gopls",
"args": ["serve"],
"extensionToLanguage": {".go": "go"}
}
}
monitors/monitors.json
[{
"name": "error-log",
"command": "tail -F ./logs/error.log",
"description": "Application error log"
}]

Each stdout line from command is delivered to Claude as a notification.

// settings.json (at plugin root)
{
"agent": "security-reviewer" // Activate a plugin agent as main thread
}

Type /plugins → graphical plugin manager → browse and install.

Terminal window
/plugin install typescript-lsp@claude-plugins-official
/plugin install my-plugin@my-marketplace
Terminal window
claude --plugin-dir ./my-plugin
claude --plugin-dir ./my-plugin.zip
claude --plugin-url https://example.com/my-plugin.zip
# Multiple plugins
claude --plugin-dir ./plugin-one --plugin-dir ./plugin-two

When installing, choose:

  • Personal (~/.claude/skills/) — all your projects
  • Project (.claude/skills/) — committed, shared with team
  • Local (project-level, not committed) — only you, this repo

Terminal window
mkdir -p my-plugin/.claude-plugin
# Create plugin.json with name, description, version
# Copy existing files
cp -r .claude/commands my-plugin/
cp -r .claude/agents my-plugin/
cp -r .claude/skills my-plugin/
# For hooks, create hooks/hooks.json from your settings.json hooks object
# Test
claude --plugin-dir ./my-plugin
# Remove originals to avoid duplicates
rm -rf .claude/commands .claude/agents .claude/skills

A marketplace is a git repository with a marketplace.json listing available plugins.

Official marketplaces:

  • claude-plugins-official — curated by Anthropic (auto-registered on first launch)
  • claude-community — third-party submissions: /plugin marketplace add anthropics/claude-plugins-community

Add your own:

/plugin marketplace add https://github.com/your-org/your-plugins

Submit to community marketplace:


After making changes to a plugin:

/reload-plugins

No need to restart Claude Code.


Ship your org’s coding standards as a plugin:

  • skills/pr-review/SKILL.md — PR checklist
  • skills/migration/SKILL.md — database migration patterns
  • hooks/hooks.json — auto-lint on file save
  • agents/security-reviewer.md — security-focused code reviewer
  • .mcp.json — connect to your internal metrics API
  • monitors/monitors.json — tail error logs in background
  • skills/incident-response/SKILL.md — incident runbook
  • .lsp.json — language server for your custom DSL
  • Enables go-to-definition, find-references, type errors
  • Trick: “A plugin is the shipping box for skills + hooks + MCP + agents.”
  • Show: install one from claude-plugins-official live.
  • They’ll trip on: forgetting /reload-plugins after installing.

Learning path:26-mcp-real-examples.md · Index · ➡ 28-agents-overview.md

Written by Fenil Patel