19

Beginning with OS X 10.0 Cheetah, and assuming they are the same through the current release 10.8 Mountain Lion, what are the default fonts rendered for the following font-families?

  • font-family: serif;
  • font-family: sans-serif;
  • font-family: monospace;
3
  • 1
    I would have thought it would be... "What are the default fonts for [insert browser here]", rather than the OS per se?
    – MrWhite
    Aug 24, 2012 at 12:06
  • 1
    Nope, the OS is responsible for supplying the default fonts. In one case that I've tested, Firefox > 10 will render Courier New in place of Courier on Windows Systems -- probably because Courier is an old bitmap font which refuses to anti-alias.
    – Jeff
    Aug 24, 2012 at 12:32
  • 1
    I should clarify my reply above. The browser most definitely has an option to choose which font it uses as a default, depending upon the OS it's installed on.
    – Jeff
    Aug 24, 2012 at 13:21

1 Answer 1

18

The default fonts for WebKit/Safari under Mac OS X are as follows:

  • Monospace -> Courier
  • Sans-serif -> Helvetica
  • Serif -> Times
  • Standard (default) -> Times

This is gleaned directly from the WebKit source, specifically the XML/plist file at Source/WebCore/Resources/DefaultFont.plist.in that's available online here. It includes the following lines:

<dict>
  <key>monospace</key>
  <string>Courier</string>
  <key>standard</key>
  <string>Times</string>
  <key>sans-serif</key>
  <string>Helvetica</string>
  <key>serif</key>
  <string>Times</string>
</dict>

The same file also includes the default monospace, sans-serif, and serif fonts for Korean, Japanese, Simplified Chinese, and Traditional Chinese, if those are of any interest to you.

1
  • 3
    The sans-serif font, Helvetica, is usually San Francisco now. You can also just use -apple-system which may be changed to system soon (source) Jul 16, 2016 at 21:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.