A GNOME Shell extension to tell whether GNOME is running under Xorg or Wayland

Since the release of Fedora GNU/Linux 25 in November 2016, Wayland has become the default choice for Gnome Shell sessions (where supported by the underlying hardware stack).

Altough GNOME Shell under Wayland works very well (actually, better than under Xorg), it is sometime required (or preferred) to run Xorg instead  (ie, some applications requires Xorg, for example TeamViewer).

So, I often wondered whether I was running Wayland or Xorg.

Since I’m lazy I developed a very simple GNOME Shell extension which does exactly that.

Here’s how it looks like:

That’s my first GNOME Shell extension (also, I don’t quite like JavaScript…) so it is probably far from perfect!¬† The source code is publically available on GitHub. Suggestions and pull requests are very welcome!


One thought on “A GNOME Shell extension to tell whether GNOME is running under Xorg or Wayland

  1. Andreas WERNER

    I did exactly what you proposed, but it didn’t work.
    Fedora 26 Gnome 3.24.2

    But it was solved when I tried to restart Gnome with message:
    isn’t available with Wayland!

    Your extension isn’t available in Gnome tweak tool. But there is an option to open files for extensions. Maybe should be done this way.
    Why not push yr extension to https://extensions.gnome.org/



Leave a Reply

Your email address will not be published. Required fields are marked *

What is 8 + 12 ?
Please leave these two fields as-is:
IMPORTANT! To be able to proceed, you need to solve the following simple math (so we know that you are a human) :-)