Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. JSON
  3. json-schema-benchmark

json-schema-benchmark

MITJavaScript

Performance benchmark and test suite for Node.js JSON-schema validators, evaluating speed, spec compliance, and side-effects.

GitHubGitHub
387 stars39 forks0 contributors

What is json-schema-benchmark?

json-schema-benchmark is a benchmarking and testing suite for Node.js JSON-schema validators. It evaluates validators based on performance, compliance with the official JSON-schema test suite, and absence of side-effects, helping developers choose the most suitable validator for their needs.

Target Audience

Node.js developers, backend engineers, and teams working with JSON-schema validation who need to compare validator performance, correctness, and safety for data validation tasks.

Value Proposition

It provides objective, comprehensive benchmarks that go beyond speed to include spec compliance and side-effect checks, offering a holistic view of validator quality that isn't available in individual validator documentation.

Overview

Benchmarks for Node.js JSON-schema validators

Use Cases

Best For

  • Comparing performance of JSON-schema validators for high-throughput applications
  • Ensuring validator compliance with official JSON-schema specifications
  • Identifying validators that avoid side-effects on input data
  • Evaluating validator options for draft4, draft6, and draft7 schema versions
  • Making data-driven decisions when selecting validation libraries
  • Testing validator correctness against comprehensive test suites

Not Ideal For

  • Projects requiring validation in browsers or other non-Node.js environments
  • Teams needing benchmarks for JSON-schema drafts beyond draft7 (e.g., 2019-09, 2020-12)
  • Developers looking for a quick, subjective 'best validator' recommendation without data analysis

Pros & Cons

Pros

Comprehensive Performance Metrics

Measures relative speed and test runs per second for over 20 validators, with clear charts and tables showing Ajv as the fastest at 17000 tests/sec.

Spec Compliance Verification

Tests against the official JSON-schema test suite for draft6, identifying failing tests, with @exodus/schemasafe having only 8 failures.

Side-Effect Safety Check

Detects validators that alter input data or schemas, highlighting risks with libraries like revalidator which caused 818 side-effects.

Multi-Draft Support

Covers draft4, draft6, and draft7 versions, allowing developers to benchmark validators across common schema standards.

Cons

Potentially Outdated Data

Uses specific validator versions (e.g., ajv 6.12.6) that may not reflect latest updates, and updates depend on community contributions.

Limited Feature Coverage

Admits it doesn't account for advanced validator features like custom keywords or async validation, which could be crucial for some use cases.

Node.js Only Focus

Exclusively benchmarks Node.js validators, ignoring browser-based or other language implementations, limiting its scope.

Frequently Asked Questions

Quick Stats

Stars387
Forks39
Contributors0
Open Issues4
Last commit2 years ago
CreatedSince 2015

Tags

#developer-tools#performance-testing#validation#spec-compliance#json-schema#nodejs#testing-tools#benchmark

Built With

N
Node.js

Included in

JSON1.5k
Auto-fetched 19 hours ago

Related Projects

ajvajv

The fastest JSON schema Validator. Supports JSON Schema draft-04/06/07/2019-09/2020-12 and JSON Type Definition (RFC8927)

Stars14,780
Forks1,003
Last commit2 months ago
jsonschemajsonschema

An implementation of the JSON Schema specification for Python

Stars4,966
Forks641
Last commit1 day ago
JSON Schema for PHPJSON Schema for PHP

JSON Schema for PHP

Stars3,630
Forks369
Last commit3 days ago
Ruby JSON Schema ValidatorRuby JSON Schema Validator

Ruby JSON Schema Validator

Stars1,645
Forks247
Last commit19 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub