Import cURL commands

cURL is a popular command-line tool for making HTTP requests. When testing a web application or API, cURL enables you to interact directly from the command line, using a well-established syntax that's common in the API developer community. If you have several cURL commands in different places, you can import them into Postman.

Import a cURL command into Postman

  1. Select Import in the sidebar.

  2. Paste your cURL command into the box at the top.

    Import data into Postman
  3. Do one of the following:

    • To save your curl as a request in a collection, enter a new collection name or select an existing collection, then select Import Into Collection.
    • To open your curl as a new request without saving it, select Import Without Saving.

You can also paste cURL commands into a request's URL box.

Convert a Postman request to a cURL command

  1. Open the request you want to use for a code snippet, then select the code icon Code icon in the right sidebar.

    Open code snippets
  2. Select cURL from the dropdown list.

  3. Select the copy icon Copy icon to copy the code snippet to your clipboard.

    Copy code snippet to clipboard

If you prefer working inside the command line with cURL making basic requests, the VS code extension is for you.

Last modified: 2024/08/14