Name colours and sizes by their role, not their value, so one change updates a whole theme.
Primitive tokens hold raw values; semantic tokens map them to roles. Themes swap semantics.
By Rohit Sonawane, product designer · Last reviewed 16 November 2026
Design tokens are named values for design decisions, such as colours, spacing and font sizes, stored once and used in both design files and code. Token layering adds tiers: primitive tokens hold raw values, and semantic tokens map them to roles like 'primary' or 'error'.
Components reference a role, not a hex. Then a rebrand or dark theme is one remapping, not a hundred edits.
Components reference --color-primary, never #3B82F6. Brand theme swaps the mapping.
Split tokens into two layers: primitives hold raw values (blue-500 = #3B82F6) and semantic tokens map them to roles (--color-primary points at blue-500). Components only ever reference the semantic role. Now a rebrand, a dark theme, or a white-label client is one remapping at the semantic layer, not a find-and-replace of a hex value across hundreds of files. This is how a design system ships multiple themes from a single component set.
The layering earns its keep when a system needs to theme, rebrand, or scale across products. A tiny one-off site with a single fixed palette can reference primitives directly without the ceremony. Add the semantic layer when a second theme, a rebrand, or a white-label requirement actually appears, not speculatively before there is anything to swap.
You can switch to a new theme or brand colour by changing token mappings alone, without touching any component.
A primitive token names a raw value, such as blue-500. A semantic token names a role, such as color-primary, and points to a primitive. Components use semantic tokens, so changing a theme only changes the mapping.
Because a raw value like #3B82F6 has no meaning. If the brand colour changes or you add a dark theme, you would have to find and change every use by hand.
The W3C Design Tokens Community Group is working on a shared format, and tools like Figma variables and Style Dictionary support tokens in design and code.
Your product ships under 3 brands. Each has its own color, type, radius.