How to Fix WooCommerce 504 Gateway Timeout Errors (UK Guide)

17 August 2026

Struggling with WooCommerce 504 errors? Step-by-step UK guide to fix gateway timeouts, improve hosting, and prevent downtime in 2026.

What Causes a 504 Gateway Timeout in WooCommerce?

A 504 Gateway Timeout means your server didn’t respond to the proxy or gateway within the allowed time. For WooCommerce, this often happens when a PHP script takes too long to execute – for example, during a bulk product import, payment processing, or a poorly optimised plugin. UK store owners frequently see this during peaks like Black Friday or after installing heavy plugins. Other culprits include insufficient PHP memory, outdated PHP versions, or an overloaded shared hosting server. The error can also stem from your CDN or proxy settings if you’re using Cloudflare or similar. Understanding the root cause is key – it’s rarely a single issue. Diagnose by checking your WordPress debug log and server error logs, which your UK host can usually provide in real time.

Immediate Steps to Restore Your UK Store

First, try a simple page refresh – often the 504 is temporary. If your store is down, log into your hosting control panel and restart PHP or your web server (e.g., Apache or Nginx). Next, clear all caches: WordPress cache, page builder cache, and server-side cache (like Varnish or Redis). You might also need to increase PHP max_execution_time and memory_limit in your wp-config.php or .htaccess. Many UK hosts provide a 'Reset' button in their dashboard for exactly this. If you can't access the admin, use FTP to temporarily rename your active plugin folder – this disables plugins and might bring the site back. Finally, contact your host's 24/7 support; reputable UK hosts like Krystal or 20i are known for fast response times.

Optimise WooCommerce to Prevent Timeouts

Prevention is better than cure. Start by auditing your plugins – deactivate any that aren't essential, especially those for inventory, booking, or heavy reporting. Use a lightweight caching plugin like WP Rocket or W3 Total Cache with page cache, object cache, and gzip enabled. A CDN such as Cloudflare or BunnyCDN (which has a London PoP) will offload static assets and reduce server load. Clean your database regularly using WP-Optimise – remove transients, spam comments, and old order data. Also, disable unused WooCommerce features like legacy REST API endpoints if not needed. Finally, optimise product images with WebP or AVIF formats. These steps can cut page load times by 50-80%, making 504 errors far less likely.

UK Hosting Considerations for WooCommerce

Your host plays a massive role in 504 errors. Shared hosting is typically the worst performer for WooCommerce because server resources are shared with noisy neighbours. Consider moving to a UK-based VPS or dedicated server, or a managed WordPress host that specialises in WooCommerce. Look for providers with SSD/NVMe storage, Litespeed or Nginx servers, and PHP 8.2+ support. Ensure your host offers automatic scaling for traffic spikes – important if you run sales or promotions. Also check their support response times: a 504 that lasts 15 minutes can cost you orders. UK hosts like SiteGround, Krystal, and 34SP.com have strong reputations. Ensure your data centre is located in the UK or EU for compliance and lower latency for British customers.

When to Upgrade or Migrate Your WooCommerce Hosting

If you're getting 504 errors frequently, it’s time to assess your hosting plan. Signs you’ve outgrown shared hosting include daily spikes, slow admin pages, and errors during backups or plugin updates. Upgrade to a VPS with at least 4GB RAM and 4 CPU cores, or better, a WooCommerce-specific managed plan that includes caching, staging, and uptime monitoring. If you decide to migrate, use a plugin like All-in-One WP Migration or hire a UK developer. Schedule the migration for off-peak hours and test payment gateways thoroughly. Budget-conscious stores can consider offloading email and PDF invoices to external services to reduce server load. Remember, a 504 error is your site saying it needs more breathing room – don’t ignore it.

FAQ

WooCommerce core rarely causes 504 errors. However, its extensions and heavy queries (like product searches, cart updates, or order reports) can trigger timeouts if your server is under-resourced. The error is usually a combination of a slow plugin, inadequate PHP memory, and a server with low limits.

Latest guides