How to add a custom font
Looking to add a custom font to your website that is not a Google Font?
To add a custom font to your website follow these steps:
- Obtain the URL for your font file. Typically this is a .otf or .ttf file, like: https://example.com/your-font-location/assets/Roboto-SemiBold.otf
- Navigate to Custom Coding > CSS
- Add the following CSS (replace the URL with your custom font URL):
@font-face {
src: url(https://example.com/your-font-location/assets/Roboto-SemiBold.otf);
font-family: title-font-custom;
}
:root {
--title-font: title-font-custom;
} - Save and publish