How to Install and Run GUI on Raspberry Pi

Install And Set Up GUI On Raspberry Pi

Raspberry Pi is a powerful computer through which you can do a lot of amazing things. Because of its computing power, it is now really ideal for multiple DIY projects. If for some reason during the installation of Raspbian, you forgot to set up the GUI correctly, you will be booted into the command line interface. Or, maybe you installed the Lite version, and now you wish to install GUI in the Pi.

Install and Run GUI on Raspberry Pi

In this article, we will take a look at how can we install and set up the GUI to run on the system startup.

Step 1: Log in to your Raspberry Pi

When you first boot into the command line, log in with your username and password. I case you haven’t changed anything, the default username is ‘pi’ and the default password is ‘raspberry’

Step 2: Connect to Wi-Fi

If you have Ethernet, you can skip this step. Type the following commands so that we have our network SSID first.

sudo iwlist wlan0 scan

This will give you the SSID of all the Wi-Fi networks near you. Note down the SSID of your network. Now, type the following commands to add our Wi-Fi network to the Pi :

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf

At the bottom of the file, add the following lines :

network={
  ssid="YOUR_SSID"
  psk="YOUR_PASSWORD"
}

Press Ctrl+O to save the file, and press Ctrl+X to exit.

Step 3: Install the GUI

Update apt, and then install the raspberrypi-ui-mods and rpi-chromium-mods packages by typing out the following commands :

sudo apt-get update && sudo apt-get -y dist-upgrade && sudo apt-get install raspberrypi-ui-mods rpi-chromium-mods

When the installation is finished, simply reboot your Pi by typing the following commands :

sudo reboot

Step 4: More Configuration

If even after the installation, your Pi doesn’t boot into the Desktop Interface, then we will manually enable the GUI from the config file. Type :

sudo raspi-config

Look for a setting named ‘Enable Boot to Desktop/Scratch’ navigate to it by pressing the tab key or arrow keys and then press enter.

Choose Desktop Login as user ‘Pi’ at the graphical desktop from the next menu. After that, Pi will ask you to reboot, tab to Yes, and then press enter. You should now successfully boot into the LXDE desktop Environment of Raspbian OS.

Summary

We hope you have successfully installed or correctly set up the GUI on your Raspbian OS using this article as your guide. You can now use your Pi as a Desktop Computer.