ReD Email Updates ReD RSS Updates
Become a ReD Facebook Fan Follow ReD on Twitter

Easily Fixing the WordPress “Fatal Error: Allowed memory size…” Issue

WordPress TipsIf you use a lot of plugins on your WordPress site then you may have run into the WordPress error message – “Fatal Error: Allowed memory size of 33554432 bytes exhausted (tried to allocate x bytes) in…”. This occurs when WordPress exceeds it’s set memory limit, and can commonly occur when performing auto-upgrades to newer versions of WordPress.

Reducing the amount of activated plugins can help and is advisable but not always practical, especially if your plugins are all essential to the running of your WordPress site. So what else can be done to fix this issue?

Well below are a few simple steps to easily increase the WordPress memory limit from it’s default ’32M’ to ’64M’.

1. Find the file named wp-settings.php

The wp-settings.php file is found in the root folder of your WordPress installation. You can access and download it via your own FTP software or through your host’s File Manager.

2. Open the wp-settings.php file

Once you’ve downloaded the file (via FTP or your host’s File Manager), open it in your preferred code editing program. Alternatively if your host’s File Manager comes with a code editor, you could open it via that feature rather than downloading the file. However if you don’t have access to any code editing software, opening the downloaded file in a simple text editor, such as Notepad, will do.

3. Search file for the line define(‘WP_MEMORY_LIMIT’, ’32M’);

In WordPress 2.9 that code can be found on line #13 of wp-settings.php

WordPress code

4. Change the ’32’ to ’64’

As shown below

WordPress code

5. Save the wp-settings.php file

If working on a downloaded copy of the file, upload the new saved wp-settings.php file (via File Manager or FTP) back to the root folder of your WordPress installation, overwriting the old wp-settings.php version. Your WordPress memory limit will now increase to 64M.

6. And you’re done!

Now with all steps completed that should fix the WordPress “Fatal Error: Allowed memory size…” issue and you shouldn’t have any problems installing plugins or auto-upgrading your WordPress installation. However if the issue still persists try increasing memory further to ’96M’ and deactivating any unnecessary plugins.

NOTE: The WordPress memory limit will revert back to ’32M’ after upgrading to newer versions of WordPress

Be Sociable, Share!
This entry was posted in WordPress Tips and tagged , . Bookmark the permalink.