How to Increase the PHP Max Upload Size in cPanel?

When the size of the file that you’re trying to upload to your website exceeds the uploading file size limit, you’ll be given an error and the process will stop. The error will notify you that the attempted upload is bigger than the allowed limit, and it will prompt you to increase the max uploading size.

For people who don’t have an idea about why this error occurs and how to resolve it, this situation could be unnecessarily annoying and alarming.

Turns out, there is an easy fix and a simple way to get around this thingamajig. That’s what we are going to be looking at in this post.

What is the Upload Max Filesize?

The ‘upload_max_filesize’ value is what decides the limit of the file size that can be uploaded to a website. When this value is set to a certain number of bytes, all uploads beyond it will be turned down and will fail to be uploaded.

In other words, the upload max filesize sets the bar for the size of the files that can be uploaded to a website.

By default, this value is set to 2 MBs in PHP. That is a low threshold, and nowadays, with newer websites and applications, it can be quite insufficient.

How to increase the PHP Max Upload Size in cPanel?

With cPanel, it’s very easy to increase the max upload size. There are just a few steps that you have to follow. Here they are:

• Open up PHP selector

Head over to the main menu in cPanel. Go under Software and open the Select PHP version. This is the screen you should see:


• Click on Options and scroll down to ‘upload_max_filesize’ and set the value

Once you get all the options listed underneath, scroll down to where it says ‘upload_max_filesize’.

Go ahead and from the drop-down menu set the maximum file size you would like. That’s it.


Some things to remember….

When increasing the max uploading file size, there are a few things to remember.

• Keep in mind, when increasing the uploading max filesize, The post max size should be equal to or greater than the upload max filesize. There is another value as well, which is called the ‘Memory limit’, and this should be larger or equal to the post max size as well. It’s basically like this:

Upload Max Filesize ≤ Post Max Size ≤ Memory Limit

• This limit is when uploading to the site directly, e.g. within the /wp-admin/media folder. The upload filesize within the File Manager in Cpanel, is up to 2GB.

• If you need to upload larger files than 2GB, use FTP or SSH.

How much should the max file size be increased?

The standard 2M limit is too low, period. While it could have been enough some time ago, it is not anymore. That is why you will have to, at some time or the other, increase the limit.

Now remains the question of how much should it be raised? If you raise it insufficiently, then it will obviously not be enough for the users to get their stuff up. If you raise it too much, there is the chance that your site could start to get held up due to the influx of large and bulky data bundles.

Essentially, it depends on the type of files that need to be uploaded to your website. If it is a site purely for written material and blog posts etc., then 20M could be enough. On the other hand, if it is for audio files, 30M or 40M could be sufficient. This has to be carefully calculated because adjusting the limit either too low or too high could be problematic.


So there you have it. If you are facing the file size exceeding the maximum upload limit error, you will need to increase the capacity by going to the PHP selector in cPanel. The process is pretty straightforward. Go ahead and scroll up ahead to look at it once again.