curl -I https://www.baidu.com
SOCKS5 Proxy Requests
# With proxy and user/pass, the following two commands are equivalent:
curl -x "socks5://user:pass@localhost:1080" http://remote-site.com
curl --socks5 "user:pass@localhost:1080" http://remote-site.com
Basic GET Request
Download a File
curl -O https://example.com/file.zip
Send POST Request with Data
curl -X POST -d "param1=value1¶m2=value2" https://example.com/api
Follow Redirects
curl -L https://example.com
Save Output to a File
curl https://example.com -o output.html
References