Skip to content

Blog

Best LiteSpeed Cache Settings for Divi

  • More than 300 five‑star Google reviews
  • Rolling monthly contracts
  • Monthly SEO report
  • One client per niche in each area

Key points

  • Back up your site and test one page in PageSpeed Insights before you change anything.
  • LiteSpeed's page cache needs LiteSpeed hosting or a LiteSpeed server product, so check with your host first.
  • Turn on the page cache, object cache, image optimisation, minify and lazy loading, and keep JS Combine off until it passes a test.
  • Change one tab at a time, press Purge All and check the page after each change.

The best LiteSpeed Cache settings for Divi turn on the page cache, object cache, image optimisation with WebP, CSS and JS minify, CSS combine and lazy loading, and leave JS Combine off. Change one tab at a time and check your pages after each change, because Divi builds its pages from scripts and styles that a few LiteSpeed options can break.

The settings below are the ones we use on our own Divi site, with the reason for each and the check to run afterwards. Where a setting has a warning in LiteSpeed's own documentation or in Elegant Themes' help pages, we say so.

Does LiteSpeed Cache work on any hosting?

The page cache is a LiteSpeed feature, so it depends on LiteSpeed. LiteSpeed's WordPress plugin documentation says that to use LSCache you need either LiteSpeed powered hosting or one of its LiteSpeed server products.

The plugin's WordPress.org page says the LiteSpeed exclusive features need OpenLiteSpeed, a commercial LiteSpeed product, LiteSpeed powered hosting or the QUIC.cloud CDN. It also says the general features work on any web server, including Apache and NGINX, and that QUIC.cloud CDN allows sites on any server to use LiteSpeed caching.

Ask your host which web server runs your site before you spend time on the Cache tab. If it is not LiteSpeed, some of the settings below may not apply to your site. Our guide to speeding up a WordPress site safely covers what other speed plugins can and cannot fix.

What should you do before you change any settings?

  1. Back up your files and your database, so you can go back if a page breaks.
  2. Test one important page in PageSpeed Insights and write down the result. Elegant Themes advises running a test on a page before you make any optimisations, so you have something to compare against.
  3. Test in a private browser window. LiteSpeed warns that Guest Optimization can hide real problems from speed tests, and says to turn it off if you want an accurate result from a speed test site.
  4. Press Purge All after each change. LiteSpeed's Page Optimization documentation gives the same advice, along with a request to test the options thoroughly before enabling them on a production site.

How do you set up LiteSpeed Cache with Divi?

Work through the tabs in this order. Each setting shows the value we use on our own Divi site.

General tab

Automatically Upgrade: OFF. LiteSpeed says you can have the plugin upgrade automatically whenever a new version is available. We leave it off so every update happens after a backup, because we like to check how Divi pages look after each change.

Guest Mode: OFF and Guest Optimization: OFF. We leave both off on our own Divi site. LiteSpeed's General tab documentation says Guest Mode serves a default cached page for a visitor's first request, then loads the personalised version afterwards. It lists much faster server response times as the main benefit.

The same page warns that extra cache variations can multiply crawlers if crawling is on, so check your server can cope. It says Guest Optimization turns on a separate mobile cache for all visitors, which may use server resources you do not have to spare, and that it can hide real problems from speed tests. For an accurate speed test, LiteSpeed says to turn it off, and it suggests checking your site in a private window as a first time visitor.

Cache, TTL and Purge tabs

Enable Cache: ON. LiteSpeed says that when this is on, your site's pages are cached. It relies on the server point above.

Cache Mobile: OFF. This keeps separate cached versions for mobile and desktop, and LiteSpeed's Cache tab documentation shows it is off by default. We leave it off, so phones and computers are served the same cached page, which suits a responsive Divi layout.

TTL tab. TTL means time to live, which is how long a cached page is kept. LiteSpeed's default for public pages and the front page is 604800 seconds, which is seven days. We set Default Public Cache TTL and Default Front Page TTL to 36000 seconds, which is 10 hours, so a cached page expires and is rebuilt more often.

Purge All On Upgrade: ON. LiteSpeed describes this as purging all pages when a plugin, a theme or WordPress core is updated. It sits on the Purge tab, and it clears old copies after a Divi update.

Object tab

Object Cache: ON, Method: Memcached. LiteSpeed's Cache documentation says the plugin does not provide object caching itself. Instead, it supports external object caches such as Memcached, LiteSpeed's own LSMCD, or Redis. It is off by default. We use it with Memcached, so ask your host whether Memcached or Redis is available before you turn it on.

Browser Cache

