Forum Moderators: phranque

Message Too Old, No Replies

What is HTTP/2?

& why you should be using it

         

keyplyr

5:27 am on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



HTTP/2 is the first major HTTP protocol update since 1997 when HTTP/1.1 was first published by the IETF. The new HTTP protocol is needed to keep up with the exponential growth of the web. HTTP/2 brings significant improvement in efficiency, speed and security. The speed advantage to your site is 50% to 70% faster using HTTP/2.
source: keycdn.com

• HTTP/2 is binary, instead of textual.

• It is fully multiplexed, sending multiple requests in parallel over a single TCP connection.

• It uses header compression HPACK to reduce overhead.

• It allows servers to "push" responses proactively into client caches instead of waiting for a new request for each resource.

• It uses the new ALPN extension which allows for faster-encrypted connections since the application protocol is determined during the initial connection.

• It reduces additional round trip times (RTT), making your website load faster without any optimization.

• Domain sharding and asset concatenation is no longer needed with HTTP/2.

• Most modern web browsers support HTTP/2 but only on sites using HTTPS protocol.

To test if your server supports HTTP/2 you can use this tool [tools.keycdn.com]

---

not2easy

6:43 am on Jun 8, 2017 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



And if the tool here says ALPN is not supported, what can be done? What's ALPN?

keyplyr

6:51 am on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



What's ALPN?
ALPN, or Application-Layer Protocol Negotiation, is a TLS extension that includes the protocol negotiation within the exchange of hello messages.

ALPN is able to negotiate which protocol should be handled over a secure connection in a way that is more efficient and avoids additional round trips.

The ever-growing in popularity HTTP/2 protocol, makes use of ALPN to further decrease website load times and encrypt connections faster.

And if the tool here says ALPN is not supported, what can be done?
Talk to your server administrator. They may have plans in the making. Most providers are in transition to these new protocols.

Peter_S

9:49 am on Jun 8, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



Thank you for the topic keyplyr.

And if the tool here says ALPN is not supported, what can be done?

It might be off-topic, but under Linux, beside getting a recent version of a web server software (nginx/apache/etc) you also need to have (and use) OpenSSL 1.0.2 or above. Previous versions of OpenSSL do not support ALPN. Also, one need to pay attention if his web server software is statically built with an older versoin of OpenSSL.

keyplyr

12:01 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



According to W3Techs, as of January 2017, 12.7% of the top 10 million websites support HTTP/2 and growing.

Many servers will need significant upgrades, others will just need to install an extension. New servers should be ready to go.

robzilla

4:54 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Here's a good visual reminder: [http2.akamai.com...]

Peter_S

6:03 pm on Jun 8, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



Many servers will need significant upgrades

I might be wrong, because I never used it, but if I don't make mistake, you need Windows 10 or Windows Server 2016, to benefit from IIS 10 with http/2 . This can be a major problem for Windows based hosting.

By the way, when I switched last summer, my site ended to download faster in http/2 (nginx) than in http 1.1 in spite of the extra load for the encryption. (note: I compiled OpenSSL so that it exploits the hardware AES-NI instructions of Intel CPUs for encryption).

keyplyr

9:32 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



List of browsers that currently support HTTP/2: [bit.ly...]

As you can see, all the major browsers already support HTTP/2 (conditions in footnotes)

robzilla

10:31 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Yes, sadly there don't seem to be any plans to add HTTP/2 support to older versions of Windows Server.

keyplyr

10:57 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



...there don't seem to be any plans to add HTTP/2 support to older versions of Windows Server
Likely by design. M$ has shown a strong preference to force retirement of older builds of public facing platforms.

Peter_S

11:02 am on Jun 9, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



Nb:

With the Google's Chrome Developer Tool, you can see which protocol is used. On the network tab, if you right click on any column name, you can enable "Protocol".

A site using http/2 should show "h2". You might also see "http/2+quic/xx". QUIC is using UDP instead of TCP. It's "potentially" the next evolution. It's very-very rare, but for example Google uses it. (Google is at the origin, like for the SPDY)

keyplyr

11:10 am on Jun 9, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Thanks Peter_S

SPDY was the precursor to HTTP/2, but yes Google has championed it from the start.

UDP is the main alternative to TCP and one of the oldest network protocols in existence, introduced in 1980, but negotiable if it is slated to replace TCP.

motorhaven

1:25 am on Jun 10, 2017 (gmt 0)

10+ Year Member Top Contributors Of The Month



HTTP/2 shines even more when combined with Brotli compression.

keyplyr

1:46 am on Jun 10, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



File density (compression ratio) benchmarks:

• Brotli ranked best
• Zstandard ranked 2nd best
• GZIP came in a close 3rd

More shared-hosting companies use GZIP. However they are all effective for increasing download times as much as 70% on some file types

born2run

5:39 pm on Jul 25, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Doesn't http/2 require an apache server to have https (ssl) enabled on the site as well?

robzilla

7:08 pm on Jul 25, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Yes, HTTP/2 requires TLS encryption (HTTPS). Not by definition, but that's the implementation.