Turn one brand color into a complete Tailwind-style 50–950 shade palette, generated perceptually in OKLCH — exported as v3 config, v4 @theme, CSS variables or JSON.
Generated locally in your browser — your colors, settings and code never leave this page.
Why generated palettes usually look wrong — and this one does not
Naive shade generators lighten and darken in RGB or HSL, which shifts perceived hue and makes light shades washy and dark shades muddy. This generator works in OKLCH — the perceptual color space Tailwind v4 itself adopted — targeting lightness steps calibrated against Tailwind’s own palettes, scaling chroma toward the ends, and holding your hue constant. The result sits naturally next to the built-in colors.
Worked example
Base #3b82f6 named brand produces eleven shades; the v4 export looks like:
@theme {
--color-brand-50: oklch(98.5% 0.021 259.8);
--color-brand-500: oklch(62% 0.188 259.8);
--color-brand-950: oklch(27% 0.103 259.8);
/* …all 11 shades… */
}After adding that block, utilities like bg-brand-500, text-brand-50 and border-brand-300 exist automatically.
Export formats
- Tailwind v3 — hex values under
theme.extend.colorsin tailwind.config.js. - Tailwind v4 — an @theme block with oklch() values.
- CSS variables — framework-free custom properties.
- JSON — for token pipelines and scripts.
Accessibility notes
- Swatch labels automatically use black or white text by real contrast ratio — the same check you should apply to your UI: verify text pairs in the WCAG Contrast Checker.
- As a rule of thumb from Tailwind’s own palettes: white text works from ~600 upward, dark text below ~400; the 400–500 band needs checking case by case.
Limitations
- Very light or very dark base colors produce compressed scales — the tool anchors your color at 500, so a near-white base leaves little room above it. Pick a mid-tone base where possible.
- Extremely high-chroma bases get gamut-clamped at some steps (hue kept, chroma reduced) so every hex stays displayable.
How to use the Tailwind Color Palette Generator
- Pick your base color — it becomes the 500 shade of the palette.
- Name the color (this becomes the class name: bg-brand-500).
- Watch the 50–950 swatch row update live.
- Choose an export format — v3 config, v4 @theme, CSS variables or JSON — then copy or download.
Frequently asked questions
How are the shades generated?
In OKLCH, the perceptual color space Tailwind v4 itself uses: each shade targets a lightness step calibrated against Tailwind's own palettes, with chroma scaled toward the light and dark ends and your hue held constant. That is why the scale looks like it belongs in Tailwind rather than like a naive lighten/darken ramp.
Which shade should my brand color be?
The 500 slot is the conventional anchor — this tool puts your input there. If your brand color is very light or very dark, consider picking the generated shade that best matches it and re-anchoring your usage instead of forcing a light color to act as a 500.
What is the difference between the v3 and v4 exports?
v3 wants hex values inside tailwind.config.js under theme.extend.colors; v4 wants CSS custom properties in an @theme block, and this tool emits those as oklch() values — the same format Tailwind v4's own palette uses.
Does this cover "Tailwind shades generator" too?
Yes — a shades generator and a palette generator are the same operation (one color → the 50–950 scale), so they are one tool here rather than two thin pages.