Theme Generator
Turn one brand color into an 11-step OKLCH scale and light and dark theme tokens, preview them on real React components and export CSS, Tailwind or JSON.
Brand color
Any CSS color: hex, rgb(), hsl() or oklch().
Fill
Every step sits at a fixed lightness, so buttons and text pass WCAG AA for any hue. Your color may move a little.
Scale
50
oklch(97.5% 0.013 293)
100
oklch(94.5% 0.029 293)
200
oklch(89% 0.059 293)
300
oklch(81% 0.105 293)
400
oklch(71% 0.167 293)
500
oklch(62% 0.224 293)
600, nearest your color
oklch(54% 0.247 293)
700
oklch(47% 0.224 293)
800
oklch(40% 0.192 293)
900
oklch(34% 0.15 293)
950
oklch(27% 0.106 293)
● marks the step nearest your color.
Preview on VaneUI components
Light
on white
Your workspace now uses the new brand theme.
Shown on your public profile.
Read the theming guide or run npm i @vaneui/ui.
Dark
on gray-950
Your workspace now uses the new brand theme.
Shown on your public profile.
Read the theming guide or run npm i @vaneui/ui.
Contrast (WCAG 2.2 AA)
All checks passLight
Accent text on the page
7.68:1
Pass 4.5:1Accent text on the accent tint
7.13:1
Pass 4.5:1Text on the filled button
5.73:1
Pass 4.5:1Text on the hovered button
7.68:1
Pass 4.5:1Focus ring on the page
5.73:1
Pass 3:1Dark
Accent text on the page
7.40:1
Pass 4.5:1Accent text on the accent tint
5.74:1
Pass 4.5:1Text on the filled button
7.68:1
Pass 4.5:1Text on the hovered button
10.16:1
Pass 4.5:1Focus ring on the page
7.40:1
Pass 3:1Export
VaneUI CSS sets the accent color for every component. Load it after the VaneUI stylesheet. The other formats give you the same scale for any codebase.
theme.css
/* Put this after the VaneUI stylesheet */:root { --color-text-accent: oklch(47% 0.224 293); --color-text-filled-accent: oklch(100% 0 0); --color-bg-accent: oklch(97.5% 0.013 293); --color-bg-hover-accent: oklch(94.5% 0.029 293); --color-bg-active-accent: oklch(89% 0.059 293); --color-bg-filled-accent: oklch(54% 0.247 293); --color-bg-filled-hover-accent: oklch(47% 0.224 293); --color-bg-filled-active-accent: oklch(40% 0.192 293); --color-border-accent: oklch(81% 0.105 293); --color-focus-accent: oklch(54% 0.247 293);}
:root[data-theme],[data-theme]:not(:root) { --color-text-accent: light-dark(oklch(47% 0.224 293), oklch(71% 0.167 293)); --color-text-filled-accent: light-dark(oklch(100% 0 0), oklch(100% 0 0)); --color-bg-accent: light-dark(oklch(97.5% 0.013 293), oklch(27% 0.106 293)); --color-bg-hover-accent: light-dark(oklch(94.5% 0.029 293), oklch(34% 0.15 293)); --color-bg-active-accent: light-dark(oklch(89% 0.059 293), oklch(27% 0.106 293)); --color-bg-filled-accent: light-dark(oklch(54% 0.247 293), oklch(47% 0.224 293)); --color-bg-filled-hover-accent: light-dark(oklch(47% 0.224 293), oklch(40% 0.192 293)); --color-bg-filled-active-accent: light-dark(oklch(40% 0.192 293), oklch(34% 0.15 293)); --color-border-accent: light-dark(oklch(81% 0.105 293), oklch(47% 0.224 293)); --color-focus-accent: light-dark(oklch(54% 0.247 293), oklch(71% 0.167 293));}Free, runs in your browser, and nothing you enter leaves it. Read the idea behind it in Dark mode tokens with light-dark() and Tailwind CSS v4.