Speed up your forum on LiteSpeed Web server.

0.2.2 2021-12-06 21:22 UTC

This package is auto-updated.

Last update: 2021-12-07 03:13:26 UTC


Latest Stable Version Total Downloads Supports latest Flarum

A Flarum extension. Integrates LSCache with your forum.

Requires a LiteSpeed Web Server.


Install with composer:

composer require acpl/flarum-lscache:"*"

You need to include this code in your .htaccess file:

<IfModule LiteSpeed>
    CacheLookup on
    RewriteEngine On
    RewriteCond %{REQUEST_METHOD} ^HEAD|GET$
    # Detection of logged-in user.
    RewriteRule .* - [E="Cache-Vary:flarum_remember,flarum_lscache_vary,locale"]
    # If you have a non-default path to the admin panel, change "admin" to match.
    RewriteCond %{ORG_REQ_URI} !/admin
    # Enable private cache for admin panel. If it causes issues set [E=Cache-Control:no-cache]
    RewriteRule .* - [E=Cache-Control:private,max-age=300]

You can also add your own rules. For more information see here:


composer update acpl/flarum-lscache:"*"
php flarum migrate
php flarum cache:clear

When you clear the Flarum cache, the LSCache is cleared automatically.

You can clear LSCache without clearing the Flarum cache in the admin panel. The option is available under the standard Flarum cache clearing option. There is also the php flarum lscache:clear command.