Browser Cache: OFF. LiteSpeed says that when Browser Cache is on, static files such as images, CSS and videos are stored on the visitor's device. It is off by default, and the recommended TTL on the Browser tab is 31557600 seconds, which is one year.

We leave Browser Cache off in the plugin on our own Divi site. If you turn it on, check that a changed logo or stylesheet still shows for returning visitors after you purge.

Advanced tab

Instant Click: ON. LiteSpeed says that with Instant Click on, the page begins loading as soon as the visitor hovers over a link. It is an optional extra, so check that your menus and buttons still work after turning it on.

Image Optimization tab

Optimize Original Images: ON and Next-Gen Image Format: WebP. LiteSpeed's Image Optimization documentation says Optimize Original Images is on by default and optimises JPG and PNG files, and that image optimisation needs QUIC.cloud services switched on in the plugin. It says the Standard Queue is free for everyone with unlimited use.

The same page says the plugin does not create next generation formats such as WebP and AVIF unless you enable that behaviour. In our version of the plugin that choice is the Next-Gen Image Format setting on the Image Optimization settings tab, and we set it to WebP. We leave Optimize Losslessly off.

The same page warns you not to run another image optimisation plugin at the same time. It also says Remove Original Backups cannot be undone, so leave that one alone until you are sure you will not need the originals.

CSS and JS tabs

CSS Minify: ON and JS Minify: ON. LiteSpeed says these strip extra spaces, new lines and comments from your files. Elegant Themes says that in general it is safe to minify CSS files, and to be careful with JavaScript files. That advice comes from its Divi speed guide, last updated in 2023.

CSS Combine: ON and CSS Combine External and Inline: ON. LiteSpeed's Page Optimization documentation says CSS Combine joins all individual CSS files into a single CSS file. It says the second option also adds external CSS files and CSS found inline in the HTML. Both are off by default. They work on our own Divi site, but check menus, fonts and page layouts after turning them on, and list any file that breaks in CSS Excludes on the Tuning CSS tab.

Font Display Optimization: Swap. LiteSpeed says this adds a font display rule to each web font before the CSS is cached, to set how fonts show while they download. We set it to Swap.

Load CSS Asynchronously: OFF. LiteSpeed says this loads CSS and HTML at the same time, using the QUIC.cloud Page Optimization service to generate Critical CSS. Its documentation says you must enable QUIC.cloud services to use it, that a fee may apply, and that CSS will not load asynchronously without them. It is off by default, and we leave it off.

Divi has its own Critical CSS option, which Elegant Themes describes as identifying the CSS needed for the content above the fold and deferring everything else. If you turn Load CSS Asynchronously on as well and a page flashes unstyled for a moment, see our guide to fixing the flash when a website loads and test with one of the two options off.

JS Combine: OFF. On our own Divi site, turning JS Combine on broke the formatting, and the icons and images did not load properly, so we keep it off. Elegant Themes' 2023 speed guide says Divi already minifies and combines its own JavaScript and CSS dynamically by default, so there may be less to gain from combining again.

Load JS Deferred: Deferred. LiteSpeed says Deferred runs the JavaScript as soon as the HTML finishes loading, while Delayed runs it only after it detects visitor activity, such as a key press or mouse movement. It is off by default. We use Deferred and list a few scripts in JS Excludes, on the Tuning tab, so they are left alone. Test sliders, forms and the mobile menu after changing this.

HTML tab

This is where HTML Minify sits. LiteSpeed says it strips extra whitespace, new lines and comments from all HTML. Elegant Themes' 2023 speed guide says Divi does not minify the HTML output, so this is one area a plugin can add to. We leave HTML Minify off on our own Divi site, so test it like any other change if you try it.

On the same tab we turn on Remove Query Strings and Remove WordPress Emoji. LiteSpeed says the first strips query strings from static resources, and the second removes the extra JavaScript file used to add emoji support in older browsers.

Media and VPI tabs

Lazy Load Images: ON and Lazy Load iframes: ON. LiteSpeed says Lazy Load Images loads images only when they are visible in the viewport, and that Lazy Load iframes works like it but applies to iframes instead of images.

We also turn on Add Missing Sizes, which LiteSpeed says adds missing width and height attributes to local images and works only when Lazy Load Images is on. A few images on our site are listed in Lazy Load Image Excludes, which LiteSpeed says is for images that need to load immediately, wherever they appear on the screen.

The web.dev guidance on lazy loading found that a WordPress approach that lazy loaded images already in the viewport hurt Largest Contentful Paint, and that not lazy loading images above the fold reversed the drop. It is a 2022 article, but the point still applies. If the main image at the top of a page appears late, test the page with Lazy Load Images off. Our post on whether lazy loading helps SEO goes into more detail.

