ASP.NET MVC 5 Custom Error Page
[1]: Remove all ‘customErrors’ & ‘httpErrors’ from Web.config [2]: Check ‘App_Start/FilterConfig.cs’ looks like this: public class FilterConfig { public static void RegisterGlobalFilters(GlobalFilterCollection filters) { filters.Add(new HandleErrorAttribute()); } } [3]: in ‘Global.asax’ add this method: public void Application_Error(Object sender, EventArgs e) { Exception exception = Server.GetLastError(); Server.ClearError(); var routeData = new RouteData(); routeData.Values.Add(“controller”, “ErrorPage”); routeData.Values.Add(“action”, “Error”); … Read more