Numbers come in two heights.

Lining figures are all the same height, roughly the height of a capital, and stand in a row like a fence. Old-style figures vary: the 1, 2 and 0 sit at x-height, the 6 and 8 rise above it, the 3, 4, 5, 7 and 9 drop below the baseline. Both are correct. The job decides which.

In prose

A sentence containing a date wants old-style figures. In 1974 the shop had four presses reads as a sentence when the figures behave like letters, and as a sentence with a small billboard in it when they do not.

Lining figures are cap height, so a four-digit year carries the visual weight of four capitals in a row, and the eye stops on it.

In tables

A table wants lining figures, and tabular ones: every digit the same width, so the columns align without help. Old-style figures break the horizontal reading of a table, and if they are proportionally spaced the decimal points wander down the column.

The bit that trips people up

A face usually has both sets, and the default is whichever the designer expected to be used more. So you ask for the other set explicitly, in CSS with font-variant-numeric, and then check the face actually contains it. Many do not, and the browser quietly ignores the request.1

Where I break the rule

Prices, and anything a reader might need to copy exactly. Charm loses to accuracy at the point where somebody has to write the number down.

Footnotes

  1. The dates and reading times on this site use tabular lining figures; the essays use whatever the text face gives by default. That is a compromise, and now you know where it is. ↩