Increase WordPress Upload Limit: How to Fix "The uploaded file exceeds the limit" Error
When trying to upload a theme, plugin, image, ZIP file, or video to WordPress, the upload may sometimes abort with an error message. A message like the following frequently appears:
"The uploaded file exceeds the upload_max_filesize directive in php.ini."
This message does not mean your WordPress installation is broken. In most cases, the maximum allowed upload size in the PHP configuration is simply set too low. This restriction protects server resources, prevents excessively large uploads, and reduces the risk of faulty or malicious file transfers.
At CURIAWEB.CH, you can often adjust these values yourself directly within cPanel. In this guide, we will show you which settings are important, how to increase the upload limit, and what you can do if very large files still fail to upload reliably through WordPress.
Only increase upload limits as much as makes sense for your website. Extremely high values can unnecessarily tie up server resources or cause upload timeouts if the browser, internet connection, or PHP execution time do not cooperate. For large files, FTP/SFTP is often the better solution.
Why is There an Upload Limit in the First Place?
WordPress itself utilizes your hosting account's PHP configuration. This configuration defines, among other things, the maximum size a file can be when uploaded, how much data a form can transmit, and how much memory PHP can use.
The upload limit affects, for example:
- uploading images to the media library,
- the upload of PDF files, videos, or ZIP files,
- installing WordPress themes as a ZIP file,
- installing or updating plugins,
- importing website content or backups.
If a file is larger than the permitted value, PHP blocks the upload before WordPress can fully process the file.
Which PHP Values are Important for Uploads?
For WordPress uploads, these specific settings are particularly relevant:
upload_max_filesize: the maximum size of a single file.post_max_size: the maximum amount of data that can be transmitted via a single form post.memory_limit: the maximum RAM allocation a PHP script can use.max_execution_time: the maximum execution time of a PHP script in seconds.max_input_time: the maximum time a script is allowed to parse input data.
The interplay between upload_max_filesize and post_max_size is especially important. The post_max_size value should always be equal to or greater than upload_max_filesize. If you wish to upload files up to 128 MB, post_max_size should also be at least 128 MB.
Recommended Values for Typical WordPress Websites
For most WordPress websites, moderate values are perfectly adequate. Overly high limits are rarely necessary and are not automatically better.
| Use Case | Recommended Value |
|---|---|
| Standard images, PDFs, and smaller files | 32M to 64M |
| Themes, plugins, and larger media | 128M |
| Backups, large ZIP files, or imports | 256M or more, if reasonable |
| Very large videos or archives | Better to upload via FTP/SFTP |
Solution 1: Increase Upload Size via cPanel
The recommended approach with CURIAWEB is to adjust settings through cPanel. This changes the PHP configuration cleanly and directly for your hosting account without having to edit WordPress files manually.
- Log in to your cPanel.
- Scroll down to the Software section.
- Click on Select PHP Version or a comparable PHP selection tool.
- Open the Options tab.
- Find the
upload_max_filesizeentry. - Set the value to 64M, 128M, or 256M, for example.
- Next, look for
post_max_size. - Set this value to be at least equal to or slightly higher.
- If necessary, check
memory_limit,max_execution_time, andmax_input_timeas well.
The changes are usually saved automatically and become active shortly thereafter. A server restart is normally not required.
For many WordPress websites, a combination of
upload_max_filesize = 128M, post_max_size = 128M, and memory_limit = 256M is a sensible starting point.Solution 2: Adjust Upload Limit via MultiPHP INI Editor
Depending on your cPanel interface layout, the MultiPHP INI Editor may also be available. This provides another convenient way to adjust PHP values.
- Open the Software section in cPanel.
- Click on MultiPHP INI Editor.
- Select your domain.
- Adjust the values for
upload_max_filesize,post_max_size, andmemory_limit. - Save the changes.
This method is particularly handy if you want to apply changes specifically to a specific domain or website.
Solution 3: Adjustment via the .htaccess File
In some hosting environments, PHP values can also be adjusted via the .htaccess file. However, this method is not always suitable, as it can cause server errors depending on the active PHP mode. Therefore, only use it if you know what you are doing, or if the cPanel route is unavailable.
The .htaccess file is typically located in the root directory of your WordPress installation—where the wp-admin, wp-content, and wp-includes folders reside.
php_value upload_max_filesize 128M php_value post_max_size 128M php_value memory_limit 256M php_value max_execution_time 300 php_value max_input_time 300
If your website displays a 500 Internal Server Error after saving the
.htaccess file, remove the inserted lines immediately. In this case, your hosting environment likely does not support this method of PHP configuration. Use cPanel instead or contact CURIAWEB support.Solution 4: Uploading via FTP or SFTP
For very large files, uploading through WordPress is not always the best option. Browser-based uploads can fail due to time limits, connection dropouts, or memory restrictions. If you want to transfer large themes, videos, ZIP archives, or backups, FTP or SFTP is often more reliable.
Typical examples include:
- large video files,
- complete website backups,
- extensive theme packages,
- import files size up to several hundred megabytes,
- manual plugin or theme installations.
For themes, you typically upload the unzipped files to /wp-content/themes/. For plugins, use /wp-content/plugins/. Afterward, you can activate the theme or plugin in the WordPress admin area.
How to Check the Current Upload Limit in WordPress
You can see directly in WordPress which upload limit is currently active:
- Log in to the WordPress admin area.
- Go to Media » Add New Media File.
- Below the upload box, you will see the maximum upload file size listed.
Alternatively, you can inspect various PHP values under Tools » Site Health » Info » Server. There you will find information regarding the PHP version, memory limit, and other server configuration metrics.
Why Does the Upload Still Fail Despite a Higher Limit?
If the upload still fails after you have raised the limit, there could be several reasons:
- The file is corrupted or incomplete.
- The internet connection dropped during the upload.
- The browser upload session timed out.
- A security plugin is blocking the upload.
- The file format is not allowed by WordPress.
- A cache or an old PHP configuration is still active.
- The file is larger than
post_max_size. - The
memory_limitis too low to process the file.
Therefore, check not only upload_max_filesize, but also the remaining relevant PHP values. RAM memory can play a crucial role, especially with large images, imports, or ZIP files.
Security and Performance: Avoid Unnecessarily High Limits
It can be tempting to set the upload limit directly to very high values like 1 GB or more. However, for normal WordPress websites, this is usually not advisable. The higher the allowed uploads, the heavier the potential load on resources during failed, simultaneous, or abusive uploads.
For websites featuring regular large media files, you should consider serving videos or downloads externally, through a CDN, or via an optimized file repository. WordPress handles images, PDFs, and standard media well, but it is not always the best platform for very large video files.
Recommendation for CURIAWEB Customers
If you run WordPress at CURIAWEB.CH, we recommend adjusting the settings via cPanel first. This method is clean, trackable, and avoids unnecessary modifications to WordPress system files. For most websites, 64M or 128M is sufficient. Higher values should only be set if they are genuinely needed.
In case of recurring upload issues, a quick check of the website configuration is worthwhile. This includes the PHP version, memory limit, active security plugins, file size, file type, and the chosen upload method.
Frequently Asked Questions about the WordPress Upload Limit
What does upload_max_filesize mean?
upload_max_filesize is a PHP configuration value that defines the maximum size a single uploaded file can be. If your file is larger than this value, the upload is blocked.
What is the difference between upload_max_filesize and post_max_size?
upload_max_filesize applies to the individual file. post_max_size applies to the total amount of data transmitted via a form submission. Therefore, post_max_size should be at least equal to or larger than the file size limit.
What upload limit is sensible for WordPress?
For normal websites, 64M or 128M is frequently enough. For larger themes, plugins, or imports, 256M can be useful. Very large files are better transferred via FTP or SFTP.
Can I upload large videos directly to WordPress?
Technically it is possible, but it is often not recommended. Large videos strain disk space, backups, and page load speeds. Specialized video platforms or external storage solutions are frequently better suited for videos.
Why do I still see the old limit after making the change?
Sometimes it takes a short moment for changes to take effect. Additionally, make sure you edited the correct domain, PHP version, or configuration profile. Clear your cache if necessary and recheck the values within WordPress.
Is the upload still not working?
If large files continue to fail or if you are unsure which values make sense for your WordPress website, CURIAWEB support is happy to assist you further.
Contact CURIAWEB SupportTip: Please let us know the affected domain, the file size, and the exact error message. This allows us to help you faster.