What Flatpak is and why you might want it

Flatpak is a way to install applications on Linux that works the same way across different Linux distributions. Instead of each distribution packaging software differently, Flatpak lets you download an app once and run it on Ubuntu, Fedora, Debian, or any other Linux system without hunting for the right version.

The main reason to use Flatpak is access to newer software. If your distribution's package manager has an older version of an application you need, Flatpak often has the current one. Flatpak also isolates applications from your system, which means a broken Flatpak app is less likely to break something else on your computer.

The trade-off is that Flatpak applications use more disk space than traditionally packaged software, and they start slightly slower. For most people, this does not matter. If you are running a very old computer or have limited storage, you might prefer to stick with your distribution's native packages.

Key Takeaways

  • Flatpak installation differs by distribution: Ubuntu and Debian use one command, Fedora uses another, and some distributions have it built in already.
  • After installing Flatpak itself, you restart your system or log out and back in before you can install Flatpak applications.
  • You install individual Flatpak applications through the command line or through your distribution's software center if it supports Flatpak.
  • Flatseal is a separate Flatpak tool that lets you control what permissions each Flatpak application has access to.

Check whether Flatpak is already installed

Some Linux distributions come with Flatpak already installed. Open a terminal and type this command:

flatpak --version

If you see a version number in response, Flatpak is already on your system and you can skip to the section on installing applications. If you see "command not found" or nothing appears, you need to install it.

Install Flatpak on Ubuntu or Debian

Open a terminal and run these commands in order:

  1. sudo apt update — this refreshes your package list so you get the newest version of Flatpak.
  2. sudo apt install flatpak — this downloads and installs Flatpak itself.
  3. sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo — this adds Flathub, the main repository where most Flatpak applications live. You only need to run this once.

After these commands finish, restart your computer or log out and log back in. This step is important — Flatpak needs to refresh your system settings before you can install applications.

Install Flatpak on Fedora

Fedora usually includes Flatpak already, but if it is missing, open a terminal and run:

sudo dnf install flatpak

Then add Flathub:

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

Restart your computer or log out and back in before installing applications.

Install Flatpak applications

Once Flatpak is installed and you have restarted, you can install applications. The easiest way is through your distribution's software center if it supports Flatpak — search for an app, and if a Flatpak version exists, you will see it as an option.

You can also install from the command line. Open a terminal and type:

flatpak install flathub [application-name]

Replace [application-name] with the actual name. For example, to install GIMP (an image editor), you would type flatpak install flathub org.gimp.GIMP. You can find the exact name of any application on the Flathub website at flathub.org.

The system will ask you to confirm the installation. Type y and press Enter. The application downloads and installs, and you can then launch it from your applications menu.

Control what permissions Flatpak applications have

By default, Flatpak applications have limited access to your files and system. Some applications need more permissions to work properly — for example, a text editor might need access to your home folder, or a music player might need access to your microphone.

To see and change these permissions, install Flatseal, a graphical tool for managing Flatpak permissions:

flatpak install flathub com.github.tchx84.Flatseal

Open Flatseal from your applications menu. You will see a list of all your Flatpak applications on the left. Click any application to see what it can access — your files, your camera, your network, and so on. Toggle switches on or off to grant or deny permissions. Most applications work fine with their default settings, but if an app cannot access something it needs, Flatseal is where you fix that.

Uninstall Flatpak applications or Flatpak itself

To remove a single Flatpak application, open a terminal and type:

flatpak uninstall [application-name]

For example, flatpak uninstall org.gimp.GIMP removes GIMP. You can also uninstall applications through your software center the same way you would any other program.

To remove Flatpak entirely from your system, use your distribution's package manager. On Ubuntu or Debian, type sudo apt remove flatpak. On Fedora, type sudo dnf remove flatpak. This removes Flatpak itself but does not affect applications you installed through your distribution's native package manager.

Frequently Asked Questions

Why does my Flatpak application not appear in my applications menu after I install it?

You probably did not restart your system or log out and back in after installing Flatpak itself. Flatpak needs to refresh your system settings before applications show up. Log out completely and log back in, and the application should appear.

Can I use both Flatpak and my distribution's native packages for the same application?

Yes, but you probably should not. If you have the same application installed both ways, they take up extra space and may conflict with each other. Stick with one version — use whichever one you installed first, or uninstall the one you do not use.

What is Flathub?

Flathub is the main repository where Flatpak applications are stored and downloaded from. When you add Flathub during setup, you are telling Flatpak where to look when you ask to install an application. Most Flatpak applications live on Flathub, though other repositories exist.

Do Flatpak applications run slower than native applications?

Flatpak applications start slightly slower than native packages because they are isolated from your system. Once running, they perform the same. The difference is usually less than a second and most people do not notice it.

Is Flatpak safe?

Flatpak is designed to be safer than traditional packages because applications are isolated and have limited permissions by default. However, you should still only install applications from sources you trust, just as you would with any software.