How to change login screen background?

Hey guys,

Sorry if this is not the right place for this, but I was just wondering how I can go about changing the Login screen background? - I assume I can just replace an image file somewhere on the file-system?

Also, just so I know does MATE on Ubuntu 14.04 use MDM or GDM?

Thanks in advance,

It’s actually using lightdm-gtk. To change the background for the login change “background =” line in the file “/etc/lightdm/lightdm-gtk-greeter-ubuntu-mate.conf” and make it point to whatever image you want to use (for example: “background = /usr/share/backgrounds/41621_anime_scenery.jpg”). I usually copy the image to “/usr/share/backgrounds” and make sure the permissions give everyone read access at least.

1 Like

Thanks very much for your reply, I’ll give that a go :smiley:

2020 and now the first item in the Control Panel under Administration is "Login Window". Very user friendly.

It shows you the path where the images are coming from if you want to add one of your own. Only catch could be making sure everybody has permission to read the file.

May 2022
Now under UM 22.04
Can't figure how to change login screen background
And there is no item in the Control Panel under Administration named "Login Window"
I've looked through other posts, used a few 'tricks' recommended, but no use.
What is it that I am missing ?

Some things changed under the hood which resulted in a bug.
See this:

and this:

and the "won't fix" answer of the author.

so you have to edit a configfile manually:
sudo pluma /usr/share/glib-2.0/schemas/30_ubuntu-mate.gschema.override

and change the background= entry

then recompile the schemas:
sudo glib-compile-schemas /usr/share/glib-2.0/schemas/.

This seems to be the accepted workaround for the time being.
It lacks a bit in elegance I'm afraid. But it works pretty well.

1 Like

See also this solution

Is there any EASIER way to change the login screen like the previous version which was way easy to change the background !!!!! :face_with_raised_eyebrow: :laughing: :laughing: :hot_face:

EDIT: improved code

Not that I know, I am eager to know if there is any.

At the moment I use this:

  1. copy & paste this to a file

exec &>/dev/null
source "$HOME/.config/user-dirs.dirs"

text1="Login Background Changer"
text2="Select Background for Login"

	rm $tmpfile
	sudo -k
trap "cleanup" INT TERM EXIT

zenity --title="$text1" --password | sudo -S true || exit

if ! grep "background='$mybg'" "$configfile"
	sudo sed -i "s|background=.*|background='$mybg'|g" "$configfile"
	sudo glib-compile-schemas "$schemadir/."

eom "$mybg" &

sleep 1
cp "$(zenity --title="$text2" --file-selection --filename="$XDG_PICTURES_DIR/*")" "$tmpfile" || exit
sudo cp "$tmpfile" "$mybg"

eom "$mybg"
  1. make that file executable.

from now on I only have to click the file whenever I want to change the background of the login screen.

Yeah, it's not ideal but it's at least a decent workaround for the time being.


Zenity is very limited in functions. I prefer Yad dialog.
However Debian still packages ancient gtk2 version of yad,
bullsye having 0.40.0-1, bookworm/sid have 0.40.0-1+b1,
which is binary NMU (Non-maintainer upload) since there is +b suffix at the end.
There is a bug report but not addressed.
And Ubuntu pulls from Debian.

Current Yad version is 12 on Github. Releases · v1cont/yad · GitHub
Anyway even with such an old version much more can be achieved with yad than zenity.

1 Like

I totally agree :slight_smile:
I like yad , it can do multiple things in a single window, it is indeed a major enhancement compared to zenity.

One step beyond yad is gtkdialog which can be used to build complete graphical interfaces.
It has become abandoned, picked up again, forked at least three times etc. so although it is a pretty good interface for bash scripts, and I really love it, its future is uncertain.

The only reason i reverted to zenity for this hack is the fact that it is already present on every Ubuntu-MATE install so nobody needs to install extra packages to get this running.

I had some thoughts about doing this in gtk/glade + C or wxglade + python but that is a bit much work for what I consider as a temporary stopgap. Also a bit harder to post in the forum. :grin:
It would be much less work to revert to the old tried and tested slick-greeter.

So that is how i came to dig up the old zenity :slight_smile:

Hey guys,

I have figured it out how to change the Boring Login Screen in Ubuntu Mate 22.04

Check the picture and you will see the path and with image file should be changed in order to have a nice login screen once you log out. :+1: :+1: :+1: :+1: :+1: :+1: :+1: :+1: :sunglasses: :sunglasses:

Just change the image with maintaining the same image file and enjoy...

1 Like

seems too easy! But I'll try it!

This solution is working for me, thanks!

doing this worked! Easy Peasy!

Yes, it works. Thank you very much.

It works for me, thank you!

It didn't work with a .jpeg image all I got was a black screen, but I saved the image as a .png and then it worked.

been told that the file is included in the default Jammy wallpapers, so if that gets updated, your changes will be lost and image will revert to the original one.