Overview
Introduction
You've got a curl command from a README, a bug report, or your shell history, and you want to load it into Postman without manually re-typing the method, headers, and body into the request builder.
This tool parses the curl command and generates the equivalent Postman request-item JSON entirely in your browser, ready to paste into Postman's "import" or build into a collection.
What Is cURL to Postman JSON Converter?
A focused converter that reads a curl command's method, URL, headers, and body, and re-emits them as a Postman request-item JSON object.
It's part of this site's API Tools collection and runs entirely client-side. It's the reverse of the Postman JSON to cURL Converter, which does the same conversion in the other direction.
How cURL to Postman JSON Converter Works
The curl command is tokenized the same way a shell would (respecting quotes and backslash-newline continuations) and its flags are parsed with the same parser the cURL to Code Converter uses, rather than a second, separately maintained curl parser.
The parsed method, URL, headers, and data are assembled into a Postman request-item object: headers become the { key, value } array Postman's schema expects, and any -d/--data value becomes a "raw"-mode body, all pretty-printed as JSON.
When To Use cURL to Postman JSON Converter
Use it when you have a curl command (from documentation, a colleague, or your own terminal history) and want it as a Postman request without re-entering every header and the body by hand.
It's also useful for building up a Postman collection programmatically from a set of curl commands, since each converted request-item JSON can be dropped straight into a collection's "item" array.
Often used alongside Postman JSON to cURL, Postman Collection Generator and cURL to Code Converter.
Features
Advantages
- Reuses the same battle-tested curl flag parser as the cURL to Code Converter instead of a second, independently-maintained one, so both tools stay in sync on which flags are recognized.
- Produces output in the exact shape the Postman JSON to cURL Converter reads back, so a curl command converted here and fed through that tool reproduces an equivalent command.
- Converts a -u/--user flag into a proper base64 Basic Authorization header, matching what curl actually sends.
Limitations
- Only produces a "raw"-mode body; curl commands using multiple -d flags are joined into one raw string rather than split into a "urlencoded" key/value array.
- Doesn't support curl's multipart form flags (-F/--form), since those don't reduce to a single raw or urlencoded Postman body.
- The generated "name" field is derived from the method and URL path as a readable label; rename it in Postman if you want something more descriptive.
Examples
Best Practices & Notes
Best Practices
- Copy curl commands using a browser's "Copy as cURL" option when possible, since that consistently quotes headers and bodies in a way this tool's tokenizer expects.
- Review the generated "name" field and rename it in Postman to something more descriptive than the auto-derived method-and-path label.
- If the original command used -u for auth, verify the generated Authorization header, since Postman's own auth tab won't automatically recognize a raw header the way it recognizes its own auth configuration.
Developer Notes
Tokenization and flag parsing (tokenizeCurlCommand / parseCurlTokens) are imported directly from the cURL to Code Converter's lib module rather than reimplemented here, so the set of recognized curl flags can't drift between the two tools. The output intentionally mirrors the bare request-object fields (method, url, header, body) that the Postman JSON to cURL Converter's own parser reads, rather than a fuller Postman schema (auth block, description, protocolProfileBehavior, etc.), keeping the two converters symmetric.
cURL to Postman JSON Converter Use Cases
- Turning a curl command from documentation or a bug report into a Postman request without retyping it
- Building a Postman collection's "item" array from a batch of existing curl commands
- Round-tripping a request between curl and Postman JSON for testing or documentation purposes
Common Mistakes
- Expecting form-data (-F) uploads to convert; only -d/--data-based bodies are supported, since multipart bodies don't map onto this tool's single raw-body output.
- Pasting a curl command with unbalanced quotes; the tokenizer expects the same quoting a shell would, so an unmatched quote will produce an incorrect parse rather than an error.
Tips
- If your curl command spans multiple lines with trailing backslashes, paste it as-is; the tokenizer collapses backslash-newline continuations before parsing.
- Use the cURL to Code Converter first if you actually want runnable code in a specific language rather than a Postman JSON object.