If you have encountered WordPress upload error message then it means your server have upload limits which only allow you to only upload a maximum of single file up to 2Mb or whatever the limit is. This is a problem when you try to upload files larger than 2Mb.

Here are some easy fixes you can try. Most probably it is a server-side issue but sometimes WordPress can be the culprit too. So let’s see how you can solve this.

 

Increase WordPress file upload limit

Follow this procedure step by step and see which step solves your problem.

 

1. Create WordPress Configuration File

To increase WordPress WordPress file size limit you just have to create php.ini file in your WordPress installation admin folder (Public_html > WordPress > Admin) and after creating file edit it and paste the following code:

Upload_max_filesize = 64M post_max_size = 64M max_execution_time = 300

This will overwrite the maximum upload size in most cases but it doesn’t try the next method.

 

2. Use .htaccess

The dot htaccess file is used to set directory permissions on apache. You can increase the upload limit using .htaccess file. To increase your upload limit through this method go to your WordPress directory root folder and edit htaccess file (You might have to enable hidden files option in the setting menu to see the htaccess file if you are using Cpanel)l Add this following code at the end of existing code and save it.

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

 

Test your WordPress installation by uploading a new file. Hopefully, it will be fixed by now. If not then you have to fix it at the server end by either yourself as discussed in the next method or have to ask your server administrator to fix it.  (Cheap hosting usually do not offer higher memory limits but it’s worth reaching out.)

 

3. Set Server PHP Configuration

If this is your personal server and you can access it via WHM then follow this method.

  1. From the WHM search panel, navigate to the PHP configuration editor.
  2. Select the PHP version you are primarily using in the option menu.
  3. Find the upload value limit in settings and change to your desired limit (128Mb is a good option).
  4. Save & Restart the server and the issue will be fixed.

 

Hopefully, this issue is fixed if not consider getting managed hosting or hiring someone to do it on your behalf is the best option.

Author

Hi Readers, Welcome to My Blog. I am Hamza Ahmed, a tech geek From Islamabad Pakistan. I love to write, code and explore new amazing stuff. You can connect with me on Twitter & Facebook. Read more about me here.

Write A Comment