LiteSpeed Cache Configuration: A Complete 14 Steps Guide

LiteSpeed Cache

LiteSpeed Cache is a website optimization tool that helps to speed up website loading times and improve overall user experience. It works by caching the dynamically generated pages of a website and serving the cached version to visitors, reducing the processing load on the server and the time required to generate the page dynamically. Configuring LiteSpeed Cache involves setting up the cache rules, optimizing the cache settings, and fine-tuning the configuration for maximum performance. This guide provides a comprehensive, step-by-step approach to configuring LiteSpeed Cache for optimal website performance.

Table of Contents

To configure LiteSpeed Cache, follow these steps:

Install the LiteSpeed Cache plugin on your website.

To install LiteSpeed Cache, log into your website’s control panel, go to the plugin section, and click on ‘Add New’ to search and install the LiteSpeed Cache plugin.

Litespeed Cache 1

And follow these steps:

WARNING!!

IT’S IMPORTANT TO SAVE CHANGES IN EVERY SECTION OF THE LITESPEED CACHE PLUGIN BEFORE CHECKING YOUR WEBSITE, AS ANY CHANGES MADE MAY CAUSE THE WEBSITE TO CRASH. IF THE WEBSITE DOES CRASH, YOU SHOULD TRY TO IDENTIFY WHICH SECTION CAUSED THE ISSUE AND DISABLE EACH OPTION ONE BY ONE UNTIL THE PROBLEM IS RESOLVED. ONCE THE WEBSITE IS FUNCTIONING AGAIN, YOU CAN RE-ENABLE ALL OPTIONS IN THE SECTION EXCEPT FOR THE ONE THAT IS CAUSING THE WEBSITE TO CRASH. THIS WILL HELP YOU ISOLATE THE ISSUE AND PREVENT FURTHER CRASHES. THIS PROCESS SHOULD BE FOLLOWED FOR EVERY SECTION OF THE LITESPEED CACHE PLUGIN TO ENSURE STABILITY AND PREVENT ANY POTENTIAL CRASHES.

Go to the LiteSpeed Cache settings page in your WordPress dashboard.

Litespeed Cache 2

Activate the specified configuration options.

1st Step General:

The General section of the LiteSpeed Cache plugin in WordPress includes options such as “Automatically Upgrade,” “Domain Key,” “Guest Mode,” “Guest Optimization,” and “Notifications.” These options allow you to control various aspects of the plugin’s behavior and determine how it will interact with your website and its visitors.

Turn on all the settings and save changes:

Litespeed Cache 3

If you are unable to locate the Domain Key in the General section of the LiteSpeed Cache plugin, simply click the “Refresh Domain Key” button and a new one will be generated for you

Leave the section’s setting at its default value.

2nd Step Cache

In Cache tab on Cache Section, Turn on all the settings and save changes:

Litespeed Cache 4

3rd Step TTL

Leave the section’s setting at its default value.

In this step, enable the “Purge All On Upgrade” option and select all the options as indicated below.

Litespeed Cache 5

Turn off Serve Stale if it is on and Leave everything at its default value.

4th Step Exclude & ESI

In Cahce’s Exclude Tab Leave everything at its default value.

In Cache’s ESI Tab if you are working on E-Commerce website it is important for you. Turn on all the options shown in the picture and leave the rest of the settings as they are in the ESI Tab of the Cache.

Litespeed Cache 6

5th Step Object

In the Object Tab of the Cache, turn off Object Cache and set the Method to Memcached. Enable all options shown in the picture 2 and maintain the default settings for the rest.

PICTURE 1

Litespeed Cache 7

PICTURE 2

Litespeed Cache 8

6th Step Browser

Enable Browser Cache

Litespeed Cache 9

7th Step Advanced

Disable Improve HTTP/HTTPS Compatibility and Enable Instant Click

Litespeed Cache 10

Then Save Changes.

8th Step CDN

In the CDN Setting section of the CDN, enable QUIC.cloud CDN and disable Use CDN Mapping. If you have Cloudflare, turn on Cloudflare API as well.

Litespeed Cache 11

With a Cloudflare account, obtaining your API code is as simple as clicking on the link shown in the image. This code is crucial for integrating the benefits of the Litespeed cache CDN into your website.

Litespeed Cache 21

And Leave everything at its default value.

More About Cloudflare and LSC configuration.

9th Step Image Optimization Summary

In this tab there is big blue button says Check Images or something like that you will not see that in the image as i already it before but after that the button will start say Send Optimization Request click on the button.

Litespeed Cache 12

You can request a maximum of 200 images at once. If you have more than this then just have to click it more.

And do not use the orignal backup options shown in the as it is irrevesable act after that you can not restore it.

Step 10 Image Optimization Settings

In this tab, ensure that the ‘Auto Request Cron’ is turned off, while the ‘Auto Pull Cron’ is turned on. Set ‘Optimize Original Images’ to off, ‘Remove Original Backups’ to off, ‘Optimize Losslessly’ to off, ‘Preserve EXIF/XMP data’ to off. Turn ‘Image WebP Replacement’ on and ‘WebP for Extra srcset’ on. Keep all other settings at their default values.

PICTURE 1

Litespeed Cache 13

PICTURE 2

Litespeed Cache 14

Step 11 Page Optimization

In the ‘CSS Settings’ tab of ‘Page Optimization’s 1,’ ensure that all options are turned on to optimize your page’s performance.

Litespeed Cache 15

In the ‘JS Settings” tab of ‘Page Optimization’s’, Enable everything and Deffered Load JS.

Litespeed Cache 15

Step 12 HTML Settings

In this step, enable ‘HTML Minify,’ ‘DNS Prefetch Control,’ ‘Remove Query Strings,’ and ‘Load Google Fonts Asynchronously.’ Turn ‘Remove Google Fonts’ off, ‘Remove WordPress Emoji’ on, and ‘Remove Noscript Tags’ off to optimize the page’s performance.

PICTURE 1

Litespeed Cache 16

PICTURE 2

Litespeed Cache 17

Step 13 Media Settings

In this step, activate ‘Lazy Load Images,’ ‘Responsive Placeholder,’ and ‘Lazy Load Iframes.’ Turn off ‘LQIP Cloud Generator,’ but enable ‘Generate LQIP in Background.’ Lastly, make sure ‘Add Missing Sizes‘ is enabled.

Step 14 Media Excludes & Localization

In Media Excludes Keep Every Thins Disable, and Localization Keep Gravatar Cache on and leave everything disable.

Upon completion of these actions, your LiteSpeed configuration will be fully set up.

See more about LiteSpeed Cache.

Spread the love

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top