Design Token Set Generator

Complete design token collections for design systems

Generates design token sets following the W3C Design Tokens (DTCG) format: color ramps, a modular type scale, spacing, shadows, and border-radius tokens with $value and $type. Reproducible from a seed, in your browser. It runs free in your browser on Gera Tools, with nothing uploaded.

Last updated Source: Gera Tools

What format are the tokens in?

They follow the W3C Design Tokens Community Group (DTCG) draft format. Each token is an object with a $value and a $type, and tokens are nested under group names like color, spacing, and shadow.

On-brand design tokens in seconds

A design token set is the single source of truth for the visual decisions in a design system: which blues, which font sizes, which spacing steps. This tool generates a complete, internally consistent set following the W3C Design Tokens (DTCG) format, so you can prototype a system or seed a tokens pipeline without hand-writing JSON.

How it works

Each token group is built from a single integer seed using a small mulberry32 pseudo-random generator, so output is fully reproducible.

  • Color ramps are generated in HSL. A base hue comes from the seed; the accent hue is offset by roughly 150 to 210 degrees so the two stay complementary. Each ramp has 10 lightness steps from 100 (light) to 1000 (dark), converted to hex.
  • Type scale uses a 1.25 modular ratio on a 16px base: base * 1.25^(i-2).
  • Spacing and border-radius use a 4px-based scale.
  • Shadows emit a structured DTCG shadow object with color, offset, blur, and spread.

Each leaf token is an object such as:

{ "$value": "#2f6fed", "$type": "color" }

What the DTCG format means

The W3C Design Tokens Community Group (DTCG) draft format defines a standard JSON shape for tokens so that tooling from different vendors can read the same file. Each token looks like this:

{
  "color": {
    "primary": {
      "500": { "$value": "#2f6fed", "$type": "color" }
    }
  }
}

The $value field holds the actual value; $type tells tooling how to interpret it (color, dimension, shadow, etc.). Token transformers like Style Dictionary read this shape and output CSS variables, Sass maps, iOS Swift constants, Android XML, or any other format your platform needs.

Using the seed for reproducibility

The seed is an integer that fully determines the generated set. Two important uses:

  1. Brand consistency across sessions: Note the seed when you find a palette you like. Entering the same seed on any device or browser will reproduce the identical token set.
  2. Testing a token pipeline: Use a fixed seed to produce a known, stable input for integration tests of your Style Dictionary config or design-token build step.

Token groups and their intended roles

GroupTokensUse in a component
Color primary10 lightness steps (100–1000)Button background, link text, focus ring
Color accent10 lightness stepsBadges, callouts, illustration accents
Typography7 size steps, weight, line-heightHeading and body text
Spacing8 steps on a 4px basePadding, margin, gap
Border-radius4 stepsCards, buttons, avatars
Shadow3 elevation levelsCards, modals, tooltips

Tips

  • Use the same seed across runs to keep a brand consistent between mockups.
  • The output is a draft DTCG document, so it transforms cleanly with tools like Style Dictionary into CSS variables or platform formats.
  • Always check the rendered ramp for contrast before shipping; the generator aims for harmony, not WCAG guarantees.
  • The 1.25 modular scale for typography is a popular choice for small-to-medium product UIs. If you need a more dramatic scale for a marketing site, consider scaling the base values up after export.