CSS Unit Converter

Convert between CSS units: px, em, rem, pt, pc, in, cm, mm, and percentages.

Embed this tool
px
16
pt
12.0003
pc
1
in
0.1667
cm
0.4233
mm
4.2334

Advertisement

Ad

CSS Units Explained

CSS offers many units for sizing elements. Choosing the right unit impacts accessibility, responsiveness, and maintainability of your designs.

Unit Categories

  • Absolute units (px, pt, in, cm): Fixed sizes that do not scale. Best for print media and precise pixel layouts.
  • Relative units (em, rem, %): Scale based on parent or root font size. Essential for accessible, responsive design.
  • Viewport units (vw, vh, vmin, vmax): Scale based on browser window dimensions. Great for full-screen sections and responsive spacing.

Frequently Asked Questions

px (pixels) is an absolute unit that maps to device pixels. rem (root em) is relative to the root font size (typically 16px). Using rem for typography improves accessibility because users can scale text via browser settings.

Related Tools