How to Check Installed Apps on Ubuntu and Remove Them Cleanly (Step-by-Step Guide)

Image

Keeping your Ubuntu system clean isn’t just about aesthetics—it directly impacts performance, stability, and even security. Over time, unused applications, leftover configuration files, and cached packages can pile up and slow things down.

In this practical guide, you’ll learn exactly how to:

  • Check installed applications on Ubuntu
  • Remove apps properly (without breaking your system)
  • Clean up leftover files and dependencies
  • Maintain a lean, efficient Linux environment

This guide is beginner-friendly but still useful for experienced users who want a clean workflow.


Why You Should Regularly Clean Installed Apps

Before diving into commands, here’s why this matters:

  • Free up disk space (especially important on SSDs)
  • Improve system performance
  • Reduce clutter in your app menus
  • Avoid dependency conflicts
  • Strengthen system security

If you install and test a lot of software, regular cleanup is essential.


Step 1: Check Installed Applications on Ubuntu

Ubuntu uses package managers to track installed software. The most common ones are apt, dpkg, Snap, and Flatpak.

List All Installed Packages

To see everything installed via APT:

apt list --installed

This shows a long list of packages. It includes both user-installed apps and system dependencies.


Search for a Specific Application

If you’re looking for a particular app:

apt list --installed | grep <app-name>

Example:

apt list --installed | grep firefox

This helps confirm whether an app is installed and its exact package name.


Use dpkg for Detailed Listing

For a more technical view:

dpkg -l

This displays:

  • Package name
  • Version
  • Status (installed, removed, config remains)

Step 2: Remove Applications (The Right Way)

Removing apps incorrectly can leave behind unnecessary files or even break dependencies. Here’s how to do it properly.


Option 1: Remove an App (Keep Config Files)

sudo apt remove <package-name>

Use this if:

  • You plan to reinstall the app later
  • You want to keep your settings

Option 2: Completely Remove an App (Recommended)

sudo apt purge <package-name>

This removes:

  • The application
  • All associated configuration files

Best practice: Use purge unless you specifically need configs.


Step 3: Clean Up Unused Dependencies

When you install software, Ubuntu installs additional packages (dependencies). After removing apps, some of these become unnecessary.

Clean them up with:

sudo apt autoremove

This command safely removes packages that are no longer needed.


Step 4: Clear Package Cache

Ubuntu stores downloaded package files in a cache. Over time, this can grow significantly.

To clear it:

sudo apt clean

This deletes all cached .deb files and frees up disk space.


Step 5: Remove Leftover Configuration Files

Sometimes, even after uninstalling apps, configuration files remain.

Find Residual Config Files

dpkg -l | grep ^rc

Packages listed here are already removed—but their config files still exist.


Remove All Leftovers in One Command

sudo dpkg --purge $(dpkg -l | grep ^rc | awk '{print $2}')

This cleans up all residual configurations in one go.


Step 6: Manage Snap Applications

Ubuntu often installs apps using Snap packages.

List Snap Apps

snap list

Remove a Snap App

sudo snap remove <package-name>

Snap apps are isolated, but they can take up significant space, so it’s worth reviewing them.


Step 7: Manage Flatpak Applications (If Installed)

Flatpak is another package system some users install manually.

List Flatpak Apps

flatpak list

Remove a Flatpak App

flatpak uninstall <package-name>

Step 8: Safe Cleanup Workflow (Recommended Routine)

Here’s a simple, effective cleanup routine you can use regularly:

sudo apt purge <package-name>
sudo apt autoremove
sudo apt clean

For deeper cleaning:

dpkg -l | grep ^rc
sudo dpkg --purge $(dpkg -l | grep ^rc | awk '{print $2}')

Common Mistakes to Avoid

❌ Removing Essential System Packages

Avoid uninstalling core packages like:

  • ubuntu-desktop
  • gnome-shell

Removing these can break your system interface.


❌ Blindly Copy-Pasting Commands

Always check what a command does before running it—especially ones using $() or awk.


❌ Ignoring Snap and Flatpak

Many users forget these package systems, leaving unused apps behind.


Pro Tips for Keeping Ubuntu Clean

  • Review installed apps monthly
  • Install only what you need
  • Use lightweight alternatives when possible
  • Check disk usage with:df -h

Final Thoughts

Cleaning your Ubuntu system doesn’t require advanced Linux knowledge—just a few essential commands used correctly.

By regularly:

  • Checking installed apps
  • Removing unused software
  • Cleaning dependencies and cache

—you’ll keep your system fast, stable, and efficient.

Think of it like routine maintenance: small actions now prevent bigger issues later.


Quick Reference Cheat Sheet

# List installed packages
apt list --installed

# Remove app completely
sudo apt purge <package-name>

# Remove unused dependencies
sudo apt autoremove

# Clean cache
sudo apt clean

# Find leftover configs
dpkg -l | grep ^rc

# Remove leftover configs
sudo dpkg --purge $(dpkg -l | grep ^rc | awk '{print $2}')

# Snap
snap list
sudo snap remove <package-name>

# Flatpak
flatpak list
flatpak uninstall <package-name>

If you follow this guide, your Ubuntu system will stay clean, efficient, and easy to manage—no unnecessary clutter, no wasted space, and fewer headaches down the line.


Leave a Reply

Your email address will not be published. Required fields are marked *