Smarter Tailwind CSS development inside VS Code.
Color-coded class highlighting, one-click sorting, a class explorer, and full support for custom classes.
Every Tailwind class is instantly highlighted with a distinct color based on its category β making large className strings scannable at a glance.
| Category | Color |
|---|---|
| Layout | Sky blue |
| Spacing | Emerald green |
| Sizing | Purple |
| Typography | Yellow |
| Color / Background | Blue |
| Border | Violet |
| Effect | Pink |
| Animation | Orange |
| Transform | Teal |
| Interactivity | Red |
| SVG | Green |
| Table | Amber |
| Accessibility | Gray |
Variants like hover:, focus:, md:, dark:lg: are fully supported β the base class is always correctly identified.
Instantly reorganize the classes inside any class or className attribute into a consistent, readable order.
Via Command Palette (Ctrl+Shift+P / Cmd+Shift+P):
TailAid: Sort Tailwind Classes by Category
Via keyboard shortcut:
| OS | Shortcut |
|---|---|
| Windows / Linux | Ctrl + Shift + T |
| macOS | Cmd + Shift + T |
Classes are sorted in this canonical order:
Layout β Sizing β Spacing β Typography β Color β Border β Effect β Animation β Transform β Interactivity β SVG β Table β Accessibility
Browse all known Tailwind classes organized by category in the VS Code sidebar. Click any class to insert it directly into your code.
Hover over any Tailwind class to see its category and description without leaving your editor.
Define your own project-specific classes with custom categories and highlight colors.
Generate the config file via Command Palette:
TailAid: Create Config File (tailaid.config.json)
This creates a tailaid.config.json at your project root:
{
"customClasses": [
{
"prefix": ["btn-", "card"],
"category": "Components",
"color": "#a78bfa",
"backgroundColor": "rgba(167,139,250,0.12)"
},
{
"prefix": ["brand-"],
"category": "Brand",
"color": "#fb923c",
"backgroundColor": "rgba(251,146,60,0.10)"
}
]
}| Field | Type | Required | Description |
|---|---|---|---|
prefix |
string | string[] |
β | One or more class prefixes/names to match |
category |
string |
β | Category label used for highlighting and sorting |
color |
string |
β | Text highlight color (any CSS color value) |
backgroundColor |
string |
β | Background tint (any CSS color value) |
Hot-reload: The extension watches
tailaid.config.jsonfor changes and re-applies highlights instantly β no restart required.
Priority: Custom classes always take precedence over built-in Tailwind categories.
- Open VS Code
- Go to the Extensions view (
Ctrl+Shift+X/Cmd+Shift+X) - Search for TailAid
- Click Install
Supported languages: html, javascript, typescript, javascriptreact, typescriptreact
Contributions are welcome! Check out CONTRIBUTING.md for guidelines.
MIT β see LICENSE for details.

