Install Software on Linux with Snap: Step-by-Step Guide
In this article
Yes, you can install software on Linux using Snap, and it's often the easiest method because Snap packages bundle all dependencies, work across most distributions, and update automatically. This guide walks you through installing Snap itself (if needed), finding and installing apps, and managing them—plus why Snap is a solid choice for many users.
What You'll Need
- A Linux distribution (Ubuntu, Debian, Fedora, Arch, etc.) with an internet connection.
- Terminal access (most steps use the command line, but some distributions have a graphical Snap Store).
- sudo privileges (you'll need to enter your password for installation commands).
- If your distribution doesn't include Snap pre-installed, you'll need to install the snapd daemon first (covered in Step 2).
Step-by-Step
- Check if Snap is already installed. Open a terminal and run:
snap --version. If you see version information, Snap is ready. If you get a "command not found" error, proceed to Step 2. - Install snapd (if needed). The method depends on your distribution:
- Ubuntu/Debian:
sudo apt update && sudo apt install snapd - Fedora:
sudo dnf install snapd - Arch Linux:
sudo pacman -S snapd(then enable the socket withsudo systemctl enable --now snapd.socket) - openSUSE:
sudo zypper install snapd
- Ubuntu/Debian:
- Find the software you want. Use the command
snap find search-term(e.g.,snap find spotify). This lists available snaps with their names, versions, and publishers. Alternatively, you can browse the Snap Store website or use the graphical Snap Store app if installed. - Install the snap. Run
sudo snap install snap-name(e.g.,sudo snap install spotify). Snap downloads the package and installs it automatically. You may see a progress bar; wait for it to finish. - Launch the application. You can find it in your application menu, or run it from the terminal by typing its name (e.g.,
spotify). Some snaps also add a desktop shortcut automatically. - Update snaps automatically. Snap updates installed apps in the background by default. To check for updates manually, run
sudo snap refresh. To see all installed snaps, usesnap list. - Remove a snap when you're done. Use
sudo snap remove snap-name(e.g.,sudo snap remove spotify). This removes the app and its data—make sure you don't need that data first.
Common Mistakes
- Forgetting to install snapd. On distributions like Fedora or Arch, Snap isn't pre-installed. Running
snap installwithout snapd gives a "command not found" error. - Not logging out after installing snapd. The Snap binaries are added to your PATH, but your current session may not see them until you log out and back in.
- Using the wrong package name. The name in the Snap Store might differ from the app's common name. Always check the output of
snap findfor the exact name. - Assuming all software is available as a snap. Some proprietary apps (like certain drivers) aren't packaged as snaps. Check the Snap Store first, but be prepared to use other methods (like .deb or AppImage) if needed.
- Ignoring snap permissions. Some snaps have strict confinement and may not access files outside your home directory. If an app can't read a file, check its permissions or use the
--classicflag only if the publisher explicitly requires it (e.g.,sudo snap install --classic codefor Visual Studio Code).
Tips
- Use the Snap Store GUI if you prefer a graphical interface. Install it with
sudo snap install snap-store, then browse and install apps with clicks. - Check snap size before installing. Some snaps are large because they bundle dependencies. Use
snap info snap-nameto see the download size. - Pin a snap to a specific channel. If you want a beta or stable version, use
sudo snap install snap-name --channel=beta(or--channel=stable). - Keep your snaps tidy. Periodically run
sudo snap refreshto update all snaps andsnap listto see what you have. Remove unused snaps to free disk space. - Understand the trade-offs. Snap apps may start slower than native packages due to their sandboxing, but they're more secure and portable across distributions.
Troubleshooting
If something goes wrong, try these checks in order:
- Snap command not found? Make sure snapd is installed and your PATH includes /snap/bin. On some systems, you may need to add it manually:
export PATH=$PATH:/snap/bin(add this to your ~/.bashrc to make it permanent). - Install fails with a network error? Check your internet connection and try again. If you're behind a proxy, configure it with
sudo snap set system proxy.http=... proxy.https=.... - App doesn't launch? Run the app from the terminal to see error messages. Sometimes a missing dependency is the issue, but snaps should include all dependencies—if it still fails, try reinstalling:
sudo snap remove snap-name && sudo snap install snap-name. - Snap refreshes fail? Run
sudo snap refreshagain. If it still fails, check disk space withdf -h—snaps need room to download updates. Also check if the snap is held:snap refresh --holdshows held snaps. - App can't access certain files or devices? Some snaps are confined. Look for a "Connect interfaces" option in the Snap Store, or use
sudo snap connect snap-name:interface(e.g.,sudo snap connect spotify:audio-record). Check the snap's documentation for required interfaces. - Still stuck? Check the Snap Store page for the app—many have a "Report an issue" link. You can also ask on the Snapcraft forum (forum.snapcraft.io) with your distribution and snap name.
Frequently Asked Questions
Why should I use Snap instead of my distribution's package manager?
Snap packages work across many distributions, bundle all dependencies (so they don't conflict with system libraries), and update automatically. This is especially useful for apps that aren't in your distro's official repos or that need frequent updates.
Are snaps safe to install?
Snaps are sandboxed, meaning they have limited access to your system. They're reviewed by Canonical (the company behind Ubuntu) and the community. However, always install from trusted publishers—check the publisher name on the Snap Store page.
Do snaps work on all Linux distributions?
Snap is supported on most major distributions, including Ubuntu, Debian, Fedora, Arch, and openSUSE. As long as you can install snapd, snaps will run. Some minimal distributions may need extra steps.
How do I update a specific snap?
Run sudo snap refresh snap-name to update just that snap. To update all snaps, use sudo snap refresh without a name.
Can I install a snap without sudo?
No, installing system-wide snaps requires sudo because they affect the whole system. However, you can use the --user flag with snap install to install a snap only for your user, but this is rare and not supported by all snaps.
What's the difference between snap and flatpak?
Both are universal packaging formats. Snap is led by Canonical and works on more distributions out of the box, while Flatpak is more popular on Fedora and some other distros. The choice often comes down to what your distribution recommends and which apps you need.