WordPress Errors
WordPress Memory Exhausted
Last reviewed
Graphic options · pick what to keep
statusBadge
decisionTree
browserMock
requestTimeline
Direct answer
WordPress memory exhausted means a PHP request ran out of RAM while WordPress was loading—raise the host memory_limit and align WP_MEMORY_LIMIT / WP_MAX_MEMORY_LIMIT in wp-config.php, then find the plugin, builder, or import that is consuming memory instead of endlessly raising the ceiling.
WordPress often surfaces memory exhaustion as a critical-error screen, white screen, failed wp-admin task, or HTTP 500 with “Allowed memory size exhausted” in the log. Page builders, WooCommerce, backup plugins, and bulk imports are frequent triggers. This guide explains how WordPress memory constants relate to php.ini, how to recover safely, and how to tell a memory fatal apart from other WordPress crashes.
What the error means
Every WordPress page load runs inside a single PHP worker with a memory budget set by the host’s memory_limit directive. When WordPress, a theme, or a plugin tries to allocate past that ceiling, PHP stops the request with a fatal: “Allowed memory size of X bytes exhausted.” WordPress can ask for more headroom through WP_MEMORY_LIMIT (front-end and general requests) and WP_MAX_MEMORY_LIMIT (admin and elevated contexts) in wp-config.php—but those defines cannot exceed what php.ini allows. A host capped at 128M will still stop at 128M even if wp-config says 512M. Memory exhaustion is a resource failure, not a syntax or compatibility error: the code may be fine in principle but the request tried to hold too much data at once. On shared hosting, repeated memory fatals can also trigger account-level resource suspensions that look like a broader “site down” problem.
Common symptoms
- Error log or wp-content/debug.log shows “Allowed memory size of … bytes exhausted” with a path under wp-content/plugins or wp-content/themes
- Critical error screen or white screen on heavy pages (builders, cart, reports) while simpler pages still load
- wp-admin fails during plugin updates, media bulk uploads, WooCommerce exports, or Site Health checks
- Elementor, Divi, Beaver Builder, or similar editors crash mid-load while the public homepage mostly works
- HTTP 500 or a generic host error page timed to the same memory fatal in logs
- Raising memory_limit temporarily restores the page; lowering it reproduces the crash on the same URL
- Symptoms worsen after adding a plugin, enlarging a page, importing products, or enabling a new backup/sync job
Most likely causes
- 01 Host PHP memory_limit too low for the current WordPress plugin and builder stack
- 02 WP_MEMORY_LIMIT unset or lower than admin-heavy workflows require
- 03 Page builder, WooCommerce, analytics, or related-products plugins loading oversized datasets in one request
- 04 Runaway loop, unbounded query, or memory leak in a custom snippet, mu-plugin, or poorly written extension
- 05 Image, XML, or CSV import processing huge files in a single PHP worker without batching
- 06 Object-cache or opcode-cache issues amplifying memory use after a partial plugin or PHP update
- 07 MultiPHP INI or plan downgrade that reset memory_limit after a PHP version change
What changed before the problem started
- New or updated page builder, WooCommerce extension, backup, or migration plugin
- PHP version or MultiPHP INI change that lowered memory_limit on the account
- Large product, media, or page import run from wp-admin or a migration tool
- Theme customization or code snippet that queries too many posts or meta rows at once
- Traffic or cron spike hitting a heavy admin-ajax, REST, or Action Scheduler endpoint
- Host plan change or resource enforcement after the site outgrew shared limits
Troubleshooting steps
- 01
Confirm the fatal is memory exhaustion
Open the host error log or wp-content/debug.log and search for “Allowed memory size” or “exhausted.” Note the file path—it often names the plugin, theme, or core include. If the fatal mentions undefined functions, parse errors, or type errors, treat that as a different WordPress crash playbook.
- 02
Raise the host PHP memory_limit first
In cPanel MultiPHP INI, Plesk PHP settings, or your host’s PHP manager, set memory_limit to at least 256M for typical WordPress sites (512M when builders and WooCommerce run together, if the plan allows). Save, wait a minute for the change to apply, and retest the failing URL in a private window.
- 03
Align WordPress memory constants in wp-config.php
Add or update `define('WP_MEMORY_LIMIT', '256M');` and, for stubborn wp-admin tasks, `define('WP_MAX_MEMORY_LIMIT', '512M');` above the “That’s all, stop editing!” line. These cannot exceed the host memory_limit—verify both layers match.
- 04
Isolate the heavy plugin or builder
If a reasonable limit still exhausts, rename the plugins folder via FTP or file manager, or disable likely offenders (builder, backup, feed/sync, statistical plugins) one at a time. Restore service with a sane limit, then re-enable extensions while watching the log for the next fatal line.
- 05
Retest the specific heavy workflow
Reproduce the same action: open the builder, run the import, load the WooCommerce report, or save the large page. Confirm the memory fatal is gone and that lighter pages still behave. Purge page cache and CDN cache so you are not viewing a cached success or failure.
- 06
Enable WP_DEBUG_LOG without displaying errors
Set WP_DEBUG and WP_DEBUG_LOG true with WP_DEBUG_DISPLAY false while reproducing once. Capture the stack trace, then turn debug display off so visitors never see paths, queries, or other internals on a live site.
When to stop troubleshooting
Escalate if the host hard-caps memory below what your stack needs, logs point to encoded or core files you cannot safely replace, exhaustion continues at 512M+, checkout or wp-admin stay down during business hours, or the host suspended the account for resource abuse. Bring the exact fatal line, phpinfo memory_limit, WP_MEMORY_LIMIT values, and a list of builder and WooCommerce plugins.
Information to collect before requesting help
- 01 Exact “Allowed memory size … exhausted” log line with file path
- 02 Effective memory_limit from phpinfo or host PHP settings
- 03 Current WP_MEMORY_LIMIT and WP_MAX_MEMORY_LIMIT values if set
- 04 Whether failure is front end, wp-admin, builder preview, REST, or cron
- 05 Recent plugin, theme, PHP, import, or traffic changes
- 06 WordPress, WooCommerce, and page-builder versions
- 07 Hosting provider, plan type, and any resource-limit notices from the host
How a professional repairs the problem
We confirm the fatal is memory exhaustion—not a generic critical error—then raise host and WordPress limits to a safe baseline for your stack. We isolate the plugin, builder view, import job, or cron task consuming RAM, reconfigure or replace leaky components, and leave limits high enough for legitimate workloads without masking runaway processes. When the host enforces account caps, we document what the site actually needs and coordinate a plan or optimization path so the next traffic spike does not trigger another suspension.
Frequently asked questions
Is WordPress memory exhausted the same as a critical error? +
Why did raising WP_MEMORY_LIMIT do nothing? +
How much memory does WordPress need? +
Can Elementor, Divi, or WooCommerce alone trigger this? +
Will more memory hide a bad plugin forever? +
Does a white screen always mean memory exhaustion? +
Repair dispatch
Still Need Help Fixing Your Website?
If you are not comfortable editing website files, changing server settings, repairing a database, or troubleshooting a live website, professional help may prevent additional damage or downtime. We will review the problem before accepting the repair.
- You will receive a clear explanation of the likely cause.
- We will tell you if the issue falls outside our repair scope.
- No additional work will be performed without approval.
- A backup should be created whenever access and website condition allow it.
Do not share passwords through an unencrypted contact form.