We have transferred numerous client websites, and sometimes a WordPress Memory Exhausted error shows up when activating a new plugin or doing some other task. Usually the error looks like this:

Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 2348617 bytes) in /home2/xxx/public_html/wp-includes/plugin.php on line xxx

We got an email from a user who was facing the same problem, so we decided to do a writeup on it because this is a common problem. The reason why this error shows up is because you exceed your default Memory Limit. There are numerous solutions for it, but in this article we will share the simplest one out of all.

First open your wp-config.php which is located in the root WordPress directory. Then add the following line inside the main php tag:

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

We just increased the memory limit to 64M. If you still get the error after this fix, then please contact your host. Most likely, they would have to go in their php.ini file to increase the memory limit for you. If you have other ways of increasing the memory limit, then let us know in the comments below.

Originally posted on June 2, 2015 @ 7:57 pm

Leave a comment

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.