How to set web.config file to show full error message

King Kong picture King Kong · Jul 26, 2012 · Viewed 255.1k times · Source

I deployed my MVC-3 application on windows Azure. But now when I am requesting it through staging url it shows me (Sorry, an error occurred while processing your request.). Now I want to see the full error message, by default it is hiding that because of some security reasons. I know that we can do this through web.config file. But how?

Answer

jim tollan picture jim tollan · Jul 26, 2012

not sure if it'll work in your scenario, but try adding the following to your web.config under <system.web>:

  <system.web>
    <customErrors mode="Off" />
  ...
  </system.web>

works in my instance.

also see:

CustomErrors mode="Off"