September 14, 2011 - Warren Held
Increase File Size Limit in WordPress
The file size limit you see displayed when you go to upload an image or video into your WordPress media area actually isn’t a WordPress limit at all, it is a PHP limit. PHP is the post popular programming language for programming dynamic web sites, and is what WordPress runs on. In order to increase the file size limit you will need access to either the PHP settings (if you run the server your site is hosted on), or your WordPress site files. You will need to create a php.ini file in a text editor (such as notepad), and in that file put these lines of code:
memory_limit = 100M
upload_max_filesize = 100M
post_max_size = 100M
max_execution_time = 1800
max_input_time = 1800
file_uploads = On
You can also download my php.ini file below.php.ini Increase File Size to 100mb
Place the php.ini file in your wp-admin folder. This will increase the file size limit to 100mb. You can adjust the limit by opening the php.ini file in a text editor and changing the 100M to whatever value you would like. Just make sure when you save it, it keeps the .ini extension. The input and execution times are the time limits (in seconds) that PHP will run a script. So if your upload takes longer than the time set here, the PHP engine might cancel the file transfer. Unfortunately, my web host (WebFusion) does not allow me to change the execution or input time, and I am locked in at 30 seconds.
If you follow the steps correctly and it doesn’t work, there is another option you can try.
You will need to create a file called .htaccess (yes you need the . in front of the name, and make sure there is no extension after the htaccess) and put the following code in it.
php_value upload_max_filesize 100M
php_value post_max_size 100M
php_value max_execution_time 1800
php_value max_input_time 1800