Enable or Disable Automatic Login in Debian 11 Bullseye

To secure our system we generally use a password to login into a Linux and other OS. However, if you are the only person who has access to your Linux system such as Debian 11 Bullseye then you can enable the autologin feature and here we will know how?

Systems that are in offices or in insure locations need to be secure with a login “password”. That a user has to enter every time he or she wants to access the files and other data residing in it. Well, this happens every time we start our computer or log out. It is a good thing but if you only work with the computer alone anyway, the repeated password entry is quite annoying. If you want to boot straight through to the desktop, you can log in automatically and switch off the password prompt when the system starts. Here we will show you how to do that in Debian-based systems.

Steps to Auto login in Debian 11 Bullseye

The steps given here will be the same for other Debian-based Linux systems such as Ubuntu including Linux Mint, POP_OS, MX Linux Elementary OS, and more…

There are two ways to enable autologin on Debian 11 with LightDM or GDM3, one is using the command terminal and the other via its default Gnome graphical Desktop user interface. Here we will show you both.

#1 Using Command line

Requirements

Debian Linux
File Editor such as Nano
A non-root sudo user

Debian 11 Bullseye – Apt Update

Run the system update command and after that install the popular easy-to-use “nano” editor.

sudo apt update
sudo apt install nano

 

Edit daemon Configuration file- for GDM display

Open command terminal on your Debian 11 Linux. After that, we will edit the Daemon configuration file that holds syntax that can enable the auto-login on our Debian 11 bullseye.

sudo nano /etc/gdm3/daemon.conf

In the file, your will see a line “Enabling Automatic login” with other setting “#AutomaticLoginEnable = true” and “#AutomaticLogin = user 1″.

Edit daemon Configuration

Enable AutoLogin in Debian 11

Just go to – AutomaticLoginEnable =true and remove the # tag and do the same for AutomcaicLogin as well. But here replace the “user 1” with your system user that you want to log in automatically with a system reboot.

Enable Autologin on Debian 11 bullseye

Save the file by pressing Ctlr+X, hit the Enter key, and then exit the same using – Ctlr+O.

Now, whenever you start your system it will not ask for a login password.

For LightDM (optional)

If you are using the LightDM as display manager instead GDm3, then edit

sudo nano /etc/lightdm/lightdm.conf

Scroll to the end of the file, add:

autologin-user=username

Note: Replace username with the user for you want to enable the autologin.

SaveCtrl+X, type Y, and hit the Enter key.

Set Auto login for LightDm

 

Disable Auto login on Debian 11

In case, in the future, you want to disable auto-login then again edit the same daemon file. And add # in front of two values we have edited.

Disable Auto login on Debian 11

Once you have added the # tag save the file again using Ctrl+X, press Y, and hit the Enter key.

Whereas for LightDM, simply remove the autologin-user=your-username

 

#2nd method using the graphical user interface

Enable or Disable Auto-Login in Gnome GUI

If you are using the default Gnome interface on Debian 11 then we can set system auto login easily using the graphical user interface.

Open Settings

Step 1: On your Debian 11, click on the Drop arrow icon given on the top right side.

Step 2: Select the Settings (with gear icon) option.

Step 3:  This will open Debian 11 Bullseye System settings.

Open Gnome Debian Settings

Unlock User Settings

Step 4:  Click on the Unlock button to edit the user settings, this will ask for your Administrator password.

Unlock to change the user settings

Turn On Automatic Login

Step 5: Scroll down to the “Authentication & Login” area and click on the Toggle-button given for “Automatic Login“.

Automatic Login Debian 11 Bullseye

 

Other Articles:

How to install Prometheus in Debian 11 
How to install sudo on Debian 11
Install free VMware Workstation Player on Debian 11

 

 

5 thoughts on “Enable or Disable Automatic Login in Debian 11 Bullseye”

  1. My old Sony Vaio PC runs Debian 11 Cinnamon and has a lightdm.conf file which is all commented-out so I edited this:
    root@Vaio:/home/vaio# sudo nano /etc/lightdm/lightdm.conf
    and appended the following two line entry:
    [SeatDefaults]
    autologin-user=vaio
    where vaio is the username of the account.
    Upon startup, a message “login: vaio” is briefly flashed on the screen and the Cinnamon desktop is then loaded.

    Reply

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.