CSS & Front-End Development Tools

rem to px

Convert rem to pixels and see how the root font size affects the final CSS dimensions.

Inputs

Processed in your browser

Live Preview

Updates automatically as you make changes
Select or copy directly

Convert rem to px with a custom root font size and see the formula and result.

Your input is processed only in your browser and is never uploaded to a server.

About This Tool

rem to px reverses the px to rem conversion. Enter rem and the actual root font size to calculate the pixel value locally, helping you understand relative sizes in existing styles.

How to Use

  1. Enter the rem values you want to convert.
  2. Enter a Root Font Size greater than 0. The default is 16px.
  3. View the px result and calculation explanation.
  4. Copy the result or load an example to check common conversions.

Examples

  • 1.5rem × 16px = 24px.
  • 2rem × 16px = 32px.
  • 1.25rem × 20px = 25px.

How the Calculation Works

px = rem × root font size. With a 16px root font size, 1.5rem equals 24px. Site styles and user settings may change the root size, so convert using the actual value.

Common Uses

  • Compare rem styles with pixel values in a design.
  • Understand size changes when a theme changes the root font size.
  • Quickly check font sizes, spacing, and container dimensions.

Privacy

Your input and results stay in your browser and are not uploaded or saved automatically. Copy any results you want to keep and save them yourself before leaving the page.

FAQ

Why isn't 1rem always 16px?

rem uses the root element's actual font size, which project CSS or user settings can change.

Can the root font size be 18 or 20?

Yes. Any valid positive value within the tool's accepted range can be used. It does not have to be 16.

Does browser zoom change this formula?

The formula describes the relationship between CSS pixels and rem. The corresponding physical screen pixels also depend on zoom and device pixel ratio.

Why do some results have no decimal places?

When a result is effectively an integer, the tool removes unnecessary trailing zeros so the output is easy to use directly in CSS.

Back to the Developer Tools Directory