+254725682556 +254725052660 info@ziprof.co.ke
Client Area

Hosting

How to Increase PHP Upload and Memory Limits for Your Website

If a file upload keeps failing, or your site shows a "memory exhausted" error, the usual fix is to raise a PHP limit on your hosting account. These limits control how large a file you can upload and how much memory a script is allowed to use, and you can change them yourself without contacting support.

What These Limits Control

  • upload_max_filesize: the largest single file you can upload through a web form, for example a media upload on your website.
  • post_max_size: the total size of a submitted form, including all files together. This should always be equal to or larger than upload_max_filesize.
  • memory_limit: how much memory a single PHP script can use before it stops with an error.

How to Change Your PHP Limits

In cPanel

  1. Log in to cPanel.
  2. Under the Software section, click MultiPHP INI Editor.
  3. Select your domain from the dropdown, or switch to Editor Mode for more control over individual settings.
  4. Find upload_max_filesize, post_max_size, and memory_limit, and enter new values, for example 64M for uploads and 256M for memory.
  5. Click Apply or Save.

In DirectAdmin

  1. Log in to DirectAdmin.
  2. Go to Extra Features and click Select PHP Version.
  3. Click the link to switch to PHP options, so you can see individual settings rather than just the version selector.
  4. Adjust upload_max_filesize, post_max_size, and memory_limit to the values you need.
  5. Click Save to apply the changes.
Changes usually take effect immediately. If you don't see the update reflected, clear your browser cache or wait a minute before reloading the page you were testing.

If You Don't See These Options

Some accounts have these settings locked at the server level for stability reasons. If the fields are greyed out or missing, or your changes don't seem to save, contact ZIPROF support and let them know the specific limit you need raised.