cURL Command Builder
Fill in a method, URL, headers, body and auth, and get a correct, copy-pasteable curl command.
About this tool
Everything runs in your browser and nothing is sent anywhere; the command is assembled as text for you to copy. Quoting is done correctly for the shell you choose, so values containing quotes, spaces or $ arrive at the server exactly as typed: single quotes for bash and zsh (an embedded ' becomes '"'"'), double quotes with \" for Windows Command Prompt, and doubled single quotes for PowerShell. In Command Prompt, text such as %PATH% is still expanded as a variable, and inside a batch file every % must be written as %%. Long commands are split over several lines with each shell's own continuation character (\, ^ or a backtick).
The body is sent with --data-raw, so a body starting with @ is sent as typed rather than read from a file, and it only applies to POST, PUT, PATCH and DELETE. -X is added only when needed, since curl already uses GET by default and POST when there's a body. On Windows the command uses curl.exe, because in Windows PowerShell 5 plain curl runs a different command.