How Can We Help?
< Back


The LiteSpeed Cache plugin is a MediaWiki extension for MediaWiki sites running on a OpenLiteSpeed webserver. Enable its LSCache feature to speed up page loading, reduce response time, and tremendously reduce server load for MediaWiki sites.

MediaWiki is a free software open source wiki package written in PHP, originally for use on Wikipedia (the free encyclopedia). It is a feature-rich wiki implementation, that uses PHP to process and display data stored in its MySQL database. It is a fairly popular wiki application on the web.


This version of LiteSpeedCache requires MediaWiki 1.25 or later and OpenLiteSpeed 1.4.28 or later.



Unzip the downloaded file with:



  1. Move the LiteSpeedCache directory to /extensions in the MediaWiki directory.
  2. Edit LocalSettings.php in the MediaWiki root directory, and add the following near the end: wfLoadExtension( ‘LiteSpeedCache’ );
  3. Log in to MediaWiki and from the administrator panel, navigate to Special pages > Data and Tools > LiteSpeed Cache.




Edit the page to enable public cache:


Set LiteSpeed Public Cache Enabled to checked and save the page.

Verify Cache Setup

If a resource is served from LiteSpeed Cache, the server response header contains X-LiteSpeed-Cache: Hit.

Load the URL and check the headers through the Network tab of the browser’s developer tool. You should see something like this:

GET /wiki/index.php/Main_Page HTTP/1.1
Accept	text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Encoding	gzip, deflate, br
Accept-Language	en-US,en;q=0.5
cache-control	public, max-age=2592000
server	LiteSpeed
vary	Accept-Encoding, Cookie
x-litespeed-cache	hit