Google: Don't Use A 502 Status Code When You Should Use A 503

Mar 23, 2021 - 7:51 am 0 by

502

Recently, Google's John Mueller posted about what to do if your site goes offline. The advice was to serve a 503 server status code if the outage is short term. So someone asked if they can serve a 502 server status code instead. John Mueller said you shouldn't.

John was asked on Twitter "does 502 error work as well or it is required to be 503 only ? I want to check because hosting companies throw different error codes in different cases."

John responded on Twitter "502 is not the same as a 503 -- I'd recommend using the proper result code. These durations aren't documented in absolute terms since they can change & vary." He gave this analogy, "If a bus is temporarily delayed for an unknown time, how long do you wait until you look for something else?"

The HyperText Transfer Protocol (HTTP) 502 Bad Gateway server error response code indicates that the server, while acting as a gateway or proxy, received an invalid response from the upstream server.

So stick with the right server status response code for the right situation.

Forum discussion at Twitter.

 

Popular Categories

The Pulse of the search community

Google Search Volatility

More Details

Search Video Recaps

 
Video Details More Videos Subscribe to Videos

Most Recent Articles

Google

Google AI Overviews Pushing Searchers Into AI Mode, Drops Show More Button

Aug 28, 2026 - 1:30 pm
Search Forum Recap

Daily Search Forum Recap: August 28, 2026

Aug 28, 2026 - 10:00 am
Search Video Recaps

Search News Buzz Video Recap: Google GoTo Parameter Fight, PDFs Go Missing In Google, SEO For AI Responses & Google and Microsoft Ads News

Aug 28, 2026 - 8:01 am
Google Ads

Google Ads Book Buttons Expand To Search & Performance Max

Aug 28, 2026 - 7:51 am
Google Search Engine Optimization

Google Announces Search Updates For Transparency, Actionable Updates Get Blog Posts

Aug 28, 2026 - 7:41 am
Google

Google Preferred Sources, Tailor Your Feed & Search Profiles Are Different

Aug 28, 2026 - 7:31 am
 
Previous Story: Study Says 65% Of Google Searches Do Not Click On Results But Should They?