PX to REM Converter

Use px to rem converter locally, without uploading your data.

Loading calculator…

What this tool does

Use px to rem converter locally, without uploading your data. Computed font-size context determines the conversion; negative CSS lengths are supported.

How to use the PX to REM Converter

  1. Enter or select pixel value.
  2. Enter or select root font size (px).
  3. Read the calculated result; change any measurement to compare alternatives.

Formula

relative units=px/base font size
value
Pixel value
base
Root font size (px)

Computed font-size context determines the conversion; negative CSS lengths are supported.

Worked example

For px to rem converter, the following measurements illustrate the exact method: Pixel value: 16; Root font size (px): 16.

Inputs

  • Pixel value16
  • Root font size (px)16

Result

  • REM1

Results explained

REM
REM from the formula above. Computed font-size context determines the conversion; negative CSS lengths are supported.

Frequently asked questions

relative units=px/base font size

Computed font-size context determines the conversion; negative CSS lengths are supported.

No. Content stays in your browser and no API is called.

Copy the result, review it in your project, and test it in the intended environment.

No. Syntax checks and conversions cannot replace application-specific testing, security review or accessibility review.