This is an old revision of the document!


Server Push supported on LiteSpeed Web Server

Server Push is a method of information delivery where a server pushes a resource directly to the client without first receiving a request to do so. By doing this the server can attempt to anticipate client requests and pre-push them into the client’s cache in an effort to avoid the usual request-response round trip delay.

  1. LiteSpeed Enterprise 5.2+
  2. Site use HTTPS
  3. Browser support HTTP/2

We are going to introduce how to verify Server Push with WordPress+LScache Site then with CloudClare. If you want to try server push and file making by yourself, please refer Server Push.

Install WordPress and LSCache

Verify browser support HTTP/2

Configure LSCache to use Server Push

  1. Navigate to WordPress Control Panel>LSCache>Settings>Optimize tab
  2. Set CSS HTTP/2 Push and JS HTTP/2 Push as On

Verify Server Push

We are going to use Chrome developer tool as our verification tool.

  • If you only enable CSS HTTP/2 Push. Header will looks like this:

  • If you enable both CSS HTTP/2 Push and JS HTTP/2 Push. Header will looks like this:

Configure CDN to serve with Server Push

Why we verify with CloudFlare? Cloudflare supports HTTP/2 Server Push with the Link header field on all plan levels. Cloudflare will look for the Link header field, in response headers from the origin server and extract URI-references with parameters rel=preload. These URI will be pushed to the client.

Follow this LiteSpeed blog to Setup CDN from LSCache

  • If you only enable CSS HTTP/2 Push. Header will looks like this:

  • If you enable both CSS HTTP/2 Push and JS HTTP/2 Push. Header will looks like this:

Other method to verify

  1. Enter browser with chrome://net-internals/#http2
  2. Refresh your test site
  3. You will see HTTP/2 sessions
  4. Click hyperlink of ID
  5. You will see Events of HTTP2_SESSION
  6. Check HTTP2_SESSION_RECV_HEADERS>link, which will contain like this
    rel=preload; as=style,</wordpress/wp-content/plugins/litespeed-cache/css/litespeed.css>; rel=preload; as=style,</wordpress/wp-includes/js/admin-bar.min.js>;
  • Admin
  • Last modified: 2017/10/24 15:03
  • by Eric Leu