WordPress Fatal Error Fix – Allowed Memory Size Exhausted

Fatal error fix – Allowed memory size exhausted

Let me guess,
Your WordPress site isn’t opening up and to make things more annoying, it keeps showing a fatal error of memory size being exhausted. So, you are here looking for a solution to this annoying issue.
Well, you have the right sense of direction and have come to the right place.

Now, this error shows up whenever the memory runs out and it usually happens while trying to install plugins, themes or messing around with things that you should probably stay away from. but, at time all you need is a bad luck!
I know! Shit happens?

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

But don’t worry,
this is a very common issue faced by most of the WordPress users and I faced this issue myself and it was very frustrating!!, but I managed to find a very simple solution to a very technical issue. So, here we go …….

4 Methods to fix the Fatal error of memory size being exhausted

Method 1 – Restoring Files and Database.

Now, this method is mainly for the users who have Godaddy as their hosting provider, but even other users with different hosting providers can try if they have the local backup enabled.

  • Go to Godaddy.com and Login to your account.
  • Click on your Username and got to My Products.
  • Then, Click on Manage of Managed WordPress Websites.
  • Under Backups tab, click on Active of Local backups.
  • Now choose the restore type as Files and Database.
  • Choose the restoration dates for both and press Restore.
  • Wait for at least 10minutes and then try if it worked.

Method 2 – Increasing memory limit using Wp-config.php. ( Recommended )

  • Use FTP program or Install & Activate this plugin – File Manager to access the root directory.
  • This File manager will allow you to upload, delete, copy, move, rename, edit, compress and extract files.
  • Search for “wp-config.php” in the search bar of the file manager.
  • Right-click on the file and choose Edit file.
  • Add this line before /* That’s all, stop editing! Happy blogging. */ and press Save and Close

    define('WP_MEMORY_LIMIT', '256M');
  • Done!

Method 3 – Increasing memory limit using .htaccess.

  • Use FTP program or Install & Activate this plugin – File Manager to access the root directory.
  • This File manager will allow you to upload, delete, copy, move, rename, edit, compress and extract files.
  • Go to the root directory, it’s the directory where you can find your wp-config.php file. You should be able to find your .htaccess file.
  • Download the file as Backup before you make any changes.
  • Right-click on the file and choose Edit file.
  • Add this into a newline at the end of the file and press Save and Close
    php_value memory_limit 256
  • Done!

Method 4 – Increasing memory limit using .php.ini File ( Do it at your own risk )

  • Install & Activate this plugin – PHP Settings
  • Go to Tools – Go to PHP Settings
  • Use the editor to manually add PHP settings

    memory_limit = 256M
  • Save Settings!

Hope this worked out for you guys.
But WAIT! Don’t leave
Make your WordPress site more awesome with these Must have WordPress Plugins of 2017.
If you have any suggestions, advice or request, then please do convey it through comments.
Have a nice day 🙂

He’s a 22yr old pursuing a career in Digital Marketing, WordPress Development, and Graphic Designing. Trying to create a mark for himself in a Dynamic World. He spends his free time watching gruesome movies, playing games, reading books, going to the gym and blogging.

SEO AUDIT
Share this Awesome Stuff with your Friends!

Pin It on Pinterest