Convert WOFF2 to TTF or TTF to WOFF2 in Ubuntu

In this article, we would discuss how to convert WOFF2 to TTF or TTF to WOFF2 in Ubuntu. WOFF is an acronym from Web Open Font Format. And, WOFF2 is WOFF File Format 2.0. The only difference between WOFF and WOFF2 is that of compression algorithm used.

whereas, TTF stands for TrueType Font. It was designed by Apple Computer, Inc.

Note: Part of following instructions would require you to have superuser privileges. In case you don’t have one, then we advise you to contact your System Administrator.

Install woff2 package in Ubuntu

First, we have to install the woff2 package. woff2 contains woff2_decompress and woff2_compress, command-line utilities. Furthermore, woff2_decompress helps us get WOFF2 to TTF. Whereas, woff2_compress – TTF to WOFF2.

As the package – woff2 is already available through Ubuntu repository. Therefore, issue the following in terminal –

sudo apt update

This updates the repository and makes the latest version of packages available to install.

Next, to install woff2

sudo apt install woff2

Convert WOFF2 to TTF in Ubuntu

Simply, issue the following in terminal –

woff2_decompress <font_name>.woff2

Convert TTF to WOFF2 in Ubuntu

Alternately,

woff2_compress <font_name>.ttf

In conclusion, we have discussed how to get WOFF2/TTF to TTF/WOFF2 in Ubuntu.

Similar Posts