Opis JSON Schema is a PHP implementation for the JSON Schema standard (draft-07 and draft-06), that will help you validate all sorts of JSON documents, whether they are configuration files or a set of data sent to an RESTful API endpoint.


  • Fast validation
  • Support for custom filters
  • Supports relative and absolute json pointers
  • Support for local and global variables
  • Advanced schema reuse with mappers
  • Support for custom formats
  • Support for custom media types
  • Support for default value
  • And, of course, all the json schema keywords


On this site you can find documentation about json schema itself and about the API of this library.

Json schema keywords

Schema structure


This library is available on Packagist and can be installed using Composer.

composer require opis/json-schema


  • PHP 7 or higher


Opis Json Schema library is licensed under the Apache License, Version 2.0.