Skip to main content
All CollectionsTechnical Resources
Learn how to install & run cURL on Windows/MacOSX/Linux
Learn how to install & run cURL on Windows/MacOSX/Linux

Learn to handle your HTTP request by using the command-line tool cURL

Sergio M avatar
Written by Sergio M
Updated over 2 weeks ago

What is cURL?

cURL is a command-line tool that lets you transfer data to/from a server using various protocols. In this case, the curl command will establish a communication to POST or GET data to/from Ubidots' server over HTTP and HTTPS.

Below you will find the step-by-step guide to installing cURL in Windows, MacOSX and Linux.

cURL and Ubidots

Send sensor data to Ubidots Cloud and create real-time IoT dashboards.

Requirements

1. Windows Installation 

1. Enter and access the URL https://curl.haxx.se/ to download the curl executable wizard.

2. Then, on the "Select Operating System" section, select Windows. Then, continue selecting the parameters required based on your version of Windows.

3. Once you've finished the on-screen steps, download the ZIP file generated. To download it, simply press "Download".

4. Next, open the .zip file and enter to the folder called "src". Inside the src folder you will find the curl executable file. At this point, you need to copy the executable file and paste it inside a local folder on your PC to be able to run the curl. 

NOTE: To get a better understanding of the following steps, let's assume the executable file is located inside a folder named "programs". 

6. From the Command Prompt, enter to the location where the executable file was pasted. To enter to the folder you need to use the cd command following the location of the folder which contains the executable file as you can see below. 

cd programs

Expected location to be shown

C:\Users\{your_user}\programs>

7. To verify if you are able to run curl commands with the command prompt, test its functionality by executing the command below:

curl --help 

At this point, you should receive all the help info related to the curl command. 

Troubleshooting: If you experience errors in the downloading process, please refer to this video for additional troubleshooting.

Now you are able to use cURL from your Windows PC!

2. MacOSX Installation

1. Access the computer's terminal.

2. Run the command below in the terminal:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null

3. If a password is required after running the command, please enter your Mac's user password to continue. Then, wait until the installation finishes.

4. Run the command below in the terminal:

brew install curl


Now you are able to use cURL from your Mac PC!

3. Linux installation 

1. Access the computer's terminal.

2. Run the command below in the terminal:

sudo apt-get install curl

3. If a password is required after running the command, please enter your computers' user password to continue. Then, wait until the installation finishes.

Now you are able to use cURL from your Linux PC!

cURL and Ubidots

Send sensor data to Ubidots Cloud and create real-time IoT dashboards.

Did this answer your question?