Page not found in IIS, but it's there

Solution 1:

For anyone that run into this and don't find the other suggestions effective, also check that Windows is displaying file name extensions. Open Windows Explorer, click "View" in the top bar and then check "File name extensions".

I found that my file was actually named index.html.txt even though it was displaying index.html prior to checking the above setting.

Solution 2:

I had this same problem.

Observe your path: C:\inetpub\wwwroot\folder\file.html.

Ensure that:

  • The file name extension you are requesting (in this case, .html) is not being blocked by IIS.
  • The directories along the path you are requesting (in this case, folder) are not being blocked by IIS.

If you are on Windows 8/ Windows 10, you can check those two things in the IIS Manager desktop application.

Here is how:

  1. Open the IIS Manager. You can type it in the Windows search bar.
  2. In the file tree in the 'Connections' box, select the root of web application.
  3. In the Features View that appears in the middle of the screen, select Request Filtering.
  4. In the File Name Extensions tab, ensure that .html does not have the value false.
  5. In the Hidden Segments tab, ensure that NONE of the folders in your path (C:\inetpub\wwwroot\folder\file.html) are listed.

NOTE: If you cannot see the Request Filtering tool, you may not have enabled all of the IIS features. Search for 'Turn off windows features' on your machine. In the Windows Features manager, select all of the boxes in Internet Information Services -> World Wide Web Services and select the box Internet Information Services -> Web Management Tools -> IIS Management Consoles.

Solution 3:

I've had this issue before - I had to set the username and password in again at Anonymous Authentication and it worked perfectly. You can also switch on Detailed errors at Error Pages in IIS to give more info.