Toolbox

Purge Tab

Once you have LiteSpeed Cache for WordPress configured and customized to your liking, you can turn your attention to managing the cache itself. Ideally, there should be very little actual cache management required. If you set your configuration correctly, the cache should function like a well-oiled machine.

Still, there are times when you might want to take matters into your own hands for whatever reason. This section will help you to successfully manage your cache manually.

!LSCWP Toolbox Section Purge Tab

Purge Front Page

Press this button to purge only the front page of your site.

Multi-site: pressing this button in the network admin will result in only the main site’s front page being purged.

Purge Pages

This button will purge all cache entries that belong to pages. Don’t let the use of the word “page” confuse you here. For this button (and this button only) “page” refers to the WordPress Page post type. Everywhere else, “page” is used in the context of individual entries in a “full-page cache.”

Purge Error Pages

These buttons allow you to purge 403, 404, and 500 error pages.

Multi-site: If one of these buttons is pressed in the network admin, the main site's error pages will be purged.

Purge All - LSCache

This button will purge all cache entries related to the current WordPress installation. This means that if a page is cached on the site using a different web application (for instance, a separate WordPress blog or a XenForo forum), it will not purge those cache entries.

If you have the crawler running, the Purge All button will also purge any crawled pages and reset the sitemap.

Multi-site: pressing this button in the network admin will trigger the "Purge All - LSCache" functionality on all of the network’s sites.

Purge All - CSS/JS

This button will purge all of the minified and combined JavaScript and CSS files that were cached as a result of the settings in the Optimize tab.

Purge All - Opcode Cache

This button clears the opcode cache, not to be confused with LSCache, which is a separate thing. Opcode cache stores compiled PHP code, not complete pages.

Purge All

This button combines all other "Purge All" buttons. It purges everything, with a couple exceptions: it does not purge Critical CSS or LQIP Placeholders.

Empty Entire Cache

This is one of those buttons that should only be used when you have a problem that can’t be solved any other way. Press it to purge all of the cache entries for the entire site, including those entries from other web applications.

Multi-site: this option is only made available in the network admin. Individual site admins do not have the ability to clear the entire cache.

Purge By...

This area allows you to purge a list of pages. The available list types are: Category, Post ID, Tag,and URL. The list of the selected type should be input one-per-line in the text area above the Purge List button.

Import/Export Tab

Use these functions to backup your LiteSpeed Cache for WordPress configuration to a local file, or restore it from one.

Situations where this would come in handy:

  • You are making an experimental change. Save your original configuration so that you may restore it if your experiment doesn't go well.
  • You are moving from a development server to a live one.
  • You are migrating your installation to a new host.
  • You manage several WP sites and you'd like to cache them all with the same settings.

Note

If you export from one server and import into another, you will need to manually update any server-specific settings. For example, Crawler > General Settings > Server IP, and CDN > Original URLs. There may be other settings that vary from server to server, so have a quick look at all of the settings after you import!

!LSCWP Toolbox Section Import Tab

Export Settings

Simply press the Export button. A data file will be created and saved on your local device. The next time you visit the Import/Export page, you will see a Last exported section that reminds you of the name of the most recently exported file and how long ago it was saved.

Import Settings

Press the Choose File button to select a previously exported data file, and press Import. LSCWP will read the data file and replace all of your existing settings with the settings in the file.

Please be careful with this! If you accidentally overwrite settings you meant to keep, there is no way to restore them, unless you have a sufficient backup system in place.

Reset All Settings

If you'd like to start over with the default LSCache settings, press the Reset button. Be careful, though. Resetting your settings is permanent. We suggest you Export your settings first, before you Reset.

Edit .htaccess Tab

!LSCWP Toolbox Section Edit .htaccess Tab

Both LiteSpeed & Apache Web Servers can use a .htaccess configuration file that is unique for each domain.

Info

This tab is moved to the Network Admin screen when used with a multisite network

.htaccess Path Settings

LSCWP can autodetect the location of your .htaccess file for both the frontend and backend of your site. If autodetection is not working for you, you can specify the file locations here.

Current .htaccess Contents

If you are an advanced user with experience modifying Apache configuration files, you may wish to make changes directly to your .htaccess file. This section allows you to easily access the file, make your changes, and save them.

LSCWP modifies .htaccess for you when you adjust certain settings within the LSCWP configuration. You can also view those entries here to confirm that other plugins haven't modified them. If so then we recommend that you just use the tabs in LiteSpeed Cache to save your changes again, and leave this file alone.

Warning

Any changes made to .htaccess may break the site. Please, if you are unsure of what you are doing, consult your host or server admin before you proceed.

The contents of your .htaccess file are displayed in the Current .htaccess Contents text box. You are free to edit the contents as you wish. Press the Save button to commit your changes. This cannot be undone, so please take care.

Heartbeat Tab

You may disable or adjust WordPress' interval heartbeats to reduce server load, but be careful. Messing with these settings may cause WP tasks triggered by AJAX to stop working.

