Share on

Table of Contents

profile-pic (1)
Mansoor Ahmad
October 12, 2024

How To Fix The “503 Service Temporarily Unavailable” Error In WordPress?

WordPress is the most popular content management system available in the market. It is simple to use, beginner-friendly and offers a whole host of features that allows any person to use it without any issue. Even those who are unsure how to operate their websites can do so with the help of WordPress. 

While WordPress is a great CMS platform, it often gets errors that are hard to fix. One such error is the 503 Server error aka Service Temporarily Unavailable error that you get on your WordPress website. The service error usually occurs when the website is in maintenance mode. However, it can also occur when there is some problem with the website such as a corrupt plugin, bad theme, or some notorious script at play. 

In this article, we are going to discuss what is 503 Service Temporarily Unavailable error and how to get it fixed.

We will be discussing the top six methods to fix the error and hopefully by the end of this article, you will have found your solution. With that said, let’s learn about the 503 WordPress server error and its possible solutions.

What is the HTTP 503 Service Unavailable Error?

The HTTP 503 error means that your server is not responding or is just unavailable. When your browser requests information from the server and the server is not available, you will get the HTTP 503 error that says that the ‘Service is temporarily unavailable.”

There can be multiple reasons behind the unavailability. Maybe the server is just too busy or maybe it is under maintenance. However, the 503 server error is different from the 502 bad gateway server error or the 504 Gateway Timeout server error. It exclusively means that the service exists but is down for maintenance and can’t be reached at the current time.

The 503 Server Error usually occurs when your website is under maintenance mode. The WordPress CMS will briefly set your site to maintenance mode when you are updating a plugin, theme, or the WordPress core software. The 503 error is shown during that time frame when someone tries to request the information available on the website. However, the error is only shown for a brief time.

You must be wondering: But what if it starts showing on my website even when the site is not on maintenance mode, what then?!

Exactly that is the purpose of this blog and we will be discussing it below.

Variations of 503 Server Error Explained

The 503 Server Error can show up in a lot of ways and many of these variations are accompanied by the 503 code. So, when you get the server error, it will be easier to identify the code through the ‘503’ number in it.

Some variations of the 503 server error that you should know about include:

  • 503 Service Unavailable
  • 503 Service Temporarily Unavailable
  • HTTP 503 Server Error 
  • HTTP 503 Error 
  • Error 503: Service Unavailable
  • The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.

These are just some of the variations of the error. There can be many more depending on the browser you use. Just make sure to notice the ‘503’ error code when reading the error message.

Fixing the 503 Error Message – Six Ways to Do It

All errors starting with the number ‘5’ means they are server errors. The problem with these server errors is that you don’t know why they occur. And, when you don’t know why server errors occur, you can’t technically troubleshoot them easily. 

With that said, the following six solutions will help you find the root causes of 503 server errors and then you can fix them easily.

How to Validate 503 Server Error?

The following ways will help you find the root cause of the 503 server error. You can try each one of them and see if the server error is gone. If it still exists, you can simply move to the next step and try that one. Eventually, one of the ways will be able to find the root cause and you can then do the necessary to get your website back up and running.

Deactivate Your WordPress Plugins Temporarily

The first way to validate the 503 Server Error is through WordPress plugins. If your website was running normally and then it suddenly started showing the 503 error, then there is a strong possibility that the error occurred because of some corrupted WordPress plugin. If that is the case, then you can simply remove that plugin from your WordPress based website.

But how?

  1. So, first go to your Public_html folder. You will need the cPanel or FTP access to your website to get this done. If your hosting solution has provided you the root access, this can be done easily.

Once you are in the public_html folder, locate the wp-content folder inside. Your wp-content folder will contain the plugins directory.

You will just need to rename the plugins directory so that WordPress is not able to find it. When that happens, it will automatically disable all your plugins.

WordPress plugins folder renamed

We have renamed the plugins directory to plugins.old. You can also rename it to plugins.disabled or anything that can help you recognize the folder later.

  1. Now you need to visit your WordPress website and test it. If the error is gone, the website will show up on your browser. However, if the error remains, then there is some other problem with your website. Read the second step to learn more about it.

Disable Your WordPress Theme

Now that we know that WordPress plugins were not the culprit, we can move to the next step i.e., disabling the WordPress theme. In some cases, the WordPress theme gets corrupted during an update. When that happens, your website will start to show the 503 server error. 

  1. To get it fixed, we have to switch the themes in the WordPress database directory. Since we can’t disable the theme like the plugins, switching themes in the PhpMyAdmin is the only option available.

So, from your website hosting panel, open the phpMyAdmin directory. 

  1. Now, search for the wp_options table in the directory.

You will need to search for the table cell name ‘Template’ through the search option available.

  1. Hit run and you will get the template that is currently installed on your WordPress website. Simply change it to the default template offered by WordPress.

