Skip to content

🐘 PHP User Overrides

phpmemoryuploadoverrides

Runtime PHP configuration

Learn more about PHP-FPM usage of .user.ini in each document root to set PHP configuration at runtime.

Increasing PHP memory

To increase the memory limit, you can define a new limit as follows:

ini
memory_limit = 128M
Make sure cgroups allocated memory is equal or more than what you set in the override.

This can only be applied to PHP CLI. Use policy maps to change PHP FPM's memory limit instead. Learn more here

Increasing upload size

To increase the upload size limit, you can raise the limit as follows:

ini
upload_max_filesize = 32M
post_max_size = 32M