What are HTTP status codes?

An HTTP status code is a server response to a browser’s request. When you visit a website, your browser sends a request to the site’s server, and the server then responds to the browser’s request with a three-digit code: the HTTP status code.

These status codes are the Internet equivalent of a conversation between your browser and the server. They communicate whether things between the two are A-okay, touch-and-go, or whether something is wrong. The first digit of each three-digit status code begins with one of five numbers, 1 through 5; you may see this expressed as 1xx or 5xx to indicate status codes in that range. Each of those ranges encompasses a different class of server response.

Common HTTP status code classes:

  • 1xxs – Informational responses: The server is thinking through the request.
  • 2xxs – Success! The request was successfully completed and the server gave the browser the expected response.
  • 3xxs – Redirection: You got redirected somewhere else. The request was received, but there’s a redirect of some kind.
  • 4xxs – Client errors: Page not found. The site or page couldn’t be reached. (The request was made, but the page isn’t valid — this is an error on the website’s side of the conversation and often appears when a page doesn’t exist on the site.)
  • 5xxs – Server errors: Failure. A valid request was made by the client but the server failed to complete the request.
1xx: HTTP Inform­ational Codes
CodeDescription
100Continue
101Switching Protocols
102Processing WebDAV
103Checkpoint draft POST PUT
122Reques­t-URI too long IE7
2xx: HTTP Successful Codes
CodeDescription
200OK
201Created
202Accepted
203Non-Au­tho­rit­ative Inform­ation 1.1
204No Content
205Reset Content
206Partial Content
207Multi-­Status WebDAV 4918
208Already Reported WebDAV 5842
226IM Used 3229 GET
3xx: HTTP Redire­ction Codes
CodeDescription
300Multiple Choices
301Moved Perman­ently
302Found
303See Other 1.1
304Not Modified
305Use Proxy 1.1
306Switch Proxy unused
307Temporary Redirect 1.1
308Permanent Redirect 7538

307 and 308 are similar to 302 and 301, but the new request method after redirect must be the same, as on the initial request.

4xx: HTTP Client Error Code
CodeDescription
400Bad Request
401Unauth­orized
402Payment Required res
403Forbidden
404Not Found
405Method Not Allowed
406Not Acceptable
407Proxy Authen­tic­ation Required
408Request Timeout
409Conflict
410Gone
411Length Required
412Precon­dition Failed
413Request Entity Too Large
414Reques­t-URI Too Long
415Unsupp­orted Media Type
416Requested Range Not Satisf­iable
417Expect­ation Failed
418I’m a teapot 2324
422Unproc­essable Entity WebDAV 4918
423Locked WebDAV 4918
424Failed Dependency WebDAV 4918
425Unordered Collection 3648
426Upgrade Required 2817
428Precon­dition Required draft
429Too Many Requests draft
431Request Header Fields Too Large draft
444No Response nginx
449Retry With MS
450Blocked By Windows Parental Controls MS
451Unavai­lable For Legal Reasons draft
499Client Closed Request nginx
5xx: HTTP Server Error Codes
CodeDescription
500Internal Server Error
501Not Implem­ented
502Bad Gateway
503Service Unavai­lable
504Gateway Timeout
505HTTP Version Not Supported
506Variant Also Negotiates 2295
507Insuff­icient Storage WebDAV 4918
508Loop Detected WebDAV 5842
509Bandwidth Limit Exceeded nostd
510Not Extended 2774
511Network Authen­tic­ation Required draft
598Network read timeout error nostd
599Network connect timeout error nostd

HTTP Code Comments

WebDAVWebDAV extension
1.1HTTP/1.1
GET, POST, PUT, POSTFor these methods only
IEIE extension
MSMS extension
nginxnginx extension
2518, 2817, 2295, 2774, 3229, 4918, 5842RFC number
draftProposed draft
nostdNon standard extension
resReserved for future use
unusedNo more in use, deprecated

Wikipedia was used to produce all HTTP status codes content: http:/­/en.wi­kip­edi­a.o­rg/­wik­i/H­TTP­_status

Leave a Comment