Economicalhost · Knowledge Base
Knowledge Base › WordPress & Apps › How to Increase the WordPress Memory Limit
WordPress & Apps

How to Increase the WordPress Memory Limit

"Allowed memory size exhausted" means WordPress needs more PHP memory. You can raise it in WordPress itself and at the PHP level — here is both.

Step-by-step

  1. Edit wp-config.php. In File Manager, open public_html/wp-config.php and add this line above "/* That's all, stop editing! */":
    define('WP_MEMORY_LIMIT', '256M');
  2. Save the file and reload your site — many memory errors clear immediately.
  3. If the error persists, raise the PHP memory limit too. Open MultiPHP INI Editor (see PHP memory limit).
  4. Set memory_limit to 256M (or 512M for large stores) and save.
  5. For the admin area specifically, you can also add define('WP_MAX_MEMORY_LIMIT', '512M'); to wp-config.php.
  6. Re-test the page that was failing — it should now load.

💡 Good to know

  • Always back up wp-config.php before editing it.
  • Persistent high memory use often comes from a heavy plugin — disable plugins one by one to find it.
  • Your plan has overall limits; if you constantly need more, discuss an upgrade with EconomicalHost.