What is it?
Error 503 ( Service Temporarily Unavailable ) in most cases means that you have exceeded one of the limits of your given resources. Here are the most popular cases and their solutions:
CPU, Memory and Processes
In short, there are two best solutions on how to fix 503 error are:
- Upgrade your current hosting plan, so it would have even more resources than your current plan.
- Optimise your website as much as possible by using recommendations from GTMetrix.
In most cases, when error 503 occurs, you have reached the limit of CPU, physical memory or the number of simultaneously running processes. To find out for sure, open your hosting accounts hPanel, find Order Usage and check the usages of your plan.
Ideally, the graphs should not reach the red lines :
Here is an example of exceeding memory resources:
NOTE : Order usage graphs are updated every 15-30 minutes, if an error has just appeared on the site, you may need to wait and check the current values.
What to do when your website is exceeding these limits?
There are several options for fixing exceeding resources:
- Pay attention to visits to the site. If you see values that are unusual for your site (for example, you usually have 100 visitors, and at some point, you had 1000 visitors), a DDoS attack might have begun on your site. To protect your site from DDoS, you will need to setup Cloudflare (if it has not already been configured with your website) and put it on under attack mode:
2. If one of the limits that is exceeded is the number of simultaneously running processes:
In this case, you can get your site back online in just a couple of minutes, just by stopping the active processes. To do this, go to the Hosting → Manage → Reset account page and click Stop running processes:
After that, you can go directly to 4th step.
3. If a large resource consumption occurs periodically (for example, once every 6 hours), check the planned tasks of your site. Perhaps you set up a regular execution of some action or script - it can be the reason for exceeding the limits.
4. The most important and effective solution is website optimisation. Here, a very simple rule applies: the more the site is optimised, the less resources it uses and the faster it opens. Sounds good, right?
There are many websites that let you check how well a site is optimized, for example GTMetrix , Google Page Speed and others. All that is needed for optimization is to analyze the site using one of the websites, get personalized recommendations according to your website and implement them.
Please note that sometimes the site can load quickly enough, but be poorly optimized:
Such websites also needs to be optimized.
5. If you checked all the options, optimised the site as much as possible, but your website still consumes almost all resources, it looks like your site has outgrown your current hosting plan. This is absolutely normal and naturally occurs during the development of the website. All you need to do in this case is upgrade your hosting plan to a higher one. By the way, as soon as you upgrade to a higher hosting plan, the remaining money from the previous plan will be recalculated and added as additional days to your hosting plan.
Inodes and disk space
If a 503 error appeared on the site, and the use of resources is small, it may be a matter of using disk space and/or inodes. You can see the usage data on your hosting account dashboard:
You can also refresh data manually by clicking here:
What to do when you're exceed disk usage and/or inodes?
If your site has exceeded the limit number of inodes or the amount of disk space, there are several options for resolving the situation:
- Delete all unnecessary files (cache files, duplicates, any old backup files and etc.). If you worry that you accidentally delete something important for the site to work, you can make a backup in advance
- Upgrade your hosting plan: with a higher hosting plan you will receive more resources
In addition to the first option, you can also integrate Google Drive into your work on the site: a free plan of Google Drive offers 15 GB of disk space, which you can use to store large files (such as documents and images), and add links to them on the site.