m3lvin / Wordpress

Fix WordPress Error 503 Service Unavailable

Often, the common culprits for WordPress 503 error are slow executing PHP scripts from plugins, themes or custom code snippets in your functions file.

Temporary Fix for 503 Error

  • Deactivate any plugins or theme recently installed.

    Some plugins require heavy server resources due to functionality, compatibility issues or just buggy code. More than what your current resource limit allow.

    Find alternatives for near-similar features and monitor.

  • Upgrade to PHP 7.x

    Caution. As always, do a backup. May cause compatibility issues, especially with unmaintained plugins.

  • Increase Server Resources

    Sometime our sites outgrow the current hosting environment. If your’re on shared hosting, perhaps is time for a VPS. If you’re already on cloud hosting, increase resource until you find a more viable solution.

Further Actions

You’ll need to find what causes this sudden problem.

WordPress is built on PHP.

When 503 error pop in to say hi, the first thing to do is check your PHP error log and PHP slow log.

Any request that takes longer than a configured threshold (say, 5 seconds) to execute will be recorded into the slow log for debug purposes.

No access to PHP log files?

Most probably you’re on shared hosting and the only solution is to contact your host provider for support.

503 Maintenance

The 503 status code can also used intentionally when sites need to go offline for maintenance work. Here’s a nice guide to customize 503 Down for Maintenance page.

Need Help?
Contact Us