Increasing the Server Max Upload Size

All SpinupWP servers are configured with a default maximum upload size of 64MB. However, you may increase this limit if you need to allow larger files to be uploaded via the Media Library.

This setting cannot be adjusted via the SpinupWP UI, so start by connecting to your server using SSH, then update your PHP and Nginx configs, as follows:

PHP

Open your php.ini file and modify the following values:

upload_max_filesize = 64M
post_max_size = 64M

These settings can also be changed on a per-site basis.

Nginx

Open your nginx.conf file and modify the following directive:

client_max_body_size 64m;

For larger uploads you may also need to increase the client timeout:

client_body_timeout 30s;

Reload Services

Reload both PHP (replacing php7.2 with the desired version) and Nginx for the changes to take effect:

sudo service php7.2-fpm reload
sudo service nginx reload

Repeat As Needed

Repeat for each SpinupWP server where you need to increase the maximum upload limit.

Ready to give SpinupWP a try?

Not sure if SpinupWP is the right fit for you? Send us an email at sudo@spinupwp.com and we’ll give you our no-BS opinion.