Skip to main content
API & Developer Testing Tools

cURL Generator

Generate a valid, copyable cURL command from a method, URL, query parameters, headers, body, and optional basic auth.

Fill in the method, URL, headers, query parameters, and body below to generate a valid, ready-to-run cURL command.

The generated command runs entirely on your own machine when you paste it into a terminal - nothing is sent from this page.

What Is a cURL Generator?

cURL is a widely used command-line tool for making HTTP requests. Its flag syntax (-X, -H, -d, and so on) is powerful but easy to get wrong by hand, especially with quoting. This generator builds a correctly escaped cURL command from a simple form.

Why Use This Tool?

Useful for documentation, support tickets, sharing a reproducible request with a teammate, or quickly testing an endpoint from a terminal without recalling exact cURL flag syntax.

How to Use the cURL Generator

  1. Choose a method and enter the URL.
  2. Add query parameters and headers as needed.
  3. Enter a request body for methods that support one.
  4. Optionally add a basic auth username and password.
  5. Copy the generated command and paste it into your terminal.

Example

Method GET, URL https://api.example.com/status, header Accept: application/json generates:

curl -X GET "https://api.example.com/status" \
  -H "Accept: application/json"

Related

Already have a cURL command and need it in a specific programming language instead? Use the cURL to Code Converter.

Share this tool: