I am Hack Sparrow
Captain of the Internets.

How to download file using cURL

Downloading files using cURL

So you wanna download files using cURL but don't know how to do that. Fear not, for the super-genius Captain Hack Sparrow is here to show you how to do just that. Learn from these examples:

$ curl -O http://example.com/Flag_of_Edward_England.svg

The above usage of cURL with the uppercase O option will download the file with the same name as the original.

$ curl -o flag.svg http://example.com/Flag_of_Edward_England.svg

The above usage of cURL with the lowercase o option will download the file with the a new name "flag.svg".

That's very basics of downloading files using cURL. cURL is multi-featured tool which has tons of options with millions of capabilities, there is a lot more to what you can do with cURL. Wanna know what else you can do with it? Do the following:

$ man curl
$ curl -h

More cURL knowledge and power to you. Happy cURLing!

Make a Comment