!LSCWP Toolbox Section Heartbeat Tab

Frontend Heartbeat Control

OFF

Turn this option ON to use heartbeat control on the WordPress frontend.

Frontend Heartbeat TTL

60

You can adjust the heartbeat interval to suit your needs. Frontend Heartbeat Control must be set to ON for this TTL to take effect. Choose any number of seconds between 15 and 120. Set to 0 to disable this heartbeat.

Backend Heartbeat Control

OFF

Turn this option ON to use the heartbeat control in WP-Admin.

Backend Heartbeat TTL

60

You can adjust the heartbeat interval to suit your needs. Backend Heartbeat Control must be set to ON for this TTL to take effect. Choose any number of seconds between 15 and 120. Set to 0 to disable this heartbeat.

Editor Heartbeat

OFF

Turn this option ON to use the heartbeat control in the WordPress editor.

Editor Heartbeat TTL

15

You can adjust the heartbeat interval to suit your needs. Editor Heartbeat Control must be set to ON for this TTL to take effect. Choose any number of seconds between 15 and 120. Set to 0 to disable this heartbeat.

Report Tab

!LSCWP Toolbox Section Report Tab

If someday you encounter a problem that requires support, we may ask to see your Environment Report. The Report tells us what settings you have enabled, what other plugins you have installed, and the contents of your .htaccess file, among other useful things.

Press the Send to LiteSpeed button.

A copy of the report will be sent to us, and if you post in a public forum, you can refer to the report simply by the Report Number shown. We'll be able to look it up from that.

You needn't wait for us to request this report, either. If you'd like to be proactive, you may include it any time you ask a support question.

Debug Settings Tab

!LSCWP Toolbox Section Debug Tab

Info

This tab is moved to the Network Admin screen when used with a multisite network

Disable All Features

OFF

Turn this option ON if you need to debug your site without any caching or optimization features getting in the way. When your testing is finished, be sure to turn Disable All Features back OFF, or your site will not be cached or optimized.

Debug Log

OFF

This enables/disables the debug log. The log will be written to wp-content/debug.log and can be viewed in the LiteSpeed Cache > Toolbox < Log View tab.

Admin IPs

127.0.0.1

This should be a comma delimited list of admin IPs. Admin IPs are used for debugging and admin purging purposes. When a request comes in with the admin IP, it is possible to purge front end pages using just a LSCWP_CTRL query string. More information can be found here.

Debug Level

Basic

This setting determines how detailed of a log to keep.

Log File Size Limit

3

Specify the maximum size of the log file. Minimum is 3MB. Maximum is 3000MB.

Log Cookies

OFF

Log request cookie values.

Collapse Query Strings

OFF

Shorten query strings in the debug log to improve readability.

Debug URI Includes

empty string

URIs listed here, one per line, will be compared to th REQUEST_URI server variable and only those that match will be logged. To indicate the beginning of a string, add ^ to the beginning of the string. To do an exact match, add $ to the end of the string.

String Matching Examples

Assume you have the following URIs:

  1. /recipes/baking/
  2. /recipes/baking/cakes
  3. /recipes/baking/brownies
  4. /popular/recipes/baking/

The string /recipes/baking/ will match all four URIs.

The string /recipes/baking/$ will match #1 (because $ indicates exact match).

The string ^/recipes/baking will match #1, #2, and #3 (because ^ indicates the beginning of the URI).

Debug URI Excludes

empty string

URIs listed here, one per line, will be compared to th REQUEST_URI server variable and only those that do not match will be logged. To indicate the beginning of a string, add ^ to the beginning of the string. To do an exact match, add $ to the end of the string.

Log View Tab

!LSCWP Toolbox Section Read Log Tab

One of the most useful tools in your arsenal, when it comes to troubleshooting, is the debug log. You can enable logging via in the LiteSpeed Cache > Toolbox < Debug Settings tab.

Once logging is enabled, you can view the log here in this tab.

!

If the log contains too many older entries, press the Clear Log button to erase all but the most recent set of entries.

If you don't see information relevant to the problem you are experiencing, try to reproduce the problem while debugging is enabled, then come back to this page to see the result.

Copy the most relevant lines (or the most recent lines, if you are unsure what is relevant) from the log and share them with LiteSpeed support, if necessary.

Be sure to turn the debug log off, if you no longer need it, as it can grow quickly.

Info

This tab is moved to the Network Admin screen when used with a multisite network

Beta Test Tab

!LSCWP Toolbox Section Beta Test Tab

This area gives you the opportunity to try versions of LSCWP not yet released officially to the public. Simply enter the GitHub commit URL into the text field and press the Upgrade button.

The Use latest GitHub commit button uses the most recent commit.

The Use latest WordPress release version button uses the official current release. Use this button to stop beta testing and go back to the latest version from the Plugin Directory.

Info

This tab is moved to the Network Admin screen when used with a multisite network. You may need to manually enter the /wp-admin/ address and/or network activate LSCWP again after upgrading.


Last update: August 7, 2020