Skip to content

upload_max_filesize post_max_size

You should set post_max_size to double what you set upload_max_filesize to. This means you can upload 2 files of your maximum limit for each POST and seems like a good middle ground.

The memory_limit directive should also be set above the value of post_max_size so your server can handle the uploads.

There are 2 ways you can set this directive:

For php.ini

Edit php.ini and modify these directives:

upload_max_filesize = 128M
post_max_size = 256M

.htaccess

Edit .htaccess

php_value upload_max_filesize 128M
php_value post_max_size 256M