locked
How to Fix “HTTP Error 403.14 – Forbidden The Web server is configured to not list the contents of this directory” RRS feed

  • Question

  • User-616684142 posted

    How to Fix “HTTP Error 403.14 – Forbidden The Web server is configured to not list the contents of this directory”

    This is one of the most common issue that developed faces when they start the New Website published with IIS or IIS Express.

    I searched internet a lot to find the exact issue and the solution that I found is to enable "Directory Listing" for the web site, similar guidance will be shown on the error page itself, but it is not recommended for security reasons.

    So to fix this issue, the easiest and best way is to add the default page or document that IIS should look while you click on browse or F5 from Visual Studio.

    1. Open IIS (Type InetMgr)

    2. Go to the WebSite you are facing the issue

    3. Click on Default Document Button, you will find it on the right side tab in IIS.

    4. You can see a list of default documents, but your default page (aspx file) is not mentioned here and that is causing the issue.

    5. Add your file here. (For example: Login.aspx)

    You can also add the following entry into the web.config:

    <system.webServer>
         <defaultDocument>
            <files>
              <add value="Login.aspx" />
            </files>
         </defaultDocument>
         <directoryBrowse enabled="false" />
    </system.webServer>

    Now run the website again .. and yes .. that will work now. Laughing

    Saturday, February 8, 2014 4:21 AM

Answers

  • User1183424175 posted

    Hi,

    We are happy that your issue has been resolved. ANd thanks for sharing solution with us:

    enable "Directory Listing" for the web site or Set default document

    Thanks.

    • Marked as answer by Anonymous Tuesday, September 28, 2021 12:00 AM
    Monday, February 10, 2014 1:31 AM