Did you know: Enable content expiration in IIS 7 / 7.5

by Vivek 12/13/2009 10:18:00 PM

When you want Web site content to expire automatically such that no obsolete information is cached at the proxy or Web browsers you configure Content expiration in IIS at the Web site level.

In IIS 6.0

  1. Right click on Web Site (Default Web Site in our case) and click on Properties
  2. Under HTTP Headers tab you can check Enable content expiration


In IIS 7 / 7.5

  1. Click on the Web Site (Default Web Site in our case)
  2. In the Features View, double click HTTP Response Headers
  3. Click on Set Common Headers… in Actions panel
    or Right click in the HTTP Response Headers Feature Page and click Set Common Headers…
  4. You can check Expire Web content: to enable content expiration


NOTE: In IIS_schema.xml, under system.webServer/staticContent under clientCache



I have enabled Expire Web content and set it to Immediately. You will see the following in the webServer setting in the web.config of the Web site.

<clientCache cacheControlMode="DisableCache" />

Hope this helps,
Vivek Kumbhar

Quote of the day:
Consistency requires you to be as ignorant today as you were a year ago. - Bernard Berenson

Tags: , ,

Did you know | IIS | Web Server

blog comments powered by Disqus