How to Install NVIDIA Drivers on Linux
Install NVIDIA proprietary drivers on Ubuntu, Debian, Fedora, and Arch Linux. Covers driver selection, Wayland setup, and troubleshooting common failures.
Before you start
- ▸A system with an NVIDIA GPU (Maxwell/GTX 900 or newer for current driver branch)
- ▸sudo or root access
- ▸Internet connection to download packages
- ▸Secure Boot status noted — may require MOK enrollment
NVIDIA driver installation on Linux is one of those tasks that looks simple until it isn't. The open-source nouveau driver works out of the box but lacks Vulkan acceleration, proper power management, and Wayland compositing support on most hardware. The proprietary NVIDIA driver delivers full performance but requires a few deliberate steps to install correctly. This guide covers both options, walks through installation on the three major distro families, and ends with Wayland-specific notes and troubleshooting.
Nouveau vs. Proprietary: Pick Your Driver
Nouveau is reverse-engineered, ships in the kernel, and requires zero setup. It is fine for driving a desktop at 2D. It is not fine for CUDA, Vulkan, hardware video decode, or modern Wayland compositing—all of which need the proprietary driver.
- Nouveau: zero install effort, open source, limited 3D/Vulkan, no CUDA, poor power management on Turing+ GPUs.
- Proprietary NVIDIA: full performance, Vulkan, CUDA, NVENC/NVDEC, required for Wayland on GNOME 46+ and KDE Plasma 6.
On modern desktop hardware (GTX 900 / "Maxwell" and newer), choose the proprietary driver unless you have a specific reason not to.
Before You Start
Identify your GPU and note the kernel version. You will need this to pick the right driver branch.
lspci -nn | grep -i nvidia
uname -r
NVIDIA publishes three active branches. Most users on a GTX 900 or newer should use the current production branch (550.x as of mid-2025). Cards older than Kepler need the legacy 470.xx or 390.xx packages.
Installation: Debian and Ubuntu
Ubuntu ships NVIDIA packages through ubuntu-drivers. Debian requires the non-free and non-free-firmware components enabled first.
Ubuntu (22.04 / 24.04)
The simplest path uses the automatic detection tool:
sudo apt update
sudo ubuntu-drivers install
That installs the recommended driver for your card. To see all candidates first:
ubuntu-drivers list
To install a specific series (e.g., 550):
sudo apt install nvidia-driver-550
Debian 12 (Bookworm)
Enable non-free in /etc/apt/sources.list so the line looks like:
deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware
Then install the driver and kernel headers:
sudo apt update
sudo apt install nvidia-driver firmware-misc-nonfree linux-headers-$(uname -r)
Reboot after installation completes. The DKMS module will build during the install.
sudo reboot
Installation: Fedora and RHEL Family
The best source on Fedora, RHEL 9, Rocky, and AlmaLinux is the RPM Fusion repository. Do not use the NVIDIA .run file—it bypasses the package manager and breaks on every kernel update.
Fedora 39 / 40
sudo dnf install https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm \
https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
sudo dnf install akmod-nvidia xorg-x11-drv-nvidia-cuda
Important: After this command returns, wait 2–5 minutes before rebooting. The akmods service builds the kernel module in the background. Rebooting too early leaves you with no NVIDIA module loaded.
sudo reboot
RHEL 9 / Rocky Linux 9 / AlmaLinux 9
sudo dnf install https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-9.noarch.rpm \
https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-9.noarch.rpm
sudo dnf install akmod-nvidia
Installation: Arch Linux
Arch ships NVIDIA packages directly in extra. For current hardware use nvidia; for older Kepler cards use nvidia-470xx-dkms from the AUR.
sudo pacman -S nvidia nvidia-utils lib32-nvidia-utils
If you are on a custom or LTS kernel (e.g., linux-lts), install the DKMS variant instead so the module rebuilds automatically:
sudo pacman -S nvidia-dkms nvidia-utils lib32-nvidia-utils
Regenerate the initramfs and reboot:
sudo mkinitcpio -P
sudo reboot
Wayland Notes
NVIDIA's Wayland support has improved significantly since driver 495 and kernel 6.2 (GBM support). As of driver 550 on kernel 6.6+, GNOME and KDE Plasma run well on Wayland with NVIDIA. A few things to know:
- Ensure
nvidia-drm.modeset=1is set as a kernel parameter. Most distro packages set this automatically; verify withcat /sys/module/nvidia_drm/parameters/modeset— it should returnY. - On Arch or manual setups, add it explicitly in your bootloader config (e.g.,
/etc/default/grub): addnvidia-drm.modeset=1toGRUB_CMDLINE_LINUX_DEFAULT, then runsudo grub-mkconfig -o /boot/grub/grub.cfg. - For explicit sync (fixes tearing in some Wayland compositors), driver 555+ supports the
nvidia-drm.explicit_sync=1parameter. - On laptops with NVIDIA Optimus (hybrid graphics), use
nvidia-prime(Ubuntu/Debian),switcheroo-control(Fedora), oroptimus-manager(Arch AUR) to manage GPU switching.
Verify the Installation
After rebooting, confirm the proprietary driver is loaded:
nvidia-smi
Typical output shows your GPU name, driver version (e.g., 550.xx), and CUDA version. If this command is not found or returns an error, the module is not loaded.
lsmod | grep nvidia
You should see nvidia, nvidia_modeset, nvidia_drm, and nvidia_uvm listed.
On Wayland, confirm the session type:
echo $XDG_SESSION_TYPE
Troubleshooting
Black screen after reboot
Drop to a TTY with Ctrl+Alt+F3. Check the systemd journal for driver errors:
sudo journalctl -b -p err | grep -i nvidia
On Fedora, the most common cause is rebooting before akmods finished building. Check with sudo akmods --force and reboot again.
Module not loading after a kernel update
Packages using DKMS rebuild automatically on kernel upgrades. If they did not:
# Debian/Ubuntu
sudo dpkg-reconfigure nvidia-dkms-550
# Arch
sudo dkms autoinstall
Secure Boot blocks the module
NVIDIA's DKMS module must be signed to load under Secure Boot. Ubuntu handles this automatically via MOK enrollment during install. On other distros, either enroll a machine owner key (MOK) manually using mokutil, or disable Secure Boot in UEFI firmware settings.
Nouveau conflicts with the proprietary driver
Most distro packages blacklist nouveau automatically. If you still see conflicts, confirm the blacklist is in place:
cat /etc/modprobe.d/blacklist-nouveau.conf
If the file is missing, create it:
echo -e 'blacklist nouveau\noptions nouveau modeset=0' | sudo tee /etc/modprobe.d/blacklist-nouveau.conf
sudo update-initramfs -u # Debian/Ubuntu
# or
sudo dracut --force # Fedora/RHELFrequently asked questions
- Should I use the .run installer from NVIDIA's website?
- Avoid it on most distros. The .run file bypasses the package manager, does not integrate with DKMS, and breaks every time the kernel updates. Use your distro's packaged driver instead.
- Does the NVIDIA proprietary driver work on Wayland in 2025?
- Yes, with driver 550+ and kernel 6.6+ it works well under both GNOME and KDE Plasma. You must have nvidia-drm.modeset=1 set, and driver 555+ adds explicit sync support that eliminates most remaining tearing issues.
- My system won't boot after installing the driver. How do I recover?
- Boot to a TTY with Ctrl+Alt+F3 or drop to a recovery shell. Check journalctl -b -p err for driver errors. On Fedora, re-run sudo akmods --force and reboot. If all else fails, remove the driver package and reinstall from scratch.
- I have an older card (GTX 600/700 Kepler). Which driver do I use?
- Kepler-era cards (GTX 600/700) require the 470.xx legacy branch. On Ubuntu install nvidia-driver-470; on Fedora install akmod-nvidia-470xx from RPM Fusion; on Arch use nvidia-470xx-dkms from the AUR.
- Does Secure Boot prevent NVIDIA drivers from loading?
- It can. The kernel module must be signed with a key enrolled in the UEFI MOK database. Ubuntu handles MOK enrollment automatically during install. On other distros, use mokutil to enroll your own signing key, or disable Secure Boot in UEFI settings.
Related guides
Linux Clipboards Explained (+ Clipboard Managers)
Learn the difference between Linux's PRIMARY and CLIPBOARD selections, use xclip, xsel, and wl-clipboard from the terminal, and manage history with GPaste or Klipper.
Configure LibreOffice for Daily Use
Configure LibreOffice for daily use: set default save formats for MS Office interop, tune autosave, install fonts, and add productivity extensions.
Configure the Touchpad and Multitouch Gestures
Configure Linux touchpad behavior and multitouch gestures using libinput, libinput-gestures, and native GNOME and KDE Plasma settings on both Wayland and X11.
Wayland vs X11: How to Choose and Configure Each
Know when to run Wayland or X11, how to check your current session, switch at login with GDM/SDDM/LightDM, and handle NVIDIA and XWayland edge cases.