Fill the Server: 80% off your first 4 monthly invoices, monthly billing. Ends Nov 30, 2026. 25 spots in this batch.FILL25
Fill the Server, annual: about 29.63% off your first annual invoice. Ends Nov 30, 2026.FILL25Y
Fill the Server, 2 year term: about 15.69% off your first biennial invoice. Ends Nov 30, 2026.FILL25B
Fill the Server, 3 year term: about 11.11% off your first triennial invoice. Ends Nov 30, 2026.FILL25T
80% off your first 3 months, monthly billing. Ends Dec 25, 2027.3MONTHS80
50% off your first annual Shared term. Ends Dec 31, 2027.50SHARED
Shared Starter, 3 year term: C$105.84 total.MOOSE294
20% off your first 3 monthly VPS invoices. Ends Dec 31, 2027.20VPS3
25% off your first annual base VPS term.25VPS

← All guides

WordPress

WordPress PHP memory limit: how to check it and fix memory errors

Published August 2026 · 8 min read · Updated 2026-09-05

A WordPress memory limit controls how much memory one PHP request can use. WordPress can request a higher application limit, but PHP and the hosting platform can still impose a lower ceiling. This is different from the total RAM assigned to the server or hosting account.

Start with the exact memory error

The common PHP fatal error says that an allowed memory size was exhausted and usually reports both the configured byte limit and the allocation that failed. Record the page or task, the time, and the plugin, theme, import, image operation or background job involved before changing settings.

If there is no memory-exhaustion error, do not assume a slow or failed WordPress request is a memory problem. Timeouts, database errors, PHP exceptions and resource limits have different fixes.

Troubleshoot PHP timeouts separately

PHP memory_limit is the server-side ceiling

PHP has a memory_limit configuration directive that limits memory for a script. Hosting providers can set or restrict that value. The PHP configuration used by the website can also differ from command-line PHP, so a CLI check is not proof of the limit serving WordPress.

If the hosting platform enforces a lower limit, changing a WordPress constant cannot override that server-side boundary.

PHP manual: memory_limit

WordPress has its own memory settings inside that boundary

WordPress supports WP_MEMORY_LIMIT for normal requests and WP_MAX_MEMORY_LIMIT for some administration tasks. These settings tell WordPress what it may request; they do not create physical memory or guarantee PHP will permit the requested value.

Check the effective web-PHP limit and the WordPress configuration together. If they disagree, the lower enforceable boundary is the one that matters for the failing request.

WordPress developer docs: increasing memory allocated to PHP

There is no single correct memory limit for every WordPress site

A small brochure site and a large WooCommerce import can have very different peak memory use. Raising a limit can be reasonable when a legitimate operation needs more headroom and the hosting plan has capacity, but choose the new value from measured workload and available capacity; there is no universal tutorial value.

Keep enough headroom for concurrent PHP workers too. A per-request limit multiplied across many simultaneous requests can become a much larger account or server memory demand.

Repeated growth is an application signal

If the same action keeps consuming more memory after increases, investigate plugins, themes, database queries, imports, image processing, background jobs and loops. More memory can postpone the next failure without fixing a leak or runaway workload.

After a change, repeat the operation that failed and watch logs and resource use. A successful test of the actual workload is stronger evidence than a settings screen alone.

Upgrade hosting when the workload actually needs more capacity

If the application is healthy but its normal requests and concurrency no longer fit the hosting plan, compare a larger shared plan or VPS. Do not move to a larger server solely because one plugin produced a memory error once.

For DotMoose WordPress hosting, compare the current plan limits and ask support if you need help distinguishing an application problem from a hosting boundary before moving plans.

Common questions

What is the WordPress PHP memory limit?

It is the amount of memory available to a PHP request running WordPress, subject to both WordPress settings and the PHP/hosting configuration. It is not the same as the server’s total RAM.

What does “Allowed memory size exhausted” mean in WordPress?

PHP reached the memory limit for that request while trying to allocate more memory. Record the failing operation and logs, then check the effective PHP and WordPress limits before deciding whether to raise a limit or fix the application.

What is the recommended WordPress memory limit?

There is no single correct value for every WordPress site. The appropriate limit depends on the application workload, plugins, themes, administrative tasks, concurrency and the capacity of the hosting plan.

Can WP_MEMORY_LIMIT override PHP memory_limit?

Not beyond a server-side limit that PHP or the hosting platform enforces. WordPress can request memory within the environment it is given; it cannot manufacture memory beyond the effective hosting boundary.

Next step

Learn the difference between WordPress memory settings and PHP memory_limit, how memory exhaustion appears, what to check before raising a limit, and when the application needs investigation.

Compare WordPress hosting resources

Keep reading

Related guides.

Do I need web hosting for WordPress? What WordPress actually needs

Self-hosted WordPress needs web hosting, but it does not require a specially branded WordPress plan. Compare WordPress.com, regular shared hosting, WordPress hosting and VPS options.

Read the guide

How to move web hosting without downtime

Move a website and database with destination testing, final synchronization, controlled DNS cutover, and rollback while preserving separate mail routing.

Read the guide

PHP timeout troubleshooting: PHP, PHP-FPM or the web server?

Find which PHP timeout fired, check the right configuration, and distinguish PHP execution limits, PHP-FPM termination and nginx FastCGI read timeouts.

Read the guide

More wordpress guides

We will handle the move. You check it first.

Your current site stays online until your new one is ready. You approve the copy first, and if anything is not right we switch you back right away. The price you pick is the price you renew at.

Start my free moveSee plans and prices
See pricesFree move