Enable .Net Core, .Net 5, .Net 6 Debug Logging

By default error logging is turned off in .Net Core, .Net 5, .Net 6 which is excellent for security.

Unlike ASP.NET and Classic ASP it will not send errors to the client browser by default.
Therefore in order to debug apps on this stack please enable error logging as follows:

  • Edit your web.config file in your applications root and change the stdoutLogEnabled attribute from "false" to "true".
  • Create a "Logs" folder in the root directory of your application.
  • Run your application and the debugging log will be created.
  • Open the debugging files in the Logs folder to see any errors being produced by your application.
  • Once you have debugged your issues please disable debugging again in the web.config to prevent constant log file generation.

If you have any issues or need help please open a support ticket and our team will help you resolve everything.

  • .net core, debug, error, logging
  • 38 Users Found This Useful
Was this answer helpful?

Related Articles

Enabling the InProcess Hosting Model

As of ASP.NET Core version 2.2 + there is a new hosting model that adds support for direct In...

HTTP Error 500.21 - Internal Server Error Handler "aspNetCore" has a bad module "AspNetCoreModuleV2" in its module list

If you receive the following error in your ASP.NET Core application please see the fix below:...

How to enable .Net Core on your website

.Net Core is enabled on all of our hosting packages by default.We support all versions of .Net...