Both are display servers which is software that allows programs to write to the screen. X is older and was created back in 1984 at MIT and Wayland is a much newer protocol that is designed to work better on newer (post 90’s) hardware.
The biggest difference is that Wayland basicly allows your desktop direct access to the screen and X has a server that runs and allows your desktop to connect to it. X was originally designed to run remotely as back in the day there was one big commuter that many people connected to.
If this is all very confusing you probably should just stick to your distros defaults. Most of the time you don’t need to care.
Wayland is a communication protocol that specifies the communication between a display server and its clients, designed to be a replacement for the X11 window system protocol and architecture.
I might be a little nitpicky here, but I feel it’s an important distinction to make as there is no single common Wayland server like Xorg is for X11.
A display server using the Wayland protocol is called a Wayland compositor, as it additionally performs the task of a compositing window manager.
Xorg on the other hand is basically one fat display server designed like a house of cards that everyone uses.
Desktop Linux is in its never-ending process of replacing old displaying system with new one.
The process is long and not really transparent, because the two displaying systems were designed in completely different times for different hardware and with different security concerns in mind, therefore the X11 clients (all the software that was ever made or ported to Linux) are very much incompatible with Wayland. For backwards compatibility there’s Xwayland, which provides full blown Xorg server running on top of Wayland compositor with all the things X11 app requires. Until now, Firefox, even though had its Wayland backend as WIP feature (possible to activate with environment variable MOZ_ENABLE_WAYLAND=1) it defaulted to Xwayland on Wayland sessions. It now uses native Wayland backend by default providing better efficiency, DPI scaling, touchpad gestures etc
Wayland is a new implementation on how your system draws windows and components in your computer (I’m not sure if it’s responsible for the content) and it tries a different way to do it compared with xorg.
Xorg is the old implementation, and it has been patched to support most of the new features, and Wayland is trying to get the same features xorg has and some extras.
As a Linux user I have noted that sharing screen is more private in Wayland, also I think multi monitor refresh rate was a problem in xorg. One common issue with Wayland is the GPU compatibility, as far as I know Wayland runs better in AMD GPU I think is because of Mesa integration.
Xorg and Wayland are graphics systems. You may have seen a command line during boot with tons of text scrolling past, that’s all you get without either Xorg or some alternative running.
Xorg runs on X11, which was designed a long time ago during the mainframe era of computers. It used to be the standard for all GUIs on Linux, BSD, and other Unixlikes for ages.
However, modern computers are nothing like the computers X11 was originally based on, and X11 started showing shortcomings. So, years ago people working on Linux decided it was time to design a new system, one that’s designed around our modern computers and operating systems. That new system is Wayland, through Ubuntu sported their own Mir for a while too.
Wayland was designed not to be a network protocol (though you can still run applications on remote computers if you wish). It also has a bunch of security benefits, like “not every application can read your key strokes, copy your password, or record your screen without you noticing”.
This new system doesn’t have the benefit of multiple decades of hard work behind it. As you may imagine, this also broke applications for a while. There’s a tool called XWayland that can run X11 applications on Wayland, so most programs just work, but things like screen recording are severely limited under thst system.
On the other hand, if you’re on a laptop, Linux can now finally reliably use touch pad gestures with more than two fingers through Wayland. You could write scripts and tools to fake them before, but they’re actually part of the UI nlw.
Wayland does have APIs for almost everything now, but not all applications have been updated to use those APIs. For example, Zoom didn’t wait for the screen recording API to be standardised, so it implemented screen sharing under Wayland as “take a thousand screenshots”. Some programs work by listening for keyboard hotkeys (basically processing every key and checking if it’s their special hotkey) but that’s no longer supported unless the program has focus.
There were also issues with drivers (well, almost exclusively Nvidia) but those have mostly been solved. It’s not for everyone yet, but there’s no reason not to try Wayland if you don’t have a full Linux setup already, anymore.
As with any big change to the Linux ecosystem (systemd, anyone?) there’s a lot of fighting between people who want the shiny, better new thing, and people who liked the way things were before. Both sides have good arguments. Big parties in the Linux world, like Gnome and KDE, are moving towards a Wayland-only desktop. At the moment you can run Gnome and KDE on either, but that’ll be harder in the future. Other GUIs, like XFCE, are heavily geared towards X11, and it may take years before you can even run those on Wayland. Some, like i3, have replacements (Sway) that do almost the same thing.
Interestingly, hardware vendors also seem to go with Wayland for their custom Linux projects. For example, the Tizen watches Samsung used to sell run Wayland. The Steam Deck runs Wayland in game mode, using a purpose built Wayland compositor as a GUI, but X11 for desktop mode.
In practice, you shouldn’t need to worry about things too much right now. Some programs will not work on Wayland, others will not work on X11. Some games run a few fps faster on Wayland, others run faster on X11, but the differences aren’t huge. If both Xorg and Wayland are supported in your distro, you can switch between the two using a button on the login screen.
As for Firefox: Firefox has had native Wayland support for a while. It was already capable of using all the Wayland APIs and protocols at least a year ago. However, by default, it ran through XWayland, to remain as compatible as possible, while Wayland was still being tested. Now, with the upcoming release, Firefox goes native.
For Xorg users, nothing will change. For Wayland users with touchpads or touch screens, gestures like pinch to zoom will be smoother and there will be more of them. The only difference is that you don’t need to stuff MOZ_ENABLE_WAYLAND=1 in a script somewhere to activate the new capabilities on Wayland.
For a user: In Wayland programs are supposed to draw their own title bar. Java aplications and old applications must use a backwards compatibility layer that can cause flicker and bad font rendering. The terminology is different (compositor = window manager). Some niche new programs may only run on Wayland. Wayland hasn’t been adopted by BSD (AFAIK).
For a programners: Wayland has more modern, tidy code, but not all toolkits support it natively and few are easy. If you code exclusively for Wayland, a lot of users won’t use your program at the moment.
In Wayland programs are supposed to draw their own title bar
That’s incorrect. GNOME does it like this, Plasma doesn’t. KDE came up with a standard so a program can communicate this to the DE, GNOME slept on it. That’s why e.g. mpv doesn’t run well on GNOME.
Java aplications and old applications must use a backwards compatibility layer that can cause flicker and bad font rendering.
There have been efforts to provide better support for Java applications on the Wayland. For instance, the OpenJDK project has been making progress on implementing native “pure” Wayland toolkit integration not dependent upon XOrg/X11 or XWayland.
but not all toolkits support it natively and few are easy.
There have been significant developments in providing native support for Wayland in various toolkits. For example : Clutter, GLFW 3, SDL, GTK 3.20+, QT5+, EFL, Slint, Iced & OpenJDK. Just to name a few.
While it is true that not all toolkits have full native support, ongoing work is/has largely shifted towards much better Wayland support.
I am new to Linux. What’s the differences between Xorg and Wayland?
Both are display servers which is software that allows programs to write to the screen. X is older and was created back in 1984 at MIT and Wayland is a much newer protocol that is designed to work better on newer (post 90’s) hardware.
The biggest difference is that Wayland basicly allows your desktop direct access to the screen and X has a server that runs and allows your desktop to connect to it. X was originally designed to run remotely as back in the day there was one big commuter that many people connected to.
If this is all very confusing you probably should just stick to your distros defaults. Most of the time you don’t need to care.
Wayland is a communication protocol that specifies the communication between a display server and its clients, designed to be a replacement for the X11 window system protocol and architecture.
I might be a little nitpicky here, but I feel it’s an important distinction to make as there is no single common Wayland server like Xorg is for X11.
A display server using the Wayland protocol is called a Wayland compositor, as it additionally performs the task of a compositing window manager.
Xorg on the other hand is basically one fat display server designed like a house of cards that everyone uses.
That’s a good way to put it, thank you
From a user perspective, Wayland is smoother and looks nicer.
Desktop Linux is in its never-ending process of replacing old displaying system with new one. The process is long and not really transparent, because the two displaying systems were designed in completely different times for different hardware and with different security concerns in mind, therefore the X11 clients (all the software that was ever made or ported to Linux) are very much incompatible with Wayland. For backwards compatibility there’s Xwayland, which provides full blown Xorg server running on top of Wayland compositor with all the things X11 app requires. Until now, Firefox, even though had its Wayland backend as WIP feature (possible to activate with environment variable MOZ_ENABLE_WAYLAND=1) it defaulted to Xwayland on Wayland sessions. It now uses native Wayland backend by default providing better efficiency, DPI scaling, touchpad gestures etc
I’m not an erudite so feel free to correct me c:
Wayland is a new implementation on how your system draws windows and components in your computer (I’m not sure if it’s responsible for the content) and it tries a different way to do it compared with xorg.
Xorg is the old implementation, and it has been patched to support most of the new features, and Wayland is trying to get the same features xorg has and some extras.
As a Linux user I have noted that sharing screen is more private in Wayland, also I think multi monitor refresh rate was a problem in xorg. One common issue with Wayland is the GPU compatibility, as far as I know Wayland runs better in AMD GPU I think is because of Mesa integration.
I’m not an expert on the matter so have a Wikipedia link.
Thanks for all the responses. All of them have been so helpful. What I’m getting is that at this moment Wayland can be seen as a successor to Xorg?
I wouldn’t worry about it too much; there’s not really anything you need to do as a user anyway.
Xorg = Massive screen tearing
Wayland = No screen tearing
Xorg = Nvidia friendly
Wayland = Fuck you nvidia!
Xorg and Wayland are graphics systems. You may have seen a command line during boot with tons of text scrolling past, that’s all you get without either Xorg or some alternative running.
Xorg runs on X11, which was designed a long time ago during the mainframe era of computers. It used to be the standard for all GUIs on Linux, BSD, and other Unixlikes for ages.
However, modern computers are nothing like the computers X11 was originally based on, and X11 started showing shortcomings. So, years ago people working on Linux decided it was time to design a new system, one that’s designed around our modern computers and operating systems. That new system is Wayland, through Ubuntu sported their own Mir for a while too.
Wayland was designed not to be a network protocol (though you can still run applications on remote computers if you wish). It also has a bunch of security benefits, like “not every application can read your key strokes, copy your password, or record your screen without you noticing”.
This new system doesn’t have the benefit of multiple decades of hard work behind it. As you may imagine, this also broke applications for a while. There’s a tool called XWayland that can run X11 applications on Wayland, so most programs just work, but things like screen recording are severely limited under thst system.
On the other hand, if you’re on a laptop, Linux can now finally reliably use touch pad gestures with more than two fingers through Wayland. You could write scripts and tools to fake them before, but they’re actually part of the UI nlw.
Wayland does have APIs for almost everything now, but not all applications have been updated to use those APIs. For example, Zoom didn’t wait for the screen recording API to be standardised, so it implemented screen sharing under Wayland as “take a thousand screenshots”. Some programs work by listening for keyboard hotkeys (basically processing every key and checking if it’s their special hotkey) but that’s no longer supported unless the program has focus.
There were also issues with drivers (well, almost exclusively Nvidia) but those have mostly been solved. It’s not for everyone yet, but there’s no reason not to try Wayland if you don’t have a full Linux setup already, anymore.
As with any big change to the Linux ecosystem (systemd, anyone?) there’s a lot of fighting between people who want the shiny, better new thing, and people who liked the way things were before. Both sides have good arguments. Big parties in the Linux world, like Gnome and KDE, are moving towards a Wayland-only desktop. At the moment you can run Gnome and KDE on either, but that’ll be harder in the future. Other GUIs, like XFCE, are heavily geared towards X11, and it may take years before you can even run those on Wayland. Some, like i3, have replacements (Sway) that do almost the same thing.
Interestingly, hardware vendors also seem to go with Wayland for their custom Linux projects. For example, the Tizen watches Samsung used to sell run Wayland. The Steam Deck runs Wayland in game mode, using a purpose built Wayland compositor as a GUI, but X11 for desktop mode.
In practice, you shouldn’t need to worry about things too much right now. Some programs will not work on Wayland, others will not work on X11. Some games run a few fps faster on Wayland, others run faster on X11, but the differences aren’t huge. If both Xorg and Wayland are supported in your distro, you can switch between the two using a button on the login screen.
As for Firefox: Firefox has had native Wayland support for a while. It was already capable of using all the Wayland APIs and protocols at least a year ago. However, by default, it ran through XWayland, to remain as compatible as possible, while Wayland was still being tested. Now, with the upcoming release, Firefox goes native.
For Xorg users, nothing will change. For Wayland users with touchpads or touch screens, gestures like pinch to zoom will be smoother and there will be more of them. The only difference is that you don’t need to stuff MOZ_ENABLE_WAYLAND=1 in a script somewhere to activate the new capabilities on Wayland.
For a user: In Wayland programs are supposed to draw their own title bar. Java aplications and old applications must use a backwards compatibility layer that can cause flicker and bad font rendering. The terminology is different (compositor = window manager). Some niche new programs may only run on Wayland. Wayland hasn’t been adopted by BSD (AFAIK).
For a programners: Wayland has more modern, tidy code, but not all toolkits support it natively and few are easy. If you code exclusively for Wayland, a lot of users won’t use your program at the moment.
That’s incorrect. GNOME does it like this, Plasma doesn’t. KDE came up with a standard so a program can communicate this to the DE, GNOME slept on it. That’s why e.g. mpv doesn’t run well on GNOME.
There have been efforts to provide better support for Java applications on the Wayland. For instance, the OpenJDK project has been making progress on implementing native “pure” Wayland toolkit integration not dependent upon XOrg/X11 or XWayland.
There have been significant developments in providing native support for Wayland in various toolkits. For example : Clutter, GLFW 3, SDL, GTK 3.20+, QT5+, EFL, Slint, Iced & OpenJDK. Just to name a few.
While it is true that not all toolkits have full native support, ongoing work is/has largely shifted towards much better Wayland support.
OpenJDK has Project Wakefield going on to address Wayland support for Java applications.
https://wiki.openjdk.org/display/wakefield/OpenJDK+Project+Wakefield+-+Wayland+desktop+support+for+JDK+on+Linux