How to Disable Welcome Screen (First Login Dialog) in Ubuntu 22.04

Last updated: January 20, 2023 — 2 Comments

When first time logging in a user account, it always pop-up a welcome dialog to setup online account, livepath, privacy, etc in Ubuntu.

It’s quite annoying if you create new user accounts regularly, since all options in that dialog are also available in system settings. In this case, you can follow this tutorial to disable this function in Ubuntu 22.04 and Ubuntu 22.10.

Tip: run /usr/libexec/gnome-initial-setup --existing-user command in terminal can manually launch Welcome dialog if need in Ubuntu.

Welcome dialog in user first login

Method 1: Remove the Welcome package

The Welcome to Ubuntu dialog is handled by the gnome-initial-setup package. It’s safe to remove the package, as no other packages depend on it.

So, the most stupid and simple way to disable this feature is press Ctrl+Alt+T on keyboard to open terminal, and run command to remove the package:

sudo apt remove --autoremove gnome-initial-setup

Method 2: Disable welcome by editing the service

Without removing the package, you may also disable the feature by adding a rule into the systemd user service.

The old method by editing the “gnome-initial-setup-first-login.desktop” file under auto-start config folder (‘/etc/xdg/autostart‘) does no longer work in Ubuntu 22.04, due to rule X-GNOME-HiddenUnderSystemd=true. Meaning, the XDG Autostart config is overridden by a systemd service.

The key is the systemd service “gnome-initial-setup-first-login.service“. However, it’s running in per user level automatically at login. It’s easy to disable or mask the service for current user by running command:

systemctl --user --now mask gnome-initial-setup-first-login.service

Or, specify which user to disable/mask the service for via command:

systemctl --user --now --machine=USER_NAME_HERE@ mask gnome-initial-setup-first-login.service.service

But, I can’t figure out how to disable the service for all users, especially for non-exist user before you creating it, because you know it runs only on first login for new user (exactly until you done the welcome dialog that auto-generates gnome-initial-setup-done file in user’s .config folder.).

As a workaround, you can add a rule into the service file to skip Welcome dialog automatically for all users:

1. Firstly, press Ctrl+Alt+T on keyboard to open a terminal window. When terminal opens, copy the service file into “/etc” directory.

sudo cp /usr/lib/systemd/user/gnome-initial-setup-first-login.service /etc/systemd/user/

It works by editing the service file under ‘/usr/lib’, but changes will be overridden once Ubuntu published an update for it. So, it’s better to copy and paste it into ‘/etc’ which has higher priority.

2. Then, run command to edit the service file:

sudo gedit /etc/systemd/user/gnome-initial-setup-first-login.service

For Ubuntu 22.10, replace gedit since it’s no longer default text editor, with nano

3. When the file opens, add following lines under [unit] section:

# Only run when ‘file-name-never-use’ file exist, meaning disable this service
ConditionPathExists=%E/file-name-never-use

It means only start the service when “file-name-never-use” file exist in user’s .config folder, while the first line started with # is description line.

Finally, save the file. For nano, press Ctrl+X, type y and hit Enter.

4. (skip this step if you’ve never edited the file) In case you’ve changed the XDG auto-start for gnome-initial-setup, open terminal (Ctrl+Alt+T) and run command:

sudo gedit /etc/xdg/autostart/gnome-initial-setup-first-login.desktop

When file opens, make sure there’s a line X-GNOME-HiddenUnderSystemd=true, so it won’t run because of the service you configured in previous steps.

That’s all, you can now try creating a user account and logging in to see the magic!

Twitter

I'm a freelance blogger who started using Ubuntu in 2007 and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please comment to remind me outdated tutorial! And, notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me via [email protected] Buy me a coffee: https://ko-fi.com/ubuntuhandbook1

2 responses to How to Disable Welcome Screen (First Login Dialog) in Ubuntu 22.04

  1. This is the second time the past content of this blog is gone. What happened there?

Leave a Reply

Text formatting is available via select HTML.

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> 

*

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