Multiple Methods to Install Apps on Ubuntu
A simple guide to installing, running, and removing applications on Ubuntu.
1. Using APT (Advanced Package Tool)
What it is:
APT is Ubuntu’s standard package manager for software from official repositories.
Install:
sudo apt update # Update package list
sudo apt install package_name
Run: Most installed apps can be run by typing their name in terminal, e.g.:
firefox
Remove:
sudo apt remove package_name # Remove but keep config files
sudo apt purge package_name # Remove including config files
sudo apt autoremove # Remove unused dependencies
Pros:
- Secure and stable
- Easy to manage dependencies
Cons:
- Limited to packages in Ubuntu repositories
- Versions may not be the latest
2. Using Snap
What it is:
Snap is a universal package system from Canonical. It bundles dependencies with the app.
Install:
sudo snap install package_name
Run:
package_name
Some snaps may have different names than the command to run.
Remove:
sudo snap remove package_name
Pros:
- Works across all Ubuntu versions
- Latest versions available
Cons:
- Larger size (includes dependencies)
- Some apps can start slower
3. Using Flatpak
What it is:
Flatpak is another universal package system, similar to Snap, maintained by the community.
Setup (once):
sudo apt install flatpak
sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
Install:
flatpak install flathub package_name
Run:
flatpak run package_name
Remove:
flatpak uninstall package_name
Pros:
- Isolated from system
- Works across distros
Cons:
- Larger disk usage
- Commands slightly different than normal packages
4. Using AppImage
What it is:
An AppImage is a single portable executable file. No installation needed.
Use:
Download
.AppImage
fileMake it executable:
chmod +x package_name.AppImage
Run it:
./package_name.AppImage
Remove:
- Just delete the
.AppImage
file; nothing else is installed.
Pros:
- Portable, no installation
- No system changes
Cons:
- No automatic updates
- Not integrated into system menu by default
What chmod
Means:chmod
(change mode) changes file permissions — who can read (r), write (w), and execute (x) a file.
5. Using DEB Files
What it is:
DEB files are Ubuntu/Debian package files you can download manually.
Install:
sudo dpkg -i package_name.deb
sudo apt -f install # Fix missing dependencies
Run: Same as APT packages, usually the package name:
package_name
Remove:
sudo apt remove package_name
Pros:
- Works offline
- Familiar with Ubuntu/Debian
Cons:
- Dependencies may require manual fixes
- Not as seamless as APT
Quick Comparison Table
Method | Source | Installation | Size & Updates | Isolation | Removal |
---|---|---|---|---|---|
APT | Official repo | sudo apt install | Small, auto updates | System-wide | sudo apt remove |
Snap | Snap store | sudo snap install | Large, auto updates | Isolated | sudo snap remove |
Flatpak | Flathub | flatpak install | Large, auto updates | Isolated | flatpak uninstall |
AppImage | Anywhere | Just download | Single file, manual update | Fully isolated | Delete file |
DEB | Downloaded file | sudo dpkg -i | Medium, manual fix | System-wide | sudo apt remove |
Core Differences in Simple Terms:
- APT & DEB: System-integrated, rely on Ubuntu’s dependency management.
- Snap & Flatpak: Bundle dependencies, more isolated, bigger, can run on other Ubuntu versions.
- AppImage: Fully portable, no install needed, very isolated, manual updates.
Why So Many Installation Methods?
Linux has multiple ways to install software because of history, stability, compatibility, and freedom of choice:
- History: Different Linux families (Debian, Red Hat, etc.) created their own package formats.
- Stability vs. Latest: APT gives stable but older software, while Snap/Flatpak/AppImage give the latest.
- Cross-distro: Snap, Flatpak, and AppImage work across all Linux distributions.
- Freedom: Linux culture values giving users multiple options, not forcing one method.
In short: APT is stable, Snap/Flatpak/AppImage are universal, and DEB/dpkg are manual.