CSS to Tailwind classes

Heuristic mapping of common CSS declarations to Tailwind v3 utilities and arbitrary values. Review in your project.

{{ t("cssToTailwindHint") }}

{{ cssToTailwind.message }}

Overview

Tailwind favors utility classes instead of long ad-hoc stylesheets. When migrating or pasting design snippets, a starting point helps: this tool reads `property: value` declarations (with or without `{}`), skips `/* */` comments, and suggests classes such as `flex`, `justify-center`, scale spacing (`p-4`, `gap-6`), or arbitrary values (`[margin:12px]`).

It does not cover all of CSS or Tailwind plugins (typography, forms). Always verify visually and add breakpoints (`md:`, `lg:`) yourself.

Sample

display: flex;
justify-content: center;
padding: 16px;

FAQ

What is this tool for?

It runs fully in your browser: useful to validate, format, or convert data in everyday development.

Are my inputs sent to a server?

Processing happens locally with JavaScript. We do not store what you paste into the text areas.

Can I use this for real production data?

Use at your own risk. For secrets (passwords, tokens), prefer controlled environments and your company policies. And always review the generated contents. Never trust blindly things you see on the internet.