Snaps
Snap is the name of Ubuntu’s native, but universal container format for applications. Snaps are seamlessly integrated into every Ubuntu system and receive automatic updates from the preconfigured Snapcraft.io repository. The snapd service handles that.
Snaps may be used on every Linux distribution, where snapd is available. However, most distros prefer using the competing format, Flatpak. The Ubuntu derivative Linux Mint has gone as far as blocking snaps, disabling them by default in the Apt package manager.
Advantages and disadvantages of container formats
Snaps have similar advantages to their competing format, Flatpaks:
- Security: Applications run in a sandbox. Similar to smartphones, access to the file system, location services, etc., can be restricted.
- Escape from Dependency Hell: Applications are packaged with all the necessary libraries inside the container, so they work across different distributions and versions.
- Relief for Developers: Instead of building and maintaining packages for individual distribution formats (deb, rpm, apk, etc.), developers only need to provide the Snap.
- Up-to-date Software: Although there are many more deb packages than Snaps, some applications are only offered as Snaps or are available in newer versions as Snaps than their older packaged counterparts.
However, this also leads to some disadvantages:
- Size: Snaps are significantly larger than traditional deb packages because they must include all the libraries required for their function.
- Potential Unreliability: Unlike packages controlled by maintainers, Snaps are managed by developers or third parties. They can be abandoned or even used for malware distribution .
Crypto scams raising security issues
Fraudulent crypto wallet apps have appeared multiple times in the Snap Store. In one case, $490,000 was stolen; in another, scammers took over the domain of a former Snap publisher and thus their account to continue their scheme under a new guise. All of this has been documented by a former Canonical employee.
In summary, similar caution is advised before installing Snaps as with using PPAs and third-party sources. Despite automated checks and — since the crypto scams — reviews by real people, only Snaps from trusted sources are truly safe:
- “Official” Snaps: The program’s or publisher’s homepage should provide a download link pointing to the Snap Store. Well-known official Snaps come from Spotify, Microsoft (VS Code), and Google (Cloud SDK).
- Source “Snapcrafters”: Snaps marked with this source indication can be assumed to be created by Canonical employees or well-known community members.
- Verified sources are marked with a green badge.
Installing snaps from the App Center
On the Ubuntu desktop, Snaps are offered alongside the traditional deb packages in the App Center, the graphical software management tool. Some applications are available both as Snaps and as traditional packages. In such cases, you should carefully consider which version you want. The search in the App Center can also be specifically filtered by “Debian packages” or “Snaps.” Some snaps come in stable, beta or edge versions. You should prefer the stable version to the development versions.
Certain core applications like the browsers Firefox and Chromium or the email program Thunderbird have been installed by Ubuntu as Snaps by default for several years. It goes so far that even running
$ apt install firefox
on the command line does not install the Deb package, but the Snap instead. Here, your only option is to set up Mozilla’s own package source (yes, Mozilla builds its own Deb packages) and use Apt pinning to configure the package management so that Firefox is installed from the alternative source.
Pre-installed snaps
It started with Ubuntu 22.04 LTS, when Firefox was forced to be installed as a snap. Over the years, more snaps were added. Here is a list of snaps installed on a fresh Ubuntu 26.04 LTS:
$ snap list
Name Version Rev Tracking Publisher Notes
bare 1.0 5 latest/stable canonical✓ base
core24 20260317 1587 latest/stable canonical✓ base
desktop-security-center 0+git.80cd2b4 150 1/stable/… canonical✓ -
firefox 149.0.2-1 8107 latest/stable/… mozilla✓ -
firmware-updater 0+git.5645b80 226 1/stable/… canonical✓ -
gnome-46-2404 0+git.f1cd5fa-sdk0+git.ca9c59c 153 latest/stable/… canonical✓ -
gtk-common-themes 0.1-81-g442e511 1535 latest/stable/… canonical✓ -
mesa-2404 25.0.7-snap211 1165 latest/stable/… canonical✓ -
prompting-client 0+git.2e14a72 204 1/stable/… canonical✓ -
snap-store 0+git.10310e85 1367 2/stable/… canonical✓ -
snapd 2.75.2 26865 latest/stable canonical✓ snapd
snapd-desktop-integration 0.9 361 latest/stable/… canonical✓ -
thunderbird 140.9.1esr-1 1057 latest/stable/… canonical✓ -
ubuntu-desktop-bootstrap 26.04 589 26.04/stable canonical✓ classic
Snap critique
Within the notoriously contentious Linux community, there are a few particularly vocal critics who have nothing good to say about Snaps. Main points of criticism are directed at the Snap Store, which is a centralized entity (in contrast to the potentially decentralized distribution of Flatpaks) and whose code is not completely open source. Snaps are, according to common criticism, just another unilateral effort by Canonical. While some arguments are basically correct, others are typical Canonical bashing. On a standard Ubuntu system, you certainly cannot avoid Snaps anyway.
Managing snaps from the command line
The basics are similar to the usage of Debian’s apt tool:
$ snap install <snap-name>
$ snap remove <snap-name>
To get a list of all snaps installed:
$ snap list
Snaps also save snapshots before they are updated or uninstalled. Snapshots include user settings and application data and are deleted by default after 31 days. To manually delete a snapshot, proceed as follows:
$ snap saved # alle Snapshots mit ihren IDs listen
$ snap forget <id-Nummer> # einen Snapshot löschen
When uninstalling a snap, a final snapshot is created. This can be prevented with the purge option:
snap remove --purge <snap-name>
How do snaps work?
Like every container format, Snaps require a lot of storage space. Canonical tries to confront this problem with several measures:
- Snaps are stored as SquashFS filesystems, which are designed to be compressed. This has a disadvantage too: snaps must be decompressed upon first execution, which may prolong the starting time more or less – depending on the hardware. Because of slow starting times with the Firefox snap the developers have changed – among other things – the compression algorithm. However, snaps are starting slower by design, the older/slower the hardware, the more you notice it.
- Snaps package many, but not all dependencies, just like Flatpaks. To save space, Ubuntu has base packages for the core, the desktop environment and the theming, which must be installed only once (actually, they are pre-installed in Ubuntu).
- When snaps get updated, the download size is minimized thanks to so-called deltas: Instead of downloading the entire Snap, only the changed parts must be downloaded.
Where are snaps stored?
All snaps are stored in /var/lib/snapd/snaps and are mounted at /snap/<name>/<revisions-nummer> as SquashFS filesystems. That’s the reason why Ubuntu systems have an awful lot of mountpoints.
User data may be found in the home directory at ~/snap.
Introspect and troubleshoot a snap
In order to introspect a snap, see their components or which base snap is used, you have two choices:
- Look into the snap.yaml file of an installed snap (open it with you text editor of choice).
- Use
snap <command> <snapname>. , . This works even with snaps that are not yet installed.
Useful commands are snap info (add the option --verbose if necessary) to get, well, information about a snap or snap connections to see, which interfaces a snap may use to break out of its sandboxed confinement.
Run the following command to see which core snap the firefox snap uses:
$ snap info --verbose firefox | grep base:
base: core24
On Ubuntu 26.04 LTS shortly after its publication this yields core24 (and not core26, as you might expect).
The following command inspects the connections the Firefox snaps is allowed to use:
$ snap connections firefox
Interface Plug Slot Notices
alsa firefox:alsa - -
audio-playback firefox:audio-playback :audio-playback -
[...]
Since Firefox requires a lot of connections (networking, audio, graphics, file system, desktop environment …), only the first lines of the command’s output are shown above. in this example, Firefox is capable of using the old ALSA sound driver (a “plug” exists), but it’s not plugged in (the “slot” is empty, indicating that ALSA is not used). Firefox is connected to an “audio-playback” interface instead (the slot “:audio-playback” is plugged in).
Automatic and manual garbage collection
When snaps are updated, at least two previous version are kept with the status “disabled”. On computers with small hard drives this may lead to a lot of garbage. Two solutions to this problem exist:
- Either you wait for automatic garbage collection, which happens by default after 31 days.
- Or you remove the outdated versions yourself.
snap list --all | awk '/disabled/{print $1, $3}' # List outdated snaps including revision
snap remove <name> --revision=<number>
