DevTools Surf logoDevTools Surf
AI / Modern DevAnimation / CSSAPI / Config
Sign in
DevTools Surf logoDevTools Surf
AI / Modern DevAnimation / CSSAPI / Config
Sign in
HomeColorHex → Tailwind

About Hex → Tailwind

Hex → Tailwind preview - Color tool

Map a hex/rgb color to the nearest Tailwind class. Part of the DevTools Surf developer suite. Browse more tools in the Color collection.

Use Cases

  • Mapping brand colors to the nearest Tailwind utility classes
  • Converting Figma design tokens to Tailwind-compatible values
  • Finding Tailwind equivalents during a CSS-to-Tailwind migration
  • Ensuring color consistency when integrating third-party design assets

Tips

  • Paste any hex code to find the closest Tailwind color class
  • Compare the visual difference between your color and the match
  • Use the result to stay within Tailwind's design system palette

Fun Facts

  • Tailwind CSS was created by Adam Wathan and first released in November 2017, growing from a side project into one of the most popular CSS frameworks.
  • Tailwind's default color palette contains 22 color families with 11 shades each (50-950), totaling 242 named color values.
  • The Tailwind color palette was redesigned from scratch for v2.0 (2020) by Steve Schoger, using perceptually uniform color spacing for better aesthetics.

FAQ

Which Tailwind version?
v3.4 by default. Toggle for v2 (older color scale) or v4 (preview). Classes differ between major versions.
How exact is the match?
Best-fit in LAB color space. You get the closest Tailwind class; exact matches are rare unless you use Tailwind's palette directly.
Can I use arbitrary values instead?
If nothing matches well, use Tailwind's arbitrary value syntax: `bg-[#1a2b3c]`. The tool shows both options — mapped class and arbitrary-value escape hatch.
What about alpha?
Color match first, alpha applied as Tailwind's `/N` suffix: `bg-blue-500/75`. Round alpha to the nearest 5% for Tailwind's supported values.

Related Color Tools

Color ConverterColor Palette GeneratorContrast CheckerGradient GeneratorColor Contrast MatrixGradient → CodeColor Name FinderColor Scheme Generator
New · Flagshipsimple REST client

REST Handler — Collections, env vars, history, cURL converter

Send requests, save collections (nested), swap environments, and convert between cURL / Collection JSON / REST Handler YAML.

Open

Popular tools

The most-used tools on DevToolsSurf, one click away.

Encoding & crypto

  • Base64 Encode
  • Base64 Decode
  • URL Encoder
  • URL Decoder
  • Hash Generator
  • JWT Decoder
  • JWT Encoder
  • UUID Generator
  • ULID Generator
  • Password Generator
  • Bcrypt Hash Tester

Converters

  • CSV to JSON
  • JSON to CSV
  • XML to JSON
  • JSON to XML
  • HTML → Markdown
  • HTML → React JSX
  • cURL to Code
  • Collection JSON → cURL
  • Swagger to Collection JSON
  • JSON → Go Struct
  • JSON → TypeScript Types

JSON & YAML

  • JSON Formatter
  • JSON Validator
  • JSON Viewer
  • JSON Minifier
  • JSON Diff
  • JSONPath Tester
  • YAML Formatter
  • YAML to JSON
  • JSON to YAML

Text & regex

  • Regex Tester
  • Text Diff
  • Case Converter
  • Word Counter
  • Markdown Preview
  • Slug Generator
  • Lorem Ipsum Generator
  • Markdown → PDF

CSS & color

  • CSS Beautifier
  • Minify CSS
  • Color Converter
  • Gradient Generator
  • Contrast Checker
  • Color Palette Generator
  • Flexbox Playground
  • Tailwind → CSS

Generators

  • QR Code Generator
  • Mock Data Generator
  • Favicon Generator
  • .gitignore Builder
  • README.md Generator
  • Dockerfile Generator
  • Sitemap Generator

API & networking

  • REST Handler
  • HTTP Header Analyzer
  • IP Address Lookup
  • CIDR Calculator
  • User-Agent Parser
  • HTTP Status Reference
  • OpenAPI Viewer

Date & time

  • Timestamp Converter
  • Timezone Converter
  • Cron Expression Parser
  • Duration Calculator
  • Age Calculator
  • Date Format Converter

Images

  • Image Converter
  • Image Resizer (Batch)
  • SVG Optimizer
  • Base64 ↔ Image
  • WebP ↔ AVIF Converter
  • Image Compressor

PDF tools

  • PDF Merger
  • PDF Splitter
  • PDF Compressor
  • Markdown → PDF
  • EPUB → PDF
  • MOBI / AZW → PDF
  • DOCX → PDF
  • HTML → PDF

Resources

  • Community feed
  • Themes marketplace
  • Pricing & credits
  • Privacy policy
  • Terms of service
  • Sitemap
  • robots.txt

Your account

  • Sign in
  • Dashboard
  • Run history
  • My profile
  • Settings
DevTools Surf logo
DevTools Surf919+ tools

Fast · privacy-first · client-side · © 2026

Home·Feed·ThemesPricing·Sign inPrivacy·Sitemap Feedback