How to Increase Maximum File Upload Size in WordPress

Some times low file upload size limit can stop you from uploading files via media uploader, or install plugins and themes. In this article, we will show yo.....

Some times low file upload size limit can stop you from uploading files via media uploader, or install plugins and themes. In this article, we will show you how to easily increase the maximum file upload size in WordPress to free your self from the ordeal it brings.

How to Check Your Maximum File Upload Size Limit in WordPress?

WordPress automatically display the maximum file upload size limit during file upload. To check it you can simply go to Media » Add New page and you will see the maximum file uplaod size limit for your WordPress site.

Diversity of WordPress has made it possible to increase or decrease file upload size in a variety of ways. NB: Always use one option a time.

1: Edit theme Functions File.

This option calls for adding the code below above the php declaration in your WordPress theme’s function.php file. The increase or decrease of the upload size is dependant on the figure you specify in M (ie. 64M) as shown below:

@ini_set( 'upload_max_size' , '64M' );
@ini_set( 'post_max_size', '64M');
@ini_set( 'max_execution_time', '300' );

2. Create or Edit existing PHP.INI file.

This option involves access to you root folder of your hosting (ie. where your hosting files are found). This can be achieved with your hosting’s file manager or an ftp access into your hosting.

Navigate into the WP Admin folder. Locate the php.ini file if present. Be sure to carefully review to surity that it does not exist before creating it. Creat a file called php.ini if you find no such file in existence in the WP Admin folder.

upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300

3. htaccess Method

This method requires that you backup the .htaccess file before proceeding. To do that copy the .htaccess file in your root folder and and name the copy htaccess.bak or as you deem fit for your recognition.

If you have safely backed up your current .htaccess file then edit the .htaccess file in your WordPress site’s root folder and add the following code:

php_value upload_max_filesize 64M
php_value post_max_size 64M
php_value max_execution_time 300
php_value max_input_time 300

4. Create .user.ini file

Our last option for you is the .user.ini file creation in the WP Admin folder. This option follows that of php.ini however the name of the file is .user.ini . Edit the .user.ini file and type or past the code below into the file.

upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300

These options would set you free from the upload issues along with execution time and input value maximum time.

We can’t end here without saying this. Shared hosting users may not enjoy all four options however they can try.

The options that works for most shared hosting providers are the php.ini and .user.ini files.

More Information

Gabby
Gabby

Inspiring readers to embrace the possibilities of the future while critically examining the impact of our present choices.

Say whats on your mind.

Videos You may like

The Best Deals
Make Savings