Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 103085
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T01:04:04+00:00 2026-05-11T01:04:04+00:00

The HTTP/1.1 specification ( RFC2616 ) defines a number of status codes that can

  • 0

The HTTP/1.1 specification (RFC2616) defines a number of status codes that can be returned by HTTP server to signal certain conditions. Some of those codes can be utilized by web applications (and frameworks). Which of those codes are the most useful in practice in both classic and asynchronous (XHR) responses, in what situations you use each of them?

Which codes should be avoided, eg. should applications mess with the 5xx code range at all? What are your conventions when returning HTTP codes in REST web services? Do you ever use redirects other than 302?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T01:04:05+00:00Added an answer on May 11, 2026 at 1:04 am

    The ones I’m using (that I could find with a quick grep 'Status:' anyway):

    • 200 Successfully retrieved a resource without affecting it
    • 201 Sent whenever a form submission puts something significant into the database (forum post, user account, etc.), creating a new resource
    • 204 Sent with empty body, for example after a DELETE
    • 304 HTTP caching. I’ve found this one is very hard to get right since it has to account for users changing display settings and so on. The best idea I’ve come up with for that is using a hash of the user’s preferences as the ETag. It doesn’t help that most browsers have unpredictable and inconsistent behaviour here…
    • 400 Used for bad form submissions that fail some validation check.
    • 403 Used whenever someone is somewhere they shouldn’t be (though I try to avoid that by not displaying links to stuff the users shouldn’t access).
    • 404 Apart from the normal webserver ones I use these when the URL contains invalid ID numbers. I suppose it’d be a good idea to check in this case whether a higher valid ID exists and send a 410 instead…
    • 429 When user’s requests are too frequents
    • 500: I tend to put these in catch{ } blocks where the only option is to give up, to make sure something meaningful is sent to the browser.

    I realise I could get away with simply letting the server send ‘200’ for everything, but they save a lot of pain when users are seeing (or causing) errors and not telling you about them. I’ve already got functions to display access-denied messages and so on, so it’s not much work to add these anyway.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

http://jqueryui.com/demos/accordion/ You can do $('#itename').accordion('activate', 0) to make an accordion closed but that'll change
The PSGI specification defines the HTTP response as consisting of three parts, the third
What is the specification for maximum data size one can send with HTTP POST
HTTP specification (RFC2616) has the following phrase: If a Transfer-Encoding header field (section 14.41)
My understanding from reading the specification ( http://www.ietf.org/rfc/rfc2445.txt ) is that the : character
In my experience and that of others (http://webster.cs.ucr.edu/Page_TechDocs/pe.txt), the PE/COFF specification document incorrectly claims
the HTTP specification states that the Transfer-Encoding header is allowed for requests - but
Regarding this specification: http://www.w3.org/TR/eventsource/ How does one close the opened connection on the server?
FLV format specification is here: http://www.adobe.com/content/dam/Adobe/en/devnet/flv/pdfs/video_file_format_spec_v10.pdf 1) FLV body consists of tags 2) Each
Mode : http://www.emacswiki.org/emacs/CSharpMode log: Loading /.emacs.d/contrib/dev/csharp-mode.el Done loading /.emacs.d/contrib/dev/csharp-mode.el File mode specification error: (void-function

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.