Cannot upload large files to IIS7 website

When running a website on Windows 2008 with IIS 7, you may have difficulties uploading large files to the website. The following error occurs

Server Error

404 – File or directory not found.

The resource you are looking for might have been removed, had its name changed, or is temporarily unavailable.

To enable uploading files, larger than 28MB, you have to change a setting in IIS 7. By the way, actually the limit is approximately 28,6 MB, because the limit of “maxAllowedContent Length” is 30000000 bytes).

To change the maximum upload setting, named “maxAllowedContent Length”, do the following:

  1. Log on to the server that holds the IIS website, and then click Start, click Programs, click Administrative Tools, click Internet Information Services (IIS) Manager
  2. Expand the website that you want to increase the maxAllowedContent Length
  3. Double click the Request Filtering icon in the main window
    Note: if you don’t have the Request Filtering icon, you need to install it through the Add Roles option. A manual to add this functionality can be found here:
  4. Click the Hidden Segment Tab
  5. Right click web.config and click Edit Feature Setting
  6. A new window named Edit Request Filtering Settings, appears.
  7. Under Request Limits heading. enter a new larger value in the Maximum allowed content length (Bytes) box. For example “2000000000”, that allows you to upload files up to 1900 MB.
  8. Click OK to apply the change. The new setting immediately takes effect. You do not have to restart the website.

4 thoughts on “Cannot upload large files to IIS7 website

  1. That’s very great topic, I spent long days searching for my problem and finally met your topic. It’s solve now.



  2. This was very helpful! Only the steps 4 and 5 are not necessary, you can simply right-click anywhere (in file name extensions tab also for instance) and select the “Edit Feature Setting” menu.


Leave a Reply

Your email address will not be published.