Home Tutorials Categories Skills About
ZH EN JA KO
Skills-Plugins

How to Build Custom Skills for OpenClaw

· 15 min read

What Is the OpenClaw Skill System

Skills are the core mechanism for extending your AI assistant's capabilities in OpenClaw. Each Skill is essentially a SKILL.md file that uses Markdown to define a set of instructions telling the AI how to behave in specific scenarios.

Here are a few practical examples:

  • A "Daily Report" Skill that has the AI summarize your day's conversations into a structured work report
  • A "Translator" Skill that automatically translates incoming foreign-language messages while maintaining a specific translation style
  • A "Code Review" Skill that has the AI review code snippets according to your team's coding standards

The design philosophy behind the Skill system is "programming with natural language" — you don't need to write code; you just need to clearly describe what you want the AI to do.

Where Skills Are Stored

All custom Skill files go in the following directory:

~/.openclaw/skills/

Each Skill lives in its own folder containing a SKILL.md file:

~/.openclaw/skills/
├── daily-report/
│   └── SKILL.md
├── translator/
│   └── SKILL.md
└── code-review/
    └── SKILL.md

OpenClaw automatically scans this directory at startup and loads all available Skills.

SKILL.md File Structure

A complete SKILL.md file consists of two parts: YAML front matter and the Markdown instruction body.

Here's a full example — a "Smart Translator" Skill:

---
name: translator
description: "Smart translator with support for Chinese-English translation and accurate technical terminology"
trigger: "translate"
version: "1.0.0"
tags: ["translation", "language"]
author: "your-name"
enabled: true
---

## Role Definition

You are a professional translation assistant. When a user sends content that needs translating, follow these rules.

## Translation Rules

1. Automatically detect the source language and translate to the target language
2. If the source language is Chinese, translate to English
3. If the source language is English, translate to Chinese
4. If the user specifies a target language, use that instead

## Translation Style

- Technical documentation: Keep terminology accurate and sentences concise
- Casual conversation: Use natural, fluent expressions
- Business emails: Use formal, professional wording

## Output Format

Output the translation directly without additional explanation. If there's ambiguous content, add a brief note in parentheses after the translation.

## Example

User input: translate "What is the rate limit of this API?"
Output: What is the rate limit of this API?

YAML Front Matter Reference

Field Required Description
name Yes Unique identifier for the Skill; use English and hyphens
description Yes Brief description of what the Skill does
trigger No Trigger keyword; the Skill activates when a user's message contains this word
version No Version number for management and updates
tags No Tag array for categorization
author No Author information
enabled No Whether the Skill is active; defaults to true

The Markdown Instruction Body

The body is where you write your instructions to the AI, using standard Markdown. Some tips for writing effective instructions:

  • Use second-level headings (##) to organize different sections — clear structure helps the AI understand your intent
  • Provide concrete examples — examples are more effective than abstract descriptions
  • Define edge cases explicitly — tell the AI what to do in specific situations
  • Keep instructions concise — avoid overly verbose descriptions

Hands-On: Create a Daily Report Skill

Let's build a practical Skill step by step:

mkdir -p ~/.openclaw/skills/daily-report

Create ~/.openclaw/skills/daily-report/SKILL.md:

---
name: daily-report
description: "Generate a structured daily work report from today's conversations"
trigger: "daily report"
version: "1.0.0"
tags: ["productivity", "work"]
enabled: true
---

## Role Definition

You are a daily work report assistant. When the user asks you to generate a report, review today's conversation history and any information the user provides to create a structured daily report.

## Report Format

Use the following format for the report:

### Completed Today
- [List work items completed today]

### In Progress
- [List work that's underway but not yet finished]

### Plan for Tomorrow
- [List tasks planned for tomorrow]

### Notes
- [Any other information worth recording]

## Guidelines

1. Extract work-related information from conversation history; ignore casual chat
2. Keep each item concise — no more than two sentences
3. If there isn't enough information, proactively ask the user to fill in the gaps
4. Use the YYYY-MM-DD date format

Testing a Skill

After creating the Skill file, restart OpenClaw to load it:

openclaw restart

You can test through the Dashboard or any connected chat channel. Send a message containing the trigger keyword, for example:

Generate my daily report for today

If the Skill loaded correctly, the AI will respond using the format and rules you defined.

To see all currently loaded Skills:

openclaw skill list

This displays every Skill's name, status, and trigger keyword.

Debugging Tips

If a Skill isn't working as expected, try these troubleshooting steps:

1. Check the file format:

Make sure the YAML front matter is properly enclosed by --- delimiters and that the YAML syntax is valid. Common mistakes include incorrect indentation and mismatched quotes.

2. Review the load logs:

openclaw logs | grep -i skill

The logs will show the Skill's load status and any error messages.

3. Verify the trigger keyword:

Confirm that your message contains the keyword defined in the trigger field. Trigger matching is case-insensitive.

4. Simplify and iterate:

If the Skill is complex, strip the instructions down to the bare minimum first. Once you've confirmed the basics work, add complexity back gradually.

Using Skills with MCP Servers

Skills can work alongside OpenClaw's MCP Server integrations, giving the AI not only instructions to follow but also tools to execute actions. For instance, your Daily Report Skill could call a calendar MCP Server to pull in today's meetings and automatically include them in the report. This is an advanced use case — for details, see the MCP section in the OpenClaw official documentation.

Wrapping Up

The Skill system is one of OpenClaw's most extensible features. With a simple Markdown file, you can teach your AI assistant entirely new capabilities. From basic translation helpers to complex workflow automation, the possibilities are limited only by your imagination. If you build a great Skill, consider sharing it with the community on the OpenClaw GitHub repository. For more information, visit OpenClaw.

OpenClaw is a free, open-source personal AI assistant that supports WhatsApp, Telegram, Discord, and many more platforms