DriversRecommendedOutdated drivers can make a good PC feel brokenScan driver issues before chasing fixes manually.Scan NowHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PC×
Skip to content
VGSources
Blog

How to Cut Memory Usage When Running Multiple WordPress Sites

A measurement-first guide to reducing WordPress memory use across separate installations or multisite networks, with safe limits, caching advice, batching steps and troubleshooting for memory-exhausted errors.
Length11 min Posted Quest giverVGSources Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The reliable way to reduce memory use across several WordPress sites is to measure the requests that fail, remove unnecessary plugin and theme work, move imports and image jobs away from visitor traffic, then set WordPress limits below the PHP limit your server actually enforces. Raising WP_MEMORY_LIMIT alone cannot create RAM or override a host-level memory_limit.

WordPress starts with a 40 MB front-end limit for a single site, 64 MB for multisite front-end requests and 256 MB for back-end operations. Those defaults are request limits, not a promise that a server can run any number of sites. Capacity depends on concurrent PHP workers, database load, plugins, themes, traffic and background jobs.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

What WordPress memory limits control

PHP assigns each request a memory ceiling through memory_limit. WordPress then uses two constants to request practical limits for different kinds of work:

Constant Request type WordPress default What the figure means
WP_MEMORY_LIMIT Front-end requests on a single-site installation 40 MB Default documented by WordPress.org in 2022; it is a per-request target, not total server RAM.
WP_MEMORY_LIMIT Front-end requests on a multisite network 64 MB Default documented by WordPress.org in 2022; every request still competes for the host’s worker and database resources.
WP_MAX_MEMORY_LIMIT Administration and other back-end operations 256 MB Current WordPress Hosting Handbook default for tasks such as editing, updates and imports.

WordPress documentation describes WP_MEMORY_LIMIT as the maximum amount of memory PHP may consume for a request. The Hosting Handbook also makes the important qualification that whether a request succeeds is up to the server. A host-level php.ini, PHP-FPM pool, container limit or control-panel policy can impose a lower ceiling than the value in wp-config.php. A higher WordPress constant cannot bypass that ceiling.

#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter | 4Pack Type C Female to A Male Cable Converter for Apple Duo 17 16 15 14 Plus,iWatch Watch 12 11 10,iPad 9 8 Air,Airpods 5 4
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.

How much RAM do several sites need?

There is no defensible universal “RAM per WordPress site” number. A brochure site with a page cache and a few lightweight plugins can use far less memory than a store, membership site, visual editor or network running simultaneous imports. Measure the peak working set of your own requests instead of multiplying an arbitrary per-site figure.

The WordPress Hosting Handbook gives useful starting tiers, not guarantees:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • 128 MB: a minimum starting point for a basic installation.
  • 256 MB: a recommended default starting tier for ordinary sites.
  • 512 MB or more: a sensible starting tier for resource-intensive sites, large networks or demanding back-end jobs.

These amounts describe available memory for the environment, not a license to allocate that amount to every PHP request. If ten PHP-FPM workers can run at once and each approaches a 256 MB limit, the pool could theoretically demand several gigabytes before the database, web server, object cache and operating system are counted. Worker concurrency and real peaks therefore matter as much as the nominal limit.

Build a capacity estimate from measurements

  1. Record the highest observed PHP memory usage for front-end, wp-admin, cron, import and image-processing requests.
  2. Multiply the peak for a request class by the number of workers that may run that class concurrently.
  3. Add memory reserved for the database, web server, opcode cache, persistent object cache and the operating system.
  4. Leave headroom for traffic spikes and deployment tasks rather than sizing to the exact calculated total.

This produces a working capacity model. Revisit it after adding a plugin, changing themes, increasing worker counts or moving more sites onto the server.

Separate installations or WordPress Multisite?

Running separate WordPress installations and running one multisite network are different memory trade-offs. Neither arrangement is automatically more efficient for every workload.

