Blog

When it comes to website performance, persistent connections pay off

June 30, 2014 Written by NetSphere Category: It Just Makes Good Business Sense
When it comes to website performance, persistent connections pay off

The old adage of persistence pays off is often attributed to achieving an individual’s goals. And although it’s often tied to offline aspirations, it’s also a mantra that holds up in the digital world. When persistent connections, also known as HTTP keep-alive, are enabled on a website, its performance will benefit, helping to drive a business’s growth initiatives. 

According to the World Wide Web Consortium, or the W3C, before the days of persistent connections, a separate TCP connection had to be established to fetch each URL. Doing so increased the load on HTTP servers and caused congestion on the web – a traffic jam of the digital kind. With a growing collection of images and other data being added to the web on a regular basis and requiring to be individually fetched, something had to be done. Enabling keep-alive on a website was the solution. In fact, it became a default setting for all websites.

Beyond curtailing network congestion, HTTP keep-alive comes with multiple advantages. The W3C lists them as follows:

  • By opening and closing fewer TCP connections, CPU time is saved in routers and hosts (clients, servers, proxies, gateways, tunnels, or caches), and memory used for TCP protocol control blocks can be saved in hosts.
  • HTTP requests and responses can be pipelined on a connection. Pipelining allows a client to make multiple requests without waiting for each response, allowing a single TCP connection to be used much more efficiently, with much lower elapsed time.
  • Latency on subsequent requests is reduced since there is no time spent in TCP's connection opening handshake.
  • HTTP can evolve more gracefully, since errors can be reported without the penalty of closing the TCP connection. Clients using future versions of HTTP might optimistically try a new feature, but if communicating with an older server, retry with old semantics after an error is reported.

In layman’s terms, keep-alive will keep a website from taking too long to load. Although it is a default setting, there are a few reasons that it might not be working. To ensure that it’s enabled and properly functioning, it’s recommended to use the free website performance test found at webpagetest.org.   

Once the test has been run, a website is given various letter grades for various aspects of page performance, including keep-alive. If the letter grade for whatever reason isn’t an A, it’s important to alert your IT team, which should have an easy time remedying the problem. Most often, it’s as simple as changing the HTTP header from “connection: close” to “connection: keep-alive.”

To get assistance making the change or enhancing the page load times of your website, feel free to contact the team at NetSphere Strategies. Our goal is to help our clients deliver the best online experience possible and has a consistent track record improving performance rates.   

SHARE
Trackback URL for this blog entry.

Abbe Miller is the marketing manager at NetSphere Strategies, located just outside Chicago. NetSphere Strategies is a boutique eCommerce company positioned to help businesses transform their online presence by providing a full complement of services that starts with our strategic consulting and creative design teams, then continues with building innovative solutions and providing ongoing post-project support.