There are many instances when your WordPress website is having critical issues. These issues can be due to plugins misconfiguration, errors in custom code, and whatnot.
Error logs allow you to see the details about these errors at your
debug.log file in the
You can write the below code in your
wp-config.php file after the line that says
"That's all, stop editing!" to log all errors, warnings, and notices. Also, it will hide errors in the frontend pages.
// Enable WP_DEBUG mode
// Enable Debug logging to the /wp-content/debug.log file
// Disable display of errors and warnings
// Use dev versions of core JS and CSS files (only needed if you are modifying these core files)