HTTP/2 is the latest version of HTTP. HTTP/2 can secure and accelerate content delivery. This topic describes what HTTP/2 is, the benefits of HTTP/2, and how to enable HTTP/2.
- If this is the first time you configure an SSL certificate, you must wait until the certificate takes effect before you can enable HTTP/2.
- If you disable the SSL certificate after you enable HTTP/2, HTTP/2 is automatically disabled.
HTTP/2, originally named HTTP/2.0, is the latest version of HTTP. Compared with HTTP/1.1, HTTP/2 supports more features. For example, multiplexing, header compression, request prioritization, and server push are supported. HTTP/2 provides optimized performance and is compatible with HTTP/1.1 semantics. HTTP/2 is supported by browsers such as Google Chrome, Internet Explorer 11, Safari, and Mozilla Firefox.
- Binary encoding: HTTP 1.x is used to parse data into text. However, HTTP/2 is used to split the data to be transmitted into messages and frames, and encode them into binary formats. Binary encoding makes HTTP/2 more extensible. For example, frames can be introduced to transmit data and instructions.
- Content security: HTTP/2 is designed based on HTTPS to ensure content security and network performance. If your services use only HTTPS, network performance may be degraded.
- Multiplexing: HTTP/2 supports multiplexing of multiple concurrent streams through the same connection. For example, a browser can be used to initiate a large number of requests in parallel through the same connection while the responses to these requests are returned at the same time. In addition, multiplexing supports stream dependencies. This allows a client to provide further details of prioritized streams to the server by using the same connection. This way, the delivery of important content is prioritized.
- Header compression: HTTP headers support large volumes of information. Each request and each response are transmitted along with these headers. HTTP/2 can be used to compress HTTP headers into HPACK format. After HTTP/2 is enabled, both ends of a connection cache a copy of HTTP header indexes. The index numbers are transmitted to identify duplicate HTTP headers. In this case, the system does not need to transmit duplicate HTTP headers. This increases the transmission speed and efficiency.
- Log on to the Alibaba Cloud CDN console.
- In the left-side navigation pane, click Domain Names.
- On the Domain Names page, find the domain name that you want to manage and click Manage in the Actions column of the domain name.
- In the management pane of the domain name, click HTTPS.
- In the HTTP/2 section, turn on HTTP/2.