At the default root font size of 16px, 18rem is exactly 288px.
Calculation based on a root font-size of 16 pixels.
How to convert 18rem to px
To convert rem to pixels, multiply the rem value by the root font size: px = rem × 16. For 18rem that is 18 × 16 = 288px.
288px is a very large size, typically used for hero headings, containers and big layout dimensions.
18rem at different root font sizes
| Root font size | Input | Result |
|---|---|---|
| 10px | 18rem | 180px |
| 12px | 18rem | 216px |
| 14px | 18rem | 252px |
| 15px | 18rem | 270px |
| 16px | 18rem | 288px |
| 18px | 18rem | 324px |
| 20px | 18rem | 360px |
| 22px | 18rem | 396px |
| 24px | 18rem | 432px |
CSS examples
font-size: 18rem; /* 288px */
padding: 18rem;
margin-bottom: 18rem;
width: 18rem;The same values in pixels, if you need a fixed size:
font-size: 288px;
padding: 288px;Tailwind CSS equivalent
The default spacing scale has a step for 18rem: use classes like p-72, m-72, gap-72, w-72 and h-72.
Nearby values
Frequently Asked Questions
18rem equals 288px when the root font size is the browser default of 16px. The calculation is 18 × 16 = 288.
288px equals 18rem at a 16px root font size (288 ÷ 16 = 18).
Yes. rem is relative to the root font size, so 18rem becomes 324px at an 18px root and 360px at a 20px root. Use the base font size field above to try any value.
Prefer rem for font sizes, spacing and layout so they respect the user's browser font settings and scale for accessibility. Use px for details that should never scale, such as 1px borders or fixed icon sizes.
