The WordPress memory exhausted error occurs when your site exceeds the allowed PHP memory limit. It often displays as a Fatal error: Allowed memory size of... exhausted message. Here’s how to fix it:
- Increase PHP Memory Limit:
- Access your wp-config.php file and increase the memory limit:
- Use FTP or File Manager to access your site’s files.
- Open wp-config.php in a text editor.
- Add the following line before the “Happy blogging” line:
- Save the file and re-upload it.
- Access your wp-config.php file and increase the memory limit:
- Increase Memory via php.ini:
- If the above step doesn’t work, you can try increasing memory via the php.ini file:
- Access the public_html or root directory.
- Look for the php.ini file. If it doesn’t exist, create one.
- Add the following line:
- Save and upload the file.
- If the above step doesn’t work, you can try increasing memory via the php.ini file:
- Edit .htaccess:
- Another option is to modify the .htaccess file:
- Open the .htaccess file.
- Add the following line:
- Save and re-upload the file.
- Another option is to modify the .htaccess file: