close
close

How to install proprietary codecs in Fedora so VLC can play all your videos

In this guide, I want to show you how to install the proprietary video codecs in Fedora via RPM Fusion. For anyone installing Fedora Workstation or any of the spins, this can be an almost mandatory step, as Fedora ships with free codecs that don't support certain video types, even when installing VLC from the Fedora repositories (the Flatpak version is different).

In April, I wrote an editorial explaining why users should choose Fedora Silverblue over Ubuntu 24.04 LTS. My arguments from that article still hold, but I realized that I need Fedora LXQt because it is lightweight. Since it doesn't have an atomic version like GNOME with Silverblue, I went back to traditional Fedora and ran into this codec problem, so I thought I'd share the solution.

The quickest and easiest way to install the codecs is through the terminal. I know a lot of people say the terminal is complicated, but it really isn't; just highlight the code below, right-click it and copy it, then right-click it in the terminal and hit Paste, then hit Enter, enter your password and hit Enter again. Here is the first command you need to run, this will enable the free and non-free RPM Fusion repositories on your system:

sudo dnf install -E %fedora).noarch.rpm -E %fedora).noarch.rpm

Once the terminal has finished executing this command, you need to enable the openh264 library. You do this with the following terminal command:

sudo dnf config-manager –enable fedora-cisco-openh264

If you need to install VLC, either get it from your software manager (Software or Dragora, depending on your variant) or use the following command:

sudo dnf vlc install

Optionally, you can also run the following command as recommended by the VLC website:

sudo dnf install python-vlc

Once you've done all this, you should be able to play any video files in VLC and other video players without any problem. Note that on any Fedora spin that supports Flatpaks out of the box, you can install the Flatpak version of VLC, which supports all video files. This guide refers to the VLC version in the Fedora repositories.

Fedora LXQt is a variant that doesn't come with Flatpak support out of the box, so enabling RPM Fusion is a good solution for those users. For anyone who's interested, Fedora LXQt uses the LXQt desktop similar to Lubuntu. It's extremely lightweight and runs fast even on very slow computers, so it's a great choice for reviving older or underpowered machines.

Let us know in the comments if you found this guide helpful. Do you even need to install these codecs these days or are you happy with the VLC Flatpak? It's worth noting that installing these codecs may also allow you to watch more video content online in Firefox, such as BBC News.