frontendhack-logo
22px = 1.375rem

At the default root font size of 16px, 22px is exactly 1.375rem.

Calculation based on a root font-size of 16 pixels.

How to convert 22px to rem

To convert pixels to rem, divide the pixel value by the root font size: rem = px ÷ 16. For 22px that is 22 ÷ 16 = 1.375rem.

22px is a medium size, common for body text, subheadings, buttons and standard spacing.

22px at different root font sizes

Root font sizeInputResult
10px22px2.2rem
12px22px1.8333rem
14px22px1.5714rem
15px22px1.4667rem
16px22px1.375rem
18px22px1.2222rem
20px22px1.1rem
22px22px1rem
24px22px0.9167rem

CSS examples

font-size: 1.375rem; /* 22px */
padding: 1.375rem;
margin-bottom: 1.375rem;
width: 1.375rem;

The same values in pixels, if you need a fixed size:

font-size: 22px;
padding: 22px;

Tailwind CSS equivalent

1.375rem is not part of the default Tailwind scale, but you can use an arbitrary value such as p-[1.375rem] or text-[1.375rem].

Nearby values

PixelsREM
22px1.375rem
2px0.125rem
3px0.1875rem
4px0.25rem
5px0.3125rem
6px0.375rem

Frequently Asked Questions

22px equals 1.375rem when the root font size is the browser default of 16px. The calculation is 22 ÷ 16 = 1.375.

1.375rem equals 22px at a 16px root font size (1.375 × 16 = 22).

Yes. If the root font size is 18px, 22px equals 1.2222rem, and at 20px it equals 1.1rem. The pixel value itself never changes, only the rem equivalent. 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.