Today we start a new series called “How to…?” with Dave from Divi Engine. The first instalment is how to clear your cache for your Divi website. Watch the video below and some further reading under that if you require more information.
What is cache?
Website caching can be one of the best and most annoying tools you can have for your website. In short cache makes your website quicker. Cache can be seen as memory, it remembers images and scripts so next time the visitor comes to your website it does not need to download them again (or make it much quicker) so therefore the page load becomes significantly quicker.
What types or cache are there?
When working on your Divi website there are a few different types of cache to think of.
1) Browser cache
The browser cache is what your, or your visitors, browser (Chrome, Safari, Firefox etc) stores. It will remember for example the CSS file so next time you visit the site it will load this CSS file much quicker.
To clear the cache you will physically have to go into the browser settings and clear it (see video) – but what happens when your visitors come to the site, how do you show them the latest CSS file for example without asking them to manually clear the cache? We show you have to setup a dynamic child theme which will force the browser to clear the cache when a new version of the file has been uploaded or saved.
2) Page cache
So page caching is quite clever – what happens is when visitor “A” comes along, the request is sent and the website is built in the browser. When you have page cache running, the content is then saved on the server so that when the next person comes to visit the site, it will serve this cached version. When visitor “B” comes, the page cache sends the previously cached version so the website does not need to be built from scratch again.
There are a number of plugins that help you with page caching, our favourite is WP Fastest Cache. As you can see in the video there is a setting to clear or purge your cache. This will clear the stored version of the website so that it will need to be re-built again.
3) Divi builder cache
The third form of caching that you might come across is the Divi builder cache. When using the builder to change the appearance of your site, for example changing the colour of your buttons, the Divi builder will create a cached version of your settings. This cached version will then be served to the visitor.
To clear this cache you need to go to Divi > Theme Options > Builder > Advanced and clear the “Static CSS File Generation”. We disable this as we, and many of our customers have the same problem, have seen issues where it won’t serve any of the appearance changes you made until you clear the cache in the settings. This is obviously not ideal as it could be days before you realise. We therefore disable this but you can leave it on if it is working for you.
There are still more examples of cache which we did not talk about in the video such as server and CDN cache but these are for another day and have not experienced many issues when moving sites and needed to clear the cache to see the changed domain or changes.
We hope this has been helpful and like always, any questions please let us know.