Anatomy of a Token
Token Structure
Section titled “Token Structure”A design token is a JSON object. Spec-defined properties use a dollar prefix ($); group and token names defined by you do not.
Core Properties
Section titled “Core Properties”$value (required unless $ref is used)
Section titled “$value (required unless $ref is used)”The token’s value. Every token must provide either $value (a direct value or curly-brace alias) or $ref (a JSON Pointer reference) — but not both.
{ "color": { "brand": { "primary": { "$type": "color", "$value": { "colorSpace": "srgb", "components": [0, 0.4, 0.8] } } } }, "spacing": { "md": { "$type": "dimension", "$value": { "value": 16, "unit": "px" } } }}$type (required or inherited)
Section titled “$type (required or inherited)”The token’s type. Can be set directly on the token or inherited from a parent group. Every token must have a determinable type — either its own $type property or one inherited from an ancestor group. Valid types: color, dimension, fontFamily, fontWeight, duration, cubicBezier, number, shadow, typography, border, strokeStyle, transition, gradient.
$description (optional)
Section titled “$description (optional)”Human-readable description for the token.
{ "color": { "brand": { "primary": { "$type": "color", "$value": { "colorSpace": "srgb", "components": [0, 0.4, 0.8] }, "$description": "Primary brand color used for CTAs and links" } } }}$deprecated (optional)
Section titled “$deprecated (optional)”Marks a token as deprecated. Use a boolean or a string message.
{ "$type": "color", "$value": { "colorSpace": "srgb", "components": [0.8, 0, 0.4] }, "$deprecated": "Use color.brand.primary instead"}$extensions (optional)
Section titled “$extensions (optional)”Vendor-specific metadata reserved for tooling.
{ "$type": "color", "$value": { "colorSpace": "srgb", "components": [0, 0.4, 0.8] }, "$extensions": { "com.figma": { "styleId": "S:abc123" } }}Group Nesting
Section titled “Group Nesting”Tokens can be nested in groups. Group names become part of the token path (e.g. color.brand.primary). Groups can set $type so all children inherit it.
{ "color": { "$type": "color", "brand": { "primary": { "$value": { "colorSpace": "srgb", "components": [0, 0.4, 0.8] } }, "secondary": { "$value": { "colorSpace": "srgb", "components": [0.4, 0.4, 0.4] } } } }}Here, color.brand.primary and color.brand.secondary both have type color from the group.
$root (optional)
Section titled “$root (optional)”A root token for a group. The $root token provides a base value for the group while allowing nested variants or extensions.
{ "spacing": { "$type": "dimension", "$root": { "$value": { "value": 16, "unit": "px" } }, "small": { "$value": { "value": 8, "unit": "px" } }, "large": { "$value": { "value": 24, "unit": "px" } } }}$extends (optional)
Section titled “$extends (optional)”Inherits tokens and properties from another group. Uses curly-brace or JSON Pointer syntax.
{ "button": { "primary": { "$type": "color", "background": { "$value": { "colorSpace": "srgb", "components": [0, 0.4, 0.8] } } }, "secondary": { "$extends": "{button.primary}", "background": { "$value": { "colorSpace": "srgb", "components": [0.4, 0.4, 0.4] } } } }}The Dollar-Prefix Convention
Section titled “The Dollar-Prefix Convention”Spec-defined properties ($value, $type, $description, $deprecated, $extensions, $ref, $root, $extends) start with $