Extension to @mikus answer (Feb 2017)
I had the exact problem described above with an ASP.NET MVC 4.5 project on my local machine which was showing IIS 403 errors.
The fix which may be of use to others:
1). Follow mikus's answer above (I used the x64 version) in a Command Prompt window. I received a response with an 'unsupported' message, but contained a useful link:
...This option is not supported on this version of the operating system. Administrators should instead install/uninstall ASP.NET 4.5 with IIS8 using the "Turn Windows Features On/Off" dialog, the Server Manager management tool, or the dism.exe command line tool. For more details please see http://go.microsoft.com/fwlink/?LinkID=216771..."
2). Using the step-by-step instructions given in the link to the Microsoft help page: http://go.microsoft.com/fwlink/?LinkID=216771. I only had to do steps 7 and 8, which I have detailed below:
- Open 'Turn Windows features on or off' [Windows key then type 'Turn Windows features on or off' and open]
- Scroll down the list and expand 'Internet Information Services'
- Within that expand 'World Wide Web Services'
- Within that expand 'Application Development Features'
- Make sure 'ASP.NET 4.6' (or 3.5 if you require that) is ticked - mine was not.
- Save and close.
3). Your IIS site should now work as expected - it did for me. Hit the site in the browser again to test.