title: Custom 404 error page not working on IIS 8.5
body: <p>I have recently moved host and have had to set up Customer Errors again in IIS.</p>
  
  <p>I can go to IIS Admin and Error Pages as follows:</p>
  
  <p><img src="https://i.stack.imgur.com/jhmid.png" alt="Custom Errors on IIS"></p>
  
  <p>Then I can go to the Custom Errors, and have set up the options as follows:</p>
  
  <p><img src="https://i.stack.imgur.com/hLDCY.png" alt="Customer Errors setup"></p>
  
  <p>That creates my web.config file as follows:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;configuration&gt;
      &lt;system.webServer&gt;
          &lt;httpErrors errorMode="DetailedLocalOnly" defaultResponseMode="ExecuteURL"&gt;
              &lt;remove statusCode="500" subStatusCode="100" /&gt;
              &lt;remove statusCode="500" subStatusCode="-1" /&gt;
              &lt;remove statusCode="404" subStatusCode="-1" /&gt;
              &lt;error statusCode="404" prefixLanguageFilePath="" path="/error_404.asp" responseMode="ExecuteURL" /&gt;
              &lt;error statusCode="500" prefixLanguageFilePath="" path="/error_500.asp" responseMode="ExecuteURL" /&gt;
              &lt;error statusCode="500" subStatusCode="100" path="/error_500.asp" responseMode="ExecuteURL" /&gt;
          &lt;/httpErrors&gt;
      &lt;/system.webServer&gt;
  &lt;/configuration&gt;
  </code></pre>
  
  <p>When I test the pages, the 505 error works fine, and redirects to the right page, but the 404 doesn't redirect and returns the standard IIS 404 error. I have confirmed that the 404 error page is in place on the server in the correct location.</p>
  
  <p>I can't see what else I need to do.</p>