WebWonder Network

How to Turn Off PHP Errors in WordPress | php.ini error reporting off | hide php errors wordpress

Table of Contents

So, you want to turn off PHP errors in your WordPress website? This is a common requirement among WordPress users and it’s actually quite easy to do. Let me guide you through it with a step-by-step process. Remember, this is a beginner-friendly guide, so don’t worry if you’re not tech-savvy!

Step 1: The first thing you need to do is access the File Manager of your website. This is usually located in your hosting account’s control panel.

Step 2: Once you’re in the File Manager, you need to locate the wp-config.php file. This file is crucial as it contains the configuration settings for your WordPress site.

Step 3: After finding the wp-config.php file, you need to edit it. But before you proceed, it’s always a good idea to create a backup of this file. This way, if anything goes wrong, you can revert to the original version.

Step 4: In the wp-config.php file, look for the line that says WP_DEBUG. If you find this line, set its value to false. This should disable all PHP error messages. If this line does not exist, you can add it at the bottom of the file. Here’s what the line should look like:

define( 'WP_DEBUG', false );

Step 4: if error is still there add this code below define wp_debug

ini_set('error_reporting', E_ALL );
define('WP_DEBUG', false);
define('WP_DEBUG_DISPLAY', false);

That’s it! You’ve successfully turned off PHP errors on your WordPress site. Remember, these steps are meant to hide PHP warnings and notices, but they won’t fix the underlying issues causing these errors. It’s always best practice to resolve these issues or get help from a professional developer1234.



  1. WPBeginner
  2. GreenGeeks
  3. Aristath’s Blog
  4. Local WP

Leave a Comment

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

Scroll to Top