Skip to content
MewixMewix

Px to rem converter

Set the root font size your design assumes, slide pixel values, and copy rem equivalents plus a :root snippet.

Updated by the Mewix team

Why use rem instead of px

Rem units scale with the root font size, so users who enlarge browser text see your spacing grow too—provided you sized with rem rather than fixed px. Most browsers default to 16px on :root, which is why designers mentally map 1rem ≈ 16px until a project changes the root.

16px base and adjustable root here

Root font size slider runs 10–24px (default 16). Pixel input runs 1–96px. Rem prints to four decimal places. Copied CSS sets :root { font-size: …px; } and an example .element { font-size: …rem; } with a px comment.

Sample px (preview list)rem at 16px root
120.750
241.500
483.000
Does rem follow the user’s zoom?

Browser zoom rescales CSS pixels, rem included. It is not the same as changing root in your stylesheet—users expect zoom to affect everything.