Em (typography) 2026-11-05
An em is a nominal typographic length set by the current font size. At a font size of typographic points, one em is typographic points long.[ref] A scalable computer font describes its geometry relative to this scale. In OpenType, unitsPerEm specifies how many font units make one em.[ref]
Suppose one em contains 2048 font units. A design length of 1024 font units is half an em. At a font size of 12 typographic points, that length is 6 typographic points; at 18 typographic points, it is 9 typographic points. The stored coordinate has not changed; the scale has.
The word em does not require the glyph for “M” to be exactly one em wide. Nor is an em the measured ink height of every glyph: a shape can occupy only part of the nominal square or extend beyond it.[ref] Glyph advances, left side bearings and right side bearings must consequently be read from the computer font's metrics rather than inferred from the em alone.
Font unit 2026-11-05
A font unit measures distances in a computer font's design coordinates. If one em contains font units, a coordinate difference represents of an em. OpenType stores in the unitsPerEm field of its font-header table; its permitted range is 16–16384.[ref]
The design coordinate is independent of a particular screen. Before grid fitting, an unrotated uniform scale with pixels per em sends a horizontal length to
For example, and send a length of 512 font units to 3 pixels. Doubling the requested font size doubles that ideal geometric length without changing the stored outline.
A font unit is consequently not itself a pixel. Grid fitting can further change a scaled outline or its glyph advance to suit the pixel grid. Nor does the height of every visible glyph equal one em: the em fixes a scale, while individual glyphs have their own bounding boxes.