Rank #2
Sale
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter | USB C Dongle with 90W Max Power Delivery, 3×5Gbps USB A Data Ports, for MacBook, Dell, and More (Charger Not Included)
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
Decision axis Separate installations Multisite network
Failure isolation A fatal plugin or theme error is usually confined to one installation, subject to shared server limits. A faulty network-wide component or shared code can affect multiple sites.
Code and cache sharing Each installation loads its own copy of WordPress and extensions; shared caches are less predictable. Core and network-enabled extensions are shared, which can improve reuse but still requires PHP workers and database capacity.
Per-site customization Each site can choose independent plugins, themes and update schedules. Network rules and network-activated plugins constrain some choices; site-specific variation can complicate administration.
Operations More individual updates, backups and configuration files. Centralized administration, with network-wide consequences when changing shared components.
Memory planning Plan for each site’s peak plus simultaneous worker demand. Use the documented 64 MB front-end default as a starting limit, then measure the network’s actual request mix; no official RAM-per-site benchmark is published.

Choose the structure that matches isolation and governance needs first. Do not migrate to multisite solely to chase a theoretical memory saving, and do not split a network without accounting for duplicated code, caches and operational work.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Measure the failing workload before changing limits

An “allowed memory size exhausted” message identifies the request that ran out of PHP memory; it does not identify the component that caused the peak. Start with evidence from logs and repeatable requests.

Capture the request and peak

  • Copy the complete PHP fatal-error line, including the allocated and attempted byte counts, timestamp and file path.
  • Record the affected site, URL or admin screen, HTTP method, logged-in state and whether the request was a cron, import or image task.
  • Compare front-end page loads with wp-admin, scheduled events, REST requests and command-line jobs. Their code paths and limits differ.
  • Note concurrent traffic and PHP-FPM worker utilization at the time. A request can fail because the host is exhausted even when its individual peak appears modest.

Check the effective PHP limit

Inspect the PHP configuration used by the web server, not only the command-line binary. A temporary diagnostic page or host control panel can show memory_limit; on a shell, php -i | grep memory_limit reports the CLI value, which may differ from PHP-FPM. Ask the host for the FPM value when runtime changes are blocked.

Make a workload inventory

  • List active and inactive plugins, must-use plugins and network-activated extensions across every installation.
  • Record theme, page-builder and multilingual components that add substantial front-end or editor code.
  • Identify importers, backup tools, image optimizers, search indexers, analytics collectors and bulk-edit tools that process many records in one request.
  • Mark extensions that load administration code on ordinary front-end requests or perform remote API calls synchronously.

Disable an extension only in a controlled staging or maintenance window, then reproduce the failing request. Removing unused code is safer than granting every request a much larger limit.

Reduce the memory demanded by each request

Remove and replace heavy extensions

Delete plugins and themes that are not used; deactivation alone leaves their files and update surface in place. Where a feature is necessary, compare alternatives by the work they perform on every request: large visual editors, all-in-one suites, page builders, security scanners and reporting dashboards can add substantial object graphs before a page is rendered.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter | 85W Max PD, 2 USB 3.0 & 1 USBC Data Ports, SD/TF Card Reader, for Laptops/Mac and Other Type C Devices (Charger Not Included)
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.

Check whether an extension offers a setting to disable front-end modules, scheduled scans or unused integrations. Keep administration-only functionality out of visitor requests where the component supports that separation. Update extensions in a staging copy first, because a newer release can fix a leak but can also change peak usage.

Reduce batch size for imports and media work

Imports and image regeneration commonly load many records or large image binaries at once. Process smaller batches, schedule them during quiet periods and monitor each batch’s peak. If a job exposes a per-request item count, lower it until the peak fits comfortably below the effective limit; do not compensate for an unbounded batch by setting an extreme global value.

Keep front-end traffic separate from maintenance

Run long jobs with WP-CLI or a scheduled worker rather than through a browser request that must remain open for a visitor. WP-CLI can target a specific site in a network and provides cache and maintenance commands, allowing you to process one site or batch at a time. For example, review network targets with wp site list --network, run a command for one site with wp --url=https://example.com command, and clear a persistent object cache after a controlled deployment with wp cache flush when your cache integration supports it.

