Knowledge base article
Introduction to LiteSpeed Cache
View other technical support articles
Related articles
Basic WordPress security and site management
Configure object cache with memcached and Litespeed Cache plugin
Other technical support articles
A beginners guide to email spoofing
Accessing your site before changing DNS
An introduction to email authentication
Basic WordPress security and site management
Check MySQL database table disk usage
Configure object cache with memcached and Litespeed Cache plugin
Configure spam filtering in cPanel
Connect via SFTP using SSH key authentication with FileZilla
Connecting to Serversaurus shared hosting via SFTP
Create a clone of your website
Create a SSH key pair and configure your SSH key in cPanel
Create a WordPress administrator via MySQL CLI
Create a WordPress administrator via phpMyAdmin
Create a WordPress cron task in cPanel
Disable automatic WordPress updates via wp-config.php
Download or restore individual files, directories or database backups with JetBackup
Enabling PHP extensions, Changing PHP Version and Setting PHP Options
Export or Import a MySQL database via CLI
Force HTTPS via .htaccess (cPanel)
Getting Started with Anycast DNS
Getting Started with the Content Delivery Network (CDN)
Getting Started with Virtual Machines
Go live with your WordPress staging website
Help! I need a backup of my cPanel-hosted website
Hide .html extension using .htaccess
How did my WordPress website get hacked? What do I do?
How to ensure website generated emails are delivered successfully
How to issue a Let’s Encrypt certificate
How to remove Site Software management
I can receive email but can’t send!
Manage DNS zones with the cPanel Zone Editor
Manual WordPress migrations in a nutshell
Migrate remote staging website to local hosting server
Migrate remote transactional website to local server
Migrating email from one POP/IMAP email account to another
My site and/or email service is down
Network Firewall (I can’t access my services on a non-standard port)
Optimising Wordfence firewall and security settings
Pointing your domain to Serversaurus
Pointing your domain to Squarespace with cPanel
Prevent website generated spam with CAPTCHA
Push updates from a staging to production website
Reconfigure production website to subdomain
Recover your hacked WordPress website
Remove Wordfence firewall block via MySQL CLI
Secure your WordPress installation
Setting up email on your iPhone
Subdomains for test sites & more
Unable to renew certificate: The Let’s Encrypt HTTP challenge failed
Understanding CloudLinux resource limits
Update a WordPress website to use a new domain name
Update your WordPress username via phpMyAdmin
Using Serversaurus’ nameservers but hosting your email elsewhere
Using the Serversaurus Cloud CDN with your WordPress website
An introduction to LiteSpeed Cache and the basic cache types available
LiteSpeed Cache is a caching system inbuilt with the LiteSpeed web server which accelerates the performance of your application by generating cached versions of your website assets.
A cached version of a webpage is a static copy of the webpage which is saved as a file (or combination of files), after the cache file(s) has been generated, the file(s) can be served extremely fast to the next user. When caching is disabled, instead of serving a static file, the web server needs to process all the scripts loading on each page, which takes a lot more time and resources than serving a cached version of the webpage which can be instantaneous.
LiteSpeed cache is simple to configure using the free LiteSpeed Cache plugins available for most popular content management systems, such as WordPress, Magento, Craft, Joomla, Drupal. Visit the LiteSpeed documentation to check if there's a LiteSpeed Cache plugin available for your web application.
Within the LiteSpeed cache plugin, you can manage various caching rules which determine how caching works for your website, for example you can adjust how long cached versions of the page are stored, or what types of files or pages you would like included in the cache. There's also advance settings which allow you to optimise various website assets, such as compressing images, minifying HTML, JS and CSS and more!
LiteSpeed Cache uses rewrite directives in the .htaccess file to mange cache configurations, these directives are automatically written to your .htaccess file when you're using a LiteSpeed Cache plugin. If a LiteSpeed Cache plugin is not available for your application, you can configure LiteSpeed Cache manually using .htaccess rewrite directives, please reference LiteSpeed's no plugin setup guideline.
There are two primary cache types when using LiteSpeed Cache:
- Public Cache - Designed for publicly accessible website content which is not user specific. Public cache files can be served to any site visitor.
- Private Cache - Designed for user specific content. Private cache is used for areas which contain private information such as a website administrative area, contact forms, personalised greetings, checkouts and carts etc. Private cache is generated separately for each user (usually tracked by an IP address or session ID) so be mindful when identifying areas where private cache is required to ensure sensitive data is protected.
Cache storage
Our performance servers each have a partition dedicated to the storage of our clients public cache files, this reduces the disk usage overhead for our clients because publicly cached files are not included in their subscriptions disk usage consumption. As a security measure private cache files are stored within a users home directory. By default private cache files are stored under ~/lscache.
Our Business hosting servers also offer LiteSpeed Cache however all cache files are stored within the clients home directory.
ESI (Edge Side Includes)
LSCache also supports Edge Side Includes (ESI) which is a markup language enabling you to seperate a webpage into different cache types. This means you can use a combination of public and private cache on webpages. This great feature makes it possible to cache the majority of your web content.
Last updated November 30, 2023