Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We are running up against some sort of size boundary on the Web.config file in our ASP.NET application. This appears to be 250KB. Is there any way to increase this limit?

EDIT Sorry, fingers got confused typing. 250KB not 250MB :)

share|improve this question
up vote 3 down vote accepted

Agree with all the comments about looking really hard at the configuration stored in it, but if you even then need to do it, then you will need to set a registry key:

See: HKLM\SOFTWARE\Microsoft\InetStp\Configuration\MaxWebConfigFileSizeInKB (REG_DWORD)

share|improve this answer

Are you sure web.config is the best place to store what you're storing? You may want to consider moving your settings to a database. I bet with a config file that large that the starting up for your app is huge!

If you need to extent it, consider a configSource to pull out your sessions. If everything is in 1 section, it won't help much though.

share|improve this answer
Sorry, meant to type 250KB not 250MB. Our WCMS takes up a good portion of this. We also have a somewhat significant number of rewrites in here due to the fact that a lot of our URLs have changed since we converted to the WCMS. – Kyle Sep 14 '10 at 13:22
250KB is a lot more manageable. For URL Rewrite, you can use configSource to have them in a separate file. Here's how to do that:… – Scott Forsyth - MVP Sep 14 '10 at 15:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.