The host caps how much memory each PHP request may use. Raise your site's limit up to what the plan allows, then find the plugin or import that needs so much rather than raising it forever.

A blank page after one click

You install a plugin, click activate, and the screen goes white. Or a product import runs for a minute and stops, leaving half the catalogue behind.

When there is a message, it reads something like "Fatal error: Allowed memory size of 33554432 bytes exhausted". That number is 32 megabytes, and it means one page load tried to use more memory than the server allows.

Often there is no message at all. Most servers hide errors from visitors, so the page comes back empty and the details go to an error log.

Nothing is broken for good. The site has hit a ceiling the host set on purpose.

Why the host sets a ceiling

On shared hosting, hundreds of sites share one server's memory. Every page view on a WordPress site starts a PHP process, which pulls in WordPress itself, the theme and all the active plugins.

Without a limit, one script stuck in a loop, or one enormous import, could take memory every other site needs. So the host sets memory_limit, a cap on what any single request may use.

When a request reaches it, PHP stops that request rather than let it take more. The cap protects your site too: a runaway plugin fails on one page instead of slowing the whole account.

What usually pushes past it

The third surprises people. A phone photo of 4000 by 3000 pixels may be a three-megabyte file, but resizing it means unpacking twelve million pixels at several bytes each, which alone can exceed a 32-megabyte limit.

Raising the limit within the plan

Ask the host first: what is the limit per request on your plan, and how high may you set it yourself? Many shared plans allow 128 or 256 megabytes; some older ones stop lower.

The method depends on how the host runs PHP. Some offer a setting in the control panel; others read a php.ini or .user.ini file in the site's folder.

WordPress asks for at least 40 megabytes by default, and a WP_MEMORY_LIMIT line in wp-config.php can ask for more, but only up to what the host permits.

Avoid the php_value line for .htaccess that forum posts often suggest. It works only on some setups, mainly where PHP runs as an Apache module, and on many others it turns every page into a server error.

What a higher limit does not fix

The limit applies to each request separately. A page that genuinely needs 200 megabytes, loaded by ten visitors at once, needs two gigabytes between them.

Many hosts also cap the memory a whole account may use at one time, and reaching that fails pages for everyone, whatever the per-request setting says.

And memory tracks work. A page that needs that much to build is usually a slow page, so a raised limit can hide a problem visitors still feel.

A worked example

A virtual office provider rents business addresses, mail handling and meeting rooms by the hour from two floors of a downtown office building, and runs its website on WordPress.

To let clients reserve rooms online, the manager installed a booking plugin and put its calendar in the sidebar. The admin screen went white on activation, and soon pages with the sidebar came back blank.

The site was set to 64 megabytes per request. The calendar loaded every booking, past and future, with its own scripts, on every page that had a sidebar, which was nearly all of them.

The host confirmed the plan permitted 128 megabytes, so the limit went up to that. The calendar moved to the meeting rooms page alone, set to load the current month only.

An old statistics plugin that logged every visit to the database was removed too, since Analytics already did that job. The error has not come back.

Finding the plugin that needs so much

The error names a file, and the path often points inside one plugin's folder. That shows where memory ran out, which is usually, though not always, the plugin responsible.

The reliable test is a copy of the site with plugins switched off one by one, reloading the failing page after each until the error stops.

A developer can also show each page's peak memory use to logged-in administrators. Comparing pages, and the same page with a plugin on and off, shows which ones are heavy.

Imports in smaller pieces

Import tools often read the whole spreadsheet, and sometimes download every product photo, inside one request.

Split the file into batches of a few hundred rows and bring the photos in separately. Each batch then fits comfortably inside the limit.

Run large imports in the evening, when fewer visitors share the account, and keep each batch file so a failed one can be run again on its own.

When the plan is the ceiling

Sometimes the plan is simply too small. A shop with thousands of products and a booking system has outgrown a plan sized for a five-page brochure.

Older servers make it worse, with older PHP versions that need more memory for the same work. A current plan on a current server often costs less than the hours spent working around a limit.

The counter-case

A brochure site with a handful of plugins rarely meets this error, and when it does, a modest increase within the plan is often the whole fix.

A one-off import may only need the limit raised for an afternoon. And some heavy plugins earn their keep: a booking system the business depends on may simply need a plan with room for it.

But a limit raised without asking why tends to be raised again next month. Raise it as far as the plan sensibly allows, then find what is using it.

When the screen goes white

  1. Read the error log for the full message.
  2. Ask the host what your plan allows.
  3. Raise the limit by the method the host supports.
  4. Test plugins one by one on a copy.
  5. Load heavy features only where they are used.
  6. Split large imports into batches.
  7. Review the plan if the site has outgrown it.

Step four is the one that ends the cycle. Raising the limit gets the site back today; finding the heavy plugin keeps it from failing again after the next update.

Hosting plans that quietly fall behind the sites on them are the subject of your account on the host's oldest server.


Frequently asked questions

What does allowed memory size exhausted mean?

One page load tried to use more memory than the server allows a single PHP request. The number is the limit in bytes; 33554432 is 32 megabytes.

Why does my host limit memory?

Hundreds of sites share one server's memory. The cap stops one faulty script or huge import taking what every other site needs, and stops your own bugs early.

How do I raise the limit?

Ask the host what your plan allows and how it runs PHP, then use its control panel setting or a php.ini file, plus WordPress's WP_MEMORY_LIMIT line.

Why not just set it very high?

It applies to each request, and many run at once, so heavy pages multiplied by visitors can exhaust the account. A page needing that much is usually slow anyway.

How do I find the heavy plugin?

Check the file path in the error, then disable plugins one by one on a copy of the site until the failing page loads again.

Why do product imports run out of memory?

Many import tools read the whole spreadsheet, and sometimes every product photo, in one request. Batches of a few hundred rows, with photos imported separately, fit inside the limit.

West Coast Media Solutions Inc. provides web design, web development, hosting, digital marketing, and business consulting to organisations across Canada, drawing on more than twenty-five years in the field.

Blank page after activating a plugin?

Send us the error message or the site address. We will find what is using the memory and what your plan allows.

Start a Conversation