When you turn on your computer, after the operating system has booted up it will often land on the login screen where you have to enter your password to log in to your desktop. If your computer is already physically secured, or if there is little chance that others will have access to your computer, then you might want to enable automatic login so you can access the desktop faster.
We have shown you how you can enable automatic login in Ubuntu, but if you are using LightDM, here are the steps to enable autologin in LightDM.
How to Enable autologin in LighDM
1. Open a terminal and type:
sudo nano /etc/lightdm/lightdm.conf
2. Scroll down the page and find the lines:
#autologin-guest=false #autologin-user=user #autologin-user-timeout=0
3. Uncomment the lines by removing the “#” in front of each line. Change the autologin-user
field to your username. It will look something like this:
autologin-guest=false autologin-user=damien autologin-user-timeout=0
4. Save the file by pressing Ctrl + O and exit (using shortcut keys Ctrl + x).
Restart the computer, and it should auto-login to the desktop.
Extra Settings for Different Linux Distros
Linux Mint
Linux Mint’s Cinnamon desktop is using LightDM by default, but it doesn’t come with the “lightdm.conf” file. Do the following steps instead:
1. Open the file:
sudo nano /etc/lightdm/lightdm.conf.d/70-linuxmint.conf
2. Add the following lines, changing “damien” to your own. username:
autologin-guest=false autologin-user=damien autologin-user-timeout=0
Save and exit the file. Restart the computer for it to take effect.
Arch Linux
If you are using Arch Linux, you have to add your user to the autologin
group before it can work:
sudo groupadd -r autologin sudo gpasswd -a username autologin
After that, follow the steps above to enable the autologin
lines in the lightdm.conf file.
It is pretty easy for anyone to enable auto-login for LightDM as long as you have deemed it safe to do so. Let us know if you are having issues or if it doesn’t work for your distro.
Our latest tutorials delivered straight to your inbox