You can increase the PHP memory limit for a specific website to allow it to process larger tasks, such as installing plugins or processing large images. This procedure is performed by a customer with access to the website's hosting control panel.
Before you begin
You will need:
Access to your hosting control panel (such as cPanel or Windows Control Panel)
The specific website's domain or account information
Adjusting the PHP Memory Limit
The method for increasing the memory limit depends on the type of hosting environment you are using.
For Linux-based hosting (cPanel)
Log in to your hosting control panel.
Locate and open the Select PHP Version or MultiPHP INI Editor tool.
Select the specific domain or account you wish to modify.
Locate the
memory_limitsetting in the list of PHP variables.Change the value (e.g., from
128Mto256Mor512M).Click Save or Apply to update the configuration.
For Windows-based hosting (Windows Control Panel)
Log in to the Windows Control Panel.
Navigate to the PHP Settings or PHP Manager section.
Select the specific website or application.
Locate the
memory_limitdirective in the configuration list.Update the value to your desired limit (e.g.,
512M).Click Save or Apply.
Confirm the result
To verify that the change has been applied, you can use a PHP information script:
Create a file named
info.phpin your website's root directory.Add the following code to the file:
<?_php phpinfo(); ?>
Open the file in your browser by navigating to
http://example.com/info.php.Locate the Loaded Configuration File or PHP_OPTIONS section to find the
memory_limitvalue.Once confirmed, delete the
info.phpfile from your server for security.
Limitations
The maximum allowable memory limit may be restricted by your specific hosting plan.
If you are using a Content Management System (CMS) like WordPress, some plugins may have their own internal limits that are independent of the server's PHP configuration.
Changes to PHP settings may take a few moments to propagate across the server.
