« Web, HTML, Tech Forum

how to create and add you own fronts

just really looking for how to do this because im sick of the plain stuff


Report Topic

1 Reply

Reply by Dollita

posted

You can use custom fonts from Google Fonts or your own hosted fonts.

1/ Use Google Fonts


Go to [https://fonts.google.com](https://fonts.google.com)

Pick a font you like.

Click Get font ->Get embed code.

Copy the <link> and the CSS font-family name.


Then paste this into your SpaceHey About Me / CSS box:


html

<style>

@import url('font link');


body, .profile, .blog {

  font-family: 'Font Name', cursive;

}

</style>


2/ Use your own font file (TTF / OTF)


Sometimes it doesn’t work on blogs depending on the font. I learned that the hard way (ノ_ヽ)


Upload your font file to: Catbox, Neocities, GitHub, etc.

Get the direct link to the .ttf or .otf


Then add this:

html

<style>

@font-face {

  font-family: "MyFont";

  src: url("yourlink.ttf");

}


body, .profile, .blog {

  font-family: "MyFont";

}

</style>


Replace the URL with your font link.


Apply to only certain parts


Example: only blog text


css

.blog * {

  font-family: "MyFont";

}

 

Or if you’re too lazy, just use default web-safe fonts:

Verdana, Tahoma, Georgia, Trebuchet MS, Comic Sans MS, Courier New...

They work with no extra code. Just add:

css

body { font-family: "Comic Sans MS", cursive; }


I recommend Comic Sans MS, it’s fun (o^ ^o)


Permalink Report Reply