curl to Code help
Paste a curl command and get the equivalent request in the language you want.
Steps
- Paste a
curlcommand. Line breaks with\and single, double, and$'…'quoting are understood. - Pick an output:
fetch(), HTTPie, or PowerShell. - Copy the result.
Flags it reads
-X/--request, -H/--header, -d and its variants, -G, -u (becomes a Basic auth header), -A, -e, -b. The --flag=value form works. Options like -L, -s, -k, --compressed are ignored; -F is noted but not fully translated.
Notes
- The method defaults to GET, or POST when a body is present.
- A default
Content-Typeofapplication/x-www-form-urlencodedis added when there is a body and none was set. - Nothing is uploaded.
Everything runs in your browser. Nothing you enter or drop is uploaded.
Back to curl to Code