• contact@ongoingthemes.com

Demo Installation Error – The Uploaded File Exceeds

Demo Installation Error Demo Installation Error - The Uploaded File Exceeds

July 27, 2020

You may have seen this error at least once when installing a theme, plug-in, or uploading an image or file. Sometimes it has nothing to do with the theme or plugin. The problem is your server settings, which limits the maximum size for uploaded files. Especially, it is more common in themes with large demo data.

This is a common error and can be easily fixed by file setting. This error message indicates that the file you are trying to upload is larger than your web host allows.

The way to overcome this problem is very easy, you need to increase the file size upload limit. You can do this yourself or ask your web hosting support team to increase the file size limit.

Ways you can fix it:

Updating Your php.ini file
Editing Your .htaccess file
Editing your wp-config.php File
Contact Web Hosting Support

Updating php.ini file

If you are developing code with PHP language, each server has a php.ini file. You need to open this file and edit your new memory limit.

Follow these steps to edit the php.ini file

If you are working in localhost, you can open the php.ini file in the directory where the php is installed and search the lines below and change the values. If you are using a server application like XAMPP, you should edit the php.ini file in the xampp\php directory.

upload_max_filesize = 128M
post_max_size = 128M
memory_limit = 400M
file_uploads = On
max_execution_time = 180

If you are working on a hosting server, you can follow the steps below to edit the php.ini file below.

  1. Go to your CPanel and scroll down to the Software section.
  2. Click “Select PHP Version”.
  3. Click “Switch to PHP Extension” or “Options” on the top left corner.
  4. The bottom of the page has “upload_max_filesize” section.
  5. Click the dropdown menu to the largest size.
  6. Click save.

Settings may vary based on what web hosting company you are using. Here is list of popular webhost documentation for quick reference:

You can browse the quick reference of the popular hosting companies below.

Editing .htaccess file

If editing in PHP.ini doesn’t work, you can edit your .htaccess file to fix this problem.
Follow these steps to edit your .htaccess file

  1. Log in to your web hosting account and go to cPanel.
  2. Click “File Manager” under the FILES panel header.
  3. If it is your website in WordPress, enter the main directory of your domain website. If you can’t see the .htaccess file make sure the checkbox for “Show Hidden Files” is checked. Click the “Settings” button in the upper right corner to check this box. Check the “Show Hidden Files” checkbox.
  4. Once you find the .htaccess file, you should open the file and edit the following line of code.
  5. Save the changes you made to the .htaccess file.

php_value upload_max_filesize 128M
php_value post_max_size 128M
php_value memory_limit 400M
php_value max_execution_time 180
php_value max_input_time 180

Editing wp-config.php file

If none of these solutions work, you can try editing the wp-config.php file located in the root directory of your WordPress website.

  1. Log in to your web hosting account and go to cPanel.
  2. Click “File Manager” under the FILES panel header.
  3. If it is your website in WordPress, enter the main directory of your domain website. If you can’t see the .htaccess file make sure the checkbox for “Show Hidden Files” is checked. Click the “Settings” button in the upper right corner to check this box. Check the “Show Hidden Files” checkbox.
  4. Once you find the wp-config.php file, you should open the file and add the following line of code.

define(‘WP_MEMORY_LIMIT’, ‘256M’);

Contact your hosting company

If none of these solutions worked for you, you can consult your web host. Your web host may have configured their servers to prevent you from increasing the file size.

Related Posts

You can find articles similar to this article below.

Why Use WordPress?

October 20, 2020

Why Use WordPress?

You hear a lot about WordPress, but you are not...

Read More