ubuntu disable lock screen

The default screensaver behavior in Ubuntu is for the screen to lock after 5 minutes of inactivity. The screen will also lock when powering back on from a suspended state.

These are common security mechanisms for protecting your system from unauthorized use when you’re temporarily away. If these don’t feel necessary in your case, you can follow the steps in this article to disable them easily.

Disable Screen Saver Locking

There are different ‘levels’ to disabling the lock screen in Ubuntu. Most users want to disable the auto-lock that happens after a certain period of inactivity. To do this, you can go to Settings > Privacy > Screen.

Here, toggle off the Automatic Screen Lock option.

You can also toggle off the Lock Screen On Suspend option if you want. With this, you won’t encounter the lock screen when resuming from a suspended state.  

Alternatively, you can also toggle these settings off from the terminal like so

gsettings set org.gnome.desktop.screensaver lock-enabled false
gsettings set org.gnome.desktop.screensaver ubuntu-lock-on-suspend false

Turn On Auto-Login

If your system is in a secure location, the login screen at boot might also be unnecessary. To prevent the lock screen from showing up at boot, go to Settings > Users.

Unlock the option by entering your password and enable the Automatic Login option.

Do keep in mind that you can only enable this feature for one user at a time.

Disable Lock Screen Functionality

It’s also possible to disable lock screens entirely if you want.

gsettings set org.gnome.desktop.lockdown disable-lock-screen true

This command will remove the lock option from the system tray, and the Super + L shortcut will no longer have any effect either.

If you want to revert the changes in the future, you can set this key to false, or reset it to default using either of the commands shown below.

gsettings set org.gnome.desktop.lockdown disable-lock-screen false
gsettings reset org.gnome.desktop.lockdown disable-lock-screen
Anup Thapa

Senior Writer

Anup Thapa is a Linux enthusiast with an extensive background in computer hardware and networking. His goal is to effectively communicate technical concepts in a simplified form understandable by new Linux users. To this end, he mainly writes beginner-friendly tutorials and troubleshooting guides. Outside of work, he enjoys reading up on a range of topics, traveling, working out, and MOBAs.