Skip to content

Tailwind Color Matrix
Visualize, test and share your Tailwind palettes

By Updated at 13 min read
WCAG ratio

WCAG Contrast Ratio

The contrast ratio measures the difference in luminance between foreground text and its background. A higher ratio means better readability.

It ranges from 1:1 (no contrast) to 21:1 (max contrast).

AA Normal text: minimum 4.5:1
AA Large text (18px+): minimum 3:1
AAA Normal text: minimum 7:1

Copied to clipboard

Matrix

Pair contrast ratio: AA ≥4.5 · AAA ≥7 · Lg ≥3 (large text)
Text color (black or white) auto-picked to maximize contrast

|

Let’s be honest: picking colors is not my strong suit. I’m a developer with a marketing background, not an art director. And I’ve already wasted hours hesitating between two shades of blue.

The other problem is the back-and-forth when working with others on a project. “Do you prefer this one?” “Maybe a bit lighter?” “What if we tried a more saturated version?” The more subjective a topic is, the more time it can waste for everyone, even though colors won’t make or break the value you deliver to your users.

Rather than going on a creative tangent, I apply color theory to Tailwind’s curated palettes. Complementary, analogous, contrast ratios… Simple rules that produce professional results, and most importantly objective criteria that help make decisions.

That’s why I built this tool. You select 2 hues from the Tailwind palette, choose the shades, and the matrix displays every combination with contrast ratios calculated in real time. Each selection updates the URL: just copy-paste it to share a specific combination with your collaborators.

How to use the tool

  1. Choose the “Row” palette (your primary color) and the “Column” palette (your secondary color)
  2. Select the shades you want to compare (500, 600, 700, etc.)
  3. Toggle WCAG to see contrast ratios
  4. Click a cell to copy the combination to the clipboard
  5. Share: the URL remembers your choices and can be shared with collaborators

Color vocabulary in Tailwind

Before combining colors, you need to speak the same language. Three fundamental concepts structure every Tailwind palette.

Hue: the color family. Blue, red, amber, emerald… Each hue corresponds to a position on the color wheel. Tailwind offers 22.

Tint: white is added to the pure hue. These are the low values: 50, 100, 200, 300. The lower the number, the lighter the color.

Shade: black is added to the pure hue. These are the high values: 700, 800, 900, 950. The higher the number, the darker the color.

The 500 value represents the “pure” hue, neither lightened nor darkened. It’s the reference point for each palette.

50Tint
100Tint
200Tint
300Tint
400
500Pure
600
700Shade
800Shade
900Shade
950Shade

Tailwind splits each hue into 11 steps (from 50 to 950). This granularity lets you build complete interfaces with a single color family, just by playing with lightness.

The 60-30-10 golden rule

Borrowed from interior design, this rule is the most reliable way to distribute colors in an interface.

  • 60%: dominant color. Surfaces, backgrounds. Often white, slate-50 or zinc-100. This is what the user sees first.
  • 30%: secondary color. Text, borders, cards, navigation. Slate-800, zinc-700 or a diluted version of your brand color.
  • 10%: accent color. Buttons, links, call-to-action. This is where your blue-600 or amber-500 shines.
60% surface
30% text
10%

The matrix above helps you find the right combination for the 30% and the 10%. Try slate + blue in the matrix.

Palette strategies

The color wheel is the fundamental tool for creating harmonious palettes. Here are the main strategies, illustrated with Tailwind colors.

Monochromatic (one hue, multiple shades)

Varying only the lightness of a single color guarantees absolute consistency. It’s the safest method to get started. It works particularly well for UI components (cards, badges, alerts).

blue-600
blue-900
green-600
green-900
amber-600
amber-900

Same palette, different shades: blue-600/blue-900, green-600/green-900, amber-600/amber-900. Try blue monochromatic.

Analogous colors (neighbors on the wheel)

Three adjacent hues produce a soft, natural harmony. You find them in nature (forests, sunsets). Perfect for interfaces that need to convey calm or trust. The risk: not enough contrast between elements.

sky-600
teal-600
amber-600
yellow-600
purple-600
blue-600

sky-600 / teal-600, amber-600 / yellow-600, purple-600 / blue-600. Try sky + teal in the matrix.

Complementary colors (opposites on the wheel)

