Skip to content
ZeroServer.tools

Postman to cURL

Paste a Postman request JSON export and get the equivalent cURL command.

About Postman to cURL

Converts a Postman request JSON export into a ready-to-run curl command. Paste the JSON from a Postman item (the object with a requestkey) or a bare request object, and the tool extracts the HTTP method, URL, headers, and raw body to produce the equivalent shell command — useful for sharing API calls with teammates who don't use Postman or for embedding requests in scripts and documentation.

Built and maintained by Meet Shah · Last updated

What this tool is used for

  • Turning a Postman request into a curl command for a bug report.
  • Sharing a reproducible request with someone who does not use Postman.
  • Converting a saved collection entry into a shell script.
  • Getting a curl command to run in CI from an exported request.
  • Checking exactly what Postman was sending.

Frequently Asked Questions

What can I paste in?
A single request exported from Postman as JSON. The method, URL, headers and body are read from Postman's own collection schema, so an export of one request or one item lifted out of a collection both work.
Are my auth tokens included?
Yes — whatever is in the headers you paste comes through into the command, because a curl command without the Authorization header would not reproduce the request. Everything runs in your browser, but treat the result as a secret before pasting it into a ticket.
Why convert to curl at all?
Because curl is the portable form. It runs in CI, in a container, over SSH on a server with no GUI, and it pastes into a bug report where a collection export does not. It is also the only version of a request everyone on a team can definitely run.
How are Postman variables handled?
They are not resolved — `{{baseUrl}}` is a Postman-side substitution that only its runtime knows, so it appears literally in the command. Replace those before running, or export with an environment selected so the values are already inlined.
Will the quoting survive my shell?
The output uses single quotes, which is right for bash and zsh. Windows `cmd` does not accept them: switch to double quotes, or run it in PowerShell with `curl.exe` — plain `curl` in PowerShell is an alias for `Invoke-WebRequest`, which takes entirely different arguments.
What happens to pre-request scripts?
They are lost — they are JavaScript that runs inside Postman to compute signatures, timestamps or tokens, and there is no shell equivalent. If the request depends on one, the generated command will be missing whatever it produced.

Common errors and gotchas

  • Leaving environment variables unresolved, so the curl command contains `{{placeholders}}`.
  • Exporting a collection that includes real tokens, which then travel in a shared command.
  • Losing pre-request scripts, which Postman ran and curl cannot.
  • Assuming Postman's implicit headers are in the export, when several are added at send time.
  • Converting a request whose body was a form file, which curl expresses very differently.

Related Developer Utilities tools

Private & free — this tool runs entirely in your browser.

IndieKitShip your Next.js startup in days.affiliate