Claude Skill Structure

Skill DevelopmentPublished 2026-12-01Author: SkillKey Skills Marketplace
claude-skill-structureclaude-skill-frontmatterskill-mdmulti-file-skillagent-skills
What's inside a Claude skill: the SKILL.md file structure, every frontmatter field with real usage data, and how top repositories organize multi-file skills.

Claude skill structure is a small contract: one directory, one SKILL.md entry file, and optional folders for anything the instructions need at runtime. The contract matters because the client discovers the folder, reads the description first, and only then loads the body. A clean structure makes that sequence predictable; a messy one makes a valid skill look broken. This guide maps the file skeleton, the frontmatter fields, and the choices real repositories make.

Claude Skill Structure: The File Skeleton

The minimum is a directory whose name matches the skill name, with a SKILL.md file inside. Anthropic's README describes the contract this way: “Each skill is self-contained in its own folder with a SKILL.md file containing the instructions and metadata that Claude uses.” A skill that needs helpers adds sibling folders rather than nesting another skill folder:

text
release-notes/
├── SKILL.md
├── scripts/
│   └── collect-prs.sh
├── references/
│   └── changelog-format.md
└── assets/
    └── release-template.md

A complete SKILL.md with comments looks like this:

markdown
---
name: release-notes
description: Draft release notes from merged pull requests. Use when the user asks for release notes or a changelog summary.
---

Use this skill when the user asks for release notes or a changelog summary.

1. Read merged pull requests since the last release tag.
2. Group changes into features, fixes and breaking changes.
3. Write one sentence per user-visible change.
4. Read references/changelog-format.md before formatting the output.
5. Stop when every merged pull request is represented or excluded.

Keep the output to one heading per group and one bullet per change.

The frontmatter is the discovery layer. The body is the procedure. scripts/ holds deterministic helpers, references/ holds detail that should load on demand, and assets/ holds templates or static data. Keep paths relative to the skill root and one level deep. The create guide walks through the first version; this page focuses on how to organize it once it grows.

Claude Skill Frontmatter Fields

The field table below uses the published markdown snapshot available on 2026-12-01: 2,417 SKILL.md files, of which 2,414 had parseable YAML frontmatter. Files were deduplicated by repository and path; 3 files had no parseable YAML frontmatter and were excluded. Usage is the share of the 2,414 parseable files that declare a non-empty value.

FieldRequiredWhat it doesCommon mistakeUsage
nameYesIdentifies the skill and must match the folderUppercase, underscores, or a name that differs from the directory99.8%
descriptionYesRouting signal for matchingToo vague, or trigger words buried at the end99.9%
metadataNoLabels such as version or ownerTreated as a version resolver when clients only read it as data57.7%
licenseNoRecords the termsMissing when the skill is copied into another repository44.9%
compatibilityNoNotes environment requirementsWritten as marketing copy instead of a constraint24.6%
allowed-toolsNoPre-approves tools in supported clientsAssumed to work in every client17.3%
versionNoLabels a top-level revisionExpected to trigger automatic upgrades5.8%
user-invocableNoHides a skill from the slash menu when falseUsed when the goal was to stop automatic loading5.5%
disable-model-invocationNoMakes a skill manual-onlyConfused with user-invocable1.2%
pathsNoLimits automatic activation to matching filesA glob that never matches the working files0.3%

Two numbers stand out. Across 2,411 descriptions, the average was 364 characters and the median 304, far below the 1,024-character limit: most skills describe the task and trigger in a few sentences. And 75 of the 2,414 parseable files, or 3.1%, had a name that did not match the parent directory in an exact string comparison. That mismatch is cheap to fix and expensive to debug later.

The snapshot also contains client- or vendor-specific keys: parent (8.5%), tags (6.2%), model (4.7%), triggers (3.4%), argument-hint (3.2%), od (3.0%) and when_to_use (2.2%). These are not part of the shared required set. The version row counts only the top-level key; many repositories put a version under metadata instead.