The VPI tab handles Viewport Images. LiteSpeed says this service excludes above the fold images from lazy loading, and that Viewport Images are generated automatically in the background on QUIC.cloud servers. It uses the QUIC.cloud Page Optimization service, so it needs QUIC.cloud services switched on. We have Viewport Images and Viewport Images Cron turned on.

Database settings

Revisions Max Number: 5 and Revisions Max Age: 100. These sit on the DB Optimization Settings tab. LiteSpeed describes Revisions Max Number as the number of most recent revisions to keep when cleaning up revisions, and says revisions newer than the Revisions Max Age, in days, are kept. Both default to 0. We use 5 and 100 days so recent edits stay available while older copies can be cleared from the database. LiteSpeed says the Post Revisions clean up removes old revisions, and you can no longer restore the earlier versions, so take a backup first.

Which LiteSpeed settings are safe to start with, and which need a test?

Start with the low risk rows and move down the table. The risk column is our own judgement from using these settings on Divi, based on what LiteSpeed and Elegant Themes warn about.

Setting What it does Risk with Divi What to check after
Enable Cache Stores finished pages Low Edit a page, press Purge All, reload while logged out
Browser Cache Keeps static files on the visitor's device Low Reload in a private window after a style change
Image optimisation and WebP Makes image files smaller Low to medium Logos, sliders and background images
CSS Minify Removes spaces and comments from CSS Low Menus, buttons and fonts
Object Cache Uses Memcached or Redis from your host Low, if your host supports it Admin screens and logged out pages
CSS Combine Joins CSS files into one Medium Menus, fonts and page layout
Load JS Deferred Runs scripts after the HTML has loaded Medium Sliders, forms and the mobile menu
JS Minify Removes spaces and comments from scripts Medium Sliders, forms, popups and the mobile menu
Lazy Load Images and Iframes Loads media when it comes into view Medium The top image, maps and videos
Load CSS Asynchronously Loads CSS and HTML at the same time Medium Any flash of unstyled content
Guest Mode and Guest Optimization Serves first time visitors a default cached page Medium Server load and the real page in a private window
JS Combine Joins script files into one High The whole page, including icons and images

Which LiteSpeed settings help which Core Web Vital?

Google's web.dev guide to Core Web Vitals says a good experience means Largest Contentful Paint within 2.5 seconds, Interaction to Next Paint of 200 milliseconds or less, and Cumulative Layout Shift of 0.1 or less. It suggests measuring at the 75th percentile of page loads. Our post on Core Web Vitals in plain English explains each one.

The table maps those three measures to the settings above. The middle and right columns are our reading of how each setting behaves.

Measure Good threshold Settings likely to help Setting to watch
Largest Contentful Paint Within 2.5 seconds Enable Cache, image optimisation and WebP, Browser Cache Lazy Load Images on the top image
Interaction to Next Paint 200 milliseconds or less JS Minify trims script size, but check your plugin list too JS Combine
Cumulative Layout Shift 0.1 or less Add Missing Sizes, which LiteSpeed says adds missing width and height to local images when Lazy Load Images is on Load CSS Asynchronously if a page flashes unstyled

Why is my Divi site so slow after setting up LiteSpeed Cache?

A slow Divi site can have several causes, and caching only helps with some of them. Hosting, image weight and Divi's own performance options are worth checking as well as the plugin.

These are the places to look, in the order we would check them.

  1. Hosting. Elegant Themes says speed starts with picking a good hosting provider. Our post on why hosting matters for speed shows what to look for.
  2. Image weight. Elegant Themes' help page on slow Divi sites says the total image size on a page should be less than three megabytes.
  3. Divi's own performance options. Elegant Themes says the performance options, including Dynamic CSS and Critical CSS, sit under Divi Options, then General, then Performance, and are enabled by default. Check nobody has turned them off.
  4. Static CSS File Generation. The help page on slow sites also says to turn this on under Builder, then Advanced, in the Divi Theme Options.
  5. Defer jQuery. The same Elegant Themes page says you can turn this off if it causes problems.

If hosting, images, Divi's settings and LiteSpeed all need a look together, that is the kind of job our Technical SEO service covers.

What do you turn off if a LiteSpeed setting breaks your Divi page?

Turn off the newest change first, press Purge All and reload the page. The table shows where to look for each symptom. If a gap under the header stays after you purge, our guide to removing white space under the header in Divi shows how to find its cause.

