Objective
The following article will explain how to install fonts on Ubuntu 18.04 Bionic Beaver Linux
Operating System and Software Versions
- Operating System: – Ubuntu 18.04 Bionic Beaver
Requirements
Privileged access to your Ubuntu System as root or via sudo
command is required.
Conventions
- # – requires given linux commands to be executed with root privileges either directly as a root user or by use of
sudo
command - $ – requires given linux commands to be executed as a regular non-privileged user
Other Versions of this Tutorial
Instructions
This article will use Bitwise.ttf
as a sample TrueType Font to be installed on Ubuntu 18.04 Desktop.
This font and many other fonts can be freely downloaded from the https://www.1001freefonts.com/ website.
Alternatively, you can use the bellow wget
and unzip
commands to download and store Bitwise.ttf
into your Downloads directory:
$ wget -O ~/Downloads/bitwise.zip https://www.1001freefonts.com/d/8190/bitwise.zip $ unzip -p ~/Downloads/bitwise.zip Bitwise.ttf > ~/Downloads/Bitwise.ttf $ rm ~/Downloads/bitwise.zip
The Bitwise.ttf
font should now be stored in your Downloads
directory:
$ ls ~/Downloads/ Bitwise.ttf $ file ~/Downloads/Bitwise.ttf /home/linuxconfig/Downloads/Bitwise.ttf: TrueType Font data, 10 tables, 1st "OS/2", 18 names, Macintosh, type 1 string, BitwiseRegular
Install Fonts using Font Manager
The first and recommended approach to installing fonts on Ubuntu 18.04 Bionic Beaver is by use of Font Manager. Let’s start by the Font Manager installation in case Font Manager is not already installed on your system.
Open up terminal and enter:
$ sudo apt update && sudo apt -y install font-manager
Once the installation of Font Manager is completed, start the font manager by searching the Start/Activities menu:
Please note that when using Font Manager all new installed fonts are stored within the ~/.local/share/fonts/
user home directory. This means that the fonts will be accessible only to the user who actually performed the fonts installation.
Read the below section Manual system-wide font installation
on how to perform the system-wide font installation.
Manual user-space font installation
It is also possible to install new fonts manually by storing any new fonts into the ~/.fonts
directory located within the user home directory.
The font installation procedure is quite simple as all what needs to be done in order to install new fonts is to copy the actual font file into ~/.fonts
:
$ mkdir ~/.fonts $ cp ~/Downloads/Bitwise.ttf ~/.fonts
All done. If you need to sort your new installed fonts into a sub-directory feel free to do so. Any directory under ~/.fonts
will be included recursively and fonts picked up by the system.
Manual system-wide font installation
To install fonts system-wide, thus to be available for any user on the system, simply use the cp
command to copy the desired font file into the /usr/local/share/fonts
directory or create a new directory with /usr/local/share/fonts
if you wish to sort your installed fonts into a sub-directory.
The following linux command will install a new font file ~/Downloads/Bitwise.ttf
into a new directory eg. /usr/local/share/fonts/sample
:
$ sudo mkdir /usr/local/share/fonts/sample $ sudo cp ~/Downloads/Bitwise.ttf /usr/local/share/fonts/sample/
All done. No further configuration is required.