"The Uploaded File Exceeds the upload_max_filesize Directive"
WordPress refuses a file with "The uploaded file exceeds the upload_max_filesize directive in php.ini" or a 413 Request Entity Too Large error — the file is bigger than your server is set to accept.
Common signs of this issue
- WordPress shows "The uploaded file exceeds the upload_max_filesize directive in php.ini" when you add a file.
- The media uploader says "filename exceeds the maximum upload size for this site" before the upload even starts.
- Large uploads end in a plain page reading "413 Request Entity Too Large", often with "nginx" underneath.
- Media, then Add New shows a small "Maximum upload file size" figure, such as 2 MB, 8 MB, or 64 MB.
- Small images upload fine, but videos, PDFs, big photos, theme zip files, or backup files fail.
- Bigger uploads sometimes fail silently: the page reloads with no error and no file.
Safe checks you can do yourself
None of these require sharing passwords with anyone.
- Check your current limit: go to Media, then Add New in the WordPress dashboard and read the "Maximum upload file size" line under the upload box. Compare it with the size of the file you are trying to upload (right-click the file on your computer and choose Properties or Get Info).
- Ask whether the file needs to be that big. Photos straight off a phone or camera are often several megabytes each; resizing to around 2000 pixels wide and compressing usually brings them well under 1 MB and makes your pages faster too. See how to reduce image size for a website.
- For video, upload to YouTube or Vimeo and embed it instead of putting the file in the media library. Video served from ordinary hosting is slow for visitors and eats your storage and bandwidth.
- If you do need a higher limit and your host uses cPanel, look for MultiPHP INI Editor (under Software). Pick your domain, then raise
upload_max_filesizeand setpost_max_sizeto the same or a slightly larger value. Many hosts with their own dashboards have a similar "PHP settings" screen — the exact label varies. - While you are there, check
max_execution_timeandmemory_limit. A large upload that passes the size check can still fail if the server gives up on processing it; modest increases are usually enough. - Save, then reload Media, then Add New to confirm the new "Maximum upload file size" figure. If it has not changed, the setting was probably overridden elsewhere or your plan caps it.
- If the error is 413 Request Entity Too Large, the limit is in the web server (often nginx) rather than PHP. That setting is usually not in your dashboard — ask your host to raise the request body size for your site.
- If none of these settings exist for you, open a support ticket and simply ask: "Please raise upload_max_filesize and post_max_size to 64M for my site." Most hosts do this in minutes, and some managed hosts have fixed caps you cannot exceed.
What this usually means
WordPress does not set this limit itself — it inherits it from PHP, the language WordPress runs on. Two PHP settings matter: upload_max_filesize is the largest single file PHP will accept, and post_max_size is the largest total amount of data a form submission can carry. The smaller of the two wins, so raising one without the other often changes nothing. Many hosts ship with low defaults, and PHP's own out-of-the-box default is only a couple of megabytes.
A 413 Request Entity Too Large error means the file was stopped even earlier, by the web server in front of PHP, before WordPress ever saw it. The same idea applies — the upload is bigger than the server allows — but the fix lives in a different place, which is why it usually needs your host. If the upload is a theme or plugin zip and you see "The link you followed has expired" instead, it is the same size problem wearing a different message: see the link you followed has expired.
Oversized uploads are often a symptom of a workflow problem rather than a server problem. Full-resolution photos and raw video files make pages slow, fill up hosting storage, and bloat backups. Raising the limit is fine when you genuinely need to upload larger files like PDFs or theme packages, but for everyday images the better fix is smaller files. If uploads fail with a vague "HTTP error" rather than this message, that is a different set of causes, covered in WordPress HTTP error when uploading images. A rejected file type is covered in file type not permitted.
What not to do
- Don't install a plugin that promises to raise the upload limit without checking your host allows it. Most such plugins cannot override the server's settings and just add clutter.
- Don't edit php.ini, .htaccess, or wp-config.php by copying code from random forums. The wrong line in .htaccess can take the whole site down with a 500 error.
- Don't set the limit to something enormous like several gigabytes. A sensible limit protects the server from runaway uploads.
- Don't upload full-size camera photos and rely on WordPress to shrink them. The originals are still stored and can slow the site and bloat backups.
- Don't host large videos in the media library if you can avoid it. A video service handles streaming far better than ordinary hosting.
- Don't raise upload_max_filesize without raising post_max_size to match. The smaller value still wins.
When to get help
If your host's dashboard has no PHP settings, the values you changed do not take effect, or the 413 error persists after support says the limit is raised, the setting is being overridden somewhere — a leftover .htaccess rule, a per-folder php.ini, a server-level cap, or a proxy like Cloudflare with its own upload limit. Tracking that down means reading the server configuration rather than guessing, and a wrong edit to .htaccess or php.ini on a live site can take it offline. Help is also worth it if large uploads are part of how your business works — client files, downloadable guides, product media — because the right answer may be a different storage setup rather than an ever-higher limit.
Glenn, who runs WebsiteSelfHelp, sorts out WordPress upload limits and the settings that quietly override them for small business sites. Send a quick description of the file and the exact error and you will get a straight answer on where the limit is set and how to raise it safely. You do not need to hand over any passwords to start.
Not sure what to do next?
Answer a few short questions and we'll point you to the safest next step — DIY, a freelancer, or a direct review. No passwords required.
Is this a business website? If this issue may be costing you leads, sales, or trust, you may want a direct review instead of trial and error.
Frequently asked questions
What does "The uploaded file exceeds the upload_max_filesize directive in php.ini" mean?
The file you tried to upload is larger than the maximum single file size your server's PHP settings allow. WordPress is reporting a limit set by your hosting, not a problem with the file itself.
How do I increase the maximum upload file size in WordPress?
Raise upload_max_filesize and post_max_size in your host's PHP settings, such as the MultiPHP INI Editor in cPanel, then check Media, then Add New for the new figure. If your host has no such screen, ask support to raise it.
What is the difference between upload_max_filesize and post_max_size?
upload_max_filesize limits a single file. post_max_size limits the total data sent in one request, including the file. post_max_size should be equal to or larger than upload_max_filesize, or it becomes the real limit.
What does 413 Request Entity Too Large mean in WordPress?
The web server itself, often nginx, rejected the upload for being too large before WordPress or PHP saw it. Your host usually has to raise that limit, since it is rarely in your dashboard.
What is a good maximum upload size for WordPress?
For most small business sites, somewhere around 32 to 128 MB covers theme packages, PDFs, and properly sized images. Images themselves should usually be well under 1 MB each.
Can I fix the upload_max_filesize error myself?
Usually. Shrinking the file or changing the PHP settings in your hosting dashboard fixes most cases. If the settings are missing or do not take effect, your host or a developer needs to find what is overriding them.
Why did the upload limit not change after I edited the settings?
Another setting is overriding it, you changed the wrong PHP version's settings, the web server has its own cap, or your plan has a fixed limit. Checking which PHP version your site actually uses is a good first step.