✅ IIS-Only Performance Optimization Settings (Complete List)
1. Application Pool Settings (IIS Core)
✔ Start Mode
- AlwaysRunning
→ Avoid cold starts.
✔ Idle Time-out
- Increase or disable (
0) if you want warm apps.
Default (20 min) causes unexpected pool shutdown.
✔ Worker Process Settings
- Maximum Worker Processes
- Keep 1 (no web garden) for ASP.NET/Core.
- Web gardens only for stateless apps.
- Queue Length
- Increase from default 1000 to 5000–20000 depending on load.
Prevents 503 (Queue full) errors.
- Increase from default 1000 to 5000–20000 depending on load.
✔ Recycling Settings
- Disable Regular Time-Based Recycling
Stops unnecessary restarts. - Enable Overlapped Recycling
Zero-downtime recycling. - Disable application pool recycling at idle
(set Idle Time-out to 0).
2. Site-Level Performance Settings
✔ Connection Limits
- connectionTimeout
- maxConnections
- Keep-alive enabled.
✔ HTTP/2 & HTTP/3
- Enable HTTP/2 (and HTTP/3 on Windows Server 2022+) for higher throughput.
✔ Compression
(IIS → Compression feature)
- Enable Static Compression
- Enable Dynamic Compression
- Ensure compression for:
- text/html
- text/css
- application/javascript
- application/json
✔ Caching (Output Caching / Kernel Caching)
(IIS → Output Caching)
- Enable Kernel Caching (huge perf win for static files)
- Enable Output Caching for dynamic pages (if safe)
- Configure:
- Cache duration
- Vary-by rules
3. Static File Handling Settings
✔ Static Content
- Enable staticContent module
- Set cache-control headers (long max-age)
- Enable ETags or Last-Modified
- Make sure static file module is above ASP.NET modules.
4. IIS Modules Management (Pipeline)
✔ Disable/Remove Unused Modules
Huge performance improvement because every module executes per request.
Disable modules like:
- WebDAV
- ASP
- PHP (if not used)
- CGI
- ISAPI Filters
- Session State
- Windows Authentication (if not needed)
- Request Filtering (if handled by reverse proxy)
Goal: Lightest possible request pipeline.
5. Request Filtering (Limits)
✔ Max Request Size
- Tune maxAllowedContentLength
- Tune maxRequestLength
✔ URL Length Limits
- Prevent long-URL attacks.
✔ Header Limits
- Tune header size limits.
All these reduce bad requests hitting Kestrel or app layer.
6. Logging Settings
✔ W3C Logging
- Disable unnecessary fields
- Keep logs on separate fast disk
- Avoid logging ALL headers (expensive)
✔ Failed Request Tracing (FREB)
- Only enable for targeted diagnostics
- Turn off afterward
7. Application Initialization (Warm-Up)
(IIS → Configuration Editor → system.webServer/applicationInitialization)
- DoAppInitAfterRestart = True
- PreloadEnabled = True
This ensures app is warm and ready before first user hit.
8. Dynamic IP Restrictions (DoS protection)
Not directly performance but prevents IIS from being overwhelmed.
- Enable Dynamic Deny based on:
- Request rate
- Concurrent requests
- Bad requests
9. WebSockets / Long-Running Connections Settings
- Enable only if needed.
- Disable WebSockets for performance if app does not use them.
10. Client Keep-Alive Settings
- Keep-alive enabled
- Keep-alive timeout tuned (15–120 seconds depending on use)
11. Centralized Configuration That Impacts Performance
✔ applicationHost.config
Key performance elements:
<system.webServer/serverRuntime uploadReadAheadSize="…"><system.webServer/security/requestFiltering><system.webServer/httpCompression><system.webServer/webSocket><system.webServer/cache>
12. Kernel-Mode Optimizations (HTTP.sys)
(These are still considered IIS-level because IIS sits on top of HTTP.sys)
✔ Enable Kernel Caching
→ Boosts static file performance massively.
✔ Set MaxBandwidth & MinFileBytesPrSec
→ Prevents slow clients from consuming server I/O.
✔ Enable URL ACL Tuning
→ Helps reduce request overhead.
🎯 FINAL OUTPUT
Exact list of IIS settings that impact performance:
App Pool
- AlwaysRunning
- Idle Timeout
- Recycling settings
- Maximum Worker Processes
- Queue Length
Compression
- Static compression
- Dynamic compression
Caching
- Kernel caching
- Output caching
- Static file caching
Modules
- Disable unused modules
- Optimize pipeline
Request filtering
- maxRequestLength
- maxAllowedContentLength
- URL/header limits
Connection settings
- connectionTimeout
- maxConnections
- Keep-alive
HTTP/2 / HTTP/3
- Enable
Logging
- Trim fields
- Optimize log location
Application Initialization
- PreloadEnabled
- DoAppInitAfterRestart
Static file handling
- cache-control headers
- ETags
- Last-Modified
Dynamic IP Restrictions
- Enable rate limiting
HTTP.sys kernel settings
- uploadReadAheadSize
- MinFileBytesPerSec
- MaxBandwidth
Here is the exact location of every IIS performance optimization setting — which GUI blade, which config file, or which PowerShell command you must use.
✅ 1. Application Pool Settings (All performance-critical)
1.1 Start Mode → “AlwaysRunning”
Where to configure:
- IIS Manager → Application Pools
- Select your App Pool → Advanced Settings
- Start Mode = AlwaysRunning
Config file:
applicationHost.config
<applicationPoolDefaults ... startMode="AlwaysRunning" />
Code language: HTML, XML (xml)
1.2 Idle Timeout
Where:
- IIS Manager → Application Pools → Your Pool → Advanced Settings
- Idle Time-out (minutes) → Set to 0 for performance-sensitive apps
Config:
<processModel idleTimeout="00:00:00"/>
Code language: HTML, XML (xml)
1.3 Recycling Settings
Where:
IIS Manager → Application Pools → Your Pool → Recycling…
Disable:
- Regular Time Interval
- Specific Time
- Memory-based recycling unless required
Config:
<recycling periodicRestart>
<schedule />
</recycling>
Code language: HTML, XML (xml)
1.4 Queue Length
Where:
IIS Manager → Application Pools → Your Pool → Advanced Settings
- Queue Length = 5000–20000
Config:
<applicationPoolDefaults queueLength="20000" />
Code language: HTML, XML (xml)
1.5 Maximum Worker Processes
Where:
IIS Manager → Application Pools → Your Pool → Advanced Settings
- Maximum Worker Processes = 1 (no web garden)
Config:
<processModel maxProcesses="1" />
Code language: HTML, XML (xml)
✅ 2. Site-Level Settings
2.1 connectionTimeout + Keep-Alive
Where:
IIS Manager → Sites → Select Site → Limits…
You can configure:
- Connection timeout
- Max connections
Config:
<limits connectionTimeout="00:02:00" maxConnections="100000" />
Code language: HTML, XML (xml)
2.2 Enable HTTP/2 / HTTP/3
Where:
- Windows Features → HTTP/2 is enabled automatically if:
- Server 2016+: HTTP/2 TLS
- Server 2022+: HTTP/3 optional feature
Config:
<system.webServer>
<httpProtocol allowKeepAlive="true" />
</system.webServer>
Code language: HTML, XML (xml)
✅ 3. Compression
3.1 Static Compression
3.2 Dynamic Compression
Where:
IIS Manager → Server or Site → Compression
- Enable:
✔ Static compression
✔ Dynamic compression
Config:
<urlCompression doStaticCompression="true" doDynamicCompression="true" />
Code language: HTML, XML (xml)
✅ 4. Caching
4.1 Output Caching
Where:
IIS Manager → Site → Output Caching
- Enable Cache
- Add caching rules
Config:
<caching enabled="true">
<profiles>
<add extension=".aspx" policy="CacheUntilChange" duration="3600"/>
</profiles>
</caching>
Code language: HTML, XML (xml)
4.2 Kernel Caching
Where:
IIS Manager → Server → Feature Delegation
Ensure:
- Output Caching = Read/Write
Config:
<caching enableKernelCache="true" />
Code language: HTML, XML (xml)
✅ 5. Static File Handling
5.1 Cache-Control headers
Where:
IIS Manager → Site → HTTP Response Headers
- Add →
Cache-Control: public, max-age=31536000
Config:
<httpProtocol>
<customHeaders>
<add name="Cache-Control" value="public, max-age=31536000" />
</customHeaders>
</httpProtocol>
Code language: HTML, XML (xml)
✅ 6. Modules Optimization (DISABLING unused modules)
Where:
IIS Manager → Site → Modules
- Remove:
- WebDAV
- ASP
- ISAPI Filters
- CGI
- Windows Authentication (if unused)
Config:
<modules>
<remove name="WebDAV" />
<remove name="ISAPI-filter" />
</modules>
Code language: HTML, XML (xml)
✅ 7. Request Filtering
7.1 Max Request Body Size
Where:
IIS Manager → Site → Request Filtering → Rules → Request Limits
- maxAllowedContentLength
- maxUrl
- maxQueryString
Config:
<requestFiltering>
<requestLimits maxAllowedContentLength="52428800" />
</requestFiltering>
Code language: HTML, XML (xml)
✅ 8. Logging Settings
Where:
IIS Manager → Site → Logging
- Choose fields
- Directory location
- Format
Config:
<logFile enabled="true" directory="D:\IISLogs" logExtFileFlags="Date,Time,ClientIP,..." />
Code language: HTML, XML (xml)
✅ 9. Application Initialization (Warm-Up)
Where:
IIS Manager → Site → Configuration Editor
Section:system.webServer/applicationInitialization
Set:
- doAppInitAfterRestart = true
- remapManagedRequestsTo = “true”
- preloadEnabled = true (in site → Advanced Settings)
Config:
<applicationInitialization doAppInitAfterRestart="true">
<add initializationPage="/"/>
</applicationInitialization>
Code language: HTML, XML (xml)
✅ 10. Dynamic IP Restrictions
Where:
IIS Manager → Site → IP Address and Domain Restrictions
- Enable:
- Deny By Concurrent Requests
- Deny By Request Rate
Config:
<dynamicIpSecurity enableRateLimiting="true" maxRequests="200" requestIntervalInMilliseconds="500" />
Code language: HTML, XML (xml)
✅ 11. WebSocket Settings
Where:
IIS Manager → Site → WebSocket Protocol
- Disable if unused
Config:
<webSocket enabled="false" />
Code language: HTML, XML (xml)
✅ 12. HTTP.sys Kernel Settings
Where:
Registry or appcmd, but can be done via Configuration Editor under:system.webServer/serverRuntime
uploadReadAheadSize
<serverRuntime uploadReadAheadSize="49152" />
Code language: HTML, XML (xml)
MinFileBytesPerSec
<serverRuntime minFileBytesPerSec="240" />
Code language: HTML, XML (xml)
🎯 FINAL SUMMARY (Mapped)
| # | Setting | Where in IIS Manager | Config Path |
|---|---|---|---|
| 1 | Start Mode | App Pool → Advanced | startMode |
| 2 | Idle Timeout | App Pool → Advanced | idleTimeout |
| 3 | Recycling | App Pool → Recycling | <recycling> |
| 4 | Queue Length | App Pool → Advanced | queueLength |
| 5 | Max Worker Processes | App Pool → Advanced | maxProcesses |
| 6 | Connection Timeout | Site → Limits | <limits> |
| 7 | HTTP/2 | System Feature | HTTP.sys |
| 8 | Compression | Server/Site → Compression | <urlCompression> |
| 9 | Output Cache | Site → Output Caching | <caching> |
| 10 | Kernel Cache | Site → Output Caching | <caching> |
| 11 | Static Headers | Site → HTTP Response Headers | <customHeaders> |
| 12 | Modules Remove | Site → Modules | <modules> |
| 13 | Request Size Limits | Site → Request Filtering | <requestFiltering> |
| 14 | Logging | Site → Logging | <logFile> |
| 15 | App Initialization | Site → Config Editor | <applicationInitialization> |
| 16 | IP Restrictions | Site → IP Restrictions | <dynamicIpSecurity> |
| 17 | WebSockets | Site → WebSocket | <webSocket> |
| 18 | uploadReadAheadSize | Config Editor | <serverRuntime> |
I’m a DevOps/SRE/DevSecOps/Cloud Expert passionate about sharing knowledge and experiences. I have worked at Cotocus. I share tech blog at DevOps School, travel stories at Holiday Landmark, stock market tips at Stocks Mantra, health and fitness guidance at My Medic Plus, product reviews at TrueReviewNow , and SEO strategies at Wizbrand.
Do you want to learn Quantum Computing?
Please find my social handles as below;
Rajesh Kumar Personal Website
Rajesh Kumar at YOUTUBE
Rajesh Kumar at INSTAGRAM
Rajesh Kumar at X
Rajesh Kumar at FACEBOOK
Rajesh Kumar at LINKEDIN
Rajesh Kumar at WIZBRAND