What you see Setting to turn off first Then try
Layout broken, icons or images missing JS Combine Exclude the problem script on the Tuning tab
Page flashes unstyled before it settles Load CSS Asynchronously Test Divi's Critical CSS on its own
Menu, slider, form or popup stops working JS Minify Exclude the script that fails
Styles missing after combining CSS Combine Add the stylesheet to CSS Excludes
Top image appears late Lazy Load Images Retest with it off, then back on
Edits not showing Nothing to turn off Press Purge All, then clear your browser cache

If you cannot tell which setting is to blame, LiteSpeed's CSS and JS troubleshooting guide gives this routine.

  1. Open the page in a private window and add /?LSCWP_CTRL=before_optm to the end of the address. If the page still looks broken, the cause is outside LiteSpeed's optimisation settings.
  2. Under Page Optimization, set every CSS optimisation feature to OFF on the CSS Settings tab, then every JS optimisation feature to OFF on the JS Settings tab. Press Purge All under Toolbox, then Purge, and reload the page.
  3. If the page now looks right, turn on only the JS features, purge and check. If the page breaks, a JS file is the cause. If it does not, turn the JS features off, turn the CSS features on, purge and check.
  4. When one group breaks the page, list its files and enter them all in the CSS Excludes box on the Tuning - CSS tab, or the JS Excludes box on the Tuning tab, with the features on. Purge and check. Then remove one file at a time, purging and checking after each, and keep a file excluded if the page breaks without it.

How do you test whether the new settings helped?

Run the same page through PageSpeed Insights before and after, in a private window. Google's PageSpeed Insights documentation says field data captures real user experience over the previous 28 day collection period, while lab data is collected in a controlled environment and is useful for debugging.

That 28 day window means a change will not show in the field data straight away. Use the lab result to check that a setting did what you wanted, and read the field data a few weeks later.

Speed is worth the effort, but it is not a guarantee. Google's page experience guidance says Core Web Vitals are used by its ranking systems. It also says good scores do not guarantee that your pages rank at the top of Google Search results.

Worked example: a plumber in Watford

This is an invented example, not a client result. Imagine a plumber in Watford with a Divi site on LiteSpeed hosting. Their mobile report shows Largest Contentful Paint over the 2.5 second line, while the other two measures sit inside the good range.

They would start with image optimisation and Enable Cache, check the top image is not lazy loaded, and leave the JS settings alone. They retest the same page after each change and keep a note of what they changed.

Free call

Want more enquiries from Google?

Book a free call and we'll look at your site with you, then show you what's holding it back.

LiteSpeed Cache and Divi questions

Is LiteSpeed Cache good for Divi?

It can be, on a LiteSpeed server, as long as you test each setting. On our own Divi site we use the page cache, object cache, image optimisation, minify, CSS combine and lazy load options. JS Combine is the one that broke our pages, so we leave it off, and we suggest you leave it off until a test shows it is safe.

Do you need a LiteSpeed server to use LiteSpeed Cache?

The page cache is a LiteSpeed feature. LiteSpeed's documentation says you need LiteSpeed powered hosting or one of its server products to use LSCache. The plugin's WordPress.org page says the general features work on any web server, and that QUIC.cloud CDN allows sites on Apache or NGINX to use LiteSpeed caching. Ask your host which server you have.

Should JS Combine be on for Divi?

We keep it off. On our own Divi site, turning it on broke the formatting and stopped icons and images loading. Elegant Themes' 2023 speed guide also says Divi already minifies and combines its own JavaScript and CSS dynamically by default. If you want to try it, test one page first and keep a backup.

How do you use LiteSpeed Cache day to day?

Once it is set up, leave it alone and press Purge All under the Toolbox after big design changes. Purge All On Upgrade clears the cache when plugins, themes or WordPress core update. If a page still looks old, clear your browser cache and reload in a private window.

What counts as a fast Divi site?

Google's web.dev says a good experience means Largest Contentful Paint within 2.5 seconds, Interaction to Next Paint of 200 milliseconds or less, and Cumulative Layout Shift of 0.1 or less. It measures these at the 75th percentile of page loads. Check them in PageSpeed Insights for your own pages.

First Place SEO - Mobile PageSpeed Insights Score
Paul, SEO expert and founder of First Place SEO

About the Author: Paul

SEO expert and founder, First Place SEO

Paul is the founder of First Place SEO, an SEO agency in London that helps businesses across London, Hertfordshire, Essex and the rest of the UK get found on Google and in AI search. He started the business in January 2024 and looks after every client account himself. He reads the same Search Console and Semrush data as his clients and joins their monthly reviews. More about Paul

Specialises inSEOLocal SEOAI search optimisationWeb designGoogle Ads (PPC)

Speak to Paul

Want a second opinion on your SEO?

Book a free call and Paul will tell you what he'd fix first on your site.