Skip to main content
Home/Validator

DTCG Validator

2025.10

Real-time validator for the W3C Design Tokens Community Group specification. Paste your token JSON and get instant feedback against the Format and Color modules.

Official spec
empty
Validation Results

{ }

Paste a token file to validate it

Results update live as you type. Use Valid sample or Invalid sample above to load examples.

About

Design tokens are indivisible pieces of a design system: colors, spacing, typography. This validator checks token files against the W3C DTCG specification 2025.10.

1

Format Module

13 token types: color, dimension, fontFamily, fontWeight, duration, cubicBezier, number, strokeStyle, border, transition, shadow, gradient, typography.

Format spec
2

Color Module

14 color spaces (sRGB, Display P3, Oklch, Lab, HSL, etc.), "none" keyword, component range validation, alpha channel handling.

Color spec
3

Resolver Module

Multi-context resolution (.resolver.json): sets, modifiers, resolutionOrder. Document structure is validated.

Resolver spec

Implementation Status

Implemented

  • All 13 token types from Format Module
  • 14 color spaces from Color Module
  • Component range validation
  • "none" keyword support
  • Strict spec value forms (object-only color/dimension/duration)
  • Deep composite sub-value type validation
  • References inside composite arrays and sub-values
  • Token naming validation
  • Token references (curly brace syntax)
  • JSON Pointer $ref (RFC 6901)
  • Property-level references ($ref)
  • $extends group inheritance (+ circular detection)
  • $root reserved root tokens
  • $deprecated handling
  • Reserved-name checks ($-prefixed names)
  • Resolver module structural validation (.resolver.json)
  • Alias resolution with circular detection
  • Chained reference resolution
  • Type inheritance through references
  • Real-time error reporting

Notes & scope

  • ·All three modules covered: Format, Color, Resolver
  • ·Resolver: validates document structure (runtime input resolution is out of scope)
  • ·XYZ ranges treated as unbounded; the spec's [0,1] would reject real D65/D50 white points