Interfaces and CSSRuns in your browser

px ↔ rem Converter

Calculate a relative rem value from pixels or convert rem back to pixels for a selected root font size.

  • Two-way conversion
  • Custom root size
  • Instant calculation
Online tool

Try the tool

Add your data, choose the settings, and get the result.

px → rem

rem → px

16 px = 1 rem

Your data stays here

Text and selected files are processed in the current browser and are not sent to a server to produce the result.

Reviewed: 2026-07-17
01

How to use it

  1. 1

    Enter the root font size.

  2. 2

    Enter a px or rem value.

  3. 3

    Read the equivalent value in the other unit.

02

What the tool can do

  • px divided by root size equals rem.
  • rem multiplied by root size equals px.
  • Decimal numeric values.
03

Common use cases

  • Translating design dimensions into relative CSS units.
  • Checking a value with a non-default root font size.
  • Converting rem back to pixels for comparison with a design.
04

How it works inside

1rem equals the computed font size of the root html element.

16 px is common but is not mandatory for every project.

05

Questions and answers

Why is 16 px often equal to 1rem?

Many browsers use 16 px as the default root font size unless the site or user changes it.

How does rem differ from em?

rem is based on the root font size, while em usually depends on the current or parent font-size context.