# cURL to PHP

Convert curl to PHP (ext-curl). Client-side and secret-safe, with guides for HTTP methods, content types and auth schemes.

Paste a curl command and get idiomatic PHP. Parsing and code generation happen entirely in your browser.

## Guides

- [Convert a cURL GET request to PHP](https://toolpaper.manavdev.site/how-to/curl-get-in-php.md): Convert a curl GET command to PHP (ext-curl). Paste your command, get idiomatic code — headers, body, auth, and cookies handled.
- [Convert a cURL POST request to PHP](https://toolpaper.manavdev.site/how-to/curl-post-in-php.md): Convert a curl POST command to PHP (ext-curl). Paste your command, get idiomatic code — headers, body, auth, and cookies handled.
- [Convert a cURL PUT request to PHP](https://toolpaper.manavdev.site/how-to/curl-put-in-php.md): Convert a curl PUT command to PHP (ext-curl). Paste your command, get idiomatic code — headers, body, auth, and cookies handled.
- [Convert a cURL PATCH request to PHP](https://toolpaper.manavdev.site/how-to/curl-patch-in-php.md): Convert a curl PATCH command to PHP (ext-curl). Paste your command, get idiomatic code — headers, body, auth, and cookies handled.
- [Convert a cURL DELETE request to PHP](https://toolpaper.manavdev.site/how-to/curl-delete-in-php.md): Convert a curl DELETE command to PHP (ext-curl). Paste your command, get idiomatic code — headers, body, auth, and cookies handled.
- [Send JSON with cURL in PHP](https://toolpaper.manavdev.site/how-to/send-json-with-curl-in-php.md): Convert a curl command that sends JSON into PHP (ext-curl). Body serialization, Content-Type, and encoding handled correctly.
- [Send form-urlencoded with cURL in PHP](https://toolpaper.manavdev.site/how-to/send-form-with-curl-in-php.md): Convert a curl command that sends form-urlencoded into PHP (ext-curl). Body serialization, Content-Type, and encoding handled correctly.
- [Send multipart form-data with cURL in PHP](https://toolpaper.manavdev.site/how-to/send-multipart-with-curl-in-php.md): Convert a curl command that sends multipart form-data into PHP (ext-curl). Body serialization, Content-Type, and encoding handled correctly.
- [Send XML with cURL in PHP](https://toolpaper.manavdev.site/how-to/send-xml-with-curl-in-php.md): Convert a curl command that sends XML into PHP (ext-curl). Body serialization, Content-Type, and encoding handled correctly.
- [Send GraphQL with cURL in PHP](https://toolpaper.manavdev.site/how-to/send-graphql-with-curl-in-php.md): Convert a curl command that sends GraphQL into PHP (ext-curl). Body serialization, Content-Type, and encoding handled correctly.
- [cURL with Bearer token in PHP](https://toolpaper.manavdev.site/how-to/curl-bearer-auth-in-php.md): Convert a curl command using Bearer token to PHP (ext-curl). Credentials pass through cleanly and can be redacted before you share.
- [cURL with Basic auth in PHP](https://toolpaper.manavdev.site/how-to/curl-basic-auth-in-php.md): Convert a curl command using Basic auth to PHP (ext-curl). Credentials pass through cleanly and can be redacted before you share.
- [cURL with API key in PHP](https://toolpaper.manavdev.site/how-to/curl-api-key-auth-in-php.md): Convert a curl command using API key to PHP (ext-curl). Credentials pass through cleanly and can be redacted before you share.
- [Convert cURL to Laravel](https://toolpaper.manavdev.site/how-to/curl-in-laravel.md): Convert curl commands into Laravel (PHP / ext-curl). Guzzle-based HTTP client wrapped by Laravel's Http facade.

---

Source: https://toolpaper.manavdev.site/curl-to-php · Converter: https://toolpaper.manavdev.site/curl-converter