I have an issue regarding neomutt not displaying the Swedish characters å, ä and ö.

When typing locale in the terminal I get:


When viewing the subject text in neomutt I get an question mark whenever it should be a character å, ä or ö. When I open an email I get \366 instead of ö, \345 instead of å and \344 instead of ä.

I'm using 5.0.7-arch1-1-ARCH.

  • what is the output of locale charmap ? – Radovan Garabík Apr 19 '19 at 19:00
  • octal 366 is the iso8859-1 encoding of ö, not the UTF-8 encoding. Chances are those emails are not properly formatted. If you press h within neomutt when viewing that email, do you see a Content-Type header? What does it say for the charset? – Stéphane Chazelas Apr 19 '19 at 19:52
  • 1
    Finally found the solution. My initial setting of LC_COLLATE=sv_SE.UTF-8 didn't work as it should've, I had to set it to sv_SE.utf8. So now the characters in the email body text works but I still can't see the correct characters in the subject text when viewing all the emails. – Ramo Mislimi Apr 20 '19 at 6:24
  • 1
    Also found the solution to the issue with my subject text. I tried sending myself a email with åäö and it showed up in my subject text. I found it weird because all my other mail didn't show those characters in it's subject text. I therefore tried refreshing my cache to see if it was because they were stored differently, which it did. Everything seems to be working now! – Ramo Mislimi Apr 20 '19 at 6:41
  • 2
    @RamoMislimi You should submit you findings and solution as an answer (and later accept that answer). Doing so would benefit people with the same issue as you. You should also mention (in the question) what Unix you are using as locale names may differ between Unices. – Kusalananda Apr 20 '19 at 8:08

The solution was to change the incorrect locale settings. Initially when I did set up my locales I enteret the same locale name that was found in /etc/locale.gen, which was sv_SE.UTF-8.

When you uncomment the locale of your choice in /etc/locale.gen you have to run locale-gen which is a program that reads locale.gen and generates localisation files. The available ones can now be found by running locale -a in the terminal.

When I ran locale -a I noticed that the sv_SE.UTF-8 wasn't an option, but sv_SE.utf8 was. What I then had to do was change my locale configurations in /etc/locale.conf and make sure that LC_COLLATE was set to sv_SE.utf8 instead of sv_SE.UTF-8. After doing this the new settings will be applied after reboot of the machine. You can also change the locale temporarily by running export LC_COLLATE=sv_SE.utf8 and then try to run neomutt to confirm that the correct characters are shown.

Efter you've rebooted your machine you can run locale to check if the locales has been changed.

Another solution is to add export LC_*=sv_SE.utf8 in your profile file that is being executed whenever you open a new terminal window.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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