At the default root font size of 16px, 2.125rem is exactly 34px.
Calculation based on a root font-size of 16 pixels.
How to convert 2.125rem to px
To convert rem to pixels, multiply the rem value by the root font size: px = rem × 16. For 2.125rem that is 2.125 × 16 = 34px.
34px is a large size, common for headings, section padding and generous layout gaps.
2.125rem at different root font sizes
| Root font size | Input | Result |
|---|---|---|
| 10px | 2.125rem | 21.25px |
| 12px | 2.125rem | 25.5px |
| 14px | 2.125rem | 29.75px |
| 15px | 2.125rem | 31.875px |
| 16px | 2.125rem | 34px |
| 18px | 2.125rem | 38.25px |
| 20px | 2.125rem | 42.5px |
| 22px | 2.125rem | 46.75px |
| 24px | 2.125rem | 51px |
CSS examples
font-size: 2.125rem; /* 34px */
padding: 2.125rem;
margin-bottom: 2.125rem;
width: 2.125rem;The same values in pixels, if you need a fixed size:
font-size: 34px;
padding: 34px;Tailwind CSS equivalent
2.125rem is not part of the default Tailwind scale, but you can use an arbitrary value such as p-[2.125rem] or text-[2.125rem].
Nearby values
Frequently Asked Questions
2.125rem equals 34px when the root font size is the browser default of 16px. The calculation is 2.125 × 16 = 34.
34px equals 2.125rem at a 16px root font size (34 ÷ 16 = 2.125).
Yes. rem is relative to the root font size, so 2.125rem becomes 38.25px at an 18px root and 42.5px 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.
