If you need to close your website down for an entire day because of maintenance, site moves, religious reasons, etc. but do not know how to go about it, Google has some tips for you. A webmaster trends analyst at Google has written a blog explaining how webmasters can properly close down their websites for the day if need be. These tips will help to make sure that your website will be closed to do the necessary changes without harming your Google rankings.
John, the Analyst from Google, offers three ways to go about day-long closures:
- Block the cart functionality from Google and your users. (e-commerce)
- Always show an interstitial or pop-up saying your site is offline today.
- Switch the whole website off for a period of time.
If you have an e-commerce website and only need to prevent customers from purchasing products on your website, the easiest method is to disable the cart function on your website. You can also block the cart pages from search engines by blocking that page within the robots.txt file or blog search engines from indexing pages with the cart function on them. This is common for those who tend to take down their websites for religious reasons such as Shabbat.
With any option, you should always have a interstitial or pop-up explaining why your website is down for the day. Google told webmasters, that fear Google’s interstitial penalty, not to worry if they use this for religious reasons. When you put up a pop-up explaining the closure, make sure that a 503 HTTP result code (Service Unavailable) appears. This result code makes sure that Google does not index the temporary content on the interstitial.
If you are moving a website to a completely new data center you should also have a 503 HTTP result code appear for all URLs. In addition, you should point your DNS to that server during that time. Below are some steps to take when switching your DNS to the temporary server.
- Set your DNS TTL to a low time (such as five minutes) a few days in advance.
- Change the DNS to the temporary server’s IP address.
- Take your main server offline once all requests go to the temporary server.
- … your server is now offline …
- When ready, bring your main server online again.
- Switch DNS back to the main server’s IP address.
- Change the DNS TTL back to normal.
Following these steps will ensure that your website will not get hit with any penalties and make the temporary closure as smooth as possible.