How to change the HTTP GZIP Compression Level for Dynamic Content in IIS7?
9,985
You need to set it in the compression scheme:
http://www.iis.net/ConfigReference/system.webServer/httpCompression/scheme
for example to set it in gzip using AppCmd:
appcmd.exe set config -section:system.webServer/httpCompression /[name='gzip'].dynamicCompressionLevel:"5" /commit:apphost
Related videos on Youtube
Author by
Alexander Konstantinov
Updated on September 17, 2022Comments
-
Alexander Konstantinov almost 2 years
I would like to change the HTTP GZIP compression level in IIS7 from 0 to 4 as mentioned in these articles:
- http://weblogs.asp.net/owscott/archive/2009/02/22/iis-7-compression-good-bad-how-much.aspx
- http://blog.stackoverflow.com/2009/08/a-few-speed-improvements/
However I cannot see any reference in them (or http://www.iis.net/ConfigReference/system.webServer/httpCompression) on how to change the compression level from 0 - 10.
The compression page in IIS only has tick-boxes to enable/disable dynamic and static compression.
My Web.config file has the line:
Please can you tell me how I can do this?
-
Adam Yarger almost 14 yearsBy the way, one easy way is using Configuration Editor which will show you all the properties, and it can generate the scripts to set that (that is how I generated the AppCmd command above)
-
Alexander Konstantinov almost 14 yearsHi CarlosAg, I have installed the Configuration Editor and have it open. In section system.webServer/urlCompression. Where is the option to set the level of compression? Many thanks.
-
Adam Yarger almost 14 yearsLevel of compression is set in system.webServer/httpCompression inside the collection, specific to the compression used (see above)