You Just Switched to Linux and Now You’re Stuck
You’ve made the leap. The sleek desktop is booted, the terminal is open, and a world of free, powerful software awaits. But the first question hits you: how do I actually get new programs on here? If you’re coming from Windows or macOS, where you download a .exe or .dmg file and double-click, Linux can feel like a different planet.
The feeling is common. The initial confusion around software installation is one of the biggest hurdles for new Linux users. You might be trying to install a code editor, a game, a media player, or a productivity tool, only to find there’s no obvious “Install” button.
Don’t worry. Installing software on Linux is not only straightforward but often more secure and reliable than the methods you’re used to. This guide will demystify the entire process, from the graphical app store on your desktop to the powerful command-line tools that give you ultimate control. By the end, you’ll know exactly where to look and what to type to get any program running.
Why Linux Installation Feels Different (And Why It’s Better)
On most other operating systems, software comes from scattered sources. You visit a developer’s website, download an installer, and hope it’s safe and compatible. Linux uses a centralized model built around something called a package manager.
Think of a package manager as an app store, but one that’s deeply integrated into the system’s core. It doesn’t just install the program; it handles finding the software, downloading it from trusted repositories (official software sources), checking for digital signatures, and automatically installing any other required software pieces, called dependencies.
This system means you get your software from a single, vetted source maintained by your Linux distribution (like Ubuntu, Fedora, or Arch). It eliminates “DLL hell” and makes updating every piece of software on your computer a one-command operation. The trade-off is you need to learn the tools of your specific distribution.
Meet Your Distribution’s Package Manager
Your first step is to identify which “family” of Linux you’re using. The package manager is the key. Here are the major players:
– Debian/Ubuntu/Linux Mint: These use the APT (Advanced Package Tool) system. The command-line tools are `apt` and `apt-get`. Software comes in `.deb` files.
– Fedora/RHEL/CentOS: These use the DNF (or older YUM) system. The command-line tool is `dnf`. Software comes in `.rpm` files.
– Arch Linux/Manjaro: These use the Pacman system. The command-line tool is `pacman`.
– openSUSE: Uses the Zypper system (`zypper` command).
For 90% of users, knowing the graphical front-end and the basic command for your distro is enough. Let’s start with the easiest method.
The Easiest Way: Your Desktop’s App Store
Almost every modern Linux desktop environment comes with a graphical software center. It’s the quickest way to browse and install applications without touching the terminal.
On Ubuntu and GNOME-based systems, it’s called “Ubuntu Software” or “GNOME Software.” On KDE Plasma, look for “Discover.” On elementary OS, it’s “AppCenter.” These tools are front-ends for your system’s package manager. You can search for applications by name or category, read descriptions and reviews, and click “Install.” The system handles the rest, including entering your password for authorization.
This is perfect for everyday applications like Firefox, VLC media player, GIMP, LibreOffice, and Steam. It’s safe, simple, and familiar. Use this as your default starting point.
When the App Store Isn’t Enough
You might search the software center and not find the specific program you want. This happens for a few reasons. The software might be very new, it might be distributed only by the developer, or it might be in a repository that isn’t enabled by default. This is when you need to graduate to the next level: the command line.
Mastering the Terminal: Installation Commands for Your Distro
The terminal is your most powerful tool. Once you know the basic commands for your distribution, you can install anything, often faster than using the GUI. Always open a terminal application first.
For Ubuntu, Debian, and Derivatives (APT)
First, update your local list of available software. This is like refreshing the app store catalog. Open a terminal and run:
`sudo apt update`
The `sudo` part gives you administrative privileges, and `apt update` fetches the latest package lists from the repositories.
Now, to install a program. Let’s say you want to install the code editor `gedit`. You would run:
`sudo apt install gedit`
The system will show you what will be installed and how much space it will use. Type `Y` and press Enter to confirm. That’s it. To remove a program, use `sudo apt remove gedit`. To completely remove it and its configuration files, use `sudo apt purge gedit`.
For Fedora, RHEL, and Derivatives (DNF)
The process is very similar. First, update your package metadata:
`sudo dnf check-update`
Then, to install a package (like the `nano` text editor):
`sudo dnf install nano`
To remove it, use `sudo dnf remove nano`.
For Arch Linux and Derivatives (Pacman)
Arch users update the system and package lists in one go with:
`sudo pacman -Syu`
Then, to install a package (like `firefox`):
`sudo pacman -S firefox`
To remove it, use `sudo pacman -R firefox`. To remove it and its unused dependencies, use `sudo pacman -Rns firefox`.
Installing Software From Outside the Repositories
Sometimes, the software you need isn’t in the official repositories. There are three common ways to handle this, each with its own level of complexity and risk.
Method 1: Enabling a Third-Party Repository (PPA/COPR)
Many developers maintain their own repositories. Adding these to your system allows you to install and update their software using your normal package manager.
On Ubuntu, these are called Personal Package Archives (PPAs). To add a PPA, you use the `add-apt-repository` command. For example, to add a popular PPA for the “Synaptic” package manager tool (though it’s already in main repos), the old syntax was:
`sudo add-apt-repository ppa:synaptic/stable`
`sudo apt update`
`sudo apt install synaptic`
On Fedora, community repositories are managed via COPR. You enable them with `dnf copr enable` commands.
Warning: Only add repositories from sources you trust. A malicious or poorly maintained repository can compromise system stability and security.
Method 2: Installing a Downloaded Package File (.deb, .rpm)
This is closest to the Windows .exe experience. You download a `.deb` file (for Debian/Ubuntu) or `.rpm` file (for Fedora/openSUSE) from a developer’s website.
You can often double-click the downloaded file, and your software center will open to handle the installation. From the terminal, navigate to your Downloads folder and use the package manager directly.
For a .deb file on Ubuntu:
`sudo apt install ./downloaded-package-name.deb`
For an .rpm file on Fedora:
`sudo dnf install ./downloaded-package-name.rpm`
The `./` is important—it tells the package manager to install from the local file in the current directory.
Method 3: Using Universal Packaging Formats (Flatpak and Snap)
This is the modern solution to the “app not in my repo” problem. Flatpak and Snap are containerized packaging systems. They bundle an application with all its dependencies into a single, secure package that runs on almost any Linux distribution.
Flatpak is often pre-installed. You can find thousands of applications on Flathub. To install a Flatpak, first add the Flathub remote (if not already done):
`flatpak remote-add –if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo`
Then, install an app like the Discord client:
`flatpak install flathub com.discordapp.Discord`
Snap is developed by Canonical (the company behind Ubuntu) and is installed by default on Ubuntu. To install a Snap, like the Spotify client, simply run:
`sudo snap install spotify`
These formats are excellent for getting the latest versions of popular desktop applications like Slack, Zoom, and Steam.
Compiling From Source: The Advanced Route
Sometimes, especially with niche or cutting-edge software, the only option is to compile it from the source code. This process typically involves:
– Installing build tools and dependencies (`build-essential` on Ubuntu, `base-devel` on Arch).
– Downloading a source code tarball (a `.tar.gz` file).
– Extracting it, running a `./configure` script (or using `cmake`).
– Running `make` to compile.
– Running `sudo make install` to copy the files to your system.
This method gives you maximum control and optimization but is complex and can lead to dependency issues. It’s generally recommended only when no other package is available. Always check the software’s `README` or `INSTALL` file for specific instructions.
What to Do When Installation Fails
Even with the right command, things can go wrong. Here’s how to troubleshoot common errors.
“Package Not Found” Error
This means the package name you typed isn’t in your enabled repositories. First, double-check the spelling. Next, search for the package to see its exact name:
On Ubuntu: `apt search keyword`
On Fedora: `dnf search keyword`
On Arch: `pacman -Ss keyword`
If it truly doesn’t exist, you may need to add a third-party repository or look for a Flatpak/Snap.
“Unable to Locate Package” After Adding a PPA
You added a repository but `apt install` still fails. Did you remember to update your package lists? Always run `sudo apt update` after adding a new repository.
Broken Dependencies or “Held Packages”
This is a more serious issue where the package manager cannot resolve conflicting software requirements. A powerful fix on APT-based systems is:
`sudo apt –fix-broken install`
This command attempts to repair the dependency tree. If that fails, tools like `sudo apt autoremove` (to remove unused packages) and `sudo apt full-upgrade` (a more aggressive upgrade) can help.
Keeping Your Software Updated
One of the biggest advantages of Linux is centralized updates. To update all the software installed from your repositories, you typically need just one command.
On Ubuntu/Debian: `sudo apt update && sudo apt upgrade`
On Fedora: `sudo dnf upgrade`
On Arch: `sudo pacman -Syu`
For Flatpaks, run `flatpak update`. For Snaps, they usually update automatically, but you can run `sudo snap refresh`.
Making this a weekly habit is the best way to keep your system secure and running smoothly.
Your New Linux Software Workflow
You now have a complete map for installing any program on Linux. Here is your practical decision tree for the next time you need something:
1. First, check your desktop’s graphical software center. It’s quick and easy.
2. If it’s not there, open a terminal and try installing via your distribution’s package manager (`sudo apt install` or `sudo dnf install`).
3. If the package isn’t found, search for a Flatpak or Snap version of the application. This is often the cleanest solution for desktop apps.
4. As a last resort, look for a .deb/.rpm download from the official project website or consider adding a trusted third-party repository.
The initial learning curve is real, but the payoff is immense. You gain a transparent, secure, and efficient system for managing all your software. You’re no longer clicking through random installers from the web; you’re using tools designed for stability and control. Start with the app store, get comfortable with a few terminal commands for your distro, and explore Flatpak for the latest apps. Before long, installing software will feel not just easy, but powerfully simple.