description: "Set up a GNOME desktop environment on WSL 2"
type: "post"
tags: ["Windows", "WSL", "Linux"]
---
*Originally posted as a [gist](https://gist.github.com/Ta180m/e1471413f62e3ed94e72001d42e77e22)*
**NOTE:** If you want the ultimate Linux desktop experience, I highly recommend installing Linux as your main OS. I no longer use Windows (except in a VM) so I will not be maintaining this guide anymore.
Think Xfce looks dated? Want a conventional Ubuntu experience? This tutorial will guide you through installing Ubuntu's default desktop environment, GNOME.
GNOME is one of the more complex — and that means more difficult to run — desktop environments, so [for](https://www.reddit.com/r/Windows10/comments/8dnyig/using_a_gui_with_wsl_on_windows_10_ubuntu_wsl/) [years](https://www.reddit.com/r/bashonubuntuonwindows/comments/9amqjr/gnome_desktop_using_vcxsrv_cant_make_it_work/) [people](https://askubuntu.com/questions/1169695/gnome-under-ubuntu-18-04-for-windows-wont-run) [couldn't](https://superuser.com/questions/1559755/gnome-desktop-environment-on-ubuntu-wsl-starting-error) [figure](https://www.reddit.com/r/bashonubuntuonwindows/comments/haof3n/cant_run_gnome_in_ubuntu_2004_lts_wsl/) [out](https://www.reddit.com/r/bashonubuntuonwindows/comments/eqwoxy/gnome_and_kde_in_wsl/) [how](https://www.reddit.com/r/bashonubuntuonwindows/comments/8dp2yu/gnome_or_kde_on_wsl/) [to](https://www.reddit.com/r/bashonubuntuonwindows/comments/hh0q9s/gnomesession_wsl2/) [run](https://www.reddit.com/r/bashonubuntuonwindows/comments/b222hp/running_everything_on_gnome/) [it](https://www.reddit.com/r/bashonubuntuonwindows/comments/8yfw8z/gnome_on_windows/) on WSL 2. On [WSL 1](https://github.com/Microsoft/WSL/issues/637) it could only run using very complicated methods that didn't transfer to well WSL 2. Any forlorn attempts to run it on WSL 2 only resulted in a smoldering heap of error messages.
__But now you can!__
## Requirements:
- WSL 2
- Ubuntu 20.04 (other distros not tested)
- An X server for Windows, such as [VcXsrv](https://sourceforge.net/projects/vcxsrv/)
- Basic knowledege on how to run GUI apps with WSL 2 (not required but highly recommended)
## Getting ready
You've been regularly updating your distro, haven't you?
```sh
sudo apt update
sudo apt upgrade
```
Install GNOME: (maybe go eat a snack while it's installing?)
Now you have a great GUI desktop and you won't need any intensive virtual machines anymore!
Profit?
## Notes
- You can disable the screensaver with `gsettings set org.gnome.desktop.session idle-delay 0`.
- You can also try KDE Plamsa using a similar method! Just `sudo apt install kde-plasma-desktop` instead and start it with `startplasma-x11`.
## Troubleshooting
If you can't get this to work, try [Xfce](https://github.com/QMonkey/wsl-tutorial/blob/master/README.wsl2.md).
If you still can't get it to work, you can ask for help on an online forum such as [r/bashonubuntuonwindows](https://www.reddit.com/r/bashonubuntuonwindows/).