How to resolve “This Page isn’t Working- HTTP ERROR 500”

HTTP ERROR 500

Hello, friends today we will learn about How to resolve “This Page isn’t Working- HTTP ERROR 500”.

HTTP ERROR 500

 

Last week we got this error while shifting one of my websites from one server to another. But no need to worry about that WordPress have this common error and we can easily resolve it. What we have to do is to follow these steps:

 

1. Deactivate all plugins

First, we will try to deactivate all the plugins. Do you know guys how we can deactivate all plugins at a time? we can do this in both ways either from admin panel of from FTP but we are getting HTTP ERROR so we can do this only from FTP/cPanel, just rename the plugin directory like this Plugins.deactivate. Through this, all plugins will get deactivated automatically. Once you deactivate all plugins, HTTP ERROR 500 will not show again and your site will run but maybe some fatal errors or a blank(White) page will show. If you get a blank(White) page then follow step 2 otherwise go to step 3

 

2. Enable WP_DEBUG

What we will do in this step is to enable(change to ‘true’) the WordPress Debug in the wp-config.php file of your website in the root directory. I think you all have seen this before:

//define('WP_DEBUG', false);
define('WP_DEBUG', true);

Once you enable WP_DEBUG to true, you will see a Fatal Error may be like this below screenshot:
memory size exhausted

If this error occurs on your website it means that website memory limit exhausted and it needs to be increased till required. Let us see the step 3 to how to increase the memory limit.

 

3. Increase WordPress Memory Limit

We can easily increase your website memory limit through php.ini, .htaccess, wp-config.php or you can directly contact your host manager. But here we will increase memory limit through the wp-config.php file. You just need to open your wp-config.php file from the root directory and increase it.

 
//define( 'WP_MEMORY_LIMIT', '64M' );
define( 'WP_MEMORY_LIMIT', '512M' ); 

Once you increase the memory limit, just refresh your website and check everything is working fine or not. If not then please comment on this post.

Please make sure that you reactivate your website plugins, What to do is first rename your plugins directory(Plugins.deactivate to Plugins) after that go to WordPress admin Panel and activate plugins one by one and please make wp_debug to ‘false‘ as well in the wp-config.php file.

Increase WordPress Memory Limit using .htaccess

Increase WordPress Memory Limit using php.ini

Share:

Facebook
Twitter
Pinterest
LinkedIn

Please share your thought