cURL Beautifier

Paste a long or minified cURL command and get a readable version with the URL on the first line and one option per line, joined with backslash continuations. Headers, JSON bodies, and quoting are preserved exactly, so the beautified command means the same as the one you pasted. Minify does the reverse, collapsing a multi-line command to a single line. Everything runs in your browser.

Input
Output
Formatted output will appear here
Ready. Press Format or Minify.

How to use the cURL Beautifier

  1. Paste a cURL command into the input pane.
  2. Press Format for one option per line, or Minify for a single line.
  3. Copy the result or download it as a .sh file.

Example

A POST with two headers and a JSON body, already split across lines.

curl -X POST https://api.example.com/v1/users \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer token123" \
  -d '{"name": "Ada", "age": 36}'

Frequently asked questions

Does it run the request?

No. It only reformats the command text. Use the API Client to send a request, or cURL to Fetch to turn it into code.

Will my headers and JSON body survive formatting?

Yes. Quoting is preserved exactly, including single-quoted JSON bodies and double-quoted header values with colons and spaces.

What happens to --url?

A --url value is moved to the first line after curl, since that is where the URL belongs in the formatted output. The command means the same thing.