When Should a Claude Skill Use Multiple Files?

A single-file skill is the right default. If the procedure fits in SKILL.md, adding folders only increases the number of paths that can break. A small skill is easier to review, easier to copy and easier to test.

Move to multiple files when one of three conditions appears. A step can be made deterministic, so it belongs in scripts/. A reference is long enough that loading it on every run wastes context, so it belongs in references/. The output needs a template or static data, so it belongs in assets/.

Do not split a skill just because the repository looks more professional with folders. Every extra file adds a path that must resolve relative to the skill root. The test is whether the main SKILL.md becomes shorter and clearer after the split. If it does not, the split is cosmetic.

How Three Repositories Organize Skills

Anthropic's anthropics/skills is the most reference-heavy example. Its document skills, such as docx, pdf, pptx and xlsx, pair a SKILL.md with scripts and reference material because the work involves file formats and repeatable transformations. This structure suits skills where correctness depends on a deterministic helper and a long specification.

OpenAI's openai/skills is the opposite shape. Its curated skills are narrow task folders, such as cli-creator, gh-address-comments and define-goal, with a single job and a short trigger description. Many directories carry their own LICENSE.txt. This suits teams that want small, auditable procedures rather than a large workflow library.

Sentry's getsentry/skills sits between the two. Some skills are single-file review checklists, while others point to references/ for deeper material; prompt-optimizer, for example, routes different request types to different reference files. This is a useful model for internal engineering skills: keep the entry file short, and load detailed guidance only when the request needs it.

Choose by failure mode. If the skill fails because the procedure is hard to repeat, add scripts. If it fails because the instructions are too long to load, add references. If it fails because the trigger is unclear, shorten the description before adding anything else.

A Claude Skill Structure Checklist

  • SKILL.md sits directly inside the skill folder.
  • The folder name matches the name field exactly.
  • description names the task and the trigger in the first sentence.
  • Long references live in references/, not in the main file.
  • Repeated or risky steps live in scripts/.
  • Templates and static data live in assets/.
  • No foo/foo/SKILL.md or bare foo.md remains.
  • The skill is tested with one positive and one negative prompt.

For the trigger test itself, follow the steps in how to create a Claude skill; this page only owns the structure. For team rules around descriptions, scripts and versions, read Claude skills best practices. For upgrades and cleanup, see how to update or remove a Claude skill. For the concept behind the folder, read what Claude skills are. To compare installable examples, browse the skill catalog.

FAQ

What is the basic structure of a Claude skill?

A Claude skill is a directory containing SKILL.md. The file begins with YAML frontmatter for name and description, followed by Markdown instructions. Optional scripts, references and assets live in sibling folders.

What is the frontmatter structure of a Claude skill?

The required fields are name and description. Optional fields include license, metadata, compatibility, allowed-tools, version, user-invocable, disable-model-invocation and paths, depending on the client.

When should a Claude skill have multiple files?

Add files when the procedure needs a deterministic script, a long reference that should not load every time, or a template or static asset. Keep a single SKILL.md when the whole procedure fits in one readable file.

Does Claude skill structure differ between repositories?

The folder contract is the same, but repositories make different choices. Anthropic's document skills use scripts and references, OpenAI's curated skills stay narrow and task-specific, and Sentry's skills range from single files to reference-backed workflows.

Related Terms

SKILL.md
The required entry file of a skill, containing YAML frontmatter and the Markdown instructions an agent follows.— Agent Skills specification
Frontmatter
The YAML block between --- markers at the top of SKILL.md that declares fields such as name and description.— Agent Skills specification
Progressive disclosure
A loading model that keeps metadata in context first and reads the full instructions and resources only when the skill is selected.— Agent Skills specification
Reference file
A supporting document inside a skill folder that the instructions load only when a step needs that detail.— Agent Skills specification

Sources