Using different fonts
Paid account only
Including fonts based on their URL is only possible on a paid account. Documents including external fonts will fail on a free account.
You can always try to find a way to import them using data-uri but it's out of the scope of this documentation.
To import a font from Google Fonts, go to https://fonts.google.com/ and search for a font you like. Once found, you can select one or several variants (weight, italic, etc) that you want to use.
In the right panel it will give you a
<link>code that you can copy at the top of your HTML.
Let's import Roboto by selecting its regular and bold styles for instance:
<!-- Importing Roboto, regular and bold -->
<link href="https://fonts.googleapis.com/css2?family=Roboto:[email protected];700&display=swap" rel="stylesheet">
Once you have added the font, you can use it in your CSS:
Alternatively you can use any paid font-hosting service you're subscribed to or simply use self-hosted fonts.
For those cases, import the fonts using a
<link>tag pointing to the CSS of the font. This CSS and the font files need to be publicly accessible otherwise they will not load in PDFMonkey.
PDFMonkey does support icon fonts like Font Awesome or Material Icons. Please refer to the documentation of the font you want to use to learn how to import it.