Ubuntu Linux

How to Manage Logout Prompt on Ubuntu Linux

Richard
Written by
Richard
Feb 1, 2023 Updated Apr 18, 2026 2 min read
How to Manage Logout Prompt on Ubuntu Linux

This guide explains how to turn the logout confirmation screen on or off in Ubuntu Linux. This article has been tested on Ubuntu 22.04 LTS and 24.04 LTS.

Why: By default, Ubuntu asks if you are sure you want to log out. This prevents you from closing your programs by mistake. Turning it off makes logging out faster but removes the safety net.

What happens when done: If you turn the prompt off, your computer will close your session immediately when you click the logout button. If you turn it on, you will see a confirmation box every time.

Turn on or off log out prompt on Ubuntu Linux

Note: These settings are specific to the GNOME desktop environment. They may not function on Ubuntu flavors like Kubuntu (KDE) or Xubuntu (XFCE).

You can change this setting using the Terminal. First, open the Terminal by pressing CTRL + ALT + T on your keyboard.

Ubuntu Linux activities overview Terminal search
Ubuntu Linux activities overview Terminal search

To turn off the logout prompt, type this command and press Enter:

gsettings set org.gnome.SessionManager logout-prompt false

To turn the prompt back on, type this command and press Enter:

gsettings reset org.gnome.SessionManager logout-prompt

Disable or enable the logout prompt using the Dconf Editor

If you prefer using a visual menu instead of typing commands, you can use the Dconf Editor. If you are familiar with Windows, you know about Windows Registry Editor.

Ubuntu uses the Dconf Editor to change advanced system settings. You must install it first. Open your Terminal and run this command:

sudo apt install dconf-editor

You can also install it via the App Center by searching for “Dconf Editor.”

ubuntu linux decon editor install
Ubuntu Linux decon editor install

After opening the Dconf Editor, follow these steps:

  • Navigate to: org -> gnome -> gnome-session
  • Find the logout-prompt setting in the list.
  • Toggle the switch to On to enable the prompt.
  • Toggle the switch to Off to disable the prompt.
Ubuntu Linux turn on or off log out prompt
Ubuntu Linux turns on or off the log-out prompt.

Once finished, your computer will follow your new rule the next time you try to sign out.

Ubuntu Linux logout prompt
Ubuntu Linux logout prompt

Conclusion

You now know how to customize your logout experience. Whether you prefer speed or safety, these tools give you full control.

Please remember that this is a data-loss prevention setting. It helps you avoid closing your work accidentally, but it is not a security authentication measure. For more information on managing your system, see How to add or remove software on Ubuntu Linux.

Was this guide helpful?

Richard

About the Author

Richard

Tech Writer, IT Professional

Richard, the owner and lead writer at Geek Rewind, is a tech enthusiast passionate about simplifying complex IT topics. His years of hands-on experience in system administration and enterprise IT operations have honed his ability to provide practical insights and solutions. Richard aims to make technology more accessible and actionable. He's deeply committed to the Geek Rewind community, always ready to answer questions and engage in discussions.

2457 articles → Twitter

📚 Related Tutorials

Enable Mobile Hotspot on Ubuntu Linux
Ubuntu Linux Enable Mobile Hotspot on Ubuntu Linux
Enable or Disable Dim Screen in Ubuntu Linux
Ubuntu Linux Enable or Disable Dim Screen in Ubuntu Linux
How to Add Desktop Icons in Ubuntu Linux
Ubuntu Linux How to Add Desktop Icons in Ubuntu Linux
How to Enable Visual Alerts on Ubuntu Linux
Ubuntu Linux How to Enable Visual Alerts on Ubuntu Linux

Leave a Reply

Your email address will not be published. Required fields are marked *