Cap height

On this page 7

Cap height is the vertical distance from the baseline to the top of a typeface’s flat-topped capital letters, such as H, E or I. In typography it is one of the core vertical metrics of a font, alongside x-height, ascender height and descender depth, and it determines how large and how heavy uppercase text appears at a given point size.

Because two fonts set at the same size can have noticeably different cap heights, the metric matters whenever designers mix typefaces, align text with icons or buttons, or need headings and labels to look optically consistent. In digital design it is also stored as a numeric value inside the font file, which software uses for layout and trimming.

How cap height is measured

Cap height is measured on flat capitals because their tops sit exactly on a horizontal line. Round letters such as O and C and pointed letters such as A deliberately overshoot the cap line by roughly 1 to 3 percent so that they look the same size as the flat letters; measuring them would give a slightly inflated value.

In a digital font, glyphs are drawn on a grid called the em square, commonly 1,000 units per em for PostScript-flavored OpenType fonts and 2,048 units for many TrueType fonts. Cap height is expressed in these units and recorded in the sCapHeight field of the OpenType OS/2 table. Dividing it by the units per em gives a ratio that is independent of point size.

The table below lists the vertical metrics that surround cap height and how each relates to it.

MetricWhat it measuresTypical ratio to the em
Cap heightBaseline to top of flat capitalsAbout 0.65 to 0.75
X-heightBaseline to top of flat lowercase lettersAbout 0.45 to 0.55
Ascender heightBaseline to top of letters such as b, d, hOften slightly above cap height
Descender depthBaseline to bottom of letters such as p, gAbout 0.20 to 0.25 below baseline
OvershootExtra extension of round and pointed lettersAbout 1 to 3 percent of cap height
Vertical metrics related to cap height

Why cap height varies between typefaces

Point size describes the height of the em square, not the height of any visible letter, so each type designer decides how much of that space the capitals occupy. A typeface with tall capitals looks larger and more assertive at 16 px than one whose capitals use a smaller share of the em.

Cap height also interacts with the ratio between capitals and lowercase. Many modern sans-serif families for screens combine a large x-height with capitals that are only moderately taller, which keeps mixed-case text even. Classical old-style serif faces often have ascenders that rise above the capitals, giving lowercase words a more lively silhouette.

Typeface styleRelative cap heightVisual consequence
Neo-grotesque sans-serifHighStrong, compact uppercase labels
Humanist sans-serifModerateFriendly, open texture in body text
Old-style serifModerate to lowAscenders often exceed the capitals
Geometric sans-serifModerateCapitals look wide and circular
Display and condensed facesVery highHeadlines fill vertical space efficiently
Script typefaceVariable and irregularCapitals are decorative, rarely measured
Typical cap height character by typeface style

Cap height compared with x-height

Cap height and x-height answer different legibility questions. X-height governs how large running lowercase text appears and is the stronger predictor of reading comfort at small sizes, while cap height governs the impact of headings, acronyms, navigation labels and all-caps text.

AspectCap heightX-height
Main influenceUppercase and numeral sizeLowercase size and reading comfort
Most relevant forLabels, buttons, headings, logosBody text, long-form reading
Used in font matchingAligning text with icons and boxesMatching apparent size of mixed fonts
CSS relative unitcapex
Common design checkOptical centering in componentsLegibility at 12 to 16 px
Cap height and x-height side by side

Numerals are usually designed to match cap height when they are lining figures, while old-style figures follow the x-height and drop below the baseline. Choosing the figure style therefore changes how numbers sit next to capitals in tables and interface labels.

Using cap height in layout and interface design

Designers use cap height mainly to achieve optical alignment and consistent sizing. A text box measured from the top of the line box includes the font’s internal leading above the capitals, so a label that is mathematically centered in a button often looks too low. Aligning by cap height removes that offset.

Modern CSS offers direct support. The `cap` unit equals the cap height of the current font, the property font-size-adjust accepts cap-height to normalize fallback fonts, and the `text-box-trim` and `text-box-edge: cap alphabetic` properties trim the space above the capitals and below the baseline so that text aligns exactly to its container.

TaskHow cap height helpsTypical technique
Centering a button labelCenters the visible capitals, not the line boxTrim to cap and alphabetic edges
Aligning icons with textMatches icon height to capitalsSize icon to about one cap
Pairing two typefacesPrevents one font looking largerAdjust sizes until cap heights match
Font fallbackReduces layout shift when web fonts loadUse font-size-adjust with cap-height
Baseline grid layoutSets consistent spacing above headingsMeasure margins from the cap line
Practical uses of cap height

Common mistakes and misconceptions

The most frequent error is assuming point size equals letter height. A 12 pt font does not have 12 pt capitals; in most text faces its capitals measure roughly 8 to 9 pt. Other recurring problems include:

  • Measuring round letters such as O, which includes overshoot and overstates the value.
  • Trusting inaccurate font metadata, since some older or free fonts store a wrong sCapHeight value.
  • Pairing fonts by point size alone, which can make a secondary typeface look one size too large.
  • Setting long passages in all caps, where a high cap height increases visual weight and slows reading.

Stripped to the essentials

Cap height is how tall the capital letters are in a font. It is measured from the line the letters sit on to the flat top of a letter like H.

Two fonts set to the same size can still have capitals of different heights. Two people with the same shoe size can also differ in height. Designers check cap height so that text looks the same size and sits neatly. This matters inside buttons, next to icons and beside other fonts.

Where it is applied

A product team building a design system noticed that labels in its 40 px tall buttons looked slightly low, even though the code centered them perfectly. The interface font had a cap height of 0.70 em, while extra internal space above the capitals pushed the visible letters downward by about 2 px.

The team applied trimming to the cap and alphabetic edges, so the label box matched the visible capitals exactly, and sized the 16 px icons to one cap height of the 14 px label text, roughly 10 px of drawn glyph inside the icon frame. They also set font-size-adjust with the cap-height metric for the fallback system font.

The result was optically centered labels across all button sizes and less visible jumping when the web font finished loading, achieved without manual pixel nudging in individual components.