It can be twentytwenty in your case because WordPress now offers twentytwenty as the default WordPress theme. Anyway, simply change the name in the option_value.

  1. Now save it. Refresh the website in your browser. If the problem is solved, your WordPress website will start to show up. If it still doesn’t show up, then there is some other problem with your server. Move to the next step to keep troubleshooting.

Temporarily Disable CDN Server

Although CDNs rarely cause the 503 error on a website but when troubleshooting, you can’t be sure about anything. So, simply disable the CDN service that you are using. 

If you are using a managed cloud hosting solution, your website host will provide you with a button to enable or disable the CDN on your website. However, if you are using an unmanaged hosting solution, then you can disable the CDN service by changing your name server in the DNS properties.

Simply change the IP address in the value section of your website. Here is a complete guide on how to point back from Cloudflare to your DNS hosting.

Limit WordPress ‘Heartbeat’ API

For those of you who don’t know how WordPress keeps a log of your content and saves it automatically, it uses the heartbeat API. It is a pulse system for WordPress that tells it if any change occurs on the CMS platform. 

Since the heartbeat API keeps you informed about plugin notifications, saves content, and shows a warning when someone else is editing a post, it consumes a lot of server resources. If your website is hosted on a shared hosting solution, all these resources can cause the server to show a 503 error. 

To ensure that heartbeat API is not the problem, you can disable it and check if your website starts functioning normally.

Here is how to disable the WordPress heartbeat through FTP or cPanel.

  1. Go to public_html folder and then functions.php file. Here you will need to add the following code in your functions file.
add_action( 'init', 'stop_heartbeat', 1 );
function stop_heartbeat() {
wp_deregister_script('heartbeat');
}

These three lines of code tell WordPress to disable the heartbeat API. Save the functions.php file for the code to process. 

Note: Make sure to create a backup of the functions.php file before you add any code to it. If you accidentally corrupt the file, you can recover the file with the backup you created.

Now try to access your website. If the 503 error was occurring because of the heartbeat issue, then you would be able to see it live. Otherwise, move to the next step.

Increase Your Web Server Resources

We have disabled plugins, disabled theme, disabled CDN, and disabled heartbeat, still, we are getting the 503 server error. This could only mean one thing that you have exceeded the limit of your website resources. The best way to find it out is by calling your WordPress hosting solution provider. They will be able to guide you if the server resources have maxed out.

In most cases, web server resource limit is causing the 503-error problem. So, you just have to move to a better hosting solution and your problem will be solved. 

When looking for a decent hosting solution, make sure to do a complete website hosting comparison because whatever hosting solution you choose, you will be stuck with it for a few years at least.

Limit Google Crawler on Your Website

While having Google Crawler on your website is a good thing because it means that Google values your content. However, sometimes crawlers make too many requests that can max out the server resources. This usually happens on websites that are hosted on a shared hosting solution. 

To fix this problem, simply limit the crawl requests that the Google crawler can make on your website. Here is how to get that done.

  1. Go to the Google Crawl Rate Setting Page. You will be asked to select the property for which you would want to manually set the crawl rate.
  1. Select a property that is getting the 503 server error and then reduce the crawl rate on that specific website.

Note: Google specifically says that don’t tinker with the crawl rate as that can cause problems in your site indexing. 

You can put the crawl rate to low and see if your website gets live again. You should note that the crawl rate is not reduced immediately. It will take time for Google bots to reduce the crawl rate. So, if the issue was occurring because of the crawl rate, it would have been fixed in a few hours.

Make sure to revert the changes you made to the Google crawl rate once you have added additional resources to your website.

Bottom-line

We have listed six ways to fix the 503 Service Unavailable error on your WordPress website including:

  1. Disabling plugins on your WordPress website
  2. Disabling the theme on your WordPress website
  3. Disabling CDN on your WordPress website
  4. Disabling WordPress Heartbeat API on Your Site
  5. Reducing Google Crawl Rate
  6. Increasing Server Resources or Changing Website Hosting 

In most cases, your WordPress problem will be solved through one of these solutions. If you are still unable to solve your WordPress 503 Service Unavailable problem through these solutions, you can always get help from our WordPress experts. We are always available to help our readers fix their issues with minimum hassle. 

Mansoor Ahmad

Mansoor Ahmad is a web developer and WordPress enthusiast. He has been building websites with WordPress since 2013. He is passionate about teaching and writing about WordPress and helping fellow web creators build better websites.

WPForms Review: Is It Really The Best Form Builder?

You have a website. Now you want to generate leads from people coming to your site. What can you do about it? You will need a form on your WordPress

Nulled WordPress Themes – Should You Use Them?

I have been in the web industry for more than 5 years now. It’s one of the job descriptions where you need to stay updated with the latest happenings. Despite

Four WooCommerce Recommended Hosting Solutions for Beginners

WooCommerce is one ecommerce platform that allows anyone to create their own store within minutes. It is fast to set up, easy to use and provides a lot of flexibility