How to Install Fonts in Ubuntu

After a long time using Windows, I switched to Ubuntu, but I noticed that my own sites and other daily ones like Gmail and different other blogs I read where not looking as good as they were before the switch. Being a web developer I know that web sites are designed with Microsoft fonts in mind and the CSS style-sheets specify those fonts. Those fonts are often referred to as web safe fonts. So, the Microsoft fonts that my eyes were used to looking at were missing. Those fonts do not come pre-installed in Ubuntu so we have to install them ourselves. However, in Ubuntu we are not restricted to have only those MS fonts we mentioned, we can add as many new fonts as we like and that is cool. Below we will be explaining the way that we can install Microsoft fonts and how to add new fonts too.

How to install Microsoft fonts in Ubuntu

There is a package called msttcorefonts that you need to install in Ubuntu to enjoy the Microsoft’s web safe fonts in your computer. The Truetype Microsoft fonts provided in the package include:

  • Andale Mono
  • Arial Black
  • Arial (Bold, Italic, Bold Italic)
  • Comic Sans MS (Bold)
  • Courier New (Bold, Italic, Bold Italic)
  • Georgia (Bold, Italic, Bold Italic)
  • Impact
  • Times New Roman (Bold, Italic, Bold Italic)
  • Trebuchet (Bold, Italic, Bold Italic)
  • Verdana (Bold, Italic, Bold Italic)
  • Webdings

To install those fonts you need to run the following command from the terminal:

sudo apt-get install msttcorefonts

You will be asked for confirmation to continue installing those fonts. After you press ‘Y‘ you will see the package being extracted in your computer. Wait until that is done and you are done too.

How to install new fonts in Ubuntu

As we said above, we can have other new fresh cute fonts installed in Ubuntu. To do so you need to follow these steps:

  1. Have those cute fonts downloaded form the fonts site (e.g.: www.dafont.com).
  2. Go to Places –> Home Folder in Ubuntu.
  3. Go to View –> Show Hidden Files or do shortcut CTRL + H.
  4. If you are doing this for the first time, you need to create a new folder and name it .fonts. Otherwise, you just need to use the same folder always every time you add new fonts.
  5. Copy and paste your fonts there and you are done.

I cannot see the newly installed fonts

That’s right, you will not be able to see the fonts immediately after you install them. To make use of your newly installed fonts you need to do one of these to things:

  1. Log out and log in again to be able to see and use the new fonts.
  2. Or you can regenerate the fonts cache by running the following command (not needing to log out):
    sudo fc-cache -fv 

That was all, have fun with your fonts and do not forget to share your experience with us.