How to Increase Maximum File Upload Size in WordPress
Last updated
Last updated
Do you want to increase the 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 you how to easily increase the maximum file upload size in WordPress to fix those issues.
This is an intermediate level tutorial. It may not work with some shared hosts in which case you would have to ask your hosting service provider for support.
WordPress will automatically show the maximum file upload size limit when you are uploading images or media. 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.
There are cases where we have seen that just by adding the following code in theme’s functions.php file, you can increase the upload size:
For this method you will need to access your WordPress site’s root folder by using FTP or File Manager app in your hosting account’s cPanel dashboard.
In most cases if you are on a shared host, then you will not see a php.ini file in your directory. If you do not see one, then create a file called php.ini and upload it in the root folder. In that file add the following code:
This method is reported to work for many users. Remember if 64 doesn’t work, then try 10MB (sometimes that work).
Some people have tried using the .htaccess method where by modifying the .htaccess file in the root directory, you can increase the maximum upload size in WordPress. Edit the .htaccess file in your WordPress site’s root folder and add the following code:
Again, it is important that we emphasize that if you are on a shared hosting package, then these techniques may not work. In that case, you would have to contact your web hosting provider to increase the limit for you.
We hope this article helped you increase the maximum file upload size in WordPress. If you are still having issues, then follow the steps in our WordPress troubleshooting guide to fix it.
If you need to allow more files to be uploaded via the Cost Calculator Pro plugin on your WordPress site, you can increase the maximum file upload by following these steps. This is particularly useful if your forms require users to upload files that exceed the default attached file upload size limits set by WordPress.
Before making changes, it's important to check the current limits set by your PHP configuration:
Access Your Hosting Control Panel: Log into your hosting account and navigate to the control panel provided by your hosting provider (if any).
Find PHP Settings: Look for a section named PHP Settings, Select PHP Version, or similar. The exact naming may vary depending on the host.
Check or Edit the PHP Configuration:
On your plugin folder, navigate to conf\php => php.ini file;
On ; Maxes find max_file_uploads;
max_file_uploads
This value determines the maximum size of an attached uploaded file.
You (or your hosting provider) may change this settings based on your preference. You can modify the PHP settings either via the hosting control panel or by editing the php.ini
file if you have access to it.
After increasing the limits:
Check PHP Configuration: Return to the PHP settings in your control panel and check whether or not code has been changed
Test File Upload: Try uploading a file through the Cost Calculator Pro form to ensure the new settings are effective.
If changes do not take effect:
Check with Hosting Provider: Some hosts do not allow changes via php.ini file
. In this case, contact your hosting support for assistance.
Server Cache: Ensure there is no server-side caching affecting the changes.