A Little HTTP Status Code Refresher

So we have looked at , or any number of other sites to get what we are about to go over.  HTTP Status codes are something that everyone should understand, yes even marketers, but we don’t always think about them or know what all the options are.  So think about this is as a quick refresher just like it’s a quick refresher for me to put it together.  So that next time you get 404ed you know how to 301 to a 200.  icon smile A Little HTTP Status Code Refresher   Ok ok that’s enough stupid jokes from me as I think you are probably about to do a 504 on this guy.  So without further ado let us 100.

Status codes come in one of five categories which are listed as hundreds and the specific status code is the final number.  Categories tell us the type of code.

1xx Success

100 Continue - Tells the client that the first part of the request has been received and that it should continue with the rest of the request or ignore if the request has been fulfilled.

101 Switching Protocols - Tells the client that the server will switch protocols to that specified in the Upgrade message header field during the current connection.

2xx Success

200 OK - The request sent by the client was successful.

201 Created - The request was successful and a new resource was created.

202 Accepted - The request has been accepted for processing, but has not yet been processed.

203 Non-Authoritative Information - The returned meta information in the entity-header is not the definitive set as available from the origin server.

204 No Content - The request was successful but does not require the return of an entity-body.

205 Reset Content - The request was successful but the User-Agent should reset the document view that caused the request.

206 Partial Content - The partial GET request has been successful.

3xx Redirection

300 Multiple Choices - The requested resource has multiple possibilities, each with different locations.

301 Moved Permanently - The resource has permanently moved to a different URI.

302 Found - The requested resource has been found under a different URI but the client should continue to use the original URI.

303 See Other - The requested response is at a different URI and should be accessed using a GET command at the given URI.

304 Not Modified - The resource has not been modified since the last request.

305 Use Proxy - The requested resource can only be accessed through the proxy specified in the location field.

306 No Longer Used - Reserved for future use.

307 Temporary Redirect - The resource has temporarily been moved to a different URI. The client should use the original URI to access the resource in future as the URI may change.

4xx Client Side Error

400 Bad Request - The syntax of the request was not understood by the server.

401 Not Authorized - The request needs user authentication

402 Payment Required - Reserved for future use.

403 Forbidden - The server has refused to fulfill the request.

404 Not Found - The document/file requested by the client was not found.

405 Method Not Allowed - The method specified in the Request-Line is not allowed for the specified resource.

406 Not Acceptable - The resource requested is only capable of generating response entities which have content characteristics not specified in the accept headers sent in the request.

407 Proxy Authentication Required - The request first requires authentication with the proxy.

408 Request Timeout - The client failed to sent a request in the time allowed by the server.

409 Conflict - The request was unsuccessful due to a conflict in the state of the resource.

410 Gone - The resource requested is no longer available and no forwarding address is available.

411 Length Required - The server will not accept the request without a valid Content-Length header field.

412 Precondition Failed - A precondition specified in one or more Request-Header fields returned false.

413 Request Entity Too Large - The request was unsuccessful because the request entity is larger than the server will allow.

414 Request URI Too Long - The request was unsuccessful because the URI specified is longer than the server is willing to process.

415 Unsupported Media Type - The request was unsuccessful because the entity of the request is in a format not supported by the requested resource for the method requested.

416 Requested Range Not Satisfiable - The request included a Range request-header field, and not any of the range-specifier values in this field overlap the current extent of the selected resource, and also the request did not include an If-Range request-header field.

417 Expectation Failed - The expectation given in the Expect request-header could not be fulfilled by the server.

5xx Server Side Error

500 Internal Server Error - The request was unsuccessful due to an unexpected condition encountered by the server.

501 Not Implemented - The request was unsuccessful because the server can not support the functionality needed to fulfill the request.

502 Bad Gateway - The server received an invalid response from the upstream server while trying to fulfill the request.

503 Service Unavailable - The request was unsuccessful to the server being down or overloaded.

504 Gateway Timeout - The upstream server failed to send a request in the time allowed by the server.

505 HTTP Version Not Supported - The server does not support or is not allowing the HTTP protocol version specified in the request.

Conclusion

By far the codes you are most likely to run into are 200, 301, 404.  Most of the time you will not see the http status codes because the page will load properly and everything is going fine.  If you’re interested in viewing them there are a couple of Firefox plugins to help with this.  What you need access to is the HTTP headers.

  • Web Developer - By going through the menus to Information -> View Response Headers you can see the status code along with some additional information returned on the page.
  • Live HTTP Headers - This little plugin is also handy for viewing the headers on pages.  Simply open up the tool and watch them fly through as you view pages.

So now hopefully you understand these bad boys a little better.  I know I do just putting this list together.

8 Responses to “A Little HTTP Status Code Refresher”

  1. Says:

    Great post Kyle. I find that too often status codes go un-noticed or have little attention paid to them. Status codes are very useful with SEO as you’ve mentioned, but they are also important with security. For example if you get a lot of 403 Forbidden status codes, you may be able to conclude that someone is trying to hack your site.

    Anyway, I’m glad to this post and hope to see more people focus on status codes.

    • Says:

      Mike,
      Glad that you enjoyed the post. Sometimes something as simple as a little refresher and educational post like this can be so important. So next time someone starts talking about a 403 you know exactly what they are talking about.

  2. Says:

    hey this is cool thanks

  3. Says:

    A magnificent post indeed, Kyle. I only encountered the 403, 404 and 500 codes before and most of the codes that being listed above are totally new to me…

    It’s really great to learn something new everyday, Kyle!

  4. Says:

    Hey, i came across your page on google and i think it’s sweet!

  5. Says:

    Kyle,

    I was doing some searching for problems relating to 502 bad proxy error and hubspot and what do you know I stumbled here. We’re having intermittent 502 errors with hubspot’s site. We don’t experience this with anyone else. Any ideas? From what I’ve seen this is most commonly related to Microsoft ISA servers and some configuration changes that need to be setup there.

    • Says:

      Have you contacted HubSpot support about this? 1-888-HUBSPOT ext 3

Trackbacks/Pingbacks

  1. Daily Links | AndySowards.com :: Professional Web Design, Development, Programming, Hacks, Downloads, Math and being a Web 2.0 Hipster? --> says:

    [...] HTTP Status Codes: A Little Refresher | .eduGuru Quick and easy status codes - Refresh your memory [...]