IIS7: Set expires header on favicon

iis-7

I know how to set expires headers for whole directories, but how do I set an expires header for an individual file – e.g. the favicon.ico file in the root directory?

Best Answer

It appears that you need to use a custom developed HttpModule to do this. Here is a similar question from StackOverflow about this. It doesn't look like there is anything built in.

IIS7: Setting far future expires header on specific files