Ways to Install or Uninstall wget on Ubuntu 22.04

Updated: October 8, 2022

Wget is a network utility to retrieve files from the web using HTTP(S) and FTP, the two most widely used internet protocols. It works non-interactively, so it will work in the background, after having logged off. The program supports recursive retrieval of web-authoring pages as well as FTP sites – you can use Wget to make mirrors of archives and home pages or to travel the web like a WWW robot. In this tutorial, I will show you ways to install wget Ubuntu 22.04.

Prerequisites

  • Operating system: Ubuntu 22.04 is needed for wget to work
  • Privileges: Make sure that you can run the sudo commands line.

Prerequisites to install wget on Ubuntu 22.04

Install wget Ubuntu 22.04

wget is one of the popular ways on Ubuntu now so that this tutorial will show you some ways to install it. Choose the one that you think is easy and you can follow.

Install wget using APT

This is one of the most popular methods for installing Ubuntu packages because it’s easy to follow, even if you are a newbie in Linux. Following these instructions to get wget on your Ubuntu 22.04.

Step 1: You must update the APT package repository cache before attempting to install, update, or remove any packages. Obtain new packages from Ubuntu by updating the APT database. Launching the terminal and entering the following Linux command:

sudo apt update

Step 2: Install the package on Ubuntu 22.04. After updating, you can install wget Ubuntu by pasting this command into the terminal and executing it.

sudo apt-get -y install wget

Install wget using Aptitude

Aptitude allows users to view a list of available packages and manage package installation, upgrade, and removal. If you haven’t already done so, run this command to install it.

sudo apt -y install aptitude

After that, you can now install wget by following these steps:

Step 1: Update the APT database to fetch new packages from Ubuntu. Opening the terminal and executing this Linux command:

sudo apt -y update

Step 2: Install the package on Ubuntu 22.04. After updating the system, you can now install wget Ubuntu by pasting this command into the terminal and pressing Enter.

sudo aptitude install wget

Uninstall wget on Ubuntu 22.04

Have you ever thought that uninstalling an application from Ubuntu might be challenging? You’re wrong; any program, not just a wget, can be easily uninstalled by anyone.

You can uninstall wget on Ubuntu by running this command if you installed it using APT or Aptitude.

sudo apt remove --auto-remove wget

To uninstall wget and remove its data and dependencies, you can also use the following command:

sudo apt autoremove --purge wget

Summary

In this tutorial, I showed you ways to install wget on Ubuntu 22.04 and ways to uninstall wget too. Please do not hesitate to contact me if you require assistance. I’m delighted to respond.