Where is WordPress Error Log

An error log helps you troubleshoot and fix errors on your WordPress website. Error log will come handy in situations where your website is crashing or you are seeing a blank screen. You can also access it to check if any plugins or theme is causing any issue on your website.

Enabling error logging on your website

Error logging can be enabled in your WordPress website by editing your wp-config file. The wp-config file not only handles your site settings it also takes care of troubleshooting settings.

Steps to enable error logging:
  1. Edit your wp-config file by using FTP or from your server file manager.
  2. Add the below line of code to the wp-config file.

    define( ‘WP_DEBUG’, true );

    In some cases this line could already be present in the file. In that case you just need to change the false value to true.
    The above line of code will enable the debugging mode on your website. Although you will now start seeing the error codes on your admin dashboard and front page of your website.

  3. To disable the error messages from displaying in your admin area and from the front page add the below line of code.

define( ‘WP_DEBUG_LOG’, true );

You can now save your changes in the file.

Where is the error log?

The errors after making the above changes will start being added to a file called debug.log inside your wp-content folder. You can open the debug.log file to view all the errors and warnings of your WordPress website.

Enable error logging using a plugin

If the above steps are complicated for you. You can use a plugin to make the task easier for you. WP Debugging  enables you to easily activate the error logging on your WordPress website.

Steps to enable error logging using WP Debugging:
  1. Install and activate the plugin.
  2. Once the plugin is activated the debug mode and error logging is activated on your website.
  3. Visit Tools -> WP Debugging for additional settings.

Conclusion

Sometimes your website might be crashing randomly or you might be facing issues with a plugin or theme, in those cases an error log is very helpful to find and fix the problems. If you are comfortable then you can directly edit the wp-config file to enable error logging otherwise a plugin will be helpful.

Have questions or confused about something WordPress Related? Join Our Forum & ask a Question

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top