Ask coding questions

← Back to all posts
font
KyraBradford

does anyone know the code to change the font in html?

Answered by Vandesm14 [earned 5 cycles]
View Answer
Voters
fingerpanic
KyraBradford
Comments
hotnewtop
Vandesm14

<p style="font-family: monospace">Hello World</p>
Just change the "monospace" to the font of your choice: https://www.w3.org/Style/Examples/007/fonts.en.html

Please mark this as answered if I helped your problem 👍

mwilki7

CSS example:

HTML example:

Sources:
https://www.w3schools.com/css/css_font.asp
https://www.w3schools.com/tags/tag_font.asp