1. Overview

Most Linux desktop environments let us remove the software that comes with it. Thereby, allowing us to save disk space or replace them with alternatives. This article discusses how to remove the stock apps that come with GNOME, the most popular desktop environment.

First, we’ll cover the components we need to keep to avoid breaking the desktop. Then, we’ll remove the stock apps in different distributions using different package managers.

Finally, we’ll cover how to find and remove GNOME apps using Snap and Flatpak.

2. Is It Possible to Remove GNOME Stock Apps?

It’s entirely possible to remove the stock apps that come with GNOME. However, the process of removing these apps is different across distributions. It also depends on the method that the software was installed. For instance, if the packages were installed via a package manager, we should use the package manager to remove the apps.

Likewise, if the packages were installed as a Snap or Flatpak, we use the respective tool to remove them.

However, if the apps were installed manually, they should be removed manually. Later, we’ll automate this with a small shell script.

2.1. What Not To Remove

We should keep in mind that some core apps come with GNOME. They are essential to running the GNOME desktop. If we remove these packages, then it might break the desktop experience; in some cases, irreversibly.

For that reason, let’s list some of the core packages that we should to keep:

  • GNOME Shell
  • GNOME Session
  • GNOME Control Center
  • GNOME Applets
  • GNOME Display Manager (Optional)
  • GNOME Keyring (Optional)
  • Mutter

The optional packages in the list can be removed but it might cripple the desktop experience. Therefore, it’s better to keep them as they are tightly integrated with GNOME for better UX. There is also a list of official GNOME apps we can use for further research.

In the next sections, we’ll discuss how to remove the GNOME stock apps on different distributions.

3. Debian, Ubuntu, and Linux Mint

In Debian, Ubuntu, and friends, we use the APT package manager to enlist and uninstall the stock apps. However, we’ll need to enlist the GNOME packages first that are already installed:

$ apt list --installed | grep -i gnome

It will print out a list of items that are associated with “gnome“:

gir1.2-gnomeautoar-0.1/noble,now 0.4.4-2build4 amd64 [installed,automatic]
gir1.2-gnomebg-4.0/noble,now 44.0-5build2 amd64 [installed,automatic]
gir1.2-gnomebluetooth-3.0/noble,now 46.0-1build1 amd64 [installed,automatic]
gir1.2-gnomedesktop-3.0/noble,now 44.0-5build2 amd64 [installed,automatic]
gir1.2-gnomedesktop-4.0/noble,now 44.0-5build2 amd64 [installed,automatic]
gnome-accessibility-themes/noble,now 3.28-2ubuntu5 all [installed,automatic]
gnome-bluetooth-3-common/noble,now 46.0-1build1 all [installed,automatic]
gnome-bluetooth-sendto/noble,now 46.0-1build1 amd64 [installed,automatic]
gnome-calculator/noble,now 1:46.0-1ubuntu1 amd64 [installed]
gnome-characters/noble,now 46.0-1build1 amd64 [installed,automatic]
gnome-clocks/noble,now 46.0-1build1 amd64 [installed,automatic]
gnome-control-center-data/noble,now 1:46.0.1-1ubuntu7 all [installed,automatic]
gnome-control-center-faces/noble,now 1:46.0.1-1ubuntu7 all [installed,automatic]
gnome-control-center/noble,now 1:46.0.1-1ubuntu7 amd64 [installed,automatic]
...

Alternatively, we can also list all the dependencies of the gnome metapackage:

$ apt show gnome | grep -i depends
Depends: gnome-core (= 1:44+1build1), desktop-base, libproxy1-plugin-networkmanager, network-manager-gnome (>= 1.8), cheese (>= 3.38), file-roller (>= 3.38), gnome-calendar (>= 3.38), gnome-clocks (>= 3.38), gnome-color-manager (>= 3.36), gnome-maps (>= 3.38), gnome-music (>= 3.36), shotwell | gnome-photos (>= 3.36), gnome-weather (>= 3.36), orca (>= 3.38), rygel-playbin (>= 0.36), rygel-tracker (>= 0.36), simple-scan (>= 3.36), avahi-daemon, evolution (>= 3.36), gnome-sound-recorder, gnome-tweaks (>= 3.30), libgsf-bin, libreoffice-gnome, libreoffice-writer, libreoffice-calc, libreoffice-impress, rhythmbox (>= 3.0), seahorse (>= 3.36), xdg-user-dirs-gtk, cups-pk-helper (>= 0.2), evolution-plugins (>= 3.36), gstreamer1.0-libav (>= 1.10), gstreamer1.0-plugins-ugly (>= 1.10), rhythmbox-plugins, rhythmbox-plugin-cdrecorder, totem-plugins

Let’s check the list for stock apps we can remove. In this case, we can remove the gnome-clocks, gnome-calculator, and gnome-characters without issue:

$ sudo apt remove --purge -y gnome-clocks gnome-calculator gnome-characters gnome-keyring

Alternatively, we can also mark the packages that we need to keep. Let’s mark the core apps as manual:

$ sudo apt-mark manual gnome-shell gnome-session gnome-control-center gdm

We can add to the list as needed. However, these are the core packages that we’ll need to keep for the desktop environment to work properly, so ensure that the list is correct.

Then, we remove the gnome meta package:

$ sudo apt purge -y gnome

It will uninstall everything in the meta package but those marked “manual“. Finally, let’s remove the unneeded dependencies that weren’t installed manually or explicitly:

$ sudo apt autoremove -y

4. Fedora and RHEL

On Fedora and RHEL, we use dnf to manage packages. The method is very similar to what we did with apt.

As usual, we need to list the GNOME packages before removing them:

$ sudo dnf list | grep gnome

This will list all GNOME-related packages. Then, we create a list of packages we need to remove except the core GNOME packages. Then, remove them using dnf:

$ sudo dnf remove -y <package...>

Afterwards, like apt, we remove the unused dependencies:

$ sudo dnf autoremove -y

5. openSUSE

openSUSE uses the zypper package manager. We can use zypper to list the installed packages matching a specific pattern:

$ sudo zypper se --installed-only gnome

The command will only list the packages that match the keyword “gnome“. Then, we can analyze the installed packages and remove the ones that we don’t need:

$ sudo zypper remove --non-interactive <packages...>

Finally, don’t forget to remove the unused packages:

$ sudo zypper rm -u --non-interactive

6. Snap and Flatpak

We cannot manage Snap and Flatpak packages with a traditional package manager. Therefore, we’ll need to use the respective tool for the job. For instance, for removing Snaps, we use the snap utility. Similarly, for managing Flatpaks, we use the flatpak tool.

We can list the installed apps using the list sub-command and narrow it down to “gnome“:

# Snap
$ snap list | grep gnome

# Flatpak
$ flatpak list | grep gnome

Afterward, we remove any of the installed GNOME apps:

# Snap
$ sudo snap remove <snap>

# Flatpak
$ sudo flatpak remove <flatpak>

Alternatively, if we want to remove all the GNOME packages, we can use a simple shell script:

for pkg in $(snap list | grep gnome | awk '{print $1}'); do
    sudo snap remove "$pkg"
done

Note that in the script, we can replace snap with flatpak, depending on the package manager we are using.

7. Conclusion

In this article, we learned how to remove the stock GNOME apps from several distributions, using their respective package managers. We also covered how to remove Snaps and Flatpaks using the snap and flatpak utilities.