Skip to content
← Back

CSS Unit Converter - px/rem/em/pt/vw Converter

Code
Runs locally · Not uploaded

Free online CSS unit converter supporting px, rem, em, pt, and vw with customizable root font size and viewport width. Processed locally, no uploads.

Was this result helpful?

For local tools, open DevTools → Network and search your input — it should not appear in requests.

Usage Guide

Convert CSS units (px/rem/em/pt/vw) locally with configurable root font-size and viewport.

1. Use

Set root/viewport, enter a value, copy the converted unit.

2. Confirm baselines

Know whether rem is 16px or 62.5%, and where em inherits.

3. Design workflow

Convert into tokens after choosing a root strategy.

4. pt

Treat print and screen differently; proof on real printers.

5. Related

Use the dedicated px↔rem page for focused rem workflows.

6. Accept

Spot-check UI after root or viewport assumption changes.

FAQ

The conversion itself does not: enter a value and your browser computes it instantly — free, no registration, and your settings are never sent to any server.

Bidirectional conversion across px, rem, em, pt, and vw covers responsive layouts, print typography, and viewport sizing. If you only convert px↔rem/em and care about the 62.5% root-font trick, the dedicated px↔rem page is more focused; come here when pt or vw is in play.

Yes — it defaults to 16px and is fully configurable; it directly drives every rem and em result. Before converting, confirm two things: which root size the design spec was annotated against, and whether your project's html font-size really is 16px or 62.5%. A wrong baseline shifts every number.

vw is computed against a configurable viewport width (default 1920px); 1vw equals 1% of it. Keep in mind the result depends on that assumption — on small mobile viewports vw can overscale, so spot-check on a real device.

Different baselines: rem is relative to the root element, em to the parent. When a component library uses rem while modules mix in em, settle the conversion baseline first — mixing units is not an error, an ambiguous baseline is.

pt means different things on screen and in print. Prefer px/rem for screen UI; take pt seriously only in print stylesheets, and proof the output on the actual target printer.

Related Tools

Related Articles