# How to Set Up a FreeBSD Desktop with XFCE
FreeBSD makes an excellent desktop operating system, and XFCE is one of the best desktop environments to pair with it. This guide walks you through every step -- from a bare FreeBSD installation to a fully functional daily-driver desktop with a web browser, office suite, proper fonts, audio, and all the tweaks that make the experience comfortable.
Whether you are migrating from Linux or setting up your first BSD desktop, this tutorial covers everything you need.
Why XFCE on FreeBSD
If you have looked at the [best desktop environments for FreeBSD](/blog/best-desktop-environment-freebsd/), you already know there are several solid options. XFCE stands out for a few important reasons.
**Lightweight and fast.** XFCE uses significantly less RAM and CPU than GNOME or KDE Plasma. On a system with 4 GB of RAM, XFCE idles around 300-400 MB, leaving plenty of room for applications. This matters on FreeBSD, where memory management is already efficient and you want the OS to stay out of your way.
**Stable and mature.** XFCE has been around since 1996. It does not chase trends or break workflows with major redesigns every release cycle. When you learn where things are, they stay there.
**GTK-based.** XFCE uses the GTK toolkit, which means it shares theming and library compatibility with Firefox, Thunderbird, LibreOffice, GIMP, and most of the productivity applications you will install. This gives you a visually consistent desktop without extra effort.
**Well-supported on FreeBSD.** The FreeBSD ports tree and pkg repository keep XFCE packages current. The FreeBSD Handbook documents XFCE setup, and the community has years of experience running it. You will not be fighting compatibility issues.
**Highly customizable.** Despite its lightweight nature, XFCE offers panel configuration, keyboard shortcuts, window manager compositing, and a plugin system that lets you build exactly the desktop you want.
Prerequisites
This guide assumes the following starting point:
- A fresh FreeBSD 14.x installation (14.1 or later recommended)
- A working network connection (Ethernet or Wi-Fi configured)
- Root access or a user account with sudo privileges
- A graphics card supported by FreeBSD (Intel, AMD, or NVIDIA)
If you are coming from a Linux background, our [FreeBSD vs Linux comparison](/blog/freebsd-vs-linux/) covers the key differences you should be aware of.
Add your user to the required groups
Your regular user account needs membership in the video and wheel groups. The video group grants access to GPU devices, and wheel grants sudo and su privileges.
sh
pw groupmod video -m your_username
pw groupmod wheel -m your_username
Replace your_username with your actual login name. Log out and back in for group changes to take effect.
Install sudo
If you do not already have sudo installed:
sh
pkg install sudo
visudo
Uncomment the line that allows members of the wheel group to run commands:
%wheel ALL=(ALL:ALL) ALL
From this point forward, you can run privileged commands with sudo from your regular user account.
Installing X.Org
X.Org provides the display server that XFCE runs on top of. FreeBSD offers two installation options.
Full X.Org installation (recommended)
The full metapackage includes all drivers, fonts, and utilities:
sh
sudo pkg install xorg
This pulls in roughly 200 packages and takes around 500 MB of disk space. It is the easiest path -- you get broad hardware support without thinking about which individual components you need.
Minimal X.Org installation
If you prefer a lean system and know your hardware:
sh
sudo pkg install xorg-minimal
With the minimal install, you will need to add your GPU driver and input drivers manually. This approach is better suited to experienced users.
Test X.Org
Before moving on, verify that X.Org starts:
sh
startx
You should see a basic window manager (twm) with an xterm. If you get a black screen or errors, the issue is almost certainly your GPU driver. Close twm by typing exit in the xterm.
GPU Driver Setup
Proper GPU acceleration makes the difference between a sluggish desktop and a responsive one. FreeBSD supports the three major GPU vendors through kernel modules.
Intel Graphics (most laptops, many desktops)
Intel integrated graphics from Haswell (2013) onward are well-supported through the drm-kmod package:
sh
sudo pkg install drm-kmod
Load the kernel module at boot by adding this line to /etc/rc.conf:
sh
sudo sysrc kld_list+="i915kms"
For older Intel GPUs (Sandy Bridge, Ivy Bridge), the same i915kms module works but performance may vary.
AMD Graphics
AMD GPUs from the GCN architecture onward (Radeon HD 7000 series and newer) use the amdgpu driver:
sh
sudo pkg install drm-kmod
sudo sysrc kld_list+="amdgpu"
For older AMD/ATI GPUs (pre-GCN), use the radeonkms module instead:
sh
sudo sysrc kld_list+="radeonkms"
NVIDIA Graphics
NVIDIA requires the proprietary driver. Check which version supports your GPU on the NVIDIA FreeBSD driver page, then install the appropriate package:
sh
sudo pkg install nvidia-driver
sudo sysrc kld_list+="nvidia-modeset"
Create or edit /usr/local/etc/X11/xorg.conf.d/nvidia.conf:
Section "Device"
Identifier "NVIDIA Card"
Driver "nvidia"
EndSection
Verify GPU acceleration
After rebooting with the correct driver loaded:
sh
sudo reboot
Then check that the driver is active:
sh
dmesg | grep -i drm
You should see messages indicating your GPU was recognized and the driver attached.
Installing XFCE
With X.Org and your GPU driver in place, install XFCE:
sh
sudo pkg install xfce
This installs the core XFCE desktop: the window manager (xfwm4), the panel, the file manager (Thunar), the settings manager, and the session manager.
Install XFCE Goodies
The goodies package adds useful plugins and extra applications:
sh
sudo pkg install xfce4-goodies
This brings in panel plugins (weather, system monitor, clipboard manager, notes), the Mousepad text editor, the Ristretto image viewer, the XFCE screensaver, and several other utilities that round out the desktop.
Enable D-Bus and HAL
XFCE requires D-Bus for inter-process communication. Add these to /etc/rc.conf:
sh
sudo sysrc dbus_enable="YES"
D-Bus is essential. Without it, XFCE components cannot communicate with each other and the desktop will not function correctly.
Display Manager: LightDM
A display manager provides a graphical login screen so you do not have to start XFCE manually from the command line every time.
LightDM is lightweight, reliable, and works perfectly with XFCE.
sh
sudo pkg install lightdm lightdm-gtk-greeter lightdm-gtk-greeter-settings
Enable LightDM in /etc/rc.conf:
sh
sudo sysrc lightdm_enable="YES"
Configure the greeter
Edit /usr/local/etc/lightdm/lightdm-gtk-greeter.conf to customize the login screen appearance:
ini
[greeter]
theme-name = Adwaita-dark
icon-theme-name = Adwaita
font-name = Sans 11
background = /usr/local/share/backgrounds/xfce/xfce-shapes.svg
You can change these values later after installing themes.
Optional: auto-login
If this is a single-user machine and you want to skip the login screen:
Edit /usr/local/etc/lightdm/lightdm.conf and find the [Seat:*] section:
ini
[Seat:*]
autologin-user=your_username
autologin-session=xfce
Replace your_username with your login name.
Complete /etc/rc.conf for Desktop Use
At this point, your /etc/rc.conf should include all the entries needed for a desktop system. Here is a complete reference of the desktop-related lines:
sh
# GPU driver (use the one matching your hardware)
kld_list="i915kms"
# kld_list="amdgpu"
# kld_list="nvidia-modeset"
# Display manager
lightdm_enable="YES"
# D-Bus (required for XFCE)
dbus_enable="YES"
# Networking
hostname="freebsd-desktop"
ifconfig_em0="DHCP"
# Mouse and touchpad
moused_enable="YES"
# Power management (laptops)
powerd_enable="YES"
# NTP time sync
ntpd_enable="YES"
ntpd_flags="-g"
# Clear /tmp on boot
clear_tmp_enable="YES"
# Crash dumps (optional, useful for debugging)
dumpdev="AUTO"
Reboot now to verify that LightDM starts and you can log in to an XFCE session:
sh
sudo reboot
Audio Setup
A desktop without sound is not much of a desktop. FreeBSD has excellent built-in audio support through the OSS (Open Sound System) framework, and you can layer PulseAudio or PipeWire on top for application compatibility.
Load the sound driver
sh
sudo sysrc kld_list+="snd_hda"
The snd_hda module covers Intel HDA-compatible audio, which includes the vast majority of built-in sound cards and HDMI audio output. After loading the module (or rebooting), check detection:
sh
cat /dev/sndstat
You should see your audio device listed.
Install PulseAudio
Most desktop applications expect PulseAudio:
sh
sudo pkg install pulseaudio pavucontrol
PulseAudio starts automatically within the XFCE session. The pavucontrol package gives you a graphical mixer to control volumes per application, select output devices, and configure input sources.
Alternative: PipeWire
PipeWire is the newer audio/video server that is replacing PulseAudio on Linux and is gaining traction on FreeBSD:
sh
sudo pkg install pipewire
PipeWire support on FreeBSD is functional but less mature than PulseAudio. For a stable desktop in 2026, PulseAudio remains the safer choice. If you want to experiment, PipeWire can run alongside a PulseAudio compatibility layer.
Volume control in XFCE
The xfce4-pulseaudio-plugin (included in xfce4-goodies) adds a volume icon to the panel. Right-click the panel, go to Panel > Add New Items, and add the PulseAudio Plugin. This gives you quick volume control and a shortcut to pavucontrol.
Set the default audio device
If you have multiple audio outputs (headphones, HDMI, USB DAC), use mixer to check and set the default:
sh
mixer
To permanently set a default device, add a line to /boot/loader.conf:
sh
hint.hdac.0.cad0.nid31.config="as=1 seq=0"
The exact values depend on your hardware. Check the FreeBSD Handbook sound section for details specific to your configuration.
Font Installation
Good fonts are essential for a pleasant desktop experience. FreeBSD does not ship many fonts by default, so you need to install them.
Essential font packages
sh
sudo pkg install noto-basic noto-emoji liberation-fonts-ttf dejavu roboto-fonts-ttf
This gives you:
- **Noto**: Google's font family designed to cover all Unicode scripts. Prevents "tofu" (missing glyph boxes) across languages.
- **Liberation Fonts**: Metrically compatible with Arial, Times New Roman, and Courier New. Essential for viewing documents created on Windows.
- **DejaVu**: Extended character coverage, widely used as a default on Unix desktops.
- **Roboto**: Clean sans-serif typeface, good for UI elements.
Nerd Fonts for terminal users
If you use a terminal with powerline prompts or status lines, install a Nerd Font:
sh
sudo pkg install nerd-fonts
Alternatively, download a specific Nerd Font (like JetBrainsMono Nerd Font or FiraCode Nerd Font) from the Nerd Fonts website and place the .ttf files in ~/.local/share/fonts/.
Enable font rendering improvements
Create or edit ~/.config/fontconfig/fonts.conf to enable subpixel rendering and hinting:
xml
true
true
hintslight
rgb
lcddefault
After saving, rebuild the font cache:
sh
fc-cache -fv
Log out and back in. You should notice significantly sharper text rendering.
Web Browser
A web browser is the most important application on any modern desktop. FreeBSD supports all the major open-source browsers.
Firefox (recommended)
sh
sudo pkg install firefox
Firefox is the best-supported browser on FreeBSD. It builds natively, receives regular updates, and integrates well with XFCE through GTK theming. Hardware video acceleration works with the correct GPU drivers.
Chromium
sh
sudo pkg install chromium
Chromium works well on FreeBSD but is a heavier install. It is useful if you need Chrome-specific web app compatibility or prefer the Chromium DevTools.
LibreWolf
sh
sudo pkg install librewolf
LibreWolf is a privacy-focused Firefox fork. It strips telemetry, disables DRM by default (you can re-enable it), and ships with uBlock Origin. A good choice if privacy is a priority.
Browser performance tip
For smoother scrolling and page rendering, enable WebRender in Firefox. Go to about:config and set:
gfx.webrender.all = true
This offloads rendering to your GPU, which makes a noticeable difference on FreeBSD systems with proper GPU driver setup.
Office and Productivity
LibreOffice
sh
sudo pkg install libreoffice
LibreOffice is the standard office suite. It handles Word, Excel, and PowerPoint files with good fidelity, and its native ODF format is excellent for long-term document storage. The full install includes Writer, Calc, Impress, Draw, Base, and Math.
Thunderbird
sh
sudo pkg install thunderbird
Thunderbird is a mature email client that supports IMAP, POP3, CalDAV calendars, and CardDAV contacts. If you use email and calendaring on your desktop, Thunderbird is the best option available on FreeBSD.
Additional productivity tools
sh
sudo pkg install evince galculator xfce4-screenshooter
- **Evince**: PDF viewer, lightweight and fast
- **Galculator**: GTK calculator
- **xfce4-screenshooter**: Screenshot tool with region selection, delay timer, and direct upload options
Thunar File Manager Customization
Thunar is XFCE's default file manager. It is fast, clean, and extensible.
Install useful plugins
sh
sudo pkg install thunar-archive-plugin thunar-media-tags-plugin
The archive plugin lets you create and extract archives (zip, tar, 7z) from the right-click menu. The media tags plugin shows audio file metadata in the detail view.
Mounting USB drives
FreeBSD does not auto-mount USB drives by default. Install the necessary packages:
sh
sudo pkg install automount exfat-utils fusefs-ntfs
Enable the required kernel modules and services:
sh
sudo sysrc kld_list+="fusefs"
sudo sysrc automount_enable="YES"
sudo sysrc devd_enable="YES"
After rebooting, USB drives with FAT32, exFAT, and NTFS file systems will auto-mount under /media/.
Custom actions in Thunar
Thunar supports custom actions that appear in the right-click menu. Go to Edit > Configure custom actions and add useful entries:
- **Open Terminal Here**: Command: xfce4-terminal --working-directory=%f (this one is built-in but worth checking)
- **Open as Root**: Command: pkexec thunar %f
- **Search Files**: Command: catfish --path=%f
Install Catfish for the file search action:
sh
sudo pkg install catfish
Terminal Emulator
xfce4-terminal (default)
The XFCE terminal emulator is already installed with the base XFCE package. It supports tabs, transparency, custom color schemes, and configurable keyboard shortcuts. For most users, it is more than sufficient.
To configure it, go to Edit > Preferences. Key settings to adjust:
- Font: Set to a monospace or Nerd Font (e.g., "JetBrainsMono Nerd Font 11")
- Scrollback: Increase from the default 1000 lines to unlimited
- Color scheme: Choose a dark theme like "Solarized Dark" or "Tango Dark"
Alacritty (alternative)
If you want a GPU-accelerated terminal:
sh
sudo pkg install alacritty
Alacritty is fast and minimal. It uses a YAML configuration file at ~/.config/alacritty/alacritty.toml. Its main advantage is rendering speed -- if you run programs that produce large volumes of terminal output (logs, builds), Alacritty handles it without lag.
Basic Alacritty configuration:
toml
[font]
size = 11.0
[font.normal]
family = "JetBrainsMono Nerd Font"
style = "Regular"
[colors.primary]
background = "#1e1e2e"
foreground = "#cdd6f4"
[window]
opacity = 0.95
padding = { x = 8, y = 8 }
Theming
A consistent visual theme makes the desktop feel polished. XFCE theming has three layers: GTK theme (application appearance), icon theme, and window manager theme.
Install popular themes
sh
sudo pkg install arc-themes papirus-icon-theme
- **Arc**: A flat theme with semi-transparent elements. Comes in light, dark, and mixed variants.
- **Papirus**: A comprehensive icon theme with thousands of icons covering most applications.
Apply themes
Open Settings Manager > Appearance:
- Style tab: Select "Arc-Dark" (or your preferred variant)
- Icons tab: Select "Papirus-Dark"
- Fonts tab: Set default font to "Noto Sans 10" and monospace font to "JetBrainsMono Nerd Font Mono 10"
Open Settings Manager > Window Manager:
- Style tab: Select "Arc-Dark" to match the GTK theme
Cursor theme
sh
sudo pkg install xcursor-themes
Apply a cursor theme in Settings Manager > Mouse and Touchpad > Theme tab.
Consistent theming across toolkits
If you install any Qt applications (like VLC or KeePassXC), make them follow your GTK theme:
sh
sudo pkg install qt5-style-plugins
Add this to your ~/.xprofile:
sh
export QT_QPA_PLATFORMTHEME=gtk2
Common Tweaks
Enable compositing
XFCE includes a built-in compositor in xfwm4. Open Settings Manager > Window Manager Tweaks > Compositor tab and enable it. This gives you:
- Window shadows
- Transparency effects
- Smooth window dragging
- Reduced screen tearing
If you experience screen tearing with the built-in compositor, try enabling "Synchronize drawing to the vertical blank" in the same tab.
For users who want more advanced compositing (blur, animations), install Picom:
sh
sudo pkg install picom
Disable the xfwm4 compositor first, then add picom to your XFCE autostart applications.
Keyboard shortcuts
Open Settings Manager > Keyboard > Application Shortcuts tab. Useful shortcuts to add:
| Shortcut | Command |
|---|---|
| Super+E | thunar |
| Super+T | xfce4-terminal |
| Super+W | firefox |
| Super+L | xflock4 (lock screen) |
| Print | xfce4-screenshooter |
| Super+D | xfce4-popup-whiskermenu (if using Whisker Menu) |
Panel configuration
The default XFCE panel is a single bar at the top. Many users prefer a taskbar-style layout.
**Switch to Whisker Menu** for a more modern application launcher:
The Whisker Menu plugin is included in xfce4-goodies. Right-click the panel, go to Panel > Add New Items, add Whisker Menu, then remove the default Applications Menu.
**Add a second panel** at the bottom for a Windows-like taskbar layout, or move the existing panel to the bottom if you prefer.
**Useful panel plugins to add:**
- System Load Monitor: CPU, memory, swap, and network usage graphs
- Clipboard Manager: Clipboard history with search
- Weather: Current conditions and forecast
- PulseAudio Plugin: Volume control
- Notification Area: System tray for background applications
Power management (laptops)
sh
sudo pkg install xfce4-power-manager
The power manager handles screen dimming, lid close actions, and battery status display. It adds a battery icon to the panel and lets you configure suspend/hibernate behavior.
Touchpad configuration (laptops)
For Synaptics touchpads, install the driver:
sh
sudo pkg install xf86-input-synaptics
For libinput-based touchpads (modern laptops):
sh
sudo pkg install xf86-input-libinput
Configure tap-to-click and natural scrolling in Settings Manager > Mouse and Touchpad.
Flatpak for Additional Apps
Some applications are not available in the FreeBSD package repository or are outdated. Flatpak provides access to a large catalog of Linux applications. For more details on running Linux software, see our guide on [Linux apps on FreeBSD](/blog/linux-apps-freebsd/).
Install Flatpak
sh
sudo pkg install flatpak
Enable the Linux compatibility layer:
sh
sudo sysrc linux_enable="YES"
sudo kldload linux64
Add the Flathub repository:
sh
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
Install applications from Flatpak
sh
flatpak install flathub com.spotify.Client
flatpak install flathub com.discordapp.Discord
flatpak install flathub org.signal.Signal
Flatpak applications integrate with the XFCE application menu automatically. They run in sandboxed environments, which adds a layer of security.
Note that Flatpak on FreeBSD relies on the Linux compatibility layer, so there may be occasional quirks. Native FreeBSD packages should always be your first choice.
Putting It All Together
Here is a single script that installs everything covered in this guide. Run it as root or with sudo:
sh
# Core desktop
pkg install -y xorg xfce xfce4-goodies lightdm lightdm-gtk-greeter
# GPU driver (uncomment the one matching your hardware)
pkg install -y drm-kmod
# sysrc kld_list+="i915kms" # Intel
# sysrc kld_list+="amdgpu" # AMD
# sysrc kld_list+="nvidia-modeset" && pkg install -y nvidia-driver # NVIDIA
# Audio
pkg install -y pulseaudio pavucontrol
# Fonts
pkg install -y noto-basic noto-emoji liberation-fonts-ttf dejavu roboto-fonts-ttf
# Browser and office
pkg install -y firefox libreoffice thunderbird
# File manager extras
pkg install -y thunar-archive-plugin automount exfat-utils fusefs-ntfs catfish
# Terminal
pkg install -y alacritty
# Theming
pkg install -y arc-themes papirus-icon-theme
# Utilities
pkg install -y evince galculator xfce4-screenshooter xfce4-power-manager picom
# Services
sysrc dbus_enable="YES"
sysrc lightdm_enable="YES"
sysrc moused_enable="YES"
sysrc kld_list+="fusefs"
sysrc kld_list+="snd_hda"
After running this, reboot and log in to your new XFCE desktop.
FAQ
Is XFCE too basic for daily use?
No. XFCE is lightweight, not limited. With the goodies package, panel plugins, and the applications covered in this guide, you get a fully functional desktop. Power users who need tiling window management can run i3 or bspwm alongside XFCE, or use XFCE's built-in keyboard shortcuts for window tiling.
Can I run Steam or games on FreeBSD with XFCE?
Gaming on FreeBSD is limited compared to Linux. Some native FreeBSD games are available through pkg, and the Linux compatibility layer allows running some Linux binaries. However, Steam and Proton (which enables Windows game compatibility) are not officially supported on FreeBSD. If gaming is a primary use case, consider dual-booting with Linux.
How do I enable suspend and hibernate on a FreeBSD laptop?
Suspend (S3 sleep) works on many laptops. Enable it with:
sh
sudo sysrc acpi_lid_switch_state="S3"
Hibernate (suspend-to-disk) is not as reliably supported on FreeBSD. Test suspend first -- if your laptop wakes properly from suspend, that is usually sufficient for daily use. The XFCE power manager can trigger suspend on lid close or after an idle timeout.
Why does my screen tear during video playback or scrolling?
Screen tearing is usually caused by the compositor not syncing with your display's refresh rate. In XFCE, open Settings Manager > Window Manager Tweaks > Compositor and enable "Synchronize drawing to the vertical blank." If that does not help, switch to Picom as your compositor and enable vsync in its configuration file.
How do I update all my packages?
FreeBSD uses pkg for binary package management:
sh
sudo pkg update
sudo pkg upgrade
Run this regularly (weekly is a good cadence) to keep your desktop environment, browsers, and system libraries current. FreeBSD quarterly package branches provide stable, tested updates.
Can I use Wayland instead of X.Org with XFCE?
As of 2026, XFCE's Wayland support is still in development. The XFCE project has been working on Wayland compatibility through the Labwc compositor and porting individual components, but the full desktop is not yet Wayland-native. For a stable experience, stick with X.Org. If you specifically need Wayland, consider Sway (a tiling compositor) or Wayfire, both of which have FreeBSD support.
How do I add a printer?
Install CUPS (the Common Unix Printing System):
sh
sudo pkg install cups cups-filters gutenprint
sudo sysrc cupsd_enable="YES"
sudo service cupsd start
Then open a browser and navigate to http://localhost:631 to configure your printer through the CUPS web interface. Most USB and network printers are supported.
Conclusion
You now have a complete FreeBSD desktop with XFCE. The system is lightweight, stable, and capable of handling everyday tasks -- web browsing, email, document editing, media playback, and software development.
FreeBSD's package manager keeps everything updated with a single command, and the system's ZFS integration (if you chose ZFS during installation) gives you snapshots and data integrity that no Linux desktop offers out of the box.
The combination of FreeBSD's rock-solid base system and XFCE's efficient, no-nonsense desktop environment is one of the best setups for users who value stability and performance over visual flash. Give it a week of daily use. You may not want to go back.