Remotely view error messages on IIS 7 (Windows 2008) and newer

When a website page encounters a coding error on a IIS 7 (Windows 2008) or newer hosting server, it will by default show a generic "500 Internal Error" page.  You can override this behavior and return a detailed error message with debugging info by placing a web.config override file in the document root of your website with the following content:

<?xml version="1.0" encoding="UTF-8"?>
        <httpErrors errorMode="Detailed" />
        <customErrors mode="Off"/>

If you already have an existing web.config file, you will need to edit/insert the "httpErrors" directive under the tag.

Was this answer helpful? 0 Users Found This Useful (0 Votes)