I start my command line in Ubuntu but if I type anything my keyboard is in qwerty. I want to change it to azerty. Is there a command that I can use to change it? If I go to the GUI of ubuntu, my keyboard is correct (azerty).


  • When exactly do you get azerty? Already at the login or only after login? Also, what type of keyboard do you use? (I personally have a case with the Logitech K350, which can not be set to another layout in advance with the Xorg configuration)
    – Adaephon
    Nov 18, 2014 at 12:22

2 Answers 2


This should set your keyboard to azerty in a terminal emulator:

setxkbmap fr

If on a console, that would be (as root):

loadkeys fr
  • 1
    Sorry, I have try your commands but it don't work... It's my first time that I work whit Ubuntu for school.
    – Mark
    Nov 18, 2014 at 15:20
  • Please elaborate the "don't work" part. Is there an error message ? Clarify too in what context this is happening. Is it the GRUB menu ? The text console login ? the graphical Login window ? Something else ??
    – jlliagre
    Nov 18, 2014 at 17:08
  • 2
    Kinda obvious, but use setxkbmap be or loadkeys beif you want to load the Belgian AZERTY layout.
    – BioGeek
    May 9, 2019 at 10:26
  • @BioGeek C'est vrai, les Belges ont aussi ces claviers azerty que le monde entier nous envie ;-)
    – jlliagre
    May 9, 2019 at 19:14

I tried what @jlliagre suggests but the OS told me "the permission is denied" so the solution here is very easy. If you are on the console you write sudo loadkeys fr to change the keyboard mode to azerty, then you enter your session password and finally all will be right.

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.