19 Feb Why Should I Care About HTTP2?
The Internet Engineering Task Force (IETF®) sat down over 2 years ago with one goal: to make the internet better. Wednesday, after over 200 designs, 17 drafts and 30 implementations, the group approved the first major update to standard internet protocol in 15 years.
As web pages get more advanced, loading a page requires more resources. HTTP (hypertext internet transfer protocol) traditionally only allows one download request per connection. Browsers have found a way around this by issuing multiple requests, and by caching files so that pages load fasters. But this isn’t really fair since all those requests can clog up the network. So what were developers to do?
Enter SPDY.
SPDY is (or was, Google announced plans to removed SPDY support in favor of HTTP/2 in February 2015) an open networking protocol developed by Google for transporting web content. It was chosen as the base framework for HTTP/2.
What is HTTP/2?
Let’s start with saying that HTTP/2 is not a rewrite of HTTP, the methods, status codes and semantics are unchanged. In fact, the newly finished protocol is designed to seamlessly switch between HTTP/1 and HTTP/2 with minimal changes to applications and APIs. HTTP/2 focuses on performance, enabling more efficient use of network resources and reducing perceived lags for the user. What did change is how the data is framed and transported between the browser and the server.
Key Differences
HTTP/2 |
VS | HTTP/1.x |
Binary |
Text | |
Multiplexed |
Ordered and blocking |
|
Servers “push” data |
Browsers request data |
|
Header compression |
No header compression |
Multiplexing and header compression are two immediate improvements over how websites load today. Multiplexing allows you to send many request as you like on a single connection, eliminating the need to open multiple connections, saving time and resources.
When compared to how long you had to wait for dial-up, web pages load lightning fast. Be we still want it faster (If you don’t believe me, you should check out the statistics on user drop off due to extended load times).
To better understand multiplexing, the ability to send multiple requests at once, check out this video.
Will there be a HTTP/3?
Maybe. If HTTP/2 works well, it should be possible to support newer versions more easily.
Ok, now really, why should I care?
These improvements will open the doors for developers to create richer content and even better performance. The possibilities are endless!
Companies like Twitter and Microsoft have already incorporated HTTP/2 in their coding. If you are interesting in learning more, the Microsoft prototype is available for download and the IETF offers plenty of advice in their wiki on how to implement it on your server.