Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I used to be able to copy&paste (or type if I load respective keyboard layout) any kind of characters (eg. é ö ñ ß و 好) in my console/terminal.

Now I bought a new computer and it does not work any more, only English/ASCII characters (but in other programs, e.g. firefox, it still works).

Distribution: Ubuntu. Terminals tried: gnome-terminal, xterm, konsole.

I tried setting LANG in /etc/environment to en_US.UTF-8 but after reboot echo $LANG still gives C. I also tried setting Character encoding to Unicode(UTF-8) in the gnome-terminal Terminal-menu - without effect.

Question: How can I get a terminal that is able to deal with non-English characters?

share|improve this question
up vote 5 down vote accepted

Locales are built upon request, because they can take a lot of space. You need to activate the locale by generating the associated data. Ubuntu undoubtedly has a GUI where you can set this, but I don't know where it is offhand. Run this once and for all in a terminal:

locale-gen en_US.UTF-8

You may need to log out and back in for the LANG value not to be sanitized down to C, but you should be able to test right now by running LANG=en_US.UTF-8 gnome-terminal.

By the way, I recommend LC_CTYPE instead of LANG. LC_CTYPE controls the character set only; LANG also affects other locale categories, in particular collation (i.e. character ordering), which can cause trouble occasionally.

share|improve this answer
locale-gen en_US.UTF-8 printed Generating locales... ` en_US.UTF-8... up-to-date` Generation complete., but after LANG=en_US.UTF-8 gnome-terminal in the new terminal it still prints only question marks. – Matthias 009 Apr 26 '12 at 13:25
however after reboot it does work! Thanks! – Matthias 009 Apr 26 '12 at 13:41

If you get your locales installed system-wide, try to set up fonts, that can display such a rare characters. There is a problem in Ubuntu in native console, when you have your locales set as UTF8_ru and UTF8_en, you can't type Russian, cause you need to set up Cyrillic fonts for that. So you need UTF8_yourlocale locale set up and appropriate console fonts installed.

And Mozilla, OO and other have their own localization packages, so it gives no effect for system-wide locale settings.

PS: Of course I may be wrong.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.