Borders

border-width to Tailwind

Widths are unprefixed numbers and the 1px default is the bare border — so border-2 is a width, not a palette shade.

The 5 mappings below are read straight out of Tailwind v4.3.3, not maintained by hand, so this is what the converter will actually produce for border-width.

border-width values and their classes

CSSTailwind
border-width: 0;border-0
border-width: 1px;border
border-width: 2px;border-2
border-width: 4px;border-4
border-width: 8px;border-8

Values that are not on the scale

Anything without a named class is written as an arbitrary value in square brackets. The converter falls back to this rather than rounding your CSS to the nearest class, because silently changing a value is worse than an ugly class name.

border-[your value]

Other borders properties

Converting a whole stylesheet?

Paste it into the converter and get every rule at once, shorthands expanded, media queries turned into breakpoint variants, and the parts that have no Tailwind equivalent flagged rather than dropped.

Open the converter