Although browser zoom works well when defining font sizes in px
, it won't scale typography when using global font size adjustments in the browser (or 'font scaling').
Setting type in relative units such as rem
or em
works with both of these.
A general rule is:
“Should this value scale up as the user increases their browser's default font size?”
If yes, rem
. Otherwise, px
.