Queueing jobs does not make them free: the worker still needs enough memory. Limit concurrency so several imports cannot run simultaneously and starve normal PHP requests.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Set WordPress constants only after confirming the host limit

Place memory constants in wp-config.php before the line that loads wp-settings.php. Use separate values for public and administrative work:

Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray | Data transfer & Fast charging for MacBook, iPhone 17/16/15, iPad, Samsung Galaxy, Apple Watch
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
define( 'WP_MEMORY_LIMIT', '128M' );
define( 'WP_MAX_MEMORY_LIMIT', '256M' );

The values above are examples of a staged configuration, not universal requirements. Select them from your measured peaks and the host’s effective memory_limit. If the host enforces 128 MB, declaring 256M in WordPress cannot make a request use 256 MB.

When the host blocks runtime changes

  1. Confirm the restriction with the host’s PHP settings or support team.
  2. Ask whether the account, container or PHP-FPM pool can receive a higher server-side memory_limit and what worker or plan limits apply.
  3. If the host cannot change it, reduce the workload, move heavy jobs to a worker environment or migrate to an environment that permits the required limit.

Do not set an arbitrarily high value to hide a plugin defect. A larger per-request ceiling can let more requests consume memory simultaneously and trigger swapping or an out-of-memory kill.

Use persistent object caching for repeated database work

A persistent object cache stores reusable WordPress objects between requests. Memcached or a compatible Redis service can reduce repeated database queries when many visitors request the same objects or when several sites repeatedly read similar data. This lowers database work and may shorten requests, but it does not reduce every form of PHP memory use.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Deploy it with headroom

  • Choose a cache size that leaves memory for PHP-FPM workers, the database, web server and operating system.
  • Monitor hit rate, misses, evictions, connection errors and latency. Frequent evictions indicate an undersized cache or an ineffective key set, not a reason to remove all safeguards.
  • Use a separate cache namespace or correctly configured salts and prefixes for each site so objects cannot collide.
  • Flush or invalidate objects after deployments that alter stored data structures; stale objects can produce incorrect pages even when memory use looks healthy.

Object caching helps when repeated database queries are the bottleneck. It cannot fix a memory spike caused by an image conversion, an importer holding thousands of records, a page builder constructing a large document or a plugin leak. The cache daemon itself consumes memory, so include it in capacity calculations.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Enable PHP opcode caching, but count its memory

Opcode caching keeps compiled PHP instructions so workers do not repeatedly compile the same files. On hosts that support it, this reduces compilation work and can improve response consistency. It is a separate shared-memory consumer, however, and its allocated segment must be sized and monitored.

Best Value
Sale
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display | 85W Max PD, 1 Powered USB-C 5Gbps & 2 Powered USB-A 3.0 5Gbps Data Ports, for MacBook Pro, MacBook Air, Dell and More (Black)
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.

Watch cache utilization, restart or revalidation behavior after deployments and warnings about a full cache. An opcode cache does not replace a persistent object cache: one avoids recompilation, while the other avoids repeated database retrieval and object construction. Enabling both can be useful when each addresses a measured bottleneck, but neither substitutes for removing an extension that allocates excessive objects.

Account for PHP-FPM and database pooling

Per-request limits are only one part of server memory. PHP-FPM’s maximum workers determine how many requests can allocate memory concurrently; the database has its own buffers and connections; web-server processes, opcode cache, object cache and the kernel also need room.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Lower worker concurrency when simultaneous peaks exhaust RAM, then verify that queueing does not create unacceptable latency.
  • Set process recycling or restart policies appropriate to the host when long-lived workers grow over time, while investigating the extension responsible for growth.
  • Separate a busy database or cache service from PHP only when measurements show that pooling is the constraint; moving services without evidence adds operational complexity.
  • Keep swap as an emergency buffer, not as planned capacity. Sustained swapping makes PHP requests slow and can turn a recoverable peak into cascading timeouts.

Troubleshoot “allowed memory size exhausted” errors

