Windows Substitutes Helvetica for Arial

I just ran into this issue today and honestly a little surprised I haven’t run into it before.

The problem was with a font stack that I wanted to try out:

font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;

If a user has Helvetica Neue or Helvetica, that’s fantastic! This is likely to be the case if they’re on a Mac.

On Windows 7 and 8, Segoe UI is installed by default. Neither Helvetica Neue nor Helvetica are. Failing all that, they’ll get the tried and trusty Arial.

Except, when I went to try it, I got Arial instead of Segoe UI, even though it’s installed. Odd.

I changed the font stack to:

font-family: "Helvetica Neue", "Segoe UI", Helvetica, Arial, sans-serif;

Notice how Segoe UI is before Helvetica this time? Sure enough, I get what I expected: Segoe UI.

Oh, did you want Helvetica?

Turns out, in Windows, there’s a registry key that aliases Helvetica to Arial. If you specify Helvetica, you’ll get Arial. If you specify Helvetica and then specify any fonts after it, you’ll get Arial.

This was tested on Windows 8.1 in Internet Explorer 11 and Chrome and both did the substitution.