Increase memory limit for PHP via .htaccess in Magento 2 with cPanel

If you don’t have access to your php.ini file you can also make the change in your .htaccess file. 

If you are using cPanel at your hosing provider, you can go to your cPanel login > File Manager

Navigate to your public_html folder. This is where Magento 2 is typically installed by default.

There, you will probably not see the .htaccess file because files that start with a dot are hidden in cPanel by default. Go to the top right and click Settings then check Show Hidden Files (dotfiles).

Click on .htaccess and edit

Then you can adjust the memory limits and the timeout instructions:

############################################ ## adjust memory limit      
php_value memory_limit 2048M     
php_value max_execution_time 18000

If you need a developer in your corner, be sure to contact us here at Variux as we offer ongoing support plans to keep Magento 2 running, updated, and secure so that you can focus on selling instead of server configuration.

Previous
Previous

How to Clear the Cache in Your Web Browser - for a computer

Next
Next

The Best Way to Design Product Detail Pages