Got a 503 error showing up when you try to view your WordPress site? Probably wondered what happened and how to get rid of it, right? Here’s some troubleshooting steps to find out.
How to Fix 503 Service Unavailable Error in WordPress
The first thing is to understand what it is. This could happen due to wrong file permissions, a mistake with htaccess, plugin or theme issue, or even your web host. 503 errors are normally seen as the Apache in your website’s server can’t handle the HTTP request. This could be due to the server being overloaded or being under maintenance.
However, before troubleshooting, find out what was the last thing you did before the 503 error that showed up. If you can remember, great! Maybe it was updating a theme or plugin, or accidentally adding missing a character or adding a character to a snippet of code to your .htaccess or something else. However, if you don’t know, then you’re going to have to troubleshoot the 503 error.
Troubleshooting 503 errors
File Permissions:
Make sure all regular file permissions (AKA CHMOD) are set as followed:
Directories (or sub folders): 0755
PHP, Images, .htaccess: 0644
If you have some security set for directory folders and PHP files, then use those.
.htaccess
Check your .htaccess file to make sure that you’re not missing code, or that it isn’t corrupted.
At the very least, your WordPress .htaccess file should look like:
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
If it has more than that, look at it carefully and see if you need the other code. Not sure, then hire someone or ask your web host.
Your Plugins
You always want to try to do a conflict check for your plugins and themes. This will whittle down the list on what is causing the problem. To do this, you can log into your web host cPanel or control panel/ file manager, or log in via FTP or sFTP or WinSCP, and try the following for troubleshooting plugins. (I use Filezilla for FTP and sFTP)
1. Navigate to your wp-content folder (like the screenshot below.)
2. Rename your plugins folder to pluginsOLD. Create a new folder named plugins. Leave it empty. This will deactivate all of your plugins.
3. Visit your WordPress site and see if the 503 error goes away. If it doesn’t, then it’s not your plugins. If it is, you will need to remove the new empty plugins folders that you created, and rename the pluginsOLD folder to plugins.
4. In case it is the plugins, after you’ve renamed your pluginsOLD folder back to plugins, as you’ll need to troubleshoot further.
5. Since you’ve already deactivated the plugins, go to your WordPress admin area, and one-by-one, activate each plugin. The one that you activate last that causes the 503 error is the culprit. You will have to go back to FTP or sFTP to deactivate the plugin (by renaming it with OLD or -old at the end of the folder’s name.)
Your Theme
Wasn’t your plugin? Try your theme.
1. Navigate to your theme folder, within your wp-content folder, and you’ll get a list of themes.
2. Rename all theme except a default theme like Twenty Seventeen, with OLD or -old, at the end of the theme folder’s name. Don’t have a default WordPress theme? Then here’s a link to go download Twenty Seventeen.
3. Visit your website to see if it is up. If deactivating those themes while keeping a default WordPress theme does the trick, then great! If not, you need to troubleshoot this further.
Web host
Let your web host know that you have a 503 error. Ask them to see if it is something on their end that might be a problem.
In conclusion, one of these options should be part of the problem. In fact, while you’re troubleshooting, you should probably look submitting a support ticket with your web host to make sure it wasn’t a problem on their end. It isn’t always the case, but it’s definitely a route to check.
Amos Denis says
Hey Nile,
Thanks for the article as it helped solve error 503 in my site. Cheers
michael says
thanks.. i have fixed mine
James Lance says
Good information to post. Had a couple of 404 errors recently which I had managed to fix after accidentally deleting some of my blog posts, but managed to fix them. Not come across 503 errors, but is good to know a method for trying to fix should they occur.
Eva Smith says
Nice blog post about how we can fix 503 error in WordPress website. Nice blog post keep the good work going.
Ryan says
Wow Wow It helped me a lot to fix the error 503 on my WordPress website had to find also how to fix the 404 page not found