Build your own OpenClaw skills from scratch. This guide covers SKILL.md syntax, permission declarations, tool definitions, input/output schemas, testing, and publishing. Includes 5 complete skill templates you can use as starting points.
OpenClaw skills are modular capabilities defined in SKILL.md files that tell OpenClaw how to perform specific tasks. Each skill declares its name, description, required permissions, available tools, and behavioral instructions. When you install a skill with `npx clawhub@latest install
Every OpenClaw skill starts with a SKILL.md file. Here's the essential structure: ``` --- name: my-custom-skill description: What this skill does in one sentence version: 1.0.0 author: your-name tags: [category, use-case] permissions: - network # Access external APIs - filesystem # Read/write local files - system.run # Execute shell commands (use sparingly) --- # My Custom Skill You are an expert at [task]. When the user asks you to [action], follow these steps: 1. First, [step one] 2. Then, [step two] 3. Finally, [step three] ## Tools - `tool_name`: Description of what this tool does ``` The frontmatter section defines metadata and permissions. The markdown body contains behavioral instructions — this is effectively the system prompt that guides OpenClaw when the skill is active. For examples of well-structured skills, browse the AI & LLM skills or productivity skills.
Example 1: Simple Prompt Skill — A skill that formats meeting notes. No permissions needed, just instructions. Example 2: API Integration Skill — A skill that queries a weather API. Requires `network` permission. Example 3: File Processing Skill — A skill that converts CSV files to formatted reports. Requires `filesystem` permission. Example 4: Multi-Tool Skill — A skill like GPT Prompt Chainer that defines multiple tools for chaining prompts, managing context, and handling errors. Example 5: Full-Stack Skill — A skill like Browser Pilot that combines network access, system execution, and complex orchestration logic. Each template is available in our GitHub repository with full documentation and tests.
Permissions are the most important security decision in skill creation. Request only what your skill needs: `network` — Required for any skill that calls external APIs. Used by skills like Deep Research and Slack Connector. `filesystem` — Required for reading/writing local files. Used by skills like PDF Generator and Markdown Formatter. `system.run` — Execute shell commands. The most powerful and dangerous permission. Used by skills like Docker Captain and Git Assistant. Only request this if absolutely necessary. Skills requesting fewer permissions are easier to get verified and more likely to be trusted by users. Over-requesting permissions is the #1 reason skills get rejected from the verified registry.
Before publishing, test your skill thoroughly: 1. Local testing: Install your skill locally with `npx clawhub@latest install ./path/to/skill` and verify all tools work as expected. 2. Edge cases: Test with unexpected inputs, large files, API failures, and permission boundaries. 3. Security review: Run your skill through the 5-point security audit from the security guide. 4. Documentation: Write clear usage examples and include them in your README. 5. Publishing: Submit to the ClawHub registry with `npx clawhub@latest publish`. Your skill will appear in the ClawSkills directory after review. To aim for verified status, follow the security best practices in our security guide and submit your skill for formal audit through the OpenClaw GitHub repository.