How to Switch Between Wayland and Xorg Sessions in GNOME on Fedora

Select GNOME on Xorg or GNOME at the login screen to switch display servers.

You upgraded Fedora and your screen recording stopped working

You boot into Fedora after a fresh install or a major release upgrade. The desktop loads, but your favorite screen recording tool refuses to capture the desktop. Or your proprietary GPU driver throws a warning about legacy display servers. The interface looks identical, but the underlying plumbing changed. You need to switch display servers before you waste an hour debugging a feature that simply does not exist in the current session.

What the display server choice actually does

GNOME ships with two display server options. Wayland is the default. It handles window compositing, input routing, and security isolation at the protocol level. Xorg is the legacy option. It routes all drawing and input through a single centralized daemon. The login manager, GDM, presents both options when available. Selecting one tells the PAM stack and the display manager which compositor to launch. The choice persists only for that login session. It does not rewrite system packages or alter kernel modules.

Think of Xorg like a shared whiteboard in a conference room. Every application draws directly on the same surface. The server tracks every keystroke and mouse movement and distributes them to whichever window has focus. It works reliably, but it gives every application broad access to your input and screen contents.

Wayland operates like a secure glass partition. Each application gets its own isolated buffer. The compositor stitches those buffers together into the final image. Input events never leave the compositor until they are explicitly routed to the correct window. This architecture blocks keyboard loggers, prevents unauthorized screen capture, and reduces input latency. It also means legacy tools that expect X11 forwarding or raw screen access will fail until they are rewritten for the Wayland API.

How to switch at the login screen

The standard method requires no terminal access. You change the session type before authentication completes.

  1. Boot the machine and wait for the GDM login screen to appear.
  2. Click your user account. The password field and a gear icon will appear in the bottom-right corner.
  3. Click the gear icon. A menu lists available sessions.
  4. Select GNOME for Wayland or GNOME on Xorg for the legacy server.
  5. Enter your password and press Enter.

The system launches the selected compositor and drops you into your desktop. The selection resets on every reboot. You must repeat this step if you switch sessions again.

Reboot before you debug. Half the time the symptom is gone.

How to force a session type when the button disappears

Some minimal installations or custom GDM configurations hide the session selector. The gear icon vanishes, leaving you stuck with whatever GDM defaults to. You can override the default by editing the GDM configuration file. This change applies system-wide until you revert it.

Here is how to lock the display server to Xorg when the UI option is missing.

# Open the GDM configuration file with root privileges
sudo nano /etc/gdm/custom.conf
# Uncomment the WaylandEnable line and set it to false
# This forces GDM to launch the Xorg backend for all users
WaylandEnable=false
# Save the file and exit the editor
# Restart the display manager to apply the change
sudo systemctl restart gdm

If you need to revert to the default behavior, change WaylandEnable=false back to WaylandEnable=true or comment the line out entirely. GDM reads this file on every boot. The setting survives package updates because it lives in /etc/, not /usr/lib/. Files in /etc/ are user-modified. Files in /usr/lib/ ship with the package. Edit /etc/. Never edit /usr/lib/.

Verify the session type

You can confirm which display server is active without guessing. The environment variable $XDG_SESSION_TYPE reports the current protocol. The loginctl utility provides a more detailed view of the session state.

Here is how to check your active session type from a terminal.

# Print the current session type to the terminal
echo $XDG_SESSION_TYPE
# Expected output: wayland or x11
# Query loginctl for detailed session metadata
loginctl show-session $(loginctl | awk 'NR==2{print $1}') -p Type
# Expected output: Type=wayland or Type=x11
# The NR==2 trick grabs the first non-header session line

If the output says x11, you are running Xorg. If it says wayland, you are on Wayland. Run this check immediately after logging in. Some applications spawn nested X11 sessions via Xwayland, which can confuse casual checks. The environment variable reflects the primary compositor, not the compatibility layer.

Common pitfalls and what the error looks like

Switching display servers introduces predictable friction points. Most issues stem from applications that have not been updated for Wayland, or from hardware drivers that still rely on Xorg extensions.

Screen sharing and remote desktop tools frequently fail on Wayland. The compositor blocks raw screen access by design. If you see Error: Cannot capture screen: permission denied in your terminal, you are hitting the Wayland security model. You must grant screen recording permissions through GNOME Settings or use a portal-compatible tool like gnome-network-displays or Waypipe.

Keyboard input quirks appear when switching mid-session. Xorg handles modifier keys and layout switching differently than Wayland. If your Caps Lock behaves like Ctrl, or your international layout stops switching, log out completely and log back in. Do not try to restart GNOME Shell with Alt+F2, r. That shortcut only works on Xorg and will do nothing on Wayland.

Proprietary NVIDIA drivers historically required Xorg for full functionality. Modern Fedora releases ship with Wayland-compatible NVIDIA drivers, but older GPU generations still default to Xorg for stability. If your desktop freezes on login with a black screen and a blinking cursor, switch to Xorg at the GDM gear menu. The driver stack will fall back to a known-good configuration.

Run journalctl -xeu gdm first. Read the actual error before guessing.

When to use Wayland versus Xorg

Use Wayland when you want modern input latency, per-application security isolation, and native fractional scaling on HiDPI displays. Use Wayland when you are running standard desktop workloads, browsing the web, or developing applications that support the Wayland API. Use Xorg when you need legacy screen recording tools, remote desktop protocols that rely on X11 forwarding, or hardware acceleration for older proprietary GPU drivers. Use Xorg when you are running virtualization clients that require raw input passthrough or when you need to debug display server crashes with familiar X11 tooling. Stay on the default Wayland session unless a specific application or driver explicitly requires Xorg.

Trust the package manager. Manual file edits drift, snapshots stay.

Where to go next