You try to upload a theme or a chunky image and WordPress refuses: “the uploaded file exceeds the upload_max_filesize directive”. That limit is set by PHP, not WordPress, and raising it takes a minute in cPanel.
Check your current limit
Go to Media → Add New in WordPress. The maximum upload size is shown right there. Many hosts default to somewhere between 8 MB and 64 MB.
Raise it with the MultiPHP INI Editor
This is the cleanest method on cPanel hosting.
- Open MultiPHP INI Editor in cPanel.
- Select your domain from the dropdown.
- Set
upload_max_filesizeto something like128M. - Set
post_max_sizeto the same or larger value — it must be at least as big as the upload limit, or uploads still fail. - While you’re there, bump
max_execution_timeto300so large uploads don’t time out. - Click Apply.
Alternative: edit .htaccess
If you prefer, add these lines to your site’s .htaccess:
php_value upload_max_filesize 128M
php_value post_max_size 128M
php_value max_execution_time 300
If this causes a 500 error, your server doesn’t allow PHP values in .htaccess — remove them and use the INI Editor instead.
Alternative: php.ini
Some setups read a php.ini file in the site root. You can add the same three directives there. The INI Editor is easier, but this works if you’re editing directly.
Why post_max_size matters
People often raise upload_max_filesize and forget post_max_size. The whole POST request (file plus form data) must fit inside post_max_size, so keep it equal to or larger than the upload limit. Miss this and the fix appears to do nothing.
Refresh the Media → Add New page to confirm the new limit. If it hasn’t budged after using the INI Editor, drop us a line and we’ll raise it at the server level.