Google’s John Mueller penned an article in the Webmaster Central blog with advice on how to properly close down a site for a day. These tips outline the correct way to temporarily shut down a site without affecting its search presence.
Block Shopping Cart Functionality
If an e-commerce site simply needs to prevent people from making purchases, then Mueller’s recommendation is to just disable shopping cart functionality. In addition to communicating the shut down to customers, it’s also recommended to block the shopping cart page from being crawled through the robots.txt file, or blocked from indexing with a robots meta tag.
Use an Interstitial or Pop-Up
If it’s necessary to block the entire site from visitors, Mueller recommends using an interstitial or pop-up to communicate the site is temporarily unavailable. In addition, the server should return a 503 HTTP result code (“Service Unavailable”) so Google doesn’t index the temporary content. It’s safe to use a 503 for up to a week — after a week Google may drop the content from search results altogether.
Turn the Whole Website Off
Turning the entire server off is another safe option, provided you have a second temporary server with a 503 HTTP result code for all URLs. In addition, it’s recommended to switch your DNS to point to that server during that time.
Mueller explains how to do this step-by-step:
- Set your DNS TTL to a low time (such as 5 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.
If you own a local business which will be closed throughout the same duration that your site will be down, it’s recommended to change the opening hours in your local listings to reflect the closure.