Token Layer
The token layer is the foundation where semantic design tokens define color roles, contrast guarantees, and perceptual relationships before any component gets built. It turns raw primitives like hex codes into meaningful decisions like text-contrast-on-subtle or border-interactive. These tokens carry the WCAG ratios or APCA scores so accessibility is enforced at the point of selection rather than during final review. Modern systems solve contrast problems here because once the token is set correctly every usage inherits the safety. Designers pick roles instead of colors. Engineers consume the same values across web and native. Brand updates propagate without breaking audits. This approach kills the myth that accessible design must look like gray airport signage. The article on accessible color contrast shows exactly why this matters. Low contrast remains the top accessibility failure because most teams treat it as a visual judgment instead of a system rule. The token layer fixes that by making the rule part of the definition.
The token layer is not a color palette. It is not a set of arbitrary hex values named with numbers. It is not the final UI that users see. Those come later. If your tokens lack semantic meaning or fail to encode contrast rules against specific backgrounds then you have a primitive scale at best. Real token layers make certain combinations impossible. A non compliant color pair should not even exist in the system. Anything less and you are still asking designers to remember rules instead of removing the possibility of breaking them.
Look at concrete examples from teams that got this right. Radix Colors created 12 step scales with explicit role tokens like text, textContrast, solid and solidHover. Step 11 and 12 are engineered to pass WCAG AA against all background steps of the same family. No designer needs to run a contrast checker. The role itself is the guarantee. Material Design 3 uses on- tokens. on-primary always meets 4.5 to 1 against primary. Google shipped this in 2022 across Android and web properties cutting contrast related issues significantly. GitHub Primer documents exact ratios next to every token. Their fg.default on bg.default carries a published 15.8 to 1 ratio. Every semantic token includes this data so the entire team skips manual validation. Adobe Spectrum built scales in perceptual uniformity using a custom model close to OKLCH. Swapping brand hues never breaks contrast because every step was designed for equal perceived brightness. Shopify Polaris refreshed their system in 2022 adding semantic color tokens with both WCAG and APCA values published. They maintain separate sets for light and dark modes ensuring text-default resolves safely in both. Linear in 2023 split their signature purple into brand-purple for large decorative use and action-purple for all buttons links and icons. Only action-purple tokens are constrained to pass 4.5 to 1 and 3 to 1 non text rules against every surface token. IBM Carbon maintains a deep token hierarchy that distinguishes decorative from functional colors with explicit contrast minimums listed in their documentation since version 10 in 2020. Tailwind CSS added semantic dark mode tokens in 2023 that encode contrast directly so bg-surface-100 only pairs with text that clears both WCAG and APCA thresholds. These systems prove the layer works at real scale with millions of users.
The token layer also enables smarter workflows. Contrast gets validated when tokens are first authored locking the allowed surfaces for each role. Component commits trigger Storybook tests with axe core. Design files use plugins that understand token roles. Production scans catch dynamic content. This is the layered approach that actually works at scale. Teams that master the token layer use three techniques to keep personality intact. They split accent colors into brand moments and accessible action colors like Linear did with their purples. They build on perceptually uniform models so hue changes do not destroy contrast like Spectrum and Radix. They treat dark mode as a first class parallel token set where text-default resolves to different values that each pass their own contrast tests.
Use this token layer approach when your product has multiple designers multiple platforms or real legal exposure from the European Accessibility Act or Section 508. Deploy it when you want brand teams and accessibility officers to work from the same foundation instead of fighting at launch. It is essential for any system that must survive brand refreshes without regression. Avoid the full semantic token investment on one off campaigns or tools with tiny user bases. Manual contrast checking with WebAIM or Stark works fine when the surface area is small and changes are rare. The moment your interface ships to thousands of users with varying vision needs or when audits become part of the roadmap the token layer becomes non negotiable. Without it you choose between a boring desaturated brand or constant compliance failures.
Accessibility lives at the token layer or it does not live at all.
Read the full guide
Related terms
Keep exploring
Design Tokens
The atomic design values (colors, spacing, typography, shadows, motion) stored as platform-agnostic variables that every component in a design system references.
Semantic Tokens
Design tokens that assign meaning to raw values. Instead of referencing color-blue-500 directly, components reference color-primary, which resolves to the appropriate raw value.
Color Tokens
Named color variables tied to roles in a design system rather than raw hex values, so the same role can resolve to different colors in different themes.
Design System
A design system is the living product of tokens, components, patterns, guidelines, and governance that stops teams from reinventing UI every sprint.