Two diametrically opposed hues create maximum contrast. It’s the ideal choice for call-to-actions: the button naturally “pops” from the background. Be careful, in equal proportions, the effect can be aggressive. The rule: one dominant (60%), one accent (10%).

blue-600
orange-600
violet-600
lime-600
red-600
teal-600

blue-600 / orange-600, violet-600 / lime-600, red-600 / teal-600. Try blue + orange in the matrix.

Split complementary (one accent, two neighbors of its opposite)

This is the ideal compromise: the visual tension of complementary, but softened. Easier to balance than a true complementary. Widely used in dashboards and multi-state interfaces.

blue-600
amber-600
blue-600
red-600

blue-600 as primary, amber-600 and red-600 as secondaries. The opposite of blue is orange; we take its two neighbors (amber and red). Try blue + amber.

Triadic (three equidistant colors)

Three colors spaced 120 degrees apart on the color wheel. This is the most dynamic and vibrant palette. Widely used in youthful or creative interfaces (apps, games, portfolios). Use sparingly: pick one dominant and keep the other two as accents.

red-600
blue-600
blue-600
yellow-500
yellow-500
red-600

red-600 / blue-600 / yellow-500: the classic primary triad. Try red + blue.

Warm + neutral (vivid color + tinted gray)

The most common combination in production. A strong brand color paired with a tinted gray (slate, zinc, stone) for text and surfaces. The gray absorbs the vivid color’s energy without creating conflict.

blue-600
slate-700
emerald-600
zinc-800
amber-600
stone-800

blue-600 / slate-700, emerald-600 / zinc-800, amber-600 / stone-800. Try emerald + zinc.

Thinking in color “architecture”

Picking pretty colors is not enough. A solid design system separates roles:

  • Primary: the brand identity color (e.g. blue-600). It appears on main buttons, links, active elements.
  • Background/Surface: background colors (white, zinc-50, slate-100). They take up most of the screen.
  • Neutral: tinted grays for text, borders, separators (slate, zinc, stone).

Tailwind simplifies this architecture by automatically providing Light, Default and Dark variants for each color through the 50-950 scale. No need to compute them manually:

  • Light: blue-100 (badge backgrounds, light alerts)
  • Default: blue-600 (buttons, links)
  • Dark: blue-900 (text on light backgrounds, hover states)

This logic applies to every hue. You only need to choose the hue; the designers behind Tailwind (Adam and Steve) give you 11 ready-made variants.

On-Colors: the core of this tool

The most important concept in a color system, and the most often overlooked: for every background color, you need to define an On-Color, the color of text and icons placed on top of it.

  • If Background = zinc-50, then On-Background = zinc-900 (dark text on light background)
  • If Primary = blue-600, then On-Primary = white (white text on blue background)
  • If Surface = slate-800, then On-Surface = slate-100 (light text on dark background)
zinc-50On: zinc-900
blue-600On: white
slate-800On: slate-100

This is exactly what the matrix above calculates automatically. The “Pied Web” text in each cell uses the optimal On-Color (black or white) to guarantee readability. The displayed WCAG ratio confirms that contrast is sufficient.

Semantic colors: the trap to avoid

Some colors carry universal meaning in interfaces:

Warning
amber
Error
red
Success
emerald
Info
sky

The trap: using red as your brand’s Primary color. If your main buttons AND your error messages are both red, the user can no longer tell a CTA from an alert. That’s cognitive confusion.

If your brand requires red as Primary, shift your errors to orange-600 or rose-600. Or conversely, pick a slightly different red for your Primary (rose-600, red-500) and reserve red-700 for strict errors. The key: each semantic role must have its own hue, without ambiguity.


Choosing colors doesn’t have to be an endless debate. By combining Tailwind palettes with a few color theory rules (complementary, analogous, 60-30-10), you turn a subjective decision into a repeatable process.

The matrix above doesn’t replace an art director. But it lets a developer or project manager propose a solid, verifiable (WCAG ratio) combination that’s shareable via a single link. That’s often enough to move forward without blocking the rest of the project.

My advice: start with warm + neutral (one brand color + a tinted gray). It’s the most common combination in production, the hardest to get wrong, and the one that leaves the most room to adjust later. And if the budget allows, have your choices validated by an art director: it’s one of those expenses that’s hard to justify by KPIs alone, but it can make the difference between “clean” and “memorable” when you’re in the top 3 players of your market.

Email • RSS • Twitter

Get notified of new posts

Continue reading: