How to use cURL to Fetch/Axios

  1. Paste a cURL command (e.g. from browser DevTools or docs).
  2. Click Convert to get JavaScript fetch() and axios code.
  3. Copy the snippet into your project.

Example

Input

Your input or data here

Output

Result will appear here after running the tool

Frequently asked questions

What cURL options are supported?
We support -X/--request, -H/--header, -d/--data/--data-raw and the URL. Other flags are ignored.
Can I convert fetch or axios back to cURL?
Use the HTTP Request Builder: enter method, URL, headers, and body in the structured format to get cURL and code.