Trying to upload an image, video, plugin or theme to WordPress, only to discover that the file exceeds the maximum upload size?
It’s a common problem, especially when working with larger media files or uploading a premium theme or plugin through the WordPress dashboard.
You might see an error stating that the uploaded file exceeds the maximum permitted size, or WordPress might refuse to complete the upload.
Fortunately, you can often increase the WordPress maximum upload size, although the correct method depends on your hosting provider and server configuration.
In this guide, we’ll explain how WordPress upload limits work, show you where to check your current limit and walk through the safest ways to increase it.
What is the maximum upload size in WordPress?
The maximum upload size is the largest file WordPress will accept through its upload interface.
This limit applies to files uploaded through the WordPress dashboard, including images, videos, documents, plugins and themes.
For example, if your website has a maximum upload size of 32 MB, you won’t normally be able to upload a 50 MB ZIP file through the WordPress admin area.
There’s no single upload limit that applies to every WordPress installation.
Your limit depends on several factors, including:
- Your hosting provider’s restrictions.
- PHP upload configuration.
- Web server and reverse proxy settings.
- WordPress Multisite settings, if applicable.
- Additional limits introduced by plugins or custom hosting configurations.
Some websites allow uploads of only a few megabytes, while others support files of 64 MB, 128 MB or more.
Increasing the limit doesn’t mean WordPress can accept files of unlimited size. Each part of your hosting environment must support the larger request.
1. Check your current WordPress upload limit
Before changing anything, confirm your existing upload limit.
Check the Media Library
Sign in to your WordPress dashboard.
Navigate to Media > Add New Media File.
Look for a message showing the maximum permitted upload size.
For example:
Maximum upload file size: 32 MB
The exact figure will depend on your website.
If the current limit is already large enough for your file, increasing it is unlikely to solve the problem.
Instead, investigate whether the upload is failing for another reason.
Check WordPress Site Health
WordPress also provides information about your PHP configuration.
Navigate to:
Tools > Site Health > Info > Media Handling
Look for values such as:
- Max size of an uploaded file.
- Max size of post data allowed.
- Max effective file size.
- Max number of files allowed.
- Whether file uploads are enabled.
These figures can help identify whether PHP is imposing the restriction.
WordPress’s reported limit may not expose every restriction imposed by your web server, CDN or hosting provider, so treat it as an important diagnostic rather than a complete picture of the entire upload process.
If you’re unsure what the values mean, the official WordPress Site Health documentation explains the information shown.
2. Understand why WordPress upload limits vary
WordPress relies on PHP and your hosting environment to receive uploaded files.
Two PHP settings are particularly important.
upload_max_filesize
The upload_max_filesize directive controls the maximum permitted size of an individual uploaded file.
For example:
upload_max_filesize = 64M
This permits an individual uploaded file of up to approximately 64 MB, subject to other restrictions.
post_max_size
The post_max_size directive controls the maximum size of the entire HTTP POST request.
An upload request contains more than just the file itself. It also includes information associated with the request.
For that reason, post_max_size should be larger than upload_max_filesize.
For example:
upload_max_filesize = 64M
post_max_size = 80M
These are illustrative values, not recommended defaults for every website.
The effective limit is constrained by the applicable settings. Raising only upload_max_filesize may accomplish nothing if post_max_size remains lower.
Other settings can also matter
PHP has additional settings that may influence uploads.
| Setting | What it controls |
|---|---|
upload_max_filesize |
Maximum size of an individual uploaded file |
post_max_size |
Maximum size of the complete POST request |
max_file_uploads |
Number of files permitted in one request |
max_input_time |
Time permitted for PHP to receive and parse input |
memory_limit |
Memory PHP scripts can use |
You don’t normally need to increase all these values.
For instance, increasing memory_limit won’t necessarily change the upload size restriction. It may be relevant if PHP runs out of memory while processing a file, but that is a separate problem.
Similarly, increasing execution time won’t override a file size restriction.
The correct approach is to identify which limit is being reached and adjust only what’s necessary.
For technical details, refer to the PHP documentation for core configuration settings.
3. Decide whether you actually need a higher upload limit
Before changing your server configuration, consider why the file needs to be so large.
For ordinary website images, reducing the dimensions or compressing the file may be a better solution than increasing the upload limit.
For example, uploading a 25 MB photograph when the website only needs a 1,600-pixel-wide image can waste bandwidth, storage and processing resources.
However, increasing the upload limit may be appropriate when you need to:
- Upload a legitimate large theme or plugin ZIP file.
- Add high-resolution images that must retain their original detail.
- Upload documents or downloadable resources.
- Work with media files that cannot reasonably be reduced.
- Import files through a process that uses normal PHP uploads.
If your aim is to fix a failed image upload, first confirm that file size is actually responsible.
Our guide to fixing common WordPress image errors covers other causes, including server processing failures, permissions and blocked requests.
Before changing configuration files, take a recent backup and confirm that you can restore the original settings if something goes wrong.
4. Method 1: Increase the upload limit through your hosting control panel
For most website owners, your hosting provider’s control panel is the best place to start.
Many hosting providers include a PHP configuration interface where you can change supported settings without editing server files manually.
Depending on your hosting provider, it might be called:
- PHP Settings.
- PHP Configuration.
- MultiPHP INI Editor.
- PHP Options.
- PHP Selector.
The available controls and names vary between hosting platforms.
Step 1: Open your hosting dashboard
Sign in to your hosting account and locate the website you want to update.
Find the PHP configuration or settings section.
Make sure you’re changing the settings for the correct website, especially if you host multiple sites on the same account.
Step 2: Locate the upload settings
Look for upload_max_filesize and post_max_size.
If you’re currently limited to 16 MB and need to upload a 50 MB file, you might choose:
upload_max_filesize = 64M
post_max_size = 80M
This leaves some room for the additional data included in the upload request.
Choose values appropriate for your actual needs and hosting resources. There’s no benefit in setting unnecessarily high limits.
Step 3: Save the changes
Save or apply the new settings.
Some hosting platforms apply them automatically. Others may need to reload the relevant PHP service.
Follow your provider’s instructions rather than restarting services unnecessarily.
Step 4: Verify the new limit
Return to Media > Add New Media File in WordPress.
Check whether the displayed maximum upload size has changed.
You can also revisit Tools > Site Health > Info > Media Handling.
If the values haven’t changed, your hosting provider may be enforcing a higher-priority configuration or additional restriction.
Avoid immediately trying multiple unrelated configuration methods. First establish why the original change didn’t take effect.
What if your host doesn’t provide these settings?
Some managed WordPress hosts don’t allow customers to change upload limits directly.
In that situation, contact support and ask whether they can increase the limit for your website.
Tell them the current limit, the required file size and the type of file you’re trying to upload.
They can confirm whether the requested increase is supported and which server-level limits apply.
5. Method 2: Adjust the active PHP configuration
If you manage your own server or have suitable technical access, you may be able to change the upload limits through PHP’s configuration.
This requires more care than using a hosting control panel.
Identify the active PHP configuration
PHP normally reads configuration from a php.ini file, potentially alongside other configuration files.
However, the php.ini file that controls your website may not be located in your WordPress directory.
Its location depends on your operating system, PHP version and hosting setup.
On a server running PHP-FPM, the website may also be subject to PHP-FPM pool-level settings.
Importantly, PHP’s command-line configuration can differ from the configuration used to serve your website.
Running:
php --ini
can help identify the configuration used by the command-line PHP executable, but it doesn’t prove that your website uses the same configuration files or values.
Use your hosting management tools or the relevant PHP-FPM configuration to identify the settings applied to web requests.
Make a backup before editing
Before changing an active PHP configuration file, save a copy of the original.
Make sure you know how to restore it if the change is rejected or causes an unexpected problem.
For example, a suitable configuration might contain:
upload_max_filesize = 64M
post_max_size = 80M
Adjust the existing directives rather than introducing unnecessary duplicate settings.
Apply the changes safely
Depending on the environment, changes to the active PHP configuration may require the relevant PHP-FPM service to reload.
On a managed server, use the hosting panel’s supported configuration and reload process.
If you manage the server directly, validate the configuration before reloading the service.
Then return to WordPress and check whether the new upload limit is reflected in Site Health.
If the limit hasn’t changed, investigate configuration precedence before making further edits.
Why editing wp-config.php doesn’t usually solve this
You might find tutorials recommending PHP code in wp-config.php to change upload limits.
However, upload_max_filesize and post_max_size aren’t ordinary runtime settings that can reliably be changed using PHP’s ini_set() function.
Their values need to be configured through a supported PHP or hosting mechanism.
Similarly, adding upload-related PHP settings to your theme’s functions.php file is not a reliable solution.
It can also introduce unnecessary risks if the code is incorrect or a theme update replaces your changes.
Don’t modify functions.php to increase PHP upload limits.
6. Method 3: Use a .user.ini file where supported
Some websites running PHP through CGI or FastCGI, including many PHP-FPM environments, support per-directory PHP configuration through .user.ini files.
This can provide a way to adjust certain PHP settings without modifying the server’s main php.ini file.
However, it only works when the hosting environment supports it.
Check whether .user.ini is supported
Before creating or editing a .user.ini file, confirm with your hosting provider that the feature is enabled.
The default filename is .user.ini, but administrators can change or disable this behaviour.
PHP also restricts which settings can be changed through these files.
Add the relevant configuration
If supported, a .user.ini file might contain:
upload_max_filesize = 64M
post_max_size = 80M
The file must be placed in a directory where it will be applied to the relevant PHP request.
Don’t assume that placing it somewhere inside your WordPress installation will affect every upload endpoint.
If your host already provides a .user.ini file, review its existing contents before changing it.
Allow the settings to refresh
PHP doesn’t necessarily reread .user.ini files on every request.
The default refresh interval is five minutes, although the hosting provider can configure a different value.
After allowing the change to take effect, check the upload limit again in WordPress.
If it remains unchanged, your host may disable .user.ini support or override the setting elsewhere.
Don’t create additional copies of the file in multiple directories without understanding how the configuration is applied.
For further information, see the official PHP documentation on .user.ini files.
7. Method 4: Check web server and reverse proxy upload limits
Even if PHP allows larger files, your web server or a reverse proxy may reject the upload before PHP receives it.
This is especially relevant when you encounter an HTTP 413 Content Too Large response.
Nginx upload limits
Nginx uses the client_max_body_size directive to control the permitted size of an HTTP request body.
A configuration might contain:
client_max_body_size 96m;
This is an illustrative example for an environment that needs to accommodate uploads up to 64 MB with additional room for the request.
It is not a setting to add blindly to an existing server.
The directive belongs in an appropriate Nginx configuration context, and changes normally require configuration validation and a controlled Nginx reload.
Your hosting provider or server administrator should confirm where it belongs and whether a lower limit is set elsewhere.
The official Nginx documentation explains this directive.
Apache upload limits
Apache also supports restrictions on HTTP request sizes, including the LimitRequestBody directive.
The relevant configuration depends on the server and any additional modules or proxies involved.
Older tutorials sometimes recommend adding PHP settings such as these to .htaccess:
php_value upload_max_filesize 64M
php_value post_max_size 80M
These directives are only applicable in compatible Apache configurations where PHP runs as an Apache module and the necessary overrides are permitted.
They are not a universal WordPress solution.
Adding them to an incompatible configuration, including many Apache setups using PHP-FPM, can result in an HTTP 500 error.
Don’t use .htaccess as a general method of increasing upload limits unless your hosting provider specifically confirms that it is supported.
CDNs and security proxies
Some websites route uploads through additional services, such as a web application firewall, reverse proxy or CDN.
These services may impose request size limits independently of WordPress and PHP.
If your PHP settings appear correct but larger uploads still fail, check whether an upstream service is rejecting them.
Your hosting provider or security service may be able to identify the relevant restriction from request logs.
Increasing PHP’s upload limit cannot override a smaller limit imposed by an upstream service.
8. WordPress Multisite: Check network upload restrictions
If your website belongs to a WordPress Multisite network, additional upload restrictions may apply.
These are separate from PHP’s configuration.
A network administrator can configure upload restrictions that affect individual websites across the network.
Check Network Admin settings
If you have Super Admin access, navigate to:
Network Admin > Settings > Network Settings
Look for the Upload Settings section.
Depending on your WordPress configuration, it can include controls for:
- Site upload space.
- Permitted upload file types.
- Maximum upload file size.
The site upload space setting controls the total amount of storage a website is permitted to use within the network.
The maximum upload file size controls the permitted size of an individual uploaded file.
These are different restrictions.
Update the appropriate setting
If the network permits only 10 MB uploads, increasing PHP’s limit to 64 MB won’t necessarily allow a 50 MB file.
The Multisite setting must also permit it.
Similarly, increasing the individual file size limit won’t resolve a website that has already exhausted its total upload space quota.
If you don’t have Super Admin access, ask the network administrator to review the relevant settings.
Don’t attempt to bypass network restrictions through theme code or unsupported plugins.
9. How to confirm your new upload limit works
After changing the appropriate settings, verify the result rather than assuming the change was successful.
Check WordPress’s reported limit
Return to:
Media > Add New Media File
Confirm that the maximum upload file size reflects the expected value.
Then check:
Tools > Site Health > Info > Media Handling
Review the effective PHP limits.
Remember that the displayed value may not reveal restrictions imposed by Nginx, Apache or a reverse proxy.
Test with a legitimate file
Choose a file that falls within your intended limit.
For example, if you’ve increased the limit to 64 MB, try a genuine file moderately larger than the previous limit but smaller than the new one.
Upload it through the same WordPress interface that previously failed.
If you’re troubleshooting plugin or theme uploads, test the relevant installation interface rather than assuming a successful Media Library upload proves every route works.
Confirm the upload completed
For media files, check that WordPress created the Media Library record and stored the uploaded file correctly.
For a plugin or theme, confirm that the package installed successfully without introducing errors.
For images, also verify that WordPress can generate the required image sizes.
A file can pass the upload limit but still fail during subsequent processing.
If you’re testing on a live website, avoid installing unneeded software or leaving unnecessary test files behind.
10. What if the upload limit doesn’t change?
If you’ve followed the appropriate hosting method but the limit remains unchanged, work through these checks before making further modifications.
Check whether you changed the correct PHP configuration
Servers can run multiple PHP versions or separate PHP-FPM pools.
Make sure the changes apply to the PHP environment serving the affected website.
A configuration change for command-line PHP may have no effect on web uploads.
Check post_max_size
If post_max_size is smaller than or equal to the desired file upload size, the request may still fail.
Leave suitable headroom above upload_max_filesize.
Check for server-side request limits
A web server or proxy can reject a large request even when PHP permits it.
If the browser reports HTTP 413, investigate request body limits at every relevant layer.
Review hosting restrictions
Managed hosting providers may enforce restrictions that can’t be overridden through files in your WordPress directory.
Ask the host whether an account-level limit applies.
Check for timeouts
Large uploads over slow connections can encounter timeouts.
If the failure is related to elapsed time rather than file size, investigate the relevant upload and request timeouts.
Changing a timeout setting won’t increase the maximum permitted file size.
Check disk space and temporary storage
PHP needs a suitable location to receive uploaded files, and WordPress needs writable storage to save them.
A full disk or unusable temporary upload directory can cause failures independently of upload size settings.
Don’t overlook unrelated upload errors
A 403 error might come from a firewall or permissions problem.
A 500 error might indicate a PHP or server issue.
A file type restriction can reject a file even when its size is within the allowed limit.
If you’re seeing these symptoms, refer to our guide to common WordPress image errors or our file permissions troubleshooting guide.
11. Alternatives to increasing the upload limit
Increasing the limit isn’t always necessary or desirable.
For some files, an alternative approach will be more appropriate.
Resize or compress images
For website photographs and ordinary graphics, prepare the image at a suitable size before uploading.
This can reduce storage, bandwidth and processing requirements without a noticeable loss of quality.
Use a supported alternative installation method
For large plugins and themes, your hosting provider or software vendor may document an alternative installation method using secure file transfer.
This can avoid the browser upload mechanism, but it does not remove the need to validate the software package or ensure the installation process is completed correctly.
Only use files obtained from trusted sources, and follow the vendor’s installation instructions.
Use suitable external storage
Large videos or downloadable files may be better hosted using an appropriate media hosting or file storage service.
This can reduce the load on your WordPress hosting account and may provide better delivery performance.
However, choose a service that meets your access, privacy and reliability requirements.
Keep limits proportionate
An unnecessarily high upload limit can allow larger requests to consume more bandwidth, processing capacity and temporary storage.
Set limits according to your actual requirements rather than increasing them without restriction.
Frequently asked questions
What is the default maximum upload size in WordPress?
WordPress doesn’t impose one universal upload limit across all installations.
The effective limit depends on PHP, the hosting environment and any additional WordPress or server restrictions.
Check Media > Add New Media File to see the reported limit for your website.
Can I increase the WordPress upload limit to 128 MB?
Potentially, yes.
Your hosting provider, PHP configuration, web server and any additional restrictions must all permit requests of the required size.
A 128 MB individual file limit also requires a sufficiently larger limit for the complete POST request.
Check whether such a large upload is appropriate for your website before making the change.
Can I increase the upload size through wp-config.php?
Not reliably for the main PHP upload size directives.
Settings such as upload_max_filesize and post_max_size need to be changed using an appropriate PHP or hosting configuration method.
Changing WordPress’s PHP memory constants is not a substitute for increasing the actual upload limit.
Does increasing the PHP memory limit increase the upload size?
No, not directly.
PHP memory limits and upload size limits control different things.
Additional memory might help when a server runs out of resources while processing an image, but it won’t override a smaller upload_max_filesize setting.
Can a plugin increase the maximum upload size?
Some plugins provide interfaces for changing upload-related settings, but their effectiveness depends on your hosting environment.
A plugin cannot reliably override PHP, web server or hosting restrictions that the website isn’t permitted to change.
Using your hosting provider’s supported configuration method is generally preferable.
Why does WordPress still reject my file after increasing the limit?
Another restriction may be lower than the new PHP limit.
Common possibilities include post_max_size, web server request limits, Multisite restrictions, hosting account limits or upstream proxies.
The failure may also be unrelated to file size.
Check the exact error message and relevant logs before making further changes.
Need help increasing your WordPress upload size?
Increasing the WordPress maximum upload size can be straightforward when your hosting provider supplies the right controls.
But when several layers of server configuration are involved, it’s important to identify which setting is actually responsible.
Changing theme files or adding unsupported server directives can create additional problems without solving the upload error.
At Newt Labs, we help website owners investigate WordPress configuration problems, resolve upload errors and make appropriate server-side changes.
If your website is still rejecting legitimate uploads, our one-off WordPress website repair service can help identify the restriction and resolve the problem safely.
And if you’re looking for ongoing help keeping your website secure, maintained and running smoothly, explore our WordPress maintenance plans.

