Free online CSS unit converter supporting px, rem, em, pt, and vw with customizable root font size and viewport width. Processed locally, no uploads.
TL;DR: Free online CSS unit converter supporting px, rem, em, pt, and vw with customizable root font size and viewport width. Enter one value to see all conversions at once. Processed locally, no uploads.
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
px, rem, em: What Each CSS Unit Actually Answers, and How to Convert Without Surprises
The boundary between px, rem, and em (root-relative vs parent-relative), the px-to-rem formula and size table, the 62.5% trick's hidden costs, the Safari media-query rem trap, and browser minimum font size — with an online converter.
Online CSS Minifier: Reduce CSS File Size for Better Performance
Learn how to minify CSS safely: whitespace, comments, hex shortening, zero-unit elision, calc protection, and UTF-8 byte savings — with an online tool you can use locally.
Online Base64 to Image Converter: Decode Base64 Strings to Image Files
Learn how to convert Base64 encoded strings back to image files. Understand Base64 decoding principles, common image MIME types, and real-world Web development use cases.