Installing Fonts in Linux

Jack Wallen
Jan 9, 2009
Updated • Dec 2, 2012

If you do much desktop publishing or graphics work in Linux than you might be at a place where you are struggling to get fonts installed. Well never fear - it's not nearly as difficult as it sounds. In fact, installing fonts in Linux is quite easy. Of course the easiest means to installing fonts in Linux is with the command line. In this article you are going to learn how to install true type fonts both per user and globally.

Naturally one of the issues with fonts is where to get them. If you do a search for "free fonts" you will come up with plenty of sites that offer fonts. There are even sites that sell fonts for a reasonable price. Of course if you are serious about desktop publishing or graphics you will want to look at higher quality fonts. On with the installation.

Per User Installation

By far the easiest installation is the per user installation. What this type of install does is install the fonts in such a way that only the targeted use has access to the fonts. For this type of installation download all of your fonts into a directory the user has access to (the ~/Downloads directory works fine.) Once you have your fonts collected (You will most likely have to unzip each file which will result in either .ttf or .TTF files) do the following (all in a terminal window) within the directory containing your downloaded fonts.

mkdir ~/.fonts

mv *ttf *TTF ~/.fonts

Now log out of your desktop environment and log back in. Those fonts should now be available to you. If you're unsure you can fire up either OpenOffice or The GIMP to see if your fonts are available. They should be.

Global Installation

Installing fonts globally allows all users access to the fonts. This is not as simple as installing per-user but it is still simple. You sill have to download all of your fonts. Once you have them downloaded unzip the files (making sure all the *ttf and *TTF files are in the same directory) and su to the root user. Once you are the root user issue the following commands:

  • mkdir   -p /usr/local/share/fonts/ttfonts
  • mv *ttf *TTF /usr/local/share/fonts/ttfonts
  • cd   /usr/local/share/fonts/ttfonts
  • ttmkfdir   -o fonts.scale
  • mkfontdir
  • chkfontpath   --add /usr/local/share/fonts/ttfonts
  • /etc/rc.d/init.d/xfs   restart

Now log out of your desktop and you can log in as any user and the fonts will be available to them.

Final Thoughts

See, installing fonts in Linux isn't difficult - especially when installing on a per user basis. For most people the first method will suffice. Unless you work on a machine that is used by more than one user, you will only need the per user method. Of course if the global installation method is a bit daunting you can always copy the fonts into the ~/.fonts directory of every user that needs access to the various true type fonts.


Previous Post: «
Next Post: «


  1. Loki said on January 11, 2009 at 7:21 am

    Thanks Jack, now how do we get these fonts to render like they do in Windows? Segoue UI is a beautiful font in Windows but looks horrible in Limux. I’ve tried many different settings in FreeType and even a couple of scripts but fonts still look bad. Please help.

  2. Paul. said on January 10, 2009 at 1:53 pm

    Thanks Jack and Stefan. Christal clear explenation again.

  3. iampriteshdesai said on January 10, 2009 at 8:28 am

    Here you can see how to install beautiful Vista fonts in Ubuntu:

  4. Stefan said on January 9, 2009 at 10:51 pm

    no problem. I’m still a bit of a Linux noob but I do have useful ideas sometimes :)

    Thanks for your linux articles, btw, they’re very useful (I’m using Xubuntu/E16 because of your posts on Enlightenment)

  5. jack said on January 9, 2009 at 10:47 pm

    Stefan: now that’s a cool solution. Thanks for that.

  6. Stefan said on January 9, 2009 at 10:43 pm

    the quickest way would probably be to make a single /Fonts folder somewhere and then use fstab to mount it to the ~/.fonts folder in each user’s Home directory, that should work, right? (I’m pretty sure you can mount folders to multiple locations)

    That way, instead of putting them in each user’s ~/.fonts folder, you just put it in your master folder and it’s done automatically

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.