I am keen to know the difference between
wget. Both are used to get files and documents but what the key difference between them.
Why are there two different programs?
The main differences are:
wget's major strong side compared to
curlis its ability to download recursively.
wgetis command line only. There's no lib or anything, but
curl's features are powered by libcurl.
curlbuilds and runs on more platforms than
wgetis released under a free software copyleft license (the GNU GPL).
curlis released under a free software permissive license (a MIT derivate).
curloffers upload and sending capabilities.
wgetonly offers plain HTTP POST support.
You can see more details at the following link:
In a few words:
wgetis a tool to download files from servers
curlis a tool that let's you exchange requests/responses with a server
Wget solely lets you download files from an
FTP server. You give it a link and it automatically downloads the file where the link points to. It builds the request automatically.
Curl in contrast to wget lets you build the request as you wish. This gives a lot of freedom to the user and makes an amazing debugging tool. Add to that the other key difference between the two: the plethora of protocols supported. Curl supports
URI. Combine these two key points and you have an amazing tool to test protocols, test server configuration, etc.
As many say, you can download a file with curl. That however is only useful if you happen to want to download a file from a server that uses a protocol that wget doesn't support.
Actually, the major difference is that
curl includes a library (
libcurl), and that library is widely used by other applications.
wget is standalone.