Getting 404 errors when downloading certain file types?

Recently, in our in-house file repository (.net based) we were getting errors 404 when trying to download .iso files, the fix is quite simple

All other file types were downloading just fine, .exe, .jpg, .gz, etc. but .iso files would produce a 404 error.  They were linked to with a simple <a href="file.iso">file.iso</a> and I checked and double checked that the files were there and the links were correct, but it still wouldn't work.  The problem is, that in order to be able to download a file as a file, it must be a registered MIME type in IIS.  The default list is pretty thorough, but some file types are left out, as was the case with .iso.


Here is how you do it:


  1. In IIS Manager, right click on your server and choose properties
  2. Click MIME Types
  3. You will see the list of registered MIME types, and your desired file extension will not be in the list (check to make sure)
  4. Click New and enter the extension in the Extension field (.iso in my case) and the description in the MIME Type field
  5. Apply and the restart IIS (iisreset in command prompt)


That is all you need to do. To set it per web site, right-click the site and select properties, then navigate to the HTTP headers tab.  From there select MIME Types at the bottom and add the desired MIME Type as necessary.

Comments are closed