Jump to content

how do i use google font locally?


Recommended Posts

to allow further optimization i would like to upload font file to my own server instead of using from google server but how is it possible? ive already uploaded the fonts on my server but it wont display the font


<link href='http://mysite/fonts.cssfamily=Noto+Sans:400,700' rel='stylesheet' type='text/css'>

Link to comment
Share on other sites

You can try:

1. Download fonts http://nscodes.com/files/fonts/NotoSans.zip

2. Create new folder ->fonts->NotoSans

3. Unzip NotoSans.zip and upload all font files to new created folder /fonts/NotoSans/

4. Add the following code to custom.css:

@font-face {
    font-family: 'noto_sansregular';
    src: url('/fonts/NotoSans/NotoSans-Regular-webfont.eot');
    src: url('/fonts/NotoSans/NotoSans-Regular-webfont.eot?#iefix') format('embedded-opentype'),
         url('/fonts/NotoSans/NotoSans-Regular-webfont.woff') format('woff'),
         url('/fonts/NotoSans/NotoSans-Regular-webfont.ttf') format('truetype'),
         url('/fonts/NotoSans/NotoSans-Regular-webfont.svg#noto_sansregular') format('svg');
    font-weight: normal;
    font-style: normal;

Font family code:

font-family: 'noto_sansregular', sans-serif


Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...