Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Expert at creating and managing Claude Code plugins that bundle agents, skills, commands, and hooks into cohesive packages. Auto-invokes when the user wants to create, structure, validate, or publish a complete plugin, or needs help with plugin architecture and best practices. Also auto-invokes proactively when Claude is about to create plugin directory structures, write plugin.json manifests, or implement tasks that involve bundling components into a plugin package.
.claude/skills/aiskillstore-building-plugins/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 319% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 434% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 197% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 979% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 260% | 0% |
You are an expert at creating Claude Code plugins. Plugins are bundled packages that combine agents, skills, commands, and hooks into cohesive, distributable units.
A plugin is a package that bundles related Claude Code components:
Plugins enable users to install complete functionality with a single command.
Use a PLUGIN when:
Use INDIVIDUAL COMPONENTS when:
Creating a plugin involves:
Component Creation: Each component type (agents, skills, commands, hooks) should follow its respective best practices. Use the corresponding building- skills for expertise on creating each type.
plugin-name/
├── .claude-plugin/
│ └── plugin.json # Required: Plugin manifest
├── agents/ # Optional: Agent definitions
│ ├── agent1.md
│ └── agent2.md
├── skills/ # Optional: Skill directories
│ ├── skill1/
│ │ ├── SKILL.md
│ │ ├── scripts/
│ │ ├── references/
│ │ └── assets/
│ └── skill2/
│ └── SKILL.md
├── commands/ # Optional: Slash commands
│ ├── command1.md
│ └── command2.md
├── hooks/ # Optional: Event hooks
│ ├── hooks.json
│ └── scripts/
├── scripts/ # Optional: Helper scripts
│ └── setup.sh
├── .mcp.json # Optional: MCP server configuration
└── README.md # Required: DocumentationThe absolute minimum for a valid plugin:
my-plugin/
├── .claude-plugin/
│ └── plugin.json
└── README.mdjson{ "name": "plugin-name", "version": "1.0.0", "description": "What the plugin does" }
json{ "name": "plugin-name", "version": "1.0.0", "description": "Comprehensive description of plugin functionality", "author": { "name": "Your Name", "email": "your.email@example.com", "url": "https://github.com/yourname" }, "homepage": "https://github.com/yourname/plugin-name", "repository": "https://github.com/yourname/plugin-name", "license": "MIT", "keywords": ["keyword1", "keyword2", "keyword3"] }
json{ "commands": "./commands/", "agents": ["./agents/agent1.md", "./agents/agent2.md"], "skills": "./skills/", "hooks": ["./hooks/hooks.json"] }
Notes:
"./commands/") to include all files in a directory["file1.md", "file2.md"]) to list specific files> ⚠️ CRITICAL FORMAT WARNING > > Arrays MUST contain simple path strings, NOT objects! > > ❌ WRONG (will silently fail to load): > json > "commands": [ > {"name": "init", "path": "./commands/init.md", "description": "..."}, > {"name": "status", "path": "./commands/status.md"} > ] > > > ✅ CORRECT: > json > "commands": [ > "./commands/init.md", > "./commands/status.md" > ] > > > This applies to all component arrays: agents, skills, commands, and hooks. > > Also note: Single-item arrays must still be arrays, not strings: > - ❌ "agents": "./agents/my-agent.md" (string - won't load) > - ✅ "agents": ["./agents/my-agent.md"] (array - correct)
json{ "mcpServers": { "server-name": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-name"], "env": { "API_KEY": "${API_KEY}" } } } }
Plugin Name:
code-review-suite, data-analytics-tools, git-workflow-automationComponent Names:
code-reviewer, test-generator)analyzing-data, reviewing-code)new-feature, run-tests)Plugins must follow semantic versioning: MAJOR.MINOR.PATCH
Examples:
1.0.0 → Initial release1.1.0 → Added new command1.1.1 → Fixed bug in existing command2.0.0 → Removed deprecated agent (breaking change)Follow these steps to create a well-structured plugin:
Ask the user:
Plan the component structure:
Example: Code Review Plugin
code-review-suite/
├── agents/
│ ├── code-reviewer.md # Deep code analysis
│ └── security-auditor.md # Security scanning
├── skills/
│ ├── reviewing-code/ # Always-on review expertise
│ └── detecting-vulnerabilities/ # Security pattern matching
├── commands/
│ ├── review.md # /review [file]
│ ├── security-scan.md # /security-scan
│ └── suggest-improvements.md # /suggest-improvements
└── hooks/
└── hooks.json # Pre-commit validationDesign Principles:
bashmkdir -p plugin-name/.claude-plugin mkdir -p plugin-name/agents mkdir -p plugin-name/skills mkdir -p plugin-name/commands mkdir -p plugin-name/hooks mkdir -p plugin-name/scripts
Use the plugin.json schema template and populate all fields:
json{ "name": "plugin-name", "version": "1.0.0", "description": "Detailed description of what this plugin provides", "author": { "name": "Author Name", "email": "email@example.com", "url": "https://github.com/username" }, "homepage": "https://github.com/username/plugin-name", "repository": "https://github.com/username/plugin-name", "license": "MIT", "keywords": ["domain", "automation", "tools"], "commands": "./commands/", "agents": "./agents/", "skills": "./skills/", "hooks": ["./hooks/hooks.json"] }
Critical Validation:
python3 -m json.tool plugin.json)Create each component using the appropriate expertise:
For Agents:
plugin-name/agents/For Skills:
plugin-name/skills/skill-name/For Commands:
plugin-name/commands/For Hooks:
plugin-name/hooks/Use the README template from {baseDir}/templates/plugin-readme-template.md.
Required Sections:
Optional Sections:
Run the validation script:
bashpython3 {baseDir}/scripts/validate-plugin.py plugin-name/
Validation Checks:
plugin.json exists and has valid JSONTesting Checklist:
.claude/plugins/ and verify Claude loads itProvide clear instructions:
markdown## Installation ### Manual Installation 1. Clone this repository 2. Symlink to Claude's plugin directory: ```bash ln -s /path/to/plugin-name ~/.claude/plugins/plugin-name ``` 3. Restart Claude Code ### Marketplace Installation (if published)
claude plugin install plugin-name
## Quick Start
1. Run your first command:
```bash
/plugin-name:command arg1 arg2
```
2. Invoke an agent:
```bash
Ask Claude to use the agent-name agent
```
3. Auto-invoked skills:
Skills activate automatically when relevant.This skill provides three plugin templates for different use cases:
File: {baseDir}/templates/minimal-plugin-template/
Use when:
Structure:
minimal-plugin/
├── .claude-plugin/plugin.json
├── commands/
│ └── main-command.md
└── README.mdFile: {baseDir}/templates/standard-plugin-template/
Use when:
Structure:
standard-plugin/
├── .claude-plugin/plugin.json
├── agents/
│ └── main-agent.md
├── commands/
│ ├── command1.md
│ └── command2.md
├── scripts/
│ └── helper.sh
└── README.mdFile: {baseDir}/templates/full-plugin-template/
Use when:
Structure:
full-plugin/
├── .claude-plugin/plugin.json
├── agents/
│ ├── agent1.md
│ └── agent2.md
├── skills/
│ ├── skill1/
│ │ ├── SKILL.md
│ │ └── scripts/
│ └── skill2/
│ └── SKILL.md
├── commands/
│ ├── cmd1.md
│ ├── cmd2.md
│ └── cmd3.md
├── hooks/
│ ├── hooks.json
│ └── scripts/
├── scripts/
│ └── setup.sh
├── .mcp.json
├── LICENSE
└── README.mdPurpose: Automate common development workflows
Components:
code-reviewer, test-generator, refactoring-assistantreviewing-code, writing-tests, refactoring-code/format, /lint, /test, /buildPreToolUse for code quality checksExample: dev-tools-suite, code-quality-automation
Purpose: Provide specialized knowledge for a domain
Components:
Example: data-analytics-tools, api-design-suite, security-analysis
Purpose: Automate repetitive tasks and processes
Components:
Example: git-workflow-automation, deployment-automation, project-scaffolding
Purpose: Connect Claude to external tools and services
Components:
Example: github-integration, jira-connector, database-tools
If you're creating plugins for the Claude Code marketplace repository, you MUST maintain the central registry.
File: .claude-plugin/marketplace.json (at repository root)
This file is the central registry for all plugins in the marketplace.
Update .claude-plugin/marketplace.json:
json{ "metadata": { "name": "Claude Code Plugin Marketplace", "version": "X.Y.Z", // ← Increment MINOR version "stats": { "totalPlugins": N, // ← Increment count "lastUpdated": "YYYY-MM-DD" // ← Update date } }, "plugins": [ // ... existing plugins ... { "name": "new-plugin-name", "source": "./new-plugin-name", // ← Path to plugin directory "description": "Plugin description", "version": "1.0.0", "category": "development-tools", // or "automation", "integration", etc. "keywords": ["keyword1", "keyword2"], "author": { "name": "Author Name", "url": "https://github.com/username" }, "repository": "https://github.com/username/repo", "license": "MIT", "homepage": "https://github.com/username/repo/tree/main/plugin-name" } ] }
Update both files:
1. Plugin's plugin.json:
2. Root marketplace.json:
json{ "metadata": { "version": "X.Y.Z", // ← Increment PATCH version "stats": { "lastUpdated": "YYYY-MM-DD" // ← Update date } }, "plugins": [ { "name": "existing-plugin", "version": "1.2.0", // ← Must match plugin's plugin.json "description": "Updated description if changed" // ... other fields } ] }
Critical: Keep Versions in Sync
marketplace.json MUST match the plugin's plugin.json versionLocation: {baseDir}/scripts/validate-plugin.py
Usage:
bashpython3 {baseDir}/scripts/validate-plugin.py /path/to/plugin/
Validates:
.claude-plugin/plugin.json existsExit Codes:
0: All validations passed1: Critical errors found2: Warnings only (non-blocking)Example Output:
✅ PLUGIN VALIDATION: my-plugin
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📋 plugin.json
✓ Valid JSON syntax
✓ Required fields present
✓ Name follows conventions
✓ Semantic versioning
📁 Directory Structure
✓ .claude-plugin/plugin.json exists
✓ All referenced paths exist
✓ README.md exists
🔧 Components (5 total)
✓ 2 agents validated
✓ 1 skill validated
✓ 2 commands validated
🔒 Security
✓ No exposed secrets
✓ Safe script permissions
📝 Documentation
⚠ README.md missing usage examples
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✅ VALIDATION PASSED (1 warning)When creating plugins:
allowed-tools in skills${API_KEY}.env to .gitignoreeval() and dynamic code executionBegin with minimal functionality:
Users should understand:
Use a naming scheme across components:
plugin-name:category:action for namespaced commands1.0.0 for initial releaseBefore publishing:
After publishing:
Comprehensive guides and examples:
When the user asks to create a plugin:
Be proactive in:
Your goal is to help users create high-quality, well-structured plugins that provide real value and follow best practices.
Plugins can implement user-configurable settings using the .claude/plugin-name.local.md pattern. This allows users to customize plugin behavior on a per-project basis.
Location: .claude/<plugin-name>.local.md in the project root
Format: YAML frontmatter + markdown body
markdown--- # Plugin configuration (YAML frontmatter) enabled: true mode: strict custom_option: value --- # Plugin Context (markdown body) Additional context or instructions that the plugin should consider. This content can be loaded by hooks or skills.
1. Hook Activation Control
markdown--- validation_enabled: true auto_format: false ---
The hook script checks this setting:
bash#!/bin/bash CONFIG_FILE=".claude/${PLUGIN_NAME}.local.md" # Quick exit if config doesn't exist [ ! -f "$CONFIG_FILE" ] && exit 0 # Parse enabled setting from frontmatter ENABLED=$(sed -n '/^---$/,/^---$/p' "$CONFIG_FILE" | grep "^validation_enabled:" | cut -d: -f2 | tr -d ' ') [ "$ENABLED" != "true" ] && exit 0 # Continue with hook logic...
2. Agent State Management
markdown--- assigned_tasks: - review-api-endpoints - update-documentation completed_reviews: 5 last_run: "2025-01-15" ---
3. Project-Specific Context
markdown--- enabled: true --- ## Project Conventions - Use TypeScript for all new code - Follow the Airbnb style guide - All API endpoints must have tests ## Domain Knowledge This project manages customer billing. Key concepts: - Subscriptions have monthly/annual cycles - Invoices generate on billing dates
Extract string/boolean fields:
bashget_setting() { local file="$1" local key="$2" sed -n '/^---$/,/^---$/p' "$file" | grep "^${key}:" | cut -d: -f2 | tr -d ' ' } ENABLED=$(get_setting ".claude/my-plugin.local.md" "enabled") MODE=$(get_setting ".claude/my-plugin.local.md" "mode")
Extract markdown body:
bashget_body() { local file="$1" sed '1,/^---$/d' "$file" | sed '1,/^---$/d' } CONTEXT=$(get_body ".claude/my-plugin.local.md")
.local.md suffix: Indicates user-local settings, should be in .gitignoremarkdown--- # my-plugin settings # Copy to .claude/my-plugin.local.md and customize # Enable/disable the plugin for this project enabled: true # Validation strictness: strict | normal | lenient mode: normal # Custom options (plugin-specific) option1: value1 option2: value2 --- # Project-Specific Context Add any project-specific information here that the plugin should consider.
In hooks (most common):
bashCONFIG=".claude/my-plugin.local.md" [ -f "$CONFIG" ] && ENABLED=$(get_setting "$CONFIG" "enabled")
In skills (via description triggers): Skills can mention checking for project settings in their workflow.
In commands (via argument defaults): Commands can read settings for default values.
Q: When should I create a plugin vs individual components? A: Create a plugin when you have 3+ related components or want to distribute functionality as a package. Individual components are fine for one-off customizations.
Q: Can I include other plugins as dependencies? A: Not directly. Document required plugins in README.md and instruct users to install them separately.
Q: How do I handle plugin updates? A: Increment version in plugin.json, update marketplace.json, document changes in README.md, and test thoroughly before releasing.
Q: Can plugins have configuration files? A: Yes! Use .plugin-name.config.json or similar. Document configuration options in README.md.
Q: What's the difference between plugin keywords and categories? A: Keywords are for search (array of strings). Categories group plugins by type (single string). Both improve discoverability.
Q: How do I deprecate a plugin component? A: Document in README.md, add deprecation notice in component description, maintain for at least one MAJOR version, then remove and bump MAJOR version.
Creating plugins is about bundling expertise into reusable, distributable packages. Follow the structure, validate thoroughly, document comprehensively, and test extensively. Plugins should feel like natural extensions of Claude's capabilities, providing value without friction.
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→pass | 9,589 | 12,982 | +35% | 1 | 1 | 0% | 2,019 | 8,452 | +319% | 0 | 0 | — |
case-02 | fail→pass | 15,607 | 8,072 | -48% | 1 | 1 | 0% | 1,590 | 8,488 | +434% | 0 | 0 | — |
case-03 | fail→pass | 21,699 | 12,853 | -41% | 1 | 1 | 0% | 3,116 | 9,242 | +197% | 0 | 0 | — |
case-04 | pass→pass | 14,187 | 26,015 | +83% | 1 | 1 | 0% | 2,335 | 9,683 | +315% | 0 | 0 | — |
case-09 | pass→pass | 6,173 | 4,980 | -19% | 1 | 1 | 0% | 1,130 | 7,664 | +578% | 0 | 0 | — |
case-05 | pass→fail | 15,144 | 14,542 | -4% | 1 | 1 | 0% | 1,765 | 7,698 | +336% | 0 | 0 | — |
case-06 | pass→pass | 16,069 | 18,446 | +15% | 1 | 1 | 0% | 2,042 | 8,544 | +318% | 0 | 0 | — |
case-07 | fail→pass | 4,297 | 6,665 | +55% | 1 | 1 | 0% | 724 | 7,813 | +979% | 0 | 0 | — |
case-08 | fail→pass | 12,118 | 5,905 | -51% | 1 | 1 | 0% | 2,203 | 7,928 | +260% | 0 | 0 | — |
case-10 | fail→pass | 9,415 | 11,567 | +23% | 1 | 1 | 0% | 894 | 8,135 | +810% | 0 | 0 | — |
case-11 | fail→pass | 20,905 | 12,637 | -40% | 1 | 1 | 0% | 3,111 | 8,095 | +160% | 0 | 0 | — |
case-12 | pass→pass | 14,509 | 11,842 | -18% | 1 | 1 | 0% | 1,522 | 8,194 | +438% | 0 | 0 | — |
case-13 | pass→pass | 13,079 | 9,799 | -25% | 1 | 1 | 0% | 1,412 | 7,725 | +447% | 0 | 0 | — |
case-14 | pass→fail | 19,226 | 15,712 | -18% | 1 | 1 | 0% | 2,753 | 8,863 | +222% | 0 | 0 | — |
case-15 | pass→pass | 5,187 | 5,603 | +8% | 1 | 1 | 0% | 937 | 7,853 | +738% | 0 | 0 | — |
case-16 | pass→pass | 22,503 | 4,883 | -78% | 1 | 1 | 0% | 2,058 | 7,698 | +274% | 0 | 0 | — |
case-17 | fail→pass | 12,036 | 9,137 | -24% | 1 | 1 | 0% | 1,227 | 7,534 | +514% | 0 | 0 | — |
case-18 | pass→pass | 9,469 | 5,912 | -38% | 1 | 1 | 0% | 1,557 | 7,852 | +404% | 0 | 0 | — |
case-19 | pass→pass | 12,483 | 4,732 | -62% | 1 | 1 | 0% | 1,254 | 7,684 | +513% | 0 | 0 | — |
case-20 | fail→pass | 20,310 | 11,211 | -45% | 1 | 1 | 0% | 2,532 | 7,879 | +211% | 0 | 0 | — |
case-21 | pass→pass | 15,442 | 8,152 | -47% | 1 | 1 | 0% | 1,738 | 8,202 | +372% | 0 | 0 | — |
case-22 | pass→pass | 13,169 | 7,038 | -47% | 1 | 1 | 0% | 2,375 | 8,221 | +246% | 0 | 0 | — |
case-23 | pass→pass | 8,170 | 9,424 | +15% | 1 | 1 | 0% | 1,334 | 7,552 | +466% | 0 | 0 | — |
case-24 | pass→pass | 11,424 | 4,744 | -58% | 1 | 1 | 0% | 1,909 | 7,680 | +302% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 24 cases were attempted. The headline lift of +29 percentage points is the difference between those two pass rates over the 24 comparable cases. 2 cases got worse with the skill loaded, and they are included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.