TicketHelp
Language

How to Modify PHP Memory Limit

Home  /  Blog  /  How to Modify PHP Memory Limit
04.10.2026 TicketHelp Editorial Team Blog
25 views
How to Modify PHP Memory Limit

Demanding applications like WordPress with WooCommerce or PrestaShop often require higher PHP memory limits. Here is how to configure them:

Method 1: DirectAdmin / cPanel PHP Selector

  1. Log in to your hosting control panel.
  2. Go to Select PHP Version → Options tab.
  3. Locate memory_limit and select your desired value (e.g., 256M, 512M, 1024M).
  4. Optionally adjust upload_max_filesize and post_max_size as needed.
  5. Settings are applied instantly without server restarts.

Method 2: Custom .user.ini file

Create or edit a .user.ini file in your website's document root (public_html) and add:

memory_limit = 512M
max_execution_time = 300
upload_max_filesize = 64M
post_max_size = 64M
Back to Blog
Looking for another option? Talk to us about an annual subscription discount or a hosting plan dedicated to your business!