One front-end URL fails

  1. Check the fatal-error file path to identify the plugin, theme or WordPress subsystem allocating at the point of failure.
  2. Reproduce with nonessential plugins disabled in staging, then reactivate them one at a time.
  3. Compare an uncached request with a cached request and inspect whether a personalization or query parameter bypasses the page cache.
  4. Raise WP_MEMORY_LIMIT only within the confirmed host limit if the workload is legitimate and the measured peak is close to the current setting.

Only the dashboard, editor or update screen fails

Back-end work uses WP_MAX_MEMORY_LIMIT and often loads more code than a public page. Reduce editor document size, split bulk updates, disable unnecessary dashboard widgets and run large updates or imports through controlled CLI batches. Confirm the FPM limit before changing the back-end constant.

A cron, import or image job fails intermittently

Inspect batch size, overlapping schedules and source-file dimensions. Ensure only one worker handles the job at a time, split the workload and retry a small batch. If failures coincide with visitor peaks, move the schedule or run the task on a dedicated worker.

The entire server becomes unavailable

Check host-level out-of-memory events, worker counts and cache occupancy rather than changing WordPress constants first. Temporarily reduce concurrency, stop runaway jobs and restore service; then identify which site and request class consumed the memory. A server-wide kill means the aggregate demand exceeded available RAM, even if each WordPress request stayed below its individual limit.

A staged operating procedure for multiple sites

  1. Baseline: capture PHP fatal logs, peak memory, worker counts and database/cache metrics for each site and request class.
  2. Clean up: remove unused plugins and themes, replace unusually heavy components and stop front-end loading of admin-only modules.
  3. Batch: move imports, image regeneration and bulk updates to WP-CLI or scheduled workers; target one site and a limited item count per run.
  4. Configure: set WP_MEMORY_LIMIT and WP_MAX_MEMORY_LIMIT only after confirming the server-side PHP limit.
  5. Cache: add a persistent object cache when repeated database reads are proven to dominate, and enable opcode caching where supported.
  6. Retest: repeat the same failing requests and maintenance jobs, compare peaks and inspect logs for evictions, worker exhaustion and memory kills.
  7. Increase incrementally: raise a limit in small steps only when the measured workload is valid, the host has headroom and the failure is a capacity limit rather than a code defect.

Monitoring checklist

  • PHP fatal errors by site, URL and request type.
  • Peak and average PHP memory per worker.
  • PHP-FPM active, idle and queued workers.
  • Database connections, slow queries and buffer usage.
  • Object-cache hit rate, evictions, allocated memory and connection failures.
  • Opcode-cache occupancy and restart or revalidation events.
  • Host RAM, swap activity and out-of-memory-kill events.
  • Duration, overlap and batch size of cron, import and image-processing jobs.

Keep a change log for plugin updates, theme changes, worker-count adjustments and cache-size changes. Comparing the same request before and after one change makes the cause visible; changing several limits and extensions at once does not.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Practical decision rules

Observed situation Best first action
One plugin or theme appears in repeated fatal traces Test, update, configure or replace that component before raising limits.
Repeated database reads dominate normal requests Evaluate a persistent object cache, size it with headroom and monitor evictions.
CPU time is spent compiling PHP while memory remains available Enable and monitor opcode caching if the host supports it.
Imports or image jobs fail but ordinary pages are healthy Split batches, limit concurrency and move work to CLI or scheduled workers.
Several sites fail together during traffic spikes Review PHP-FPM worker concurrency and total server RAM before changing per-site constants.
The host refuses a required PHP limit Reduce the workload or use an environment that permits the server-side setting; a WordPress constant cannot override the host.

The durable strategy is demand reduction plus measured capacity: keep each request’s work bounded, reserve memory for every shared service, and increase limits only when logs show a legitimate workload needs more room. WordPress’s documented defaults and the Hosting Handbook’s 128 MB, 256 MB and 512 MB starting tiers are useful reference points, but your measured peaks and host controls determine whether multiple sites remain reliable.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
Windows Errors? Fix Them Before They SpreadFree repair scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.