PX โ‡„ REM Converter

Convert CSS pixels to rem and back.

Also called: PX to REM, REM to PX.

FreeNo sign-upRuns in your browser
DESIGN

PX โ‡„ REM Converter

Convert CSS pixels to rem and back.

Runs locally in your browser
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.

Find a tool

Loading toolsโ€ฆ

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

  1. 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.
  2. Pick the optionsdirection (the defaults suit most uses).
  3. Press Run toolThe result appears right under the button.
  4. 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

See all Design tools