PX to REM Converter

Convert pixels to REM and back with a custom root font size.

Browsers default to 16 px. Match the font-size of your CSS html element.

Values saved on this device.

16 px
1 rem

Common sizes at this base

Tap a row to load it into the converter.

pxrem
0.5
0.625
0.75
0.875
1
1.125
1.25
1.5
2
3
4

PX to REM in seconds

  1. Set the root font size your project uses (usually 16 px).
  2. Type a pixel value to get REM, or a REM value to get pixels back.
  3. Copy the result or share the exact values with a link.

Good to know

What is the difference between REM and EM?

REM is relative to the root (html) font size, so 1.5rem is always 1.5 times the base. EM is relative to the parent element, which compounds in nested layouts. REM is more predictable for spacing and type scales.

Why is 16 px the default base?

It is the default root font size in browsers. If your CSS sets html to another size, change the base here and every conversion follows it.

What is the formula?

REM equals pixels divided by the base. Pixels equal REM times the base. This tool rounds to four decimals and trims trailing zeros.