# Getting Started with cURL

cURL is an important concept in backend development, this article will explain cURL and its usage in a simpler way.

Before getting into details, let us understand servers. A server is nothing but another computer that stores data, runs programs and gives information when someone asks for it. We normally use a browser to access things from a server but devs have to generally test servers or use APIs or send requests without a browser. That is when cURL comes in the picture.

![A laptop that identifies itself as a server !](https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQBBUx8I3xzQ10T7s0QfjYRbYme8eBGMiWgMw&s align="center")

cURL or Client URL is a widely used open source command line tool that lets you send data to or from a server from the terminal. There is just raw communication taking place.

**cURL is used by programmers to :**

1. Test APIs
    
2. Check if the server is working
    
3. Debug
    
4. Transfer data
    

**Making a request to fetch a webpage:**

We will type `curl` [`http://example.com`](http://example.com) in our terminal and press enter.  
cURL has sent a request to example.com and will now print the raw response sent by the server in HTML. cURL will not make the response look pretty, it will print what the server has sent.

**Understanding request and response :**

Every server communication is divided into two parts: request and response.

Request would be when we are sending the URL to the server (GET or POST) and response is what the server replies with (HTML, JSON, text, etc.).

Both browser and cURL make HTTP requests to a server, the difference lies in their purpose and subsequent actions. A browser is an application designed to fetch, interpret, render and display an interactive webpage for the user but a cURL request only fetches a specific data source and displays the raw data.

**Where cURL fits in backend development :**

See, primarily cURL is used to transfer data to and from a server. It also used essentially for API testing, debugging network, authentication, etc.

This article gives a basic overview of what cURL is, there is no hurry to master it on the first try!
