When you are a Linux user, you are so familiar to wget command. In simple words, it is a command to download file from a given URL and port. Most Linux users and some windows users are familiar to this handy command download tool and on most Linux distributions it is pre-installed, but on Max OSX it is not installed and Apple does not offer it in AppStore, so the suer should install it manually, which is so straightforward, fast and easy.

In this tutorial I want to describe how to install wget on Mac OS X.

Thing we will go through in this tutorial:

Download the last version of wget Make the downloaded package ready Installation process

Things you need to have installed on your Mac OSx:

Have C compiler inorder to compile he wget source code which you can have it installed via installing xCode. (For more info, check out the comments)

1. Download the last version of wget

We are going to use the official download location of wget. Go to the link below and download the latest version of wget in .tar.gz format:

http://ftp.gnu.org/pub/gnu/wget/

2. Make the downloaded package ready

This step is also easy, we should extract the .tar.gz file and that’s it 😀 (In this tutorial i’m going to use the wget-1.14.tar.gz which is the latest version at the moment of writing this article)

cd Downloads tar -xzf wget-1.14.tar.tar.tar.gz

3. Installation process

When you extract the downloaded file with the command above, a directory will automatically been created near the .tar.gz file with similar name, so we should go in that directory:

cd wget-1.14

Then we should run the configuration file with the desired options:

./configure --with-ssl=openssl

Now it is the time to start the automated compiling and installation by using the following commands:

make sudo make install

The sudo which is in front of the command above will ask you the administration password, so the installation be able to proceed.

By now the wget should be successfully installed on you Mac, however you can simply check if the installation was successful or not by asking the Mac to show the help of wget:

wget --help

If you see the help document, then the wget is perfectly installed. Now that everything is done correctly, it’s time to cleanup the mess :D. use the following commands to remove unnecessary files and folders:

cd .. rm -rf wget-*