How to Increase PHP Limits (memory_limit, upload_max_filesize)
Check your current PHP limits in WordPress Site Health, then open a support ticket with the setting (such as memory_limit, upload_max_filesize or post_max_size) and the exact value you need. The highest values are set by the server.
Applies to: CloudLinux cPanel Blue Arctic Shared Web Hosting (cPanel)
On this page
PHP settings limit what your site can do, such as how much memory one page can use or how large an uploaded file can be. If you see “Allowed memory size of … bytes exhausted”, “… exceeds the maximum upload size for this site” or “The uploaded file exceeds the upload_max_filesize directive in php.ini”, the matching limit needs to go up. Check your current value, then ask us for the new one.
Note
This guide is for Shared Web Hosting. On Managed WordPress Hosting, open a support ticket with the setting and value you need.
Which setting to change
| Setting | What it controls | Raise it when |
|---|---|---|
memory_limit | Memory one page load can use | You see “Allowed memory size of … bytes exhausted” |
upload_max_filesize | Largest single file you can upload | A large image, theme or plugin upload fails |
post_max_size | Total size of one form submission or upload | Keep it a little larger than upload_max_filesize |
max_execution_time | Seconds a script can run | Imports or backups time out |
max_input_vars | Number of fields a form can send | Large menus or settings pages don’t save fully |
Tip
Raise a limit a little at a time, then test again. Very high limits can hide a faulty plugin and use up your account’s resources faster. The highest values on offer are set by the server.
1. Check your current limits
If your site uses WordPress:
- Go to Tools → Site Health, click Info, and open Server.
- Write down PHP memory limit, Upload max filesize and PHP post max size. If you also see PHP memory limit (only for admin screens), ignore that row. WordPress raises it for its own admin pages.
If your site doesn’t use WordPress, copy the full error message instead.
2. Ask us to raise the limit
- Open a support ticket from the Client Portal.
- Give your domain, the setting (for example
memory_limit), the value it has now and the exact value you need. A plugin’s instructions or error message usually says what it needs. For memory and file sizes, write the number with anM(megabytes), as in128M. - Say what needs it, such as the upload or import that failed.
If your cPanel has a Select PHP Version or MultiPHP INI Editor tool (type its name in cPanel’s search box, Ctrl+K or Cmd+K), you can raise the setting there yourself instead. Changes in Select PHP Version can apply to every site on your account. In MultiPHP INI Editor, choose your domain rather than Home Directory, which changes every site, and always type the M: without it, 128 means 128 bytes, which can stop your site loading.
Why not edit .user.ini or .htaccess yourself?
Blue Arctic’s shared servers run the LiteSpeed web server. LiteSpeed doesn’t recommend .user.ini files, so a file you make yourself may be ignored. Ask us for the change instead.
Warning
Don’t add PHP lines to .htaccess yourself. One mistake in that file can take your whole site offline.
How to tell it worked
When we’ve made the change:
- If your site uses WordPress, go back to Tools → Site Health → Info → Server and check that the values have changed.
- In WordPress, you can also go to Media → Add Media File and read Maximum upload file size: under the upload box.
- Try the upload or task that failed before.
Troubleshooting
- The new value doesn’t show: wait a minute, then reload. Check that you’re looking at the right site. If it still shows the old value, reply to your ticket. Don’t edit
wp-config.phpfor this. - Uploads still fail at the same size: ask us to raise
post_max_sizetoo. It must be larger thanupload_max_filesize. - Your site shows an error right after a change: reply to your ticket straight away. If you changed the value yourself, set it back to what it was, then check that you typed the
M. - The value you need is higher than we can set: explain in your ticket what needs it.
Still need help?
Open a support ticket from the Client Portal at my.bluearctic.com (see our support page). Include your domain, the setting and value you need, the full error message, a screenshot and what you already tried. Never include your password.