Publicidade - Adsense
How to install cURL on Windows
TLDR; cURL requires an install on Windows, but it isn’t always easy unless you use a one-click installer or Chocolatey.
I remember cURL being easier to install than it currently seems to be. I’ve had a few questions from people working through my book “Automating and Testing a REST API” on who were experiencing difficulties installing cURL on Windows. I documented a few different approaches.
In order of easiness:
- install it using Chocolatey
- install it with a one click installer
- using official cURL binaries
Install it using Chocolatey
Assuming you have Chocolatey installed.
choco install curl
Install it with a one click installer
If you prefer graphical installers then the one click installer from confused by code seemed to work well.
This installs everything and adds curl to your path, I’ve used this before for setting up my machines for training courses.
During the installation process, it might prompt you to install the VC++ redistributables, but there is a link in the installer that takes you to the download, then download and install then click continue in the cURL install to continue.
Then cURL should be on your path.
Official Installs from cURL
I found these the hardest to work with. It was not easy to see which were binary packages and which were not.
I went to curl.haxx.se/dlwiz
and looked at the window compiled versions
I found the following that worked relatively easily:
- the SSL enabled cab file 7.59.0 from Stefan Kanthak
- but you have to be able to extract cab files properly
- the 7.59 MinGW version from Viktor Szakats. curl.exe is in the \bin folder and if I can run curl from this folder or add it to the path.
- Mingw is a set of libraries that can be used to compile Unix applications for running on windows so they are often self-contained executables.
I haven’t tried these for a while, but they might offer useful research opportunities.
- cURL comes with Cygwin so you could install that
- install a Linux VM which has cURL installed e.g. from Turnkey or Bitnami or OSBoxes
- install cURL into the Windows 10 Bash shell using the Windows 10 Linux Distro
You can also find all the videos on the “Automating and Testing a REST API Book Support Page
Install Using Chocolatey
Confused By Code Installer