Skip to content
ToolZone

Tailwind Color Generator

Generate a full Tailwind CSS shade scale, from 50 to 900, for any base color, matching the structure of Tailwind's default palette.

Runs in your browser. Nothing you enter or upload leaves your device.

#3B82F6
50
#EBF3FE
100
#D8E6FD
200
#B1CDFB
300
#89B4FA
400
#629BF8
500
#3B82F6
600
#3575DD
700
#2F68C5
800
#295BAC
900
#234E94
950
#1E417B
@theme {
  --color-primary-50: #EBF3FE;
  --color-primary-100: #D8E6FD;
  --color-primary-200: #B1CDFB;
  --color-primary-300: #89B4FA;
  --color-primary-400: #629BF8;
  --color-primary-500: #3B82F6;
  --color-primary-600: #3575DD;
  --color-primary-700: #2F68C5;
  --color-primary-800: #295BAC;
  --color-primary-900: #234E94;
  --color-primary-950: #1E417B;
}

Keyboard shortcuts

Run the main action
⌘ / Ctrl + Enter
Copy the result
⌘ / Ctrl + Shift + Enter
Download the result
⌘ / Ctrl + S
Paste a file or image into file tools
⌘ / Ctrl + V
Search all tools
⌘ / Ctrl + K
Show these shortcuts
?

You can also drop files anywhere on the page.

About the Tailwind Color Generator

Tailwind Color Generator takes a single brand color and builds a full set of shades named 50, 100, 200 through 900 and 950, the same naming scheme Tailwind CSS uses for its built-in colors. You can name the color and export the scale in the format your project needs, ready to paste.

How it works

The base color becomes shade 500 unchanged. Lighter shades are made by mixing the base toward white in RGB: 400 is 20% of the way to white, 300 is 40%, 200 is 60%, 100 is 80% and 50 is 90%. Each channel is computed as c + (255 - c) x weight and rounded.

Darker shades scale each channel down toward black: 600 keeps 90% of the base, 700 keeps 80%, 800 70%, 900 60% and 950 50%. The color name is lowercased and any character other than a-z, 0-9 or a hyphen becomes a hyphen, so "Brand Green" turns into brand-green. The code is then written in the selected format with uppercase HEX values.

How to use

  1. 1

    Click the color swatch and pick your base color.

  2. 2

    Type a Color name, such as primary or brand.

  3. 3

    Review the 11 shades, and use the copy icon on any row to grab a single HEX value.

  4. 4

    Choose Tailwind v4, Tailwind v3 or CSS variables, then click Copy config and paste the code into your project.

Worked examples

Emerald brand color for Tailwind v4

A startup uses #10B981 as its brand color and calls it brand.

Input
Base #10B981, name: brand, format: Tailwind v4
Result
@theme { --color-brand-50: #E7F8F2; --color-brand-100: #CFF1E6; --color-brand-200: #9FE3CD; --color-brand-300: #70D5B3; --color-brand-400: #40C79A; --color-brand-500: #10B981; --color-brand-600: #0EA774; --color-brand-700: #0D9467; --color-brand-800: #0B825A; --color-brand-900: #0A6F4D; --color-brand-950: #085D41; }

After pasting this into your main CSS file, classes such as bg-brand-50 and text-brand-700 become available.

Same scale as CSS variables

A project without Tailwind wants the default blue as variables.

Input
Base #3B82F6, name: primary, format: CSS variables
Result
:root { --primary-50: #EBF3FE; --primary-100: #D8E6FD; ... --primary-500: #3B82F6; ... --primary-950: #1E417B; }
Limitations
Shades are produced by linear RGB mixing, not perceptual color spaces such as OKLCH, so they won't exactly match Tailwind's hand-tuned palettes. Only one color is handled at a time; build each brand color separately and merge the code. The color is chosen through the browser's picker; there's no text field for pasting a HEX code.
Assumptions
Your base color is the shade you want at 500. You're using Tailwind CSS v3 or v4, or plain CSS custom properties.
Privacy
The scale is generated in your browser and none of your colors or names are sent or saved.

Frequently asked questions

How does Tailwind's shade numbering work?+

Lower numbers are lighter and higher numbers are darker. 50 is the palest tint, 950 the deepest shade, and 500 is typically the core color.

Can I use these shades outside of Tailwind?+

Yes. Choose the CSS variables format to get a :root block that works in any stylesheet, or copy individual HEX values.

Why don't my shades match Tailwind's built-in blue?+

Tailwind's palettes are hand-tuned in OKLCH. This tool mixes toward white and black in RGB, which is predictable but slightly different.

Where do I paste the Tailwind v4 code?+

In your main CSS file, after the line that imports Tailwind. The @theme block registers the colors as utilities.

What happens if my color name has spaces or capitals?+

It's lowercased and any character other than letters, digits or hyphens is replaced with a hyphen, so "Brand Green" becomes brand-green.

Related tools