The table describes the options and the type of info expected for each option.
option argument to curl-easy-setopt.
curl_easy_setopt.
info argument to curl-easy-setopt. These may differ
from those in the manual page for C library function
curl_easy_setopt. See Option Data Types, for more about
these types.
| Option Symbol | C Library Name | Info Type |
|---|---|---|
| BEHAVIOR OPTIONS | ||
| verbose | CURLOPT_VERBOSE | boolean |
| header | CURLOPT_HEADER | boolean |
| nosignal | CURLOPT_NOSIGNAL | boolean |
| wildcardmatch | CURLOPT_WILDCARDMATCH | boolean |
| CALLBACK OPTIONS | ||
| readdata | CURLOPT_READDATA | input port |
| NETWORK OPTIONS | ||
| url | CURLOPT_URL | string |
| path-as-is | CURLOPT_PATH_AS_IS | boolean |
| protocols | CURLOPT_PROTOCOLS | integer4 |
| redir-protocols | CURLOPT_REDIR_PROTOCOLS | integer5 |
| default-protocol | CURLOPT_DEFAULT_PROTOCOL | string |
| proxy | CURLOPT_PROXY | string |
| pre-proxy | CURLOPT_PRE_PROXY | string |
| proxyport | CURLOPT_PROXYPORT | integer |
| proxytype | CURLOPT_PROXYTYPE | integer6 |
| noproxy | CURLOPT_NOPROXY | string |
| httpproxytunnel | CURLOPT_HTTPPROXYTUNNEL | boolean |
| connect-to | CURLOPT_CONNECT_TO | slist |
| socks5-auth | CURLOPT_SOCKS5_AUTH | integer7 |
| socks5-gssapi-service | CURLOPT_SOCKS5_GSSAPI_SERVICE | string |
| socks5-gssapi-nec | CURLOPT_SOCKS5_GSSAPI_NEC | boolean |
| proxy-service-name | CURLOPT_PROXY_SERVICE_NAME | string |
| haproxyprotocol | CURLOPT_HAPROXYPROTOCOL | integer (1 or 0) |
| service-name | CURLOPT_SERVICE_NAME | string |
| interface | CURLOPT_INTERFACE | string |
| localport | CURLOPT_LOCALPORT | integer |
| localportrange | CURLOPT_LOCALPORTRANGE | integer |
| dns-cache-timeout | CURLOPT_DNS_CACHE_TIMEOUT | integer |
| doh-url | CURLOPT_DOH_URL | string |
| buffersize | CURLOPT_BUFFERSIZE | integer |
| port | CURLOPT_PORT | integer |
| tcp-fastopen | CURLOPT_TCP_FASTOPEN | boolean |
| tcp-nodelay | CURLOPT_TCP_NODELAY | boolean |
| address-scope | CURLOPT_ADDRESS_SCOPE | integer |
| tcp-keepalive | CURLOPT_TCP_KEEPALIVE | boolean |
| tcp-keepidle | CURLOPT_TCP_KEEPIDLE | integer |
| tcp-keepintvl | CURLOPT_TCP_KEEPINTVL | integer |
| unix-socket-path | CURLOPT_UNIX_SOCKET_PATH | string |
| abstract-unix-socket | CURLOPT_ABSTRACT_UNIX_SOCKET | string |
| NAMES AND PASSWORD OPTIONS | ||
| netrc | CURLOPT_NETRC | integer8 |
| netrc-file | CURLOPT_NETRC_FILE | string |
| userpwd | CURLOPT_USERPWD | string |
| proxyuserpwd | CURLOPT_PROXYUSERPWD | string |
| username | CURLOPT_USERNAME | string |
| password | CURLOPT_PASSWORD | string |
| login-options | CURLOPT_LOGIN_OPTIONS | string |
| proxyusername | CURLOPT_PROXYUSERNAME | string |
| proxypassword | CURLOPT_PROXYPASSWORD | string |
| httpauth | CURLOPT_HTTPAUTH | integer9 |
| tlsauth-username | CURLOPT_TLSAUTH_USERNAME | string |
| tlsauth-type | CURLOPT_TLSAUTH_TYPE | string |
| proxy-tlsauth-username | CURLOPT_PROXY_TLSAUTH_USERNAME | string |
| tlsauth-password | CURLOPT_TLSAUTH_PASSWORD | string |
| proxy-tlsauth-password | CURLOPT_PROXY_TLSAUTH_PASSWORD | string |
| tlsauth-type | CURLOPT_TLSAUTH_TYPE | string |
| proxy-tlsauth-type | CURLOPT_PROXY_TLSAUTH_TYPE | string |
| proxyauth | CURLOPT_PROXYAUTH | integer10 |
| sasl-ir | CURLOPT_SASL_IR | boolean |
| xoauth2-bearer | CURLOPT_XOAUTH2_BEARER | string |
| disallow-username-in-url | CURLOPT_DISALLOW_USERNAME_IN_URL | boolean |
| HTTP OPTIONS | ||
| autoreferer | CURLOPT_AUTOREFERER | boolean |
| accept-encoding | CURLOPT_ACCEPT_ENCODING | string |
| transfer-encoding | CURLOPT_TRANSFER_ENCODING | string |
| followlocation | CURLOPT_FOLLOWLOCATION | boolean |
| unrestricted-auth | CURLOPT_UNRESTRICTED_AUTH | boolean |
| maxredirs | CURLOPT_MAXREDIRS | integer |
| postredir | CURLOPT_POSTREDIR | integer11 |
| put | CURLOPT_PUT | boolean |
| post | CURLOPT_POST | boolean |
| postfields12 | CURLOPT_POSTFIELDS | bytevector |
| postfieldsize | CURLOPT_POSTFIELDSIZE | integer |
| postfieldsize-large | CURLOPT_POSTFIELDSIZE_LARGE | biginteger |
| copypostfields13 | CURLOPT_COPYPOSTFIELDS | bytevector |
| mimepost | CURLOPT_MIMEPOST | mimepost |
| httppost | CURLOPT_MIMEPOST | mimepost14 |
| referer | CURLOPT_REFERER | string |
| useragent | CURLOPT_USERAGENT | string |
| httpheader | CURLOPT_HTTPHEADER | slist15 |
| headeropt | CURLOPT_HEADEROPT | integer |
| proxyheader | CURLOPT_PROXYHEADER | slist |
| http200aliases | CURLOPT_HTTP200ALIASES | slist |
| cookie | CURLOPT_COOKIE | string |
| cookiefile | CURLOPT_COOKIEFILE | string |
| cookiejar | CURLOPT_COOKIEJAR | string |
| cookiesession | CURLOPT_COOKIESESSION | boolean |
| cookielist | CURLOPT_COOKIELIST | string |
| httpget | CURLOPT_HTTPGET | boolean |
| request-target | CURLOPT_REQUEST_TARGET | string |
| http-version | CURLOPT_HTTP_VERSION | integer16 |
| http09-allowed | CURLOPT_HTTP09_ALLOWED | boolean |
| ignore-content-length | CURLOPT_IGNORE_CONTENT_LENGTH | boolean |
| http-content-decoding | CURLOPT_HTTP_CONTENT_DECODING | boolean |
| http-transfer-decoding | CURLOPT_HTTP_TRANSFER_DECODING | boolean |
| expect-100-timeout-ms | CURLOPT_EXPECT_100_TIMEOUT_MS | integer |
| pipewait | CURLOPT_PIPEWAIT | boolean |
| stream-wait | CURLOPT_STREAM_WEIGHT | integer |
| SMTP OPTIONS | ||
| mail-from | CURLOPT_MAIL_FROM | string |
| mail-rcpt | CURLOPT_MAIL_RCPT | slist |
| mail-auth | CURLOPT_MAIL_AUTH | string |
| TFTP OPTIONS | ||
| tftp-blksize | CURLOPT_TFTP_BLKSIZE | integer |
| tftp-no-options | CURLOPT_TFTP_NO_OPTIONS | boolean |
| FTP OPTIONS | ||
| ftpport | CURLOPT_FTPPORT | string |
| quote | CURLOPT_QUOTE | slist |
| postquote | CURLOPT_POSTQUOTE | slist |
| prequote | CURLOPT_PREQUOTE | slist |
| dirlistonly | CURLOPT_DIRLISTONLY | boolean |
| append | CURLOPT_APPEND | boolean |
| ftp-use-eprt | CURLOPT_FTP_USE_EPRT | boolean |
| ftp-use-epsv | CURLOPT_FTP_USE_EPSV | boolean |
| ftp-use-pret | CURLOPT_FTP_USE_PRET | boolean |
| ftp-create-missing-dirs | CURLOPT_FTP_CREATE_MISSING_DIRS | boolean |
| ftp-response-timeout | CURLOPT_FTP_RESPONSE_TIMEOUT | integer |
| ftp-alternative-to-user | CURLOPT_FTP_ALTERNATIVE_TO_USER | string |
| ftp-skip-pasv-ip | CURLOPT_FTP_SKIP_PASV_IP | boolean |
| ftpsslauth | CURLOPT_FTPSSLAUTH | integer17 |
| ftp-ssl-ccc | CURLOPT_FTP_SSL_CCC | integer18 |
| ftp-account | CURLOPT_FTP_ACCOUNT | string |
| ftp-filemethod | CURLOPT_FTP_FILEMETHOD | integer19 |
| RTSP OPTIONS | ||
| rtsp-request | CURLOPT_RTSP_REQUEST | integer20 |
| rtsp-session-id | CURLOPT_RTSP_SESSION_ID | string |
| rtsp-stream-uri | CURLOPT_RTSP_STREAM_URI | string |
| rtsp-transport | CURLOPT_RTSP_TRANSPORT | string |
| rtsp-client-cseq | CURLOPT_RTSP_CLIENT_CSEQ | integer |
| rtsp-server-cseq | CURLOPT_RTSP_SERVER_CSEQ | integer |
| PROTOCOL OPTIONS | ||
| transfertext | CURLOPT_TRANSFERTEXT | boolean |
| proxy-transfer-mode | CURLOPT_PROXY_TRANSFER_MODE | boolean |
| crlf | CURLOPT_CRLF | boolean |
| range | CURLOPT_RANGE | string |
| resume-from | CURLOPT_RESUME_FROM | integer |
| resume-from-large | CURLOPT_RESUME_FROM_LARGE | biginteger |
| customrequest | CURLOPT_CUSTOMREQUEST | string |
| filetime | CURLOPT_FILETIME | boolean |
| nobody | CURLOPT_NOBODY | boolean |
| infilesize | CURLOPT_INFILESIZE | integer |
| infilesize-large | CURLOPT_INFILESIZE_LARGE | biginteger |
| upload | CURLOPT_UPLOAD | boolean |
| upload-buffersize | CURLOPT_UPLOAD_BUFFERSIZE | integer |
| maxfilesize | CURLOPT_MAXFILESIZE | integer |
| maxfilesize-large | CURLOPT_MAXFILESIZE_LARGE | biginteger |
| timecondition | CURLOPT_TIMECONDITION | integer |
| timevalue | CURLOPT_TIMEVALUE | integer |
| timevalue-large | CURLOPT_TIMEVALUE_LARGE | biginteger |
| CONNECTION OPTIONS | ||
| timeout | CURLOPT_TIMEOUT | integer |
| timeout-ms | CURLOPT_TIMEOUT_MS | integer |
| low-speed-limit | CURLOPT_LOW_SPEED_LIMIT | integer |
| low-speed-time | CURLOPT_LOW_SPEED_TIME | integer |
| max-send-speed-large | CURLOPT_MAX_SEND_SPEED_LARGE | biginteger |
| max-recv-speed-large | CURLOPT_MAX_RECV_SPEED_LARGE | biginteger |
| maxconnects | CURLOPT_MAXCONNECTS | integer |
| fresh-connect | CURLOPT_FRESH_CONNECT | boolean |
| forbid-reuse | CURLOPT_FORBID_REUSE | boolean |
| connecttimeout | CURLOPT_CONNECTTIMEOUT | integer |
| connecttimeout-ms | CURLOPT_CONNECTTIMEOUT_MS | integer |
| ipresolve | CURLOPT_IPRESOLVE | integer21 |
| connect-only | CURLOPT_CONNECT_ONLY | boolean |
| use-ssl | CURLOPT_USE_SSL | integer22 |
| resolve | CURLOPT_RESOLVE | slist |
| dns-interface | CURLOPT_DNS_INTERFACE | string |
| dns-local-ip4 | CURLOPT_DNS_LOCAL_IP4 | string |
| dns-local-ip6 | CURLOPT_DNS_LOCAL_IP6 | string |
| dns-servers | CURLOPT_DNS_SERVERS | string |
| dns-shuffle-addresses | CURLOPT_DNS_SHUFFLE_ADDRESSES | boolean |
| accepttimeout-ms | CURLOPT_ACCEPTTIMEOUT_MS | integer |
| happy-eyeballs-timeout-ms | CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS | integer |
| upkeep-interval-ms | CURLOPT_UPKEEP_INTERVAL_MS | integer) |
| SSL AND SECURITY OPTIONS | ||
| sslcert | CURLOPT_SSLCERT | string |
| proxy-sslcert | CURLOPT_PROXY_SSLCERT | string |
| sslcerttype | CURLOPT_SSLCERTTYPE | string |
| proxy-sslcerttype | CURLOPT_PROXY_SSLCERTTYPE | string |
| sslkey | CURLOPT_SSLKEY | string |
| proxy-sslkey | CURLOPT_PROXY_SSLKEY | string |
| sslkeytype | CURLOPT_SSLKEYTYPE | string |
| proxy-sslkeytype | CURLOPT_PROXY_SSLKEYTYPE | string |
| keypasswd | CURLOPT_KEYPASSWD | string |
| proxy-keypasswd | CURLOPT_PROXY_KEYPASSWD | string |
| ssl-enable-alpn | CURLOPT_SSL_ENABLE_ALPN | boolean |
| ssl-enable-npn | CURLOPT_SSL_ENABLE_NPN | boolean23 |
| sslengine | CURLOPT_SSLENGINE | string |
| sslengine-default | CURLOPT_SSLENGINE_DEFAULT | boolean |
| ssl-falsestart | CURLOPT_SSL_FALSESTART | boolean |
| sslversion | CURLOPT_SSLVERSION | integer24 |
| proxy-sslversion | CURLOPT_PROXY_SSLVERSION | integer25 |
| ssl-verifyhost | CURLOPT_SSL_VERIFYHOST | boolean |
| proxy-ssl-verifyhost | CURLOPT_PROXY_SSL_VERIFYHOST | boolean |
| ssl-verifypeer | CURLOPT_SSL_VERIFYPEER | boolean |
| proxy-ssl-verifypeer | CURLOPT_PROXY_SSL_VERIFYPEER | boolean |
| cainfo | CURLOPT_CAINFO | string |
| proxy-cainfo | CURLOPT_PROXY_CAINFO | string |
| issuercert | CURLOPT_ISSUERCERT | string |
| capath | CURLOPT_CAPATH | string |
| proxy-capath | CURLOPT_PROXY_CAPATH | string |
| crlfile | CURLOPT_CRLFILE | string |
| ssl-verifyhost | CURLOPT_SSL_VERIFYHOST | integer |
| certinfo | CURLOPT_CERTINFO | boolean |
| random-file | CURLOPT_RANDOM_FILE | string |
| egdsocket | CURLOPT_EGDSOCKET | string |
| ssl-cipher-list | CURLOPT_SSL_CIPHER_LIST | string |
| ssl-sessionid-cache | CURLOPT_SSL_SESSIONID_CACHE | boolean |
| krblevel | CURLOPT_KRBLEVEL | string |
| gssapi-delegation | CURLOPT_GSSAPI_DELEGATION | integer26 |
| SSH OPTIONS | ||
| ssh-auth-types | CURLOPT_SSH_AUTH_TYPES | integer27 |
| ssh-host-public-key-md5 | CURLOPT_SSH_HOST_PUBLIC_KEY_MD5 | string |
| ssh-public-keyfile | CURLOPT_SSH_PUBLIC_KEYFILE | string |
| ssh-private-keyfile | CURLOPT_SSH_PRIVATE_KEYFILE | string |
| ssh-known-hosts | CURLOPT_SSH_KNOWNHOSTS | string |
| new-file-perms | CURLOPT_NEW_FILE_PERMS | integer |
| new-directory-perms | CURLOPT_NEW_DIRECTORY_PERMS | integer |
| telnetoptions | CURLOPT_TELNETOPTIONS | slist |
| MORE OPTIONS | ||
| failonerror | CURLOPT_FAILONERROR | boolean |
| keep-sending-on-error | CURLOPT_KEEP_SENDING_ON_ERROR | boolean |
| suppress-connect-headers | CURLOPT_SUPPRESS_CONNECT_HEADERS | boolean |
| ssl-verifystatus | CURLOPT_SSL_VERIFYSTATUS | boolean |
| ssh-compression | CURLOPT_SSH_COMPRESSION | boolean |
| doh-ssl-verifypeer | CURLOPT_DOH_SSL_VERIFYPEER | boolean |
| doh-ssl-verifystatus | CURLOPT_DOH_SSL_VERIFYSTATUS | boolean |
| doh-ssl-verifyhost | CURLOPT_DOH_SSL_VERIFYHOST | integer |
| quick-exit | CURLOPT_QUICK_EXIT | boolean (libcurl 7.87.0) |
| mail-rcpt-allowfails | CURLOPT_MAIL_RCPT_ALLOWFAILS | boolean (libcurl 8.2.0) |
| ssl-options | CURLOPT_SSL_OPTIONS | integer28 |
| proxy-ssl-options | CURLOPT_PROXY_SSL_OPTIONS | integer29 |
| altsvc-ctrl | CURLOPT_ALTSVC_CTRL | integer30 |
| hsts-ctrl | CURLOPT_HSTS_CTRL | integer31 |
| maxage-conn | CURLOPT_MAXAGE_CONN | integer |
| maxlifetime-conn | CURLOPT_MAXLIFETIME_CONN | integer (libcurl 7.80.0) |
| mime-options | CURLOPT_MIME_OPTIONS | integer (libcurl 7.81.0)32 |
| ca-cache-timeout | CURLOPT_CA_CACHE_TIMEOUT | integer (libcurl 7.87.0) |
| ws-options | CURLOPT_WS_OPTIONS | integer (libcurl 7.86.0)33 |
| server-response-timeout | CURLOPT_SERVER_RESPONSE_TIMEOUT | integer |
| server-response-timeout-ms | CURLOPT_SERVER_RESPONSE_TIMEOUT_MS | integer (libcurl 8.6.0) |
| tcp-keepcnt | CURLOPT_TCP_KEEPCNT | integer (libcurl 8.9.0) |
| upload-flags | CURLOPT_UPLOAD_FLAGS | integer (libcurl 8.13.0)34 |
| altsvc | CURLOPT_ALTSVC | string |
| aws-sigv4 | CURLOPT_AWS_SIGV4 | string |
| ech | CURLOPT_ECH | string (libcurl 8.8.0) |
| haproxy-client-ip | CURLOPT_HAPROXY_CLIENT_IP | string (libcurl 8.2.0) |
| hsts | CURLOPT_HSTS | string |
| pinnedpublickey | CURLOPT_PINNEDPUBLICKEY | string |
| proxy-pinnedpublickey | CURLOPT_PROXY_PINNEDPUBLICKEY | string |
| protocols-str | CURLOPT_PROTOCOLS_STR | string (libcurl 7.85.0) |
| redir-protocols-str | CURLOPT_REDIR_PROTOCOLS_STR | string (libcurl 7.85.0) |
| proxy-crlfile | CURLOPT_PROXY_CRLFILE | string |
| proxy-issuercert | CURLOPT_PROXY_ISSUERCERT | string |
| proxy-ssl-cipher-list | CURLOPT_PROXY_SSL_CIPHER_LIST | string |
| proxy-tls13-ciphers | CURLOPT_PROXY_TLS13_CIPHERS | string |
| tls13-ciphers | CURLOPT_TLS13_CIPHERS | string |
| sasl-authzid | CURLOPT_SASL_AUTHZID | string |
| ssh-host-public-key-sha256 | CURLOPT_SSH_HOST_PUBLIC_KEY_SHA256 | string (libcurl 7.80.0) |
| ssl-ec-curves | CURLOPT_SSL_EC_CURVES | string |
| ssl-signature-algorithms | CURLOPT_SSL_SIGNATURE_ALGORITHMS | string (libcurl 8.14.0) |
| rtspheader | CURLOPT_RTSPHEADER | slist |
| cainfo-blob | CURLOPT_CAINFO_BLOB | blob (libcurl 7.77.0) |
| proxy-cainfo-blob | CURLOPT_PROXY_CAINFO_BLOB | blob (libcurl 7.77.0) |
| issuercert-blob | CURLOPT_ISSUERCERT_BLOB | blob |
| proxy-issuercert-blob | CURLOPT_PROXY_ISSUERCERT_BLOB | blob |
| sslcert-blob | CURLOPT_SSLCERT_BLOB | blob |
| proxy-sslcert-blob | CURLOPT_PROXY_SSLCERT_BLOB | blob |
| sslkey-blob | CURLOPT_SSLKEY_BLOB | blob |
| proxy-sslkey-blob | CURLOPT_PROXY_SSLKEY_BLOB | blob |
Options marked with a libcurl version need that version or later. With an
older libcurl, setting them raises an error saying that the option is not
supported by this version of libcurl. The integer options take the
corresponding CURLSSLOPT_, CURLALTSVC_, CURLHSTS_,
CURLMIMEOPT_, CURLWS_, CURLULFLAG_ and CURLAUTH_
constants, combined with logior where libcurl allows several.
See Integer Constants for protocols.
See Integer Constants for protocols.
See Integer Constants for proxytype.
See Integer Constants for socks5-auth.
See Integer Constants for netrc.
See Integer Constants for httpauth.
See Integer Constants for httpauth.
See Integer Constants for postredir.
See Postfields.
See Postfields.
Another name for mimepost, kept for programs written for versions before 1.0.0.
Pass an empty list to clear out the HTTP headers.
See Integer Constants for http-version.
See Integer Constants for ftpsslauth.
See Integer Constants for ftp-ssl-ccc.
See Integer Constants for ftp-filemethod.
See Integer Constants for rtsp-request.
See Integer Constants for ipresolve.
See Integer Constants for use-ssl.
It has no effect since libcurl 7.86.0.
See Integer Constants for sslversion.
See Integer Constants for sslversion.
See Integer Constants for gssapi-delegation.
See Integer Constants for ssh-auth-types.
See Integer Constants for ssl-options.
See Integer Constants for ssl-options.
See Integer Constants for altsvc-ctrl.
See Integer Constants for hsts-ctrl.
See Integer Constants for mime-options.
See Integer Constants for ws-options.