Units Per Em Scale Factor
Multiplier that maps font design units to pixels at a requested CSS font size.
Description
Multiplier that maps font design units to pixels at a requested CSS font size.
Units Per Em Scale Factor is a focused tool for the following task. Multiplier that maps font design units to pixels at a requested CSS font size. It reports Pixels Per Font Unit from the values you provide rather than inventing measurements, coefficients, or professional judgment that are not part of the input.
When to use Units Per Em Scale Factor
Use this typography calculation when the font metrics, writing system, layout direction, rendering environment, and measurement units are known.
- Font Size Pixels (px)
- Required number in px.
- Units Per Em
- Required number.
The cited overview of Typography supplies background for the terminology and domain context used by this tool.1
How Units Per Em Scale Factor works
Multiplier that maps font design units to pixels at a requested CSS font size. Inputs are interpreted exactly in the displayed units and the calculation returns the following fields without presentation rounding.
- Pixels Per Font Unit (px/unit)
- Returned number in px/unit.
Limitations and assumptions
- Font design, shaping engine, hinting, variable axes, fallback fonts, ligatures, language, display density, and browser rounding can change rendered text measurements.
- Font Size Pixels must be at least 0.
- Units Per Em must be at least 0.
- Use finite inputs in the displayed units, preserve source measurements and assumptions, and independently verify consequential decisions.
Alternative or Complementary approaches
Measure the final shaped text in the target renderer and test the actual fonts, languages, viewport sizes, and accessibility settings used in production.
References
-
Typography — Wikipedia contributors
Similar or alternative tools
- Leading From Font Size Ratio
Line-height in CSS pixels from font size and a unitless leading multiplier.
- Pixels To Rem 16base
CSS rem units from CSS pixels using a 16-pixel root font size.
- Rem To Pixels 16base
CSS pixels from rem units using a 16-pixel root font size.