Short answer: Go to cPanel Select PHP Version > Options tab, and increase memory_limit, upload_max_filesize, post_max_size, and max_execution_time to match application requirements.
Quickly increase upload_max_filesize, memory_limit, post_max_size, and max_execution_time using CloudLinux PHP Selector and .user.ini.
Before you start: Back up your site files and database and download the backup to your own computer. How to take a full backup
Quick reference
| Interface | cPanel > Software > Select PHP Version > Options Tab |
|---|---|
| Alternative File | public_html/.user.ini |
| Recommended WordPress Values | memory_limit = 512M | upload_max_filesize = 128M | max_execution_time = 300 |
Steps
- Open PHP Selector: In cPanel, navigate to Software > Select PHP Version.
- Switch to the Options Tab: At the top of the interface, click on the Options tab.
- Adjust Critical Directives: Click the value next to any directive to edit it:
- memory_limit: Increase to
256Mor512M(essential for heavy plugins and WooCommerce). - upload_max_filesize: Increase to
64M,128M, or256Mfor large theme/plugin uploads. - post_max_size: Must be set equal to or greater than
upload_max_filesize(e.g.,128M). - max_execution_time: Change from
30to120or300seconds to prevent timeouts during imports. - max_input_vars: Increase to
3000or5000for massive mega-menus or translated option tables.
- memory_limit: Increase to
- Save: Click anywhere outside the input box. CloudLinux saves the settings automatically.
Troubleshooting and tips
- Values Not Applying via .htaccess: Change PHP values from the Options tab of Select PHP Version or in
.user.ini. If addingphp_valuelines to.htaccesscauses an HTTP 500 error, remove those lines. - Hard Limits: Shared hosting accounts have an upper physical memory ceiling governed by CloudLinux LVE. Setting
memory_limit = 4096Mwill still be capped by your account's physical RAM quota (PMEM).
Need more help? If you run into an error while following these steps, open a ticket with technical support and our team will look into it. Open a ticket