Increasing the WordPress Memory Limit
There might be cases in which you encounter problems regarding Memory Exhaustion. That means the settings of the PHP on your server does not allow its language to use more than a specific memory size. Our Themes recommended memory size to be at least 96 MB for the theme to work normally. Actually this is also recommended for normal usage of WordPress itself. Both Jupiter and The Ken themes need same amount of memory.
In this article
How to Increase PHP Memory Limit from Server
Contacting Your Hosting Service Provider
If you use the services of shared web hosting plans, you most probably will not have access to php.ini or have permission to change the memory limit from the HTACCESS file. For such cases you need to contact your hosting service provider and ask them to increase the PHP memory limit from their side.
Using PHP.INI file
The PHP language settings can be accessed via a file called php.ini. You can open up that file with your simple text editor such as Notepad in Windows or TextEdit in Mac, and start editing. If you have full access to your server, you need to find the file as well as the line below; if it is not there add one as follows:
memory_limit = 96M
Using HTACCESS file
In some cases, users do not have access to the php.ini file to change the settings, but their hosting service provider does allow them to increase the option using the HTACCESS file. HTACCESS is a file in Unix based in servers which can be added via the FTP or control panel of a server at the root folder of the website.
You most probably will see it there by default, but if not you can simply add a text file, change the name and extension of the file to .htaccess, and then open it up with any text editor you like.
To increase the PHP memory limit using the HTACCESS file, you need to add the code below to the end of the file:
php_value memory_limit 94M
How to Increase PHP Memory Limit from WordPress
After you make sure that the PHP memory limit is increased from the server, you need to do the same from your WordPress installation. To do that you need to go to the root folder of your website, find the wp-config.php file, and open it via a text editor. Then you can edit it, or if there is no such line in the file, before “/* That’s all, stop editing! Happy blogging. */“, add the following:
This will make sure that your WordPress installation also has enough PHP memory limit for your theme to function normally. For more detailed information about wp-config.php and how to increase the PHP memory limit in WordPress please click here.
Testing for PHP memory limit:
You can always check your PHP memory limit by creating a text file and changing its name and extension to info.php. Then you can edit that file and add the code below:
<?php phpinfo(); ?>
Upload the file to the root of your server and access it via a browser like this: www.yourwebsite.com/info.php. Please delete that file after you’ve checked and seen your PHP memory limit.
Q: I increased the memory limit but yet I see the memory is low, what is wrong?
A: Sometimes, some shared hostings do not allow you to increase the memory limit more than a certain value. In those cases, you should contact the web hosting support and ask them to increase it for you.