FreeBSD.software
Home/Guides/Wayland on FreeBSD: Display Protocol Review
review·2026-04-09·11 min read

Wayland on FreeBSD: Display Protocol Review

Review of Wayland on FreeBSD: current status, compositor options, XWayland compatibility, application support, GPU drivers, and comparison with X11.

Wayland on FreeBSD: Display Protocol Review

Wayland is the display protocol designed to replace X11 on Unix systems. On Linux, Wayland compositors like Sway and GNOME's Mutter have reached production-ready status. On FreeBSD, the situation is different. Wayland works, but with caveats. This review covers the current state of Wayland on FreeBSD, available compositors, XWayland compatibility, application support, GPU driver status, and whether it is a practical alternative to X11 for FreeBSD desktop users today.

What Wayland Is

Wayland is not a display server. It is a protocol that defines how a compositor communicates with its clients (applications). The compositor is both the display server and the window manager. There is no standalone "Wayland server" equivalent to Xorg.

Key concepts:

  • Compositor: The program that manages windows, handles input, and renders output. It replaces both the X server and the window manager.
  • Wayland protocol: The communication protocol between clients and the compositor, using Unix domain sockets and shared memory.
  • wl_display, wl_surface, wl_buffer: Core protocol objects for connection management, window surfaces, and pixel buffers.
  • XWayland: An X11 server that runs as a Wayland client, providing backward compatibility for X11 applications.

On FreeBSD, the Wayland libraries and protocol definitions are available as packages. The real question is which compositors work and how well.

sh
# Install core Wayland libraries on FreeBSD pkg install wayland wayland-protocols

Current Status on FreeBSD

Wayland on FreeBSD is functional but not yet at parity with the Linux experience. The main factors:

  1. DRM/KMS support: FreeBSD has kernel-level DRM (Direct Rendering Manager) support through the drm-kmod port. This provides the kernel modesetting (KMS) infrastructure that Wayland compositors require. Intel and AMD GPUs are well supported. NVIDIA support is incomplete.
  1. libinput: FreeBSD has a working libinput port that provides input device handling for Wayland compositors. Keyboard, mouse, and touchpad support works. Touchscreen and tablet support is less tested.
  1. Compositor availability: Sway, Wayfire, Hikari, Hyprland, and labwc are available as ports or packages. GNOME Wayland and KDE Plasma Wayland have experimental support.
  1. evdev/libinput integration: FreeBSD uses evdev compatibility through evdev-proto and the input/evdev kernel module. This bridges the gap between FreeBSD's native input subsystem and libinput.
sh
# Install GPU driver support pkg install drm-kmod # Load the driver at boot (Intel example) sysrc kld_list+="i915kms" # For AMD GPUs sysrc kld_list+="amdgpu"

GPU Driver Status

Wayland compositors require working DRM/KMS. The driver situation on FreeBSD:

Intel GPUs

Intel graphics are the best-supported option on FreeBSD for Wayland. The i915kms driver covers generations from Sandy Bridge through Alder Lake. The xe driver for newer Intel Arc GPUs is in development.

sh
# Verify Intel GPU is detected sysctl dev.drm dmesg | grep -i drm

AMD GPUs

AMD support through the amdgpu driver covers GCN and RDNA architectures. Most modern AMD GPUs work, though newer generations may lag behind Linux support.

sh
# Load AMD GPU driver kldload amdgpu dmesg | grep -i amdgpu

NVIDIA GPUs

NVIDIA remains the most problematic. The proprietary NVIDIA driver on FreeBSD does not support GBM (Generic Buffer Management), which most Wayland compositors require. The nouveau open-source driver has limited FreeBSD support and lacks power management for modern GPUs. Practically, NVIDIA GPUs and Wayland on FreeBSD do not work together reliably. If you want Wayland on FreeBSD, use Intel or AMD.

Compositor Options

Sway

Sway is the most mature Wayland compositor on FreeBSD. It is a drop-in replacement for i3 (the tiling window manager for X11) and implements the wlroots library for Wayland protocol handling.

sh
pkg install sway swaylock swayidle swaybg

Configuration goes in ~/.config/sway/config. The syntax is nearly identical to i3:

sh
# Launch Sway (from a TTY, not from within X11) sway

Example configuration snippet for ~/.config/sway/config:

sh
# Set modifier key set $mod Mod4 # Terminal emulator set $term foot # Application launcher set $menu wmenu-run # Start a terminal bindsym $mod+Return exec $term # Kill focused window bindsym $mod+Shift+q kill # Start launcher bindsym $mod+d exec $menu # Output configuration (monitor) output HDMI-A-1 resolution 1920x1080 position 0,0 # Input configuration (touchpad) input type:touchpad { tap enabled natural_scroll enabled }

Sway on FreeBSD works well for daily use with Intel and AMD GPUs. Screen sharing and some portal features may not function identically to Linux.

Wayfire

