How to Uninstall Applications on Linux

Ubuntu is a Linux distribution managed- using the command line interface. Ubuntu distribution supports hundreds of packages that can be installed on computers by using different package managers. After an application is installed using a package manager, the user needs to utilize the same for uninstalling the application. This post serves the possible ways to uninstall applications from Ubuntu 22.04.

There are four approaches to deleting the applications from Ubuntu that are listed below:

Let’s start this guide!

Method 1: Using the apt package manager

The default package manager to manage the packages on Ubuntu is an apt package manager. This package manager is used to install, update and remove the packages available in the default repository or added to the default repository.

How to install Kali Linux in Window...

The general syntax of using the apt package manager to remove packages is:

$ sudo apt remove [package name]

For example, to uninstall the package of VLC, use the command:

$ sudo apt remove vlc -y

The above package has been removed from the Ubuntu, but files associated with its downloaded package and configuration are still in Ubuntu which can be removed by executing the command:

$ sudo apt auto-remove -y

Now, the package of VLC has been completely removed from Ubuntu with its configuration files. The recommended and easiest way to uninstall the package is by using the purge option with the apt command utility. This option will remove the package along with all its files:

$ sudo apt purge vlc -y

The package of VLC (It is installed again to elaborate the above command) has been removed from Ubuntu successfully.

Method 2: Using the dpkg Package Manager

To manage the Debian packages on Ubuntu, we mostly use the dpkg package manager. The downloaded Debian packages can be installed and uninstalled using the dpkg manager

The general syntax of using the dpkg manager to uninstall the packages is

$ sudo dpkg –r [package name]

For example, the following command will uninstall the package of “visual studio code” using the dpkg manager tool:

$ sudo dpkg  -r code

Note: However, the recent releases of Ubuntu support the apt package manager to handle “.deb” files. So, the users can adapt the apt package manager method to uninstall the “.deb” applications.

Method 3: Using the snapd utility

The package installed by downloading from the snap craft store can only be deleted using the snapd utility. To uninstall the snap packages, follow the syntax:

$ sudo snap remove [package name]

For example, we can delete the installed package using the snap utility.

$ sudo snap remove thunderbird

Method 4: Using the flatpak utility

Like snapd utility, flatpak utility is used to manage the packages installed from the flat hub store. The flatpak utility to uninstall packages is:

$ flatpak uninstall flathub [package address]

For instance, the WhatsApp application is deleted using the following flatpak command:

$ flatpak uninstall flathub com.github.eneshecan.WhatsAppForLinux

That’s all from this guide!

Conclusion

To uninstall the applications on Ubuntu, use apt pkg manager, dpkg manager, snapd utility, and flatpak utility. The uninstallation method depends on the method which is followed for installation. Like, the packages installed from the snap utility will be removed using snap. The same goes for other package managers as well. In this blog, all possible methods to uninstall applications from Ubuntu 22.04 are practically demonstrated.