Provided that all caches in the path will obey these directives, this is the way you can do it.

When an item is fully cached, the browser may choose to not contact the server at all and simply use its own cached copy: For instance, once CSS stylesheets from your application are downloaded by the browser there’s no need to download them again during the user’s session.

This holds true for many asset types like javascript files, images and even infrequently changing dynamic content.

If you specify this command, Google will not save the page and the page will be unavailable via its cache.

Sometimes you want to avoid caching of your website, maybe you are developing it and you want to see the fresh copy each time you hit reload.

header is the most important header to set as it effectively ‘switches on’ caching in the browser.

With this header in place, and set with a value that enables caching, the browser will cache the file for as long as specified.Without this header the browser will re-request the file on each subsequent request.simply sets a date from which the cached resource should no longer be considered valid.- may be cached but not archived The directive CACHE-CONTROL: NO-CACHE indicates cached information should not be used and instead requests should be forwarded to the origin server.This directive has the same semantics as the PRAGMA: NO-CACHE.However, incorrect caching can cause users to see out-of-date content and hard to debug issues.