Why Your Developer Keeps Telling You to “Hard Refresh” Your Browser?

Abstract depiction of emptying cache.

As a website owner or user, you might have heard a developer say, “Try a hard refresh!” But what does that mean, and why is it necessary? In this article, we’ll explore the concept of caching, why it’s important, and how a hard refresh helps resolve certain issues.

Skip the background, tell me how to do it!

What is a cache, and why is it important?

A cache (pronounced “cash” or “caysh”) is a storage mechanism used by your web browser to save copies of website files, such as images, stylesheets, and scripts, on your device. Caching serves a vital purpose:

  • Speeds Up Loading Times: Instead of downloading files from the server every time you visit a site, the browser can use files stored locally. This results in faster page loads.
  • Reduces Server Load: With fewer requests going to the server, websites can handle more users simultaneously.
  • Improves User Experience: Websites appear to load more smoothly, and frequently accessed pages are displayed quickly.
  • While caching improves web performance, it can sometimes cause problems when a website is updated.

When the cache becomes a problem

When developers make changes to a website, such as fixing bugs, updating content, or redesigning a layout, the updated files need to replace the older, cached ones. However, browsers don’t always fetch the newest version of these files. Instead, they rely on the cached versions, leading to issues like:

  • Seeing outdated content.
  • Broken functionality due to mismatched code.
  • Missing or incorrect visual elements.

In these cases, performing a hard refresh ensures the browser ignores the cached files and loads the latest ones directly from the server.

Why does using a new browser or an Incognito/Private window solve this?

When you open a new browser or switch to incognito/private mode, the cache is empty for that session. This forces the browser to fetch the latest files from the server. However, this isn’t always a convenient solution, especially if you’re logged into an account or using cookies to save preferences. In those cases, a hard refresh is a quicker and easier fix.

Hard Refresh vs Clearing Cache

What’s a Hard Refresh?

A hard refresh forces your browser to reload the page and bypass the locally cached version of that specific page’s files (like CSS, JS, and images).

When Should You Use the Hard Refresh or Clear Cache Method?

  • Hard Refresh – When a site looks broken or hasn’t updated visually (e.g. styles not loading) after changes.
  • Clear Cache – When repeated hard refreshes don’t work, or you’re debugging multiple sites that may be using cached files (especially useful for developers and testers).

How to perform a hard refresh

The steps for a hard refresh vary depending on your browser and operating system. Here’s a handy guide:

Google Chrome

  • Windows/Linux: Press Ctrl + F5 or Shift + Ctrl + R
  • Mac: Press Command + Shift + R.

Mozilla Firefox

  • Windows/Linux: Press Ctrl + F5 or Shift + Ctrl + R
  • Mac: Press Command + Shift + R

Microsoft Edge

  • Windows/Linux: Press Ctrl + F5 or Shift + Ctrl + R

Safari

  • Cmd + Option + R

Clearing Cache

Clearing the cache completely wipes all locally stored files (HTML, CSS, images, JavaScript) from the browser for all websites (or a selected time range).

What it does:

  • Permanently removes all cached data.
  • Affects all sites, not just the one you’re viewing.
  • Useful when updates aren’t reflecting due to persistent cache, even after a hard refresh.

How to Clear Cache in Desktop Browsers

Google Chrome

  1. Click the three dots (top-right corner).
  2. Go to Settings > Privacy and security.
  3. Click Clear browsing data.
  4. Under the Basic tab:
    • Select Cached images and files.
    • (Optional: Deselect history & cookies if you only want to clear cache.)
  5. Choose a time range (e.g. All time), then click Clear data.

Safari (macOS only)

Safari doesn’t have a native Windows version anymore.

  1. Open Safari.
  2. In the top menu, click Safari > Settings (or Preferences).
  3. Go to the Advanced tab and tick “Show Features For Developers” – it’s all the way at the bottom of that window. After this is checked, close the settings.
  4. In the top menu, click Develop > Empty Caches.

Alternatively:

  • You can also use Command + Option + E as a shortcut to empty the cache.

Microsoft Edge

  1. Click the three dots (top-right corner).
  2. Select Settings > Privacy, search, and services.
  3. Scroll to Clear browsing data and click Choose what to clear.
  4. Tick Cached images and files.
  5. Choose the time range (e.g. All time) and click Clear now.

Mozilla Firefox

  1. Click the three lines (top-right corner).
  2. Select Settings > Privacy & Security.
  3. Scroll to Cookies and Site Data.
  4. Click Clear Data….
  5. Tick Cached Web Content, then click Clear.

Mobile Browsers

iOS (iPhone/iPad) browser caches can be notoriously “sticky” as in, you can clear the cache and you STILL see the old version of files. Why is a mystery that only Apple can answer.

In iOS rather than clearing a cache, we often find it’s easier to simply open an incognito or private browsing window instead, as this loads files afresh (as long as you completely close your private browsing session in-between reloads).

Open a Private Browsing Window on iOS

Load a website in Safari (iPhone/iPad) Private Browsing Mode

  1. Open the Safari app.
  2. Tap the Tabs icon (two overlapping squares) in the bottom-right corner.
  3. Tap [x] Tabs or Start Page at the bottom centre to reveal tab groups.
  4. Select Private.
  5. Tap the + icon to open a new private tab.

Safari will turn the UI dark to indicate you’re in Private mode.

Chrome (iPhone/iPad) – Incognito Mode

  1. Open the Chrome app.
  2. Tap the three dots in the bottom-right corner.
  3. Tap New Incognito Tab.
  4. A new tab will open with a dark theme and the πŸ‘€β€πŸ•΅οΈ icon, indicating you’re in Incognito mode.

Tip: You can switch between regular and Incognito tabs using the tab switcher icon.

If you’re on iOS and feeling lucky, these are the steps to clear your cache.

Clear Browser Cache on iOS

Safari (iPhone/iPad)

  1. Open Settings on your iOS device.
  2. Scroll down & tap Safari.
  3. Tap Clear History and Website Data.
  4. Confirm when prompted.

Note: This clears cookies and browsing history too, – there’s no way to clear a cache alone in Safari.

Chrome (iPhone/iPad)

  1. Open the Chrome app.
  2. Tap the three dots at the bottom-right corner.
  3. Tap History > then Clear Browsing Data.
  4. Select Cached Images and Files (you can deselect others if you don’t want to remove them).
  5. Tap Clear Browsing Data, then confirm.

Clear Browser Cache on Android

Chrome (Android)

  1. Open the Chrome app.
  2. Tap the three dots (top-right corner).
  3. Tap the ‘i’ (info) icon next to “History” or go directly to Settings.
  4. Tap Privacy and security > then Clear browsing data.
  5. Select a time range (e.g., “All time”).
  6. Tick Cached images and files (you can untick others if needed).
  7. Tap Clear data, then confirm.

Samsung Internet

  1. Open the Samsung Internet app.
  2. Tap the menu icon (three horizontal lines or dots) > Settings.
  3. Tap Privacy > Delete browsing data.
  4. Select Cached images and files (and any others if you want).
  5. Tap Delete data, then confirm.

Have a new project or just want to say hello?