YAML Schema

YAML Schema is a tool to define and validate the structure and constraints of YAML documents, in YAML.

The YAML Schema specification is based on JSON Schema (https://json-schema.org/), but expressed as YAML.

It also provides a reference implementation and CLI (ys) written in Rust: the yaml-schema crate (source on GitHub).

Try it now

No install needed: the Playground lets you edit a schema and a YAML document side by side, validating as you type. Validation runs locally in your browser via WebAssembly, so nothing is sent to a server.

Open the Playground

Getting Started

If you’re new to YAML Schema, we recommend starting with these guides:

  1. Playground - Experiment in your browser without installing anything
  2. Installation - Install the ys command-line tool
  3. Basic Usage - Learn the fundamentals of schema validation
  4. Features - YAML Schema features

Getting Help


This documentation is built with Just the Docs, a modern documentation theme for Jekyll.


This site uses Just the Docs, a documentation theme for Jekyll.