sergio's blog

Using Native Fonts

To use the default fonts, use the following declaration on CSS:

body {
  font-family: -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

You can also use native monospace fonts for code blocks, etc. In this site, you'll see headings on monospace font:

code, tt {
  font-size: 85%;
  font-family: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, "Liberation Mono", monospace;
}

My approach is to define the fonts as root classes, and later define with a variable. You can check the main.css↗ of this very same website.

You can read more information about why choosing native founts here: Why use this Font Stack?↗.