cURL vs HTTPie: Interacting with HTTP servers

Published on 2020-05-21

For testing and debugging while developing RESTful APIs or HTTP servers or even playing around with APIs, cURL used to be my default tool of choice. However, my life literally changed once I found out about HTTPie. HTTPie is a command line HTTP client written in python that allows for sending arbitrary HTTP requests using a simple and natural syntax, and displays colorized output.

Let’s make some GET and POST requests using curl and httpie and see the difference in request syntax as well as responses.

GET Request

POST Request


Installing HTTPie is pretty simple using pip.

pip install httpie

I really like HTTPie due to its expressive and intuitive syntax, formatted and colorized terminal output and built-in JSON support. I recommend you try it as well.