The different Types of Website Caching and How to Clear Them

  1. Serverside Cache (plugin)00:46
  2. Browser Cache02:42
  3. CDN/Cloudflare04:56
  4. Hello Cache Episode05:57
  5. Understanding Caching and WordPress Part One06:05

Read the full episode transcript below:

00:31 David Blackmon: Hey everybody, welcome to another episode of WP the Podcast, brought to you by WP Gears. I’m David Blackmon.

00:35 Tim Strifler: And I’m Tim Strifler.

00:37 David Blackmon: Today we’re gonna talk about the different types of website caching and how to clear them. Tim, tell me what server side caching is.

00:46 Tim Strifler: Yeah, absolutely. So basically caching, and there’s different types of cache we’re gonna go through them, but most of the time when someone’s referring to caching, or clearing your cache, they’re probably talking about the server level cache. And so there’s different types or things that go into it, but essentially, high level overview. A WordPress website out of the box can load kinda slow because every time you load a page, it has to go to the database to check and get the most recent content, make sure that they have the content and then it builds it dynamically on the fly. Where when you install some sort of caching plugin, whether it’s a plugin itself or at the server level, then it will essentially take a copy of that page, so once the page loads once, it’ll take a copy of it, and then the next time that someone else visits that page, it’s gonna show them the copy instead of having to go and build the live one. And so that makes it load a lot quicker than having to go to the database on every single page load.

01:44 Tim Strifler: And so, there’s different ways to do server side caching, the most common is to use a WordPress caching plugin. In tomorrow’s episode we’re gonna talk about some of the best ones, so stay tuned for that. But essentially in terms of how to clear the cache, well if you’re using a caching plugin that you’re gonna need to use the built in functionality to clear the cache. So if you’re using Hummingbird, for example, they’re gonna have a clear cache button. If you’re using WP Rocket, and so they might have some different options. But that’s essentially what you’re looking for when someone says clear your cache, is to clear the cache of the plug in. If we’re using a host like WP Engine or Flywheel, they’re gonna have a control somewhere built into the install. Like WP Engine has their page within every WordPress install on their hosting, where you can go and you can clear cache, and it’s essentially the same thing, it’s just you don’t have any of the controls like you would with the caching plugin, ’cause it’s done at the server level.

02:42 David Blackmon: Next is a browser cache. So this is very simple, depending on the type of browser that you’re using. You’re gonna go into the browser history, and clear the cache. I gotta be honest, I hate doing this, because it always resets all of my damn passwords, and I have to re login to everything. I know there’s a checkbox that allows you to stay logged in, but it never seems to work for me, and I end up always clearing out everything. So occasionally you need to reset your browser cache, because even though you’ve cleared the server side cache, as Tim said, sometimes you still show a cached version, and you need to go in and just clear the browser cache. And a lot of times that’ll solve the problem for you. So depending on the browser you’re using, go to the history, and wipe it out. Clear all browsing data.

03:37 Tim Strifler: Yeah, and this exact thing actually happened yesterday to me and David for We had a new version of the homepage that was sent live, and our team told us, “Hey, uh it’s live, go check it out.” And we looked and it wasn’t. And so we went and we cleared the server side cache, okay we’re still seeing the old version. And then okay, it must be browser cache. And you can clear browser cache. Sometimes what I like to do is to see if it is browser cache, I’ll open up a new incognito window, a new private browsing window, depending, each browser calls it a little bit different. And that will basically show you a new session without any cache, or without any cookies, without anything like that. So then you can see that, okay I’m seeing the version I’m supposed to be seeing, in this incognito, private browsing session. Well then it must be browser cache then. Your non-incognito, your normal browser has a version of that page cached in it. And so browser cache can be annoying because it’s not easy to see if it is. But if you do that little hack where you either look in another browser entirely, that you haven’t been on that page in a while, or you do the incognito, private browsing, that way you can see right away.

04:56 Tim Strifler: The last type of caching is a CDN or Cloudflare, which Cloudflare’s kind of a CDN. And so a CDN will cache your images and your CSS and your JavaScript, and Cloudflare will do that as well. And so sometimes you do the server cache, the plugin cache, you do the browser cache, and you’re still seeing something that’s not quite right. And so, then you go to your CDN, or if you’re using Cloudflare, login to Cloudflare, and just go to the purge cache. And so Cloudflare has a setting where you can purge just a page, or you can purge the entire website cache. And that will make sure that they go and fetch new versions of the CSS, the images, anything that they’ve cached, and that way you’re gonna see the most recent version. I’ve had that happen a few times where everything else has been cleared, and I’m still seeing the old version, and it gets hung up in Cloudflare. And so that’s kinda the final step.

05:57 David Blackmon: And we’re gonna put a couple of links in our show notes, because our good friends over at Hello, WP! Podcast did an awesome episode called, Hello Cache. That’s the WPMU DEV team in case you’re wondering, and they also have another blog post written, Understanding Caching and WordPress Part One. We’re gonna link to those couple of the podcast episode obviously, we highly recommend listening to the podcast, it’s awesome. And check out the blog post if you wanna know more about cache. Tomorrow we’re gonna talk about the best WordPress caching plugin for 2019. Tim, until tomorrow, we’ll see you then.

06:42 Tim Strifler: Take care, bye bye.

Did you Enjoy this Episode?

  • Will you consider sharing it online? Just click one of the share buttons below!
  • Will you leave us a review? 🙂
  • Have a question, or a topic request? Let us know in the comments below!

Want to Connect with David & Tim?

Submit a Comment

Your email address will not be published.

Where To Find Us

Listen to WP The Podcast on your favorite platform: