How to Cleanly Uninstall a Snap Package in Ubuntu Using snap remove

The Snap Package Dilemma

Ubuntu Linux heavily relies on “Snap” packages—containerized software applications that bundle all their necessary dependencies into a single, secure file. While this makes installing software incredibly easy and prevents library conflicts, uninstalling Snaps can be messy. When you delete a Snap application using standard methods, the system often leaves behind large, hidden “snapshot” folders containing your user data, configuration files, and saved states. Ubuntu keeps these backups for 31 days just in case you decide to reinstall the app. However, if you are uninstalling a massive game or a large development environment to free up hard drive space, you need those gigabytes back immediately, not next month.

How to Completely Remove a Snap App

You can force the Snap manager to instantly purge all associated data by using a specific flag in the terminal.

  1. Open your Terminal application (Ctrl + Alt + T).
  2. First, find the exact, system-registered name of the application by typing:
  3. snap list
  4. Press Enter and locate your target app in the left-hand column (e.g., vlc or gimp).
  5. To completely uninstall the app and destroy all associated backup data immediately, type the following command:
    sudo snap remove --purge [app_name]
  6. For example: sudo snap remove --purge vlc
  7. Press Enter and provide your administrator password.

Cleaning Up Old Snap Revisions

Even if you cleanly uninstall apps, the Snap daemon automatically keeps two or three older versions (revisions) of every installed app on your hard drive so you can easily roll back if an update breaks something. If you are desperate for disk space, you can run a bash script to clear them out. A safer, built-in method to limit this behavior in the future is to change the system retention policy:

  1. sudo snap set system refresh.retain=2

This command tells Ubuntu to only ever keep a maximum of two versions of any Snap package, preventing your system folders from bloating out of control over the years.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.