CSS Tool

Pixel ↔ REM Converter

Convert pixels to REM and REM to pixels for responsive CSS. Set any base font size and instantly see conversions. Includes a reference table of common px-to-rem values.

px to remrem to pxpixel to rem convertercss unit converterpx rem calculatorconvert px rem cssrem converter freeresponsive css units

🛠️ Pixel ↔ REM Converter

px (default: 16px)
Enter a value above to convert.

How to Use the Pixel ↔ REM Converter

  1. Enter a pixel value in the left field to convert it to REM, or enter a REM value in the right field to convert it to pixels.

  2. Set the base font size (usually 16px, which is the browser default). If your root font size is different, update this field.

  3. The conversion appears instantly in the output box. A quick reference table for common sizes is also shown.

What is the REM Unit in CSS?

REM (Root EM) is a CSS unit that is relative to the font size of the root element (html). By default, most browsers set the root font size to 16px, which means 1rem = 16px. Using REM units instead of pixels makes your design responsive to user font size preferences and simplifies scaling the entire interface by changing a single value.

Why Use REM Instead of Pixels?

The Conversion Formula

To convert px to rem: rem = px ÷ base font size
To convert rem to px: px = rem × base font size
Example: 24px ÷ 16 = 1.5rem