Color to Tailwind Finder

What Is a Color to Tailwind Finder?

A color to Tailwind finder bridges the gap between design mockups and Tailwind CSS development. Designers specify colors as hex codes in Figma, Sketch, or Adobe XD. Developers need to translate those into Tailwind utility class names like bg-blue-600 or text-emerald-400. This tool automates that translation.

Enter a hex color (or pick one) and the tool ranks Tailwind's 220 default v3 colors by RGB distance. It shows the 12 nearest with their swatch, name, hex value and a match percentage, so you can compare them side by side.

How to Use This Tool

  1. Enter your color — Paste a hex code (#3b82f6 or #38f) or use the color picker. RGB and HSL strings are not parsed; convert them to hex first with the Color Converter.
  2. View the closest matches — The 12 nearest Tailwind colors are ranked by RGB distance, each with its swatch, name, hex value and match percentage.
  3. Copy the color name — Click a result to copy its name, such as blue-500, then add the prefix you need: bg-, text-, border- and so on.
  4. Compare side by side — The tool shows your input color next to the Tailwind match so you can visually judge whether the approximation is close enough for your design.

Worked example: how good is the "closest" match?

The finder ranks Tailwind's colors by straight-line distance between red, green and blue values (Euclidean distance in sRGB). The match percentage is 100 minus that distance as a share of the largest possible distance, black to white, which is 441.7. That's fast and simple. But equal RGB distances don't look equally different to the eye, so we checked ten design colors against a perceptual measure, CIEDE2000 (ΔE₀₀), computed with the coloraide library on October 12, 2026. Lower is closer, and 0 means identical.

Your colorTool's #1 matchTool's %ΔE₀₀ of that matchClosest by ΔE₀₀
#FF6B6Bred-40098%1.6red-400 (same)
#FFC914yellow-40099%2.1yellow-400 (same)
#2A9D8Fteal-60093%3.3teal-600 (same)
#E4572Ered-50093%9.1orange-600, ΔE₀₀ 5.3
#76B041lime-50088%9.0lime-600, ΔE₀₀ 5.4
#F4A261orange-30093%6.7orange-400, ΔE₀₀ 5.2
#6B4E71zinc-60092%14.9fuchsia-900, ΔE₀₀ 14.1

Two lessons. First, the percentage looks generous. 92–93% sounds close, yet three of those matches are visibly different colors (ΔE₀₀ 6.7–14.9). Second, the #1 pick isn't always the perceptually closest. For 4 of our 10 test colors, a neighbour in the 12 results was nearer by eye, so scan the top few swatches rather than taking the first. When even the best swatch looks different next to your color, the palette has no real equivalent. Use an arbitrary value (bg-[#6B4E71]) or add the color to your theme.

Tailwind v3 hex vs v4 OKLCH

The finder's palette is Tailwind's v3 hex values: 220 colors, 20 families from slate to rose, shades 50–950. It doesn't include neutral or stone. Tailwind v4 redefined the same names in OKLCH. We compared all 220 against the v4.1.13 theme.css. The median difference is ΔE₀₀ 1.0, so most names are effectively the same color. The biggest shifts are orange-600 (6.1), orange-500 (5.2), yellow-400 (5.1) and amber-600 (5.0). Also, 94 of the 220 v4 values lie outside sRGB. On a wide-gamut (Display P3) screen they render more saturated than any hex code can describe. If your project is on v4 and the match is a vivid orange, yellow, green or pink, check it against the v4 value with the Tailwind v4 OKLCH palette.

Frequently Asked Questions

What is a color to Tailwind finder?+
A color to Tailwind finder takes any color value — hex, RGB, HSL — and finds the closest matching Tailwind CSS utility class. Instead of guessing which Tailwind color name corresponds to your design mockup color, the tool gives you the exact class name instantly.
How accurate is the color matching?+
The ranking uses straight-line RGB distance, and the percentage is 100 minus that distance as a share of the black-to-white maximum. It is a quick guide, not a perceptual score: in our test, matches shown at 92-93% ranged from barely different to clearly different colors (CIEDE2000 3.3 to 14.9), and for 4 of 10 colors a lower-ranked result was closer to the eye. Compare the top few swatches before choosing.
Does it support Tailwind v4?+
It uses the v3 hex palette (220 colors, 20 families; neutral and stone are not included). Tailwind v4 keeps the same names but defines them in OKLCH: most are within a just-noticeable difference of v3 (median CIEDE2000 1.0), but some oranges, yellows and ambers moved by about 5, and 94 of the 220 v4 values are outside sRGB. For v4 projects, double-check vivid matches against the v4 palette.
Can I find matches across all shade levels?+
Yes. It searches every included family (slate, gray, zinc and 17 color families) at every shade from 50 to 950, and lists the 12 nearest.
What if there is no close match?+
The tool always lists the 12 nearest colors and does not flag poor matches, so judge the swatches yourself. If the best one still looks different, use an arbitrary value such as bg-[#6b4e71], which Tailwind compiles as-is, or add the color to your theme.
Can I paste colors from Figma or Sketch?+
Yes, as hex. Figma and Sketch both show colors as hex by default; paste the 6- or 3-digit value. RGB and HSL strings are not parsed.
Does the converter handle Tailwind v4 OKLCH colors?+
No. Matching is against the v3 hex values. The v4 OKLCH values are close for most colors (median CIEDE2000 1.0 against v3) but differ more for some oranges and yellows, and many are wide-gamut colors no hex code can represent. Use the Tailwind v4 OKLCH Palette tool to check a match against v4.
What if my color does not have a close Tailwind match?+
The tool does not flag it, so look at the swatches: if the nearest one is visibly different, use an arbitrary value like bg-[#yourhex], which Tailwind compiles inline, or add the color to your theme (theme.extend.colors in v3, a --color-* variable in @theme in v4).

📖 Learn More

Related Article How to Find Tailwind Color → Related Article Tailwind CSS Colors Guide →

Built by Derek Giordano · Part of Ultimate Design Tools

Privacy Policy · Terms of Service