Free tools, no sign-up — everything runs in your browser.
ToolHub 1000Free online tools

PX to REM Explained: Sizing That Scales With Text

Fixed pixels ignore user text settings, while rem units adapt. This guide shows how to convert and when rem is the better choice.

What is the PX to REM Converter?

Rem units scale with the font size set on the root element, so they keep layouts flexible when a user changes their default text size. This tool divides a pixel value by the root font size to give the rem equivalent. The usual root size is 16 pixels, but you can enter whatever your project uses. It converts a single value, not a whole stylesheet, and it does not account for any other scaling on the page.

How to use it

  1. Enter the pixel value.
  2. Enter the root font size, usually 16.
  3. Press the button to see the rem value.

Worked example

32 pixels with a 16 pixel root font size converts to 2 rem.

How many rem is 24 pixels?

With the usual 16 pixel root size, 24 pixels is 1.5 rem. Divide the pixel value by the root size to get the answer.

Frequently asked questions

What is the usual root font size?

Most browsers default to 16 pixels, so many projects divide by 16. If your project sets a different root size, use that number instead.

Why use rem instead of pixels?

Rem sizes follow the root font size, so text and spacing can scale when a user changes their browser text size, which helps accessibility.

Try the PX to REM Converter free · All guides