Since Ubuntu 20.04, Snap becomes the default underlying method replacing the standard DEB in the Software Center, and the latest Ubuntu LTS release (22.04 Jammy Jellyfish) being pushed as new default package manager replacing the apt package manager, we used for years. For example, when you install the fresh installation of Ubuntu 22.04, you’ll find Firefox installed as Snap.
The problem is, when Snap is broken, in this specific case of Firefox as Snap, you can’t open your browser, you can’t browse the Internet or find any solution on the Internet when you got a trouble. There are known stability issues that simply don’t happen with traditional .deb packages, such as slower performance and due to its design, the application installation size is huge and costs disk space because it packages all the dependencies.
You may decide to remove the Snap completely in your system, or just the packages you don’t need and replace them with regular .deb packages. In these steps, I’ll show you how to remove completely Snap packages.
Remove Snap Packages
First, remove the packages installed by snap in Ubuntu. View the list of Snap packages installed in your system using the below command.
$ snap list Name Version Rev Tracking Publisher Notes bare 1.0 5 latest/stable canonical✓ base chromium 108.0.5359.94 2238 latest/stable canonical✓ - core 16-2.57.6 14399 latest/stable canonical✓ core core20 20221123 1738 latest/stable canonical✓ base cups 2.4.2-5 872 latest/stable openprinting✓ - firefox 107.0.1-1 2154 latest/stable/… mozilla✓ - gnome-3-38-2004 0+git.6f39565 119 latest/stable/… canonical✓ - gtk-common-themes 0.1-81-g442e511 1535 latest/stable/… canonical✓ - snap-store 41.3-66-gfe1e325 638 latest/stable/… canonical✓ - snapd 2.57.6 17883 latest/stable canonical✓ snapd snapd-desktop-integration 0.1 49 latest/stable/… canonical✓ -
It shows the snap packages such as Firefox, software store, themes and other core packages installed by default. Because some packages depend on each other, it is better to remove each one individually. Firstly remove Firefox, Secondly, snap-store and the other packages that you see in the above command output in your system.
$ sudo snap remove --purge firefox $ sudo snap remove --purge snap-store $ sudo snap remove --purge gnome-3-38-2004 $ sudo snap remove --purge gtk-common-themes (..)
If you still need Snap on your system and only remove unneeded packages on Snap, you can remove the packages already installed in the Snap list without removing whole Snap packages, such as only Firefox or Chromium.
Remove the snap daemon
After all Snap packages were removed, remove the snap daemon via
sudo apt remove --autoremove snapd
Finally, clear any leftover cache from Snap:
sudo rm -rf /var/cache/snapd/ rm -rf ~/snap
Installing Firefox as deb files
With Snap removed, you’ll need to install Firefox from a PPA. Because apt will still try to install the Snap version of Firefox, you will run into an error, create a new file within Apt’s preferences dir:
sudo nano /etc/apt/preferences.d/firefox-no-snap
Include the following content in the newly created file:
Package: firefox* Pin: release o=Ubuntu* Pin-Priority: -1
Then use the official PPA via the below commands.
sudo add-apt-repository ppa:mozillateam/ppa sudo apt update sudo apt install firefox