Converter Web ToolsConverter WebTools

PX to REM Converter

PX to REM Converter — get the answer instantly in your browser, free and private.

Root font size px (browser default is 16px)
PXREMPXREM
REM is relative to the root (<html>) font size. 1rem = the root size (16px by default), so 24px = 1.5rem. Using rem makes layouts scale with the user's font-size preference.

About px and rem

This tool converts between PX and REM both ways, using an adjustable root font size. Type a pixel value to get rem (or vice versa), and use the reference table for common sizes. REM units scale with the user’s font-size setting, which makes layouts more accessible and easier to maintain than fixed pixels.

How PX to REM works

How to convert px to rem

  1. Set the root font size (16px by default in browsers).
  2. Type a value in the PX or REM box — the other updates instantly.
  3. Use the table for quick reference of common sizes.

What rem means

1rem equals the root (<html>) font size. With the default 16px, 16px = 1rem, 24px = 1.5rem and 8px = 0.5rem. The formula is simply rem = px ÷ root size.

Why use rem

Because rem scales with the user’s browser font-size preference, sizing in rem improves accessibility and keeps spacing consistent. Many teams size typography and spacing in rem and reserve px for borders.

Common uses

  • Convert design pixels to rem for CSS
  • Build accessible, scalable typography
  • Keep spacing consistent across a site
  • Translate a style guide to rem
  • Convert rem back to px to check sizes
  • Set a custom root font size
  • Reference common px↔rem values
  • Speed up responsive CSS work

Frequently asked questions

How do I convert px to rem?
Divide the pixel value by the root font size (16px by default), so 24px = 1.5rem. This tool does it both ways instantly.
What is the default root font size?
Browsers default to 16px, but you can change it here if your site uses a different base.
Is rem better than px?
Rem scales with the user’s font preference, which is better for accessibility; px is fixed.
What is the difference between rem and em?
Rem is relative to the root font size; em is relative to the element’s own font size.
Does it round the result?
It keeps several decimals so the conversion is exact.
Is anything uploaded?
No — it converts entirely in your browser.
Can I convert many values?
Use the reference table for common sizes, or type any value for an exact result.
Is it free?
Yes — completely free with no sign-up.