Skip to content

Increasing memory limit in WordPress

Sunshine does have a few functions that can require higher memory limits than are the default – especially when it comes to uploading high resolution images or when downloading large zip files of digital negatives. One thing to try is increasing the available memory your server/WordPress/Sunshine has access to so the process can properly run.

There are two places where the maximum allowed memory is set: At the server level and in WordPress.

If you go to Sunshine > Server Info you can see there are two lines for “PHP Memory Limit” and “WordPress Memory Limit”. We want those to be as high as possible.

Step 1

First step is to change the memory limit in WordPress as this is required no matter what.

Edit your wp-config.php file and add the following:

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

We want this as high as possible that your server will allow. So look at your “PHP Memory Limit” (as described above) and match that number.

Step 2

Next step is to ask your web host to increase your available PHP memory to the max they allow.

Still need help?

If you have not yet found your answer in the documentation articles, please contact support