Popular interpretation and dictionary of HTTP code often used


1XX – information response, processing

  • 101 Switching ProtocolProtocol upgrade.

2XX – successful response

  • 200 OKRequest normal return. The other one is200 CacheIt is HTTP strong cache related, indicating the cache content read directly.
  • 204 No ContentThe server successfully processed the request without returning content.
  • 206 Partial ContentSome requests processed successfully. That is to say, HTTP 1.1 adds a new breakpoint for continuous transmission, which is generally used to download large filesRangeuse.

3xx – redirect

  • 300 Multiple ChoiceSubsequent operations are required, and the user or browser is required to select one of the multiple redirection addresses returned.
  • 301 Moved PermanentlyPermanent redirection. The server willLocationField to return the new address. Search engine will update and record the current address, which is generally used for site reconstruction and other scenarios.
  • 302 FoundTemporary redirection. Also inLocationReturns the new address. The search engine does not update.
  • 304 Not ModifiedThe content has not changed, indicating that the browser’s cache is available. Generally used for HTTP negotiation cache.

4xx – client error

  • 400 Bad RequestGenerally, it is used as a client request parameter or semantic error and cannot be understood by the server.
  • 401 UnauthorizedThe request requires user authentication. Generally, it means that the user does not carry the correct authentication information, that is, the user does not log in.
  • 403 ForbiddenThe server refused execution. It is generally used for insufficient user rights, for example, the ordinary user requests the interface to which the administrator belongs.
  • 404 Not FoundThe resource does not exist. Needless to say, the most common one.
  • 405 Method Not AllowedRequest method error. For example, getting user information is a get request, but the client sends a post request.

5xx – server error

  • 500 Internal Server ErrorIn general, it is an unknown error that the server directly catches.
  • 502 Bad GatewayGateway error.
  • 504 Gateway TimeoutThe request timed out while the server was acting as a gateway.