Wayfire is a 3D compositor inspired by Compiz, with compositing effects and a plugin system.

sh
pkg install wayfire

Configuration is in ~/.config/wayfire.ini. Wayfire provides desktop effects (wobbly windows, cube, expo) that are absent from Sway. It works on FreeBSD but is less tested than Sway.

Hikari

Hikari is a Wayland compositor developed specifically with FreeBSD in mind. It follows a stacking (floating) window management paradigm and uses a clean configuration format.

sh
pkg install hikari

Configuration goes in ~/.config/hikari/hikari.conf. Hikari is lightweight and stable on FreeBSD. It is not as feature-rich as Sway but has the advantage of being designed for FreeBSD from the start.

Hyprland

Hyprland is a dynamic tiling compositor with animations and rounded corners. It is available on FreeBSD:

sh
pkg install hyprland

Hyprland is visually appealing and feature-rich, but it moves fast and may have more FreeBSD-specific issues than Sway due to its rapid development pace. Configuration is in ~/.config/hypr/hyprland.conf.

labwc

labwc is a wlroots-based stacking compositor inspired by openbox. It aims for simplicity and compliance with the wlr-layer-shell protocol.

sh
pkg install labwc

labwc is a good choice if you want a traditional floating window manager experience under Wayland.

XWayland Compatibility

XWayland provides backward compatibility for X11 applications running under a Wayland compositor. On FreeBSD, XWayland is available as a package:

sh
pkg install xwayland

Most Wayland compositors automatically start XWayland when an X11 application launches. In Sway, XWayland is enabled by default. To explicitly control it, add to the Sway config:

sh
# Enable XWayland in Sway config xwayland enable

What Works Through XWayland

  • Firefox (also has native Wayland support)
  • Chromium (also has native Wayland support)
  • LibreOffice
  • GIMP
  • Xterm and other X11 terminal emulators
  • Most GTK2 and older Qt applications
  • Java applications (Swing, JavaFX)
  • Wine / Windows applications

XWayland Limitations

  • No fractional scaling (XWayland renders at integer scale, then the compositor scales)
  • Input handling may differ (keyboard shortcuts, IME)
  • Screen sharing and window selection may not work correctly for XWayland windows
  • Clipboard synchronization works but can be inconsistent with some applications
  • Gaming performance through XWayland can be lower than native X11
sh
# Check if an application is running under XWayland in Sway swaymsg -t get_tree | grep -A5 "app_id" # XWayland windows show "null" for app_id and use "class" instead

Application Support

Native Wayland Applications

Applications using modern toolkit versions support Wayland natively:

| Toolkit | Wayland Support | Notes |

|---------|----------------|-------|

| GTK 3/4 | Yes | Native by default on Wayland sessions |

| Qt 5/6 | Yes | Set QT_QPA_PLATFORM=wayland |

| SDL2 | Yes | Set SDL_VIDEODRIVER=wayland |

| Firefox | Yes | Set MOZ_ENABLE_WAYLAND=1 |

| Chromium | Yes | Use --ozone-platform=wayland flag |

| Electron | Partial | Newer versions support --ozone-platform=wayland |

sh
# Environment variables for Wayland-native application support # Add to ~/.profile or ~/.config/sway/config (as exec) export QT_QPA_PLATFORM=wayland export MOZ_ENABLE_WAYLAND=1 export SDL_VIDEODRIVER=wayland export _JAVA_AWT_WM_NONREPARENTING=1 export XDG_SESSION_TYPE=wayland

Terminal Emulators

For Wayland on FreeBSD, use a native Wayland terminal:

  • foot: Lightweight, fast, Wayland-native. Recommended for Sway.
  • Alacritty: GPU-accelerated, supports Wayland natively.
  • kitty: Feature-rich, native Wayland support.
sh
pkg install foot # or pkg install alacritty

Screen Sharing and Portals

Screen sharing under Wayland uses the xdg-desktop-portal protocol. On FreeBSD, this requires:

sh
pkg install xdg-desktop-portal xdg-desktop-portal-wlr

The portal integration on FreeBSD is less polished than on Linux. Screen sharing in Firefox and Chromium may require PipeWire:

sh
pkg install pipewire wireplumber

PipeWire on FreeBSD is functional but still maturing. Video capture for screen sharing works in some configurations but is not universally reliable.

Session Management

Starting Sway

Launch Sway from a TTY login, not from within an X11 session:

sh
# Login on tty1, then: exec sway

Or create a shell profile entry:

sh
# Add to ~/.profile if [ "$(tty)" = "/dev/ttyv0" ]; then exec sway fi

Display Managers

GDM and SDDM have Wayland session support, but on FreeBSD, TTY-based launching is more reliable:

sh
# If using SDDM, install and enable pkg install sddm sysrc sddm_enable="YES"

SDDM can list Wayland sessions from /usr/local/share/wayland-sessions/. The session file for Sway is typically installed by the Sway package.

