Get 30% off your WordPress Hosting with code WPSAVE10. Launch Faster. Save More!
  • 00 Days
  • 00 Hours
  • 00 Minutes
  • 00 Seconds

How to force a cache MISS - SIRSTEVEHQ CP

You can ensure a webpage doesn't cache at the CDN nodes by setting a cache-control header through a .htaccess file. For example, to avoid a webpage caching altogether, you can simply add the following rule into the .htaccess file of the directory of the page being loaded:

# DISABLE CACHING
Header set Cache-Control: no-store

You'll then need to purge the entire cache for the changes to take effect.

To choose specific file types you can add the following to the same .htaccess instead:

<filesMatch ".(jpg|jpeg|png|gif|ico)$">
Header set Cache-Control: no-store
</filesMatch>

To disable cache for a particular file, i.e. login.php, you can add the following instead:

<Files login.php>
Header set Cache-Control: no-store
</Files>

For multiple files, you'd just add two rules.

<Files login.php>
Header set Cache-Control: no-store
</Files>
<Files hello.php>
Header set Cache-Control: no-store
</Files>
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Why are my images not being converted to WEBP format? - SIRSTEVEHQ CP

The SIRSTEVEHQ Web Optimisations allow you to quickly and easily optimise resources on your...

Does the SIRSTEVEHQ CDN perform cache warming?

Yes. The SIRSTEVEHQ CDN performs cache warming to ensure cached pages are served as frequently as...

CDN Security Headers - SIRSTEVEHQ CP

Using HTTP security headers can improve website and application security and protect against...

Do I need caching plugins in addition to the SIRSTEVEHQ CDN?

The short answer is no, the SIRSTEVEHQ Content Delivery Network takes care of caching for you....

How do I create a Website Acceleration Suite template? - SIRSTEVEHQ CP

There are over 40 settings in the Website Acceleration Suite that can make your site load faster....