Site Login

Lost your password? (close)

Nigeria Bloggers Forum

Welcome, Guest: Join Nigeria Bloggers Forum / / Advertise / Privacy / Recent / Terms and Conditions / News
Stats: 6 members, 7 topics. Date: Saturday, 15th May 2021 at

 

How to increase the upload_max_filesize limit in cPanel

Nigeria Bloggers Forum / Web Master / How to increase the upload_max_filesize limit in cPanel (22 Views)

(0) (Reply)

How to increase the upload_max_filesize limit in cPanel by : 9:09 pm On April 24, 2021


In some cases, default server settings may not let you upload larger files via your website. This tutorial shows how to increase PHP upload limit in cPanel or by modifying .htaccess file.

What you’ll need
Before you begin this guide you’ll need the following:

Access to your hosting account’s cPanelOR
Ability to connect via FTP client
Option 1 – Increasing PHP upload Limit in cPanel
If you don’t have access to cPanel, please refer to Option 2.

Step 1 — Opening up PHP Settings
Log in to your cPanel and navigate to Select PHP Version –> Switch to PHP Options:

Step 2 — Changing Upload Limit values
Let’s say you are having an error while trying to upload 19 Mb WordPress theme file through your WordPress Admin Area.
The following configuration illustrates appropiate settings for this example:

Set memory_limit to 128M. memory_limit describes the maximum amount of memory a script can allocate. It is recommended to set this to maximum available value. Letter M stands for megabytes.
Set upload_max_filesize to 64M. upload_max_filesize describes a maximum size of an uploaded file. It must be larger than the theme file mentioned in the example.
Set post_max_size to 64M. post_max_size has a similar functionality to upload_max_filesize. Make it larger than 19 MB (theme file) as well.

Don’t forget to Save the changes.

IMPORTANT! Your cPanel may be a bit different and you may not have found Select PHP Version section. Consult your hosting provider about modifying PHP variables.

Option 2 – Increasing PHP Upload Limit Using .htaccess
If there is no possibility to edit PHP settings via your cPanel, you can use another method which involves editing your .htaccess file by connecting via FTP Client. The following tutorial explains connecting via FTP Client in detail:

Note that .htaccess file is a hidden file, therefore you would need to enable its visibility.

Add the following lines to .htaccess file to increase upload limit:

php_value memory_limit 128M

php_value upload_max_filesize 64M

php_value post_max_size 64M
Conclusion
You have learned how to increase PHP upload limit in cPanel. You have also learned an alternative method to accomplish that using .htaccess file by connecting via FTP Client.

Note that your website settings may be overriding server configuration. In this case, you would need to configure these settings separately.

Reply


(0) (Reply)

HOW TO UNBLOCK YOUR URL FROM FACEBOOK (%100 GUARANTEED) / 6 WAYS TO FIX 500 INTERNAL SERVER ERROR /  

(Go Up)

Put your Text Adverts Here...

Sections: Featured Posts on Front Page (6) Phones (1) SEO Tips (1) Web Master (3) WordPress (2) WordPress Plugins (1)

Links: (0) (1) (2) (3) (4) (5) (6) (7) (8) (9)

Copyright © All rights reserved.
Disclaimer: Every member is solely responsible for anything that he/she posts or uploads here.