QuestionsCategory: Technicalis it not possible to add custom fonts?
apps4 asked 3 months ago

I’ve used another plugin to upload a custom font, but can’t see how I can use it since it’s not a Google font. Any ideas?

4 Answers
Khanh Hoang Staff answered 3 months ago

You don’t need any plugins, simply upload folder custom fonts you want to child theme, use file style.css in child theme and Refer to using font-face here:
https://stackoverflow.com/questions/12144000/using-custom-fonts-using-css
https://www.w3schools.com/csSref/css3_pr_font-face_rule.asp
Example:
@font-face {
font-family: ‘{name font}’;
src: url(‘{url font in host}’) format(‘woff2’),
url(‘{url font in host}’) format(‘woff’);
font-weight: normal; // normal, bold, 100, 400 …
font-style: normal; // italic, normal, bold …
}

apps4 answered 3 months ago

Thanks!

apps4 answered 3 months ago

But then how do I reference that font on a Page or in the Typography settings? Should it appear on the dropdown list of fonts when assigning the H1 H2 fonts etc?

Khanh Hoang Staff answered 3 months ago

Font in theme options is google font only, you can add custom font in style child theme and css body, heading font-family by custom font, it’s short css.