blob: e247b649c606d8ab6e8f900d552fb1abb4139ce3 [file] [log] [blame]
xf.li6c8fc1e2023-08-12 00:11:09 -07001c: Copyright (C) 1998 - 2022, Daniel Stenberg, <daniel@haxx.se>, et al.
2SPDX-License-Identifier: curl
3Long: http2
4Tags: Versions
5Protocols: HTTP
6Added: 7.33.0
7Mutexed: http1.1 http1.0 http2-prior-knowledge http3
8Requires: HTTP/2
9See-also: no-alpn
10Help: Use HTTP 2
11See-also: http1.1 http3
12Category: http
13Example: --http2 $URL
14Multi: mutex
15---
16Tells curl to use HTTP version 2.
17
18For HTTPS, this means curl will attempt to negotiate HTTP/2 in the TLS
19handshake. curl does this by default.
20
21For HTTP, this means curl will attempt to upgrade the request to HTTP/2 using
22the Upgrade: request header.
23
24When curl uses HTTP/2 over HTTPS, it does not itself insist on TLS 1.2 or
25higher even though that is required by the specification. A user can add this
26version requirement with --tlsv1.2.