LiteSpeed Cache (LSCache) is a free, all-in-one WordPress performance plugin: full-page caching, object cache integration, image optimization, CSS/JS minification, critical CSS, lazy loading and more. Its main feature, server-level page caching, only works when your site runs on a LiteSpeed web server: either commercial LiteSpeed Enterprise, or the free OpenLiteSpeed.

Does it work on Nginx or Apache?

  • Page cache: no. It requires LiteSpeed or OpenLiteSpeed (or QUIC.cloud’s CDN in front).
  • Other features (image optimization through QUIC.cloud, CSS/JS minification, lazy loading, database cleanup, object cache) work on any server.

If your VPS runs Nginx, use Nginx FastCGI cache or another cache plugin for page caching. See Nginx FastCGI cache and WordPress cache plugins compared.

Set up OpenLiteSpeed on a VPS

OpenLiteSpeed (OLS) is free, fast, has a web admin console, and reads Apache-style rewrite rules (on restart). One-click scripts install OLS, LSPHP, MariaDB and WordPress. See install OpenLiteSpeed.

In short:

  • the OLS WebAdmin console runs on port 7080 (keep it firewalled, or use an SSH tunnel);
  • PHP runs as LSPHP (LiteSpeed’s PHP SAPI), for example lsphp83;
  • .htaccess changes require a graceful restart (sudo systemctl restart lsws, or the console).

Install and enable the plugin

wp plugin install litespeed-cache --activate

Then go to LiteSpeed Cache → Cache:

  • Enable Cache: ON.
  • Cache Logged-in Users: OFF (unless you know what you’re doing, because it uses private caches).
  • Cache REST API: ON (for public endpoints).
  • Cache Mobile: ON only if your theme serves different HTML on mobile.

Check it works: open your site in a private window, and look for the response header x-litespeed-cache: hit (on the second load).

Cache → TTL: defaults are fine (public pages about a week). Purging is automatic when you edit content.

Cache → Purge: “Purge All on upgrade” ON. Leave auto-purge rules for related pages (archives, home) at their defaults.

Cache → Excludes: WooCommerce cart, checkout and account pages are excluded automatically. Add any custom dynamic pages (for example membership dashboards).

Object cache: with Redis installed (sudo apt install redis-server, plus the LSPHP Redis extension), enable it in Cache → Object, with host 127.0.0.1 and port 6379. Test the connection status on that page. See install Redis.

Browser cache: ON (long expiry headers for static files).

Page optimization: enable carefully

The Page Optimization tab (CSS/JS minify, combine, defer, delay JS, critical CSS, unused CSS removal) can give big gains, and can also break layouts and scripts. Enable one option at a time, and test:

  1. CSS minify → test.
  2. JS minify → test.
  3. JS defer → test menus, sliders, forms and checkout.
  4. “Load CSS asynchronously” (generates critical CSS via QUIC.cloud) → test.

If something breaks, exclude the specific file in the plugin’s exclude lists, rather than turning everything off.

Image optimization

LSCache can send images to QUIC.cloud for compression and WebP/AVIF generation (free quota, then paid credits), and serves WebP to supporting browsers. Alternatively, use another image plugin or server-side tools. See WordPress image optimization.

QUIC.cloud CDN (optional)

QUIC.cloud is LiteSpeed’s CDN. It can cache full pages at the edge, even for sites not on a LiteSpeed server. It’s an alternative to Cloudflare. Don’t stack two full-page CDNs.

Common pitfalls

  • Plugin active on Nginx/Apache: no page caching, only the optimization features. Check the x-litespeed-cache header.
  • Another cache plugin active at the same time: conflicts and double caching. Keep one.
  • Cloudflare HTML caching plus LSCache: purges don’t reach Cloudflare unless configured. Pick one layer for HTML.
  • Logged-in or personalized content cached: use the ESI or private cache features, or exclude those pages.

Quick reference

Item Value
Page cache requirement LiteSpeed Enterprise or OpenLiteSpeed
Check x-litespeed-cache: hit header
Object cache Redis or Memcached via Cache → Object
OLS admin console port 7080 (restrict)
Optimizations enable one at a time, then test

Related: W3 Total Cache setup and WordPress TTFB.

  • WordPress
  • Performance
  • LiteSpeed