Wayland vs X11 on FreeBSD

| Aspect | Wayland (Sway) | X11 (i3/Xorg) |

|--------|---------------|----------------|

| Maturity on FreeBSD | Good, improving | Excellent, decades of use |

| GPU Support | Intel, AMD (good); NVIDIA (poor) | Intel, AMD, NVIDIA (all good) |

| Application Compatibility | Most apps via XWayland | All X11 apps natively |

| Screen Tearing | None (compositor handles vsync) | Possible without compositor |

| Input Latency | Lower (direct compositor path) | Higher (X11 protocol overhead) |

| Security | Better (no keylogging via X protocol) | Weaker (any client can capture input) |

| Screen Sharing | Portal-based, still maturing | Established (X11 screen capture) |

| Remote Desktop | Limited (no equivalent to X forwarding) | X forwarding, VNC, RDP |

| Multi-Monitor | Per-output scaling | Single global scaling |

| HiDPI | Good fractional scaling support | Poor (integer scaling, per-app hacks) |

| Configuration | Per-compositor config files | Centralized xorg.conf + WM config |

When to Use Wayland on FreeBSD

  • You use Intel or AMD graphics
  • You want tear-free rendering
  • You need per-monitor scaling for mixed-DPI setups
  • You value the security model (no X11 keylogging vulnerability)
  • You are comfortable with a tiling workflow (Sway is the most tested)

When to Stick with X11 on FreeBSD

  • You use NVIDIA graphics
  • You depend on X11 forwarding for remote GUI access
  • You need specific X11-only applications without XWayland issues
  • You use a desktop environment (GNOME/KDE) that has better X11 integration on FreeBSD
  • You need mature screen recording/sharing workflows

Troubleshooting

Sway Fails to Start

sh
# Check for DRM support kldstat | grep drm # If no DRM module is loaded, load it: kldload i915kms # Intel kldload amdgpu # AMD # Check permissions ls -la /dev/dri/ # Your user must be in the 'video' group pw groupmod video -m yourusername

No Input After Starting Compositor

sh
# Verify evdev support kldstat | grep evdev kldload evdev # if not loaded # Check libinput sees your devices libinput list-devices

Flickering or Artifacts

Ensure your GPU firmware is loaded. For Intel:

sh
pkg install gpu-firmware-intel-kmod

For AMD:

sh
pkg install gpu-firmware-amd-kmod

XWayland Applications Look Blurry on HiDPI

XWayland renders at integer scale. On a 2x HiDPI display, X11 applications may appear blurry because they render at 1x and the compositor upscales. This is a fundamental XWayland limitation with no clean workaround.

Frequently Asked Questions

Is Wayland ready for daily use on FreeBSD?

With Intel or AMD GPUs and Sway as the compositor, yes. It is usable for daily work. Some rough edges remain around screen sharing and portal integration, but core functionality (window management, application launching, multi-monitor, clipboard) works reliably.

Can I use GNOME with Wayland on FreeBSD?

GNOME Wayland sessions are experimental on FreeBSD. Basic functionality works, but expect bugs. The X11 session for GNOME is more stable on FreeBSD today.

Can I use KDE Plasma with Wayland on FreeBSD?

KDE Plasma Wayland is available but less tested than the X11 session on FreeBSD. Multi-monitor support and some Plasma widgets may not function correctly.

Does Wayland support remote desktop on FreeBSD?

There is no direct equivalent to X11 forwarding. VNC-based solutions like wayvnc exist for Sway. RDP support is possible through xrdp with XWayland, but it is less seamless than X11 remote access.

sh
pkg install wayvnc # Start wayvnc after Sway is running wayvnc 0.0.0.0 5900

Will NVIDIA ever work with Wayland on FreeBSD?

It depends on NVIDIA providing a FreeBSD driver with GBM support. On Linux, NVIDIA now supports GBM. A similar update for FreeBSD would enable Wayland support, but there is no announced timeline.

Do games work under Wayland on FreeBSD?

SDL2-based games with Wayland support run natively. Other games run through XWayland. Performance is generally acceptable, but frame latency may be slightly higher through XWayland compared to native X11.

How do I switch between Wayland and X11?

Both can coexist on the same system. Start Sway from a TTY for Wayland, or start Xorg with your preferred window manager for X11. They use different login session mechanisms and do not conflict.

sh
# Wayland session exec sway # X11 session startx

Does copy-paste work between Wayland and XWayland applications?

Yes. Clipboard synchronization between native Wayland clients and XWayland applications is handled by the compositor. It generally works, though occasional edge cases with clipboard managers may occur.

How do I take screenshots under Wayland?

Use grim for screenshots and slurp for region selection:

sh
pkg install grim slurp # Full screenshot grim /tmp/screenshot.png # Region selection grim -g "$(slurp)" /tmp/region.png

Get more FreeBSD guides

Weekly tutorials, security advisories, and package updates. No spam.