PX โ REM Converter
Convert CSS pixels to rem and back.
Also called: PX to REM, REM to PX.
DESIGN
Runs locally in your browserPX โ REM Converter
Convert CSS pixels to rem and back.
Ready. Fill in the fields above, then press Run tool.
Privacy note: this tool runs in your browser, so the text you enter stays on your device.
Watch: how to use the PX โ REM Converter (13 seconds)
Recorded on a phone, steps written on screen, no sound.
About the PX โ REM Converter
Convert CSS pixels to rem and back. With the usual 16 px root size, 24 px = 1.5 rem.
Rem sizes follow the visitor's font-size setting, which helps people who need bigger text.
How to use the PX โ REM Converter
- Add your inputFill in value and base font size. An example is already filled in, so you can press Run tool first to see how it works.
- Pick the optionsdirection (the defaults suit most uses).
- Press Run toolThe result appears right under the button.
- Copy or download the resultCopy text results with Copy output; when the tool makes a picture or file, use its Download button.
This tool works inside your browser: what you enter stays on your device.
Example
A sample input and the result the PX โ REM Converter gives for it (produced by the tool itself, not typed by hand).
- Value
- 24
- Base font size
- 16
- Direction
- px โ rem
Result:
24px = 1.5rem
Good to know
- What you need
- You type or choose: Value, Base font size
- Where it runs
- In your browser, on your device.
- Cost
- Free, no sign-up.
Questions
What base should I use?
16 px unless your CSS sets a different root font size.
rem or em?
rem follows the root; em follows the parent element.
More tools in Design
- Screen Colour Picker (eyedropper)
- Screenshot Mockup (browser or phone frame)
- SVG Minifier
- App Icon & Favicon Generator (ZIP)
- Aspect Ratio Calculator
- Chart Maker (bar, line, pie)
- Colour Contrast Checker
- Colour Converter
- Colour Palette Generator
- Colour Shades & Tints Scale (50โ950)
- CSS Box Shadow Generator
- CSS clamp() Fluid Size Generator