LinuxOpen Source SoftwareRaspberryPiTutorials

How to switch from Wayland to X11 on Raspberry Pi

Since the release of Raspberry Pi OS Bookworm (previously called Raspbian), the default display server now runs on Wayland. But depending on your hardware, Wayland might be slower on your Raspberry Pi or certain GUI applications don't work as they haven't been adjusted to work with Wayland.

Desktop freeze

In my particular situation a Raspberry Pi 4B 2GB was installed with the latest Raspberry Pi OS Bookworm to use it as a monitoring station. Chromium browser would remain open and a tab rotator add-on would switch between different monitoring overviews and observability dashboards.

Raspberry Pi with Wayland

However after a few days, the Desktop froze and Raspberry Pi needed to be rebooted (SSH was still working). This happened three times, after running for a couple of days.

Maybe X11 would be more stable on this older hardware?

Switching from Wayland to X11

Luckily a switch from Wayland to the older but proven stable X11 Desktop backend is not complicated. Just open the Raspberry Pi configuration by running the following command in a terminal:

$ sudo raspi-config

A (NCurses) menu comes up and offers you different configuration options.

Use your keyboard arrows and select "6 Advanced Options", confirm with the [Enter] key:

Raspberry Pi configuration

In the next next, select A6 Wayland:

Raspberry Pi configuration for Wayland

Now you can choose between X11 (X11 backend) or Wayfire (Wayland backend). By default Waywire is selected. Change the selection and select X11:

Raspberry Pi configuration switch between Desktop engines

You should get a confirmation that X11 is now active:

Raspberry Pi configuration

You should now be back in the "main menu" of the Raspberry Pi configuration. Choose "Finish" now.

Raspberry Pi configuration

In order to use the X11 Desktop now, you need to reboot. By finishing the Raspberry Pi configuration, this prompt comes up and asks you to reboot or not. You can also reboot later but only a reboot will switch the Desktop from Wayland to X11.

Raspberry Pi configuration asks for reboot

Reviewing the Switch to X11

After running more than a week on X11, the Raspberry Pi Desktop seems faster and definitely more stable than previously with Wayland. I have not experienced a single freeze – yet.

One negative side effect is that the default VNC Server (wayvnc) on Raspberry Pi does not work anymore, as this software is programmed for the Wayland backend. You would need to install a different VNC server in this case (but there are plenty of options, e.g. TigerVNC).

Claudio Kuenzler
Claudio has been writing way over 1000 articles on his own blog since 2008 already. He is fascinated by technology, especially Open Source Software. As a Senior Systems Engineer he has seen and solved a lot of problems - and writes about them.

You may also like

Comments are closed.

More in:Linux