How to enable guest account automatic login?

I noticed in Ubuntu 11.10, that finally there is possible to log in with guest account already from log in screen. The last step is remaining – how to enable the guest account automatically log in, e.g. when computer starts? This would be very helpful for public computers, e.g. in libraries, schools, universities, student campus etc. This would be workaround for user account deep freeze feature, which is still missing from Ubuntu.

Here is Solutions:

We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.

Solution 1

Edit /etc/lightdm/lightdm.conf with your favourite editor like gksu gedit /etc/lightdm/lightdm.conf
and under the section [SeatDefaults] add


Solution 2

For both Ubuntu 14.10 and Ubuntu 15.10 this is what worked for me:

sudo nano /etc/lightdm/lightdm.conf

with the following content


What did not work for me under Ubuntu 14.10 (Note: this was not tried under Ubuntu 15.10)…

  1. Creating the 50-autoguest.conf file in /usr/share/lightdm/lightdm.conf.d/
  2. Creating the 50-autoguest.conf file in /etc/lightdm/lightdm.conf.d/
  3. Having the setting allow-guest=true in the settings file (that disabled Guest session altogether).

According to the LightDM wiki entry, the right place to put such modifications is in


The following path is for the system-provided configuration only



The way I solved this was ‘brute force’. I knew that I could set an auto-login using a regular account in Ubuntu 14.10 so I did that in Settings. Then I looked in the three locations I knew of where the auto-login preference was stored and, voila, the file /etc/lightdm/lightdm.conf was created with a single entry for the account that was subject to auto login. Figuring that less is more I commented out the entry (prefixed #) and added only autologin-guest=true and it worked!

PS nano is my preferred command-line text editor. Its simple to use. That said, use whatever is your preferred text editor, e.g. gksu gedit if you prefer a GUI text editor.

Solution 3

The lightdm config file location has changed in Ubuntu 14.04. To accomplish the same you need to create a new file /usr/share/lightdm/lightdm.conf.d/50-auto-guest.conf, for example by running

gksu gedit /usr/share/lightdm/lightdm.conf.d/50-auto-guest.conf

and putting in this content:


Solution 4

Solution suggested by JumpingJuniper works for me too, but only following all of his path.

before adding



sudo vi /etc/lightdm/lightdm.conf

you must enable autologin for one user using graphical interface. …or find where you need to change something else. I checked every /usr/share/lightdm/lightdm.conf.d file without success

Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂

All methods was sourced from or, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply