Cloud Service >> Knowledgebase >> WordPress >> How To Clear WordPress Cache?
submit query

Cut Hosting Costs! Submit Query Today!

How To Clear WordPress Cache?

Clearing the cache in WordPress is essential for troubleshooting, ensuring that the latest changes are visible to visitors, and improving website performance. Caching stores copies of files or data to serve them more quickly, but sometimes you need to clear the cache to ensure the latest version of your site is displayed. Here's how to clear different types of caches in WordPress:

1. Clear Cache Using a Caching Plugin

If you're using a caching plugin in WordPress, it likely has a built-in option to clear the cache.

Common Caching Plugins:

WP Super Cache

W3 Total Cache

WP Rocket

LiteSpeed Cache

Steps to Clear Cache in Common Plugins:

WP Super Cache:

Go to Settings > WP Super Cache.

Click the Delete Cache button.

W3 Total Cache:

Go to Performance > Dashboard.

Click the empty all caches button.

WP Rocket:

Go to Settings > WP Rocket.

Click on the Clear Cache button.

LiteSpeed Cache:

Go to LiteSpeed Cache > Dashboard.

Click Purge All.

2. Clear Browser Cache

Sometimes, the issue might not be with the server or WordPress caching but with your browser's cache. Clearing your browser cache ensures that you see the latest version of your website.

Steps to Clear Browser Cache:

Google Chrome:

Click the three-dot menu in the top-right corner.

Go to More Tools > Clear Browsing Data.

Choose Cached images and files.

Click Clear data.

Mozilla Firefox:

Click the three-line menu in the top-right corner.

Go to Settings > Privacy & Security.

Under Cookies and Site Data, click Clear Data.

Select Cached Web Content and click Clear.

Safari:

Go to Safari > Preferences.

Click on the Advanced tab.

Check Show Develop menu in menu bar.

Go to the Develop menu and select Empty Caches.

3. Clear Server Cache

Some web hosting providers implement server-level caching that you can manage through your hosting control panel.

Common Server Caching Solutions:

cPanel:

Log in to your cPanel account.

Look for a caching option under the Advanced section (e.g., Cache Manager).

Clear the cache from here.

Managed WordPress Hosting (e.g., CyfutureCloud, Go4hosting, CloudOYE):

Log in to your hosting account dashboard.

Find the caching section (often under Tools or Performance).

Use the provided option to clear the cache.

4. Clear CDN Cache (if applicable)

If you're using a Content Delivery Network (CDN), you may need to clear the cache at the CDN level.

Steps to Clear CDN Cache:

Log in to your account.

Go to the Caching tab.

Click Purge Everything to clear all cached content.

Other CDNs:

Each CDN has a similar option to clear the cache. Check your CDN provider's documentation for specific instructions.

5. Clear Object Cache (Database Cache)

If you’re using a plugin or a hosting environment that uses object caching (like Memcached or Redis), you might need to clear the object cache.

Steps:

W3 Total Cache:

Go to Performance > Dashboard.

Click empty all caches.

Object caching is usually handled by the host or an additional plugin; consult your cloud hosting provider’s instructions if you’re using an object cache.

6. Clear Opcode Cache (Advanced)

If your server uses an opcode cache like OPcache, you may need to clear it via the command line or through your hosting control panel.

Steps:

Via cPanel:

Log in to cPanel.

Look for PHP Selector or PHP Configuration.

If available, you might find an option to clear OPcache.

Via Command Line (requires SSH access):
bash
Copy code
sudo service php7.x-fpm reload

 

Replace 7.x with your version of PHP.

Final Step: Verify the Site

After clearing the cache, revisit your WordPress site to ensure that the changes are reflected. You can also use a different browser or an incognito/private browsing window to check if the changes are visible.

Clearing the cache at different levels ensures that any outdated content is removed, and the most recent version of your WordPress site is served to your visitors.

Cut Hosting Costs! Submit Query Today!

Grow With Us

Let’s talk about the future, and make it happen!