utf8gen command not found

In this troubleshooting guide we learn how to fix utf8gen command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

utf8gen: command not found

or when using sudo you get the following error message

sudo: utf8gen: command not found

Solutions to utf8gen: command not found

How To Fix utf8gen: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu utf8gen is provided by utf8gen package.

utf8gen is:

The utf8gen package contains one program, utf8gen, which reads hexadecimal numbers interpreted as Unicode code points and produces formatted output. The numbers are provided one per line. Each number is optionally followed by a space plus miscellaneous text.

The output is specified by providing printf(3)-style format strings on the command line. This provides the flexibility to print UTF-8 byte values in any desired base, echo the input value formatted as a comment for any desired programming language, or even to provide HTML-like table entries. Optional miscellaneous text on each input line can be copied to the output.

To fix this problem, we can install more using the command below.

sudo apt-get -y install utf8gen

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install utf8gen.

sudo apt -y install utf8gen

Or if you have aptitude installed you can use the following command.

sudo aptitude install utf8gen

Summary

In this tutorial we learn how to fix utf8gen command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.