Skip to content
Colour Lab

Tailwind Shade Generator

Tailwind color palette generator: turn one colour into a full 50 to 950 shade scale, as a Tailwind config or CSS variables in hex or OKLCH.

  • #tailwind color palette
  • #tailwind color generator
  • #tailwind shades
  • #tailwind
  • #shades
  • #colour scale
  • #palette
  • #css
100% client-side

Runs in your browser. Your data never leaves this device.

The Workbench
Tailwind Shade Generator — workspaceLive
Network requests0
Bytes uploaded0
Trackers fired0
The Guide

About Tailwind Shade Generator

/01 Turning one colour into a full Tailwind scale

Tailwind expects each colour to come as a numbered scale from 50 through 950. Hand-mixing eleven consistent steps is tedious and usually produces a scale that drifts in hue or bunches up in the middle.

Give this generator one colour and it produces the whole ramp, ready to paste into your theme configuration.

/02 What makes a good colour ramp

The steps should feel evenly spaced in lightness, hold a consistent hue, and stay usable at both ends — 50 light enough for a subtle background, 950 dark enough for text. Ramps built by naively mixing with white and black tend to go chalky at the top and muddy at the bottom.

In practice the 500 step anchors the scale, the 50 to 200 range covers backgrounds and hover states, and the 700 to 950 range handles text and borders that need to pass contrast checks.

/03 Generating a custom Tailwind color palette

Tailwind's built-in colours each come as eleven shades, 50 through 950. A custom brand colour needs the same structure, so it can use every utility, from bg-brand-50 for subtle backgrounds to text-brand-900 for strong headings. Building that ramp by hand usually produces uneven steps and muddy dark shades.

Pick a base colour and choose a generation mode. Classic follows the familiar Tailwind feel, Luminance Anchored spaces the steps evenly in perceived brightness, Vivid keeps saturation strong across the scale, and Muted produces softer, greyer shades. Hue shift nudges the hue as shades get lighter and darker, which mimics how real pigments behave and stops the dark end looking dull. Name the colour and copy the result as a Tailwind config block, as CSS variables, or as CSS variables in OKLCH.

/04 Tailwind v4, OKLCH and CSS variables

Tailwind CSS v4 moved configuration into CSS and defines its default palette in OKLCH, a colour space where equal numeric steps look like equal steps to the eye. That makes OKLCH variables the natural choice for a v4 project: declare them inside the @theme block, such as --color-brand-500, and the matching utilities appear automatically.

Tailwind v3 projects still use the JavaScript config, so copy the config output into theme.extend.colors there. Either way, keep your brand colour near the 500 or 600 step, since that is where most buttons and links will pull from.

FAQ

Questions about Tailwind Shade Generator.

How do I add the scale to Tailwind?
Paste it into the theme colours in your Tailwind config (or your CSS theme block in v4), under a name of your choosing. The numbered keys then work with every colour utility.
Which step should my brand colour be?
Usually 500, the midpoint of the scale. If your brand colour is notably light or dark, anchor it where it naturally falls so the rest of the ramp stays usable.
Will every step pass contrast on white?
No — the lighter steps are meant for backgrounds, not text. Check any step you intend to set text in against its background before shipping it.
How do I add custom colors in Tailwind CSS v4?
Add CSS variables inside the @theme block in your main stylesheet, for example --color-brand-500: oklch(...). Tailwind generates utilities such as bg-brand-500 and text-brand-500 from those names automatically.
How do I add custom colors in Tailwind v3?
Paste the generated scale into theme.extend.colors in tailwind.config.js under a name such as brand. Using extend keeps the default Tailwind colours available alongside your own.
What are Tailwind color shades 50 to 950?
They are lightness steps of one colour. 50 is the lightest, used for tinted backgrounds, 500 to 600 is usually the core colour for buttons and links, and 900 to 950 is the darkest, used for text and deep backgrounds.
Related
Colour Converter

Convert hex to RGB, and between HSL, OKLCH, LAB, LCH and OKLAB, with a colour picker and every format shown at once.

hex to rgbrgb to hexcolor code converter
Contrast Checker

WCAG contrast checker: test any text and background colour pair against WCAG 2.1 AA and AAA ratios, with a live preview.

contrast checkerwcag contrastcolor contrast checker
Harmony Generator

Color harmony generator: build complementary, triadic, analogous, split-complementary, tetradic and monochromatic schemes from one colour.

color harmonycomplementary colorscolor wheel generator
Gradient Generator

CSS gradient generator for linear, four-corner and mesh gradients with optional grain. Copy the CSS or export a PNG background.

gradient generatorcss gradientbackground gradient generator
Pixel Picker

Color picker from image: upload a photo or screenshot and sample the exact hex colour of any pixel with a magnified zoom loupe.

color picker from imagehex color from imageimage color picker
Palette Extractor

Color palette from image: extract dominant, vibrant, muted, warm or cool colours from any photo, with hex codes to copy.

color palette from imageextract colors from imageimage to color palette
Palette Generator

Color combination generator: create colour palettes from a seed colour with multiple strategies, lock colours you like, and export them.

color combination generatorcolor palette generatorcolor scheme generator
Palette Collection

Browse 284 curated color palettes across artistic, nature, vintage, modern, soft, bold, seasonal and monochrome styles, and copy any colour.

color palettescolor palette ideashex color palettes
Colour Blindness Simulator

Color blindness simulator: preview an image or colour as people with protanopia, deuteranopia, tritanopia and five other colour vision types see it.

color blindness simulatorcolor blind simulatorred green color blindness