Change system language on Ubuntu 22.04 from command line

The purpose of this tutorial is to show how to change the system language from command line on Ubuntu 22.04 Jammy Jellyfish. This configuration is especially applicable for Ubuntu 22.04 servers, where there is no GUI to change your system language, although this also works fine on desktop systems.

In this tutorial you will learn:

  • How to check system language settings
  • How to set new system language from command line
Change system language on Ubuntu 22.04 from command line
Change system language on Ubuntu 22.04 from command line
Software Requirements and Linux Command Line Conventions
Category Requirements, Conventions or Software Version Used
System Ubuntu 22.04 Jammy Jellyfish
Software N/A
Other Privileged access to your Linux system as root or via the sudo command.
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

Change system language on Ubuntu 22.04 from command line step by step instructions



  1. In the first step we will open a command line terminal and check the current system language settings. To do so, execute the locale command with no arguments:
    $ locale
    
    Check the current system language settings using locale command
    Check the current system language settings using locale command
  2. Next, we will reconfigure the current system language settings. To do so, execute the below dpkg-reconfigure command:
    $ sudo dpkg-reconfigure locales
    
    Re-configuring current locales language settings
    Re-configuring current locales language settings
    DID YOU KNOW?
    The systemd specific command to change system language is localectl which allows for more configuration options. However, in this case using dpkg-reconfigure is easier as it also automatically downloads the required language pack and directly provides the user with an option to set new system language in one go. In any case it is worth to check the man localectl for more information.
  3. Next, select your desired system language. Select system language from the menu using navigational arrows and SPACE. Once ready move to OK by using the TAB key and press ENTER.
    Choose system language and proceed
    Choose system language and proceed
  4. Next, select which language you wish to use as primary language for the entire system.

    Finish up by selecting system environment language
    Finish up by selecting system environment language



  5. Log out and log in to confirm your selection by execution the locale command.
    $ locale
    
    Check new language settings
    Check new language settings

Closing Thoughts

In this tutorial, we saw how to change the system langauge from the command line on Ubuntu 22.04 Jammy Jellyfish Linux. The new language settings should persist for all new packages installed, and will be observable across all areas of your system, provided that the packages you install have a translation available for the language you selected.