curl [options] URLArguments explained
- URL is the target address.
- -I fetches headers only.
- -L follows redirects.
- -o writes output to a file.
- -X chooses an HTTP method.
- -H adds a header.
Common examples
curl -I https://example.comShows HTTP response headers without the body.
curl -L -o file.tar.gz https://example.com/file.tar.gzFollows redirects and saves to a chosen filename.
| Field | Details |
|---|---|
| Command | curl |
| Category | Networking |
| Primary use | Transfers data with URLs. |
| Syntax | curl [options] URL |