Updated on 2023-12-18 GMT+08:00

Status Codes

An HTTP status code consists of three digits, which is classified into five categories: 1xx: related information; 2xx: operation successful; 3xx: redirection; 4xx: client error; 5xx: server error.

The following table lists the common status codes.

Status Code

Coding

Description

100

Continue

The server has received the initial part of the request and the client should continue to send the remaining part.

It is issued on a provisional basis while request processing continues. It alerts the client to wait for a final response.

101

Switching Protocols

The requester has asked the server to switch protocols and the server has agreed to do so. The target protocol must be more advanced than the source protocol.

For example, the current HTTPS protocol is switched to a later version.

200

OK

The server has successfully processed the request.

201

Created

The request has been fulfilled, resulting in the creation of a new resource.

202

Accepted

The request has been accepted, but the processing has not been completed.

203

Non-Authoritative Information

The server has successfully processed the request, but is returning information that may be from another source.

204

No Content

The server has successfully processed the request, but does not return any content.

The status code is returned in response to an HTTP OPTIONS request.

205

Reset Content

The server has successfully processed the request, but does not return any content.

206

Partial Content

The server has successfully processed a part of the GET request.

300

Multiple Choices

There are multiple options for the location of the requested resource. The response contains a list of resource characteristics and addresses from which the user or user agent (such as a browser) can choose the most appropriate one.

301

Moved Permanently

The requested resource has been assigned a new permanent URI, and the new URI is contained in the response.

302

Found

The requested resource resides temporarily under a different URI.

303

See Other

The response to the request can be found under a different URI, and should be retrieved using a GET or POST method.

304

Not Modified

The requested resource has not been modified. In such a case, there is no need to retransmit the resource since the client has a previously-downloaded copy.

305

Use Proxy

The requested resource must be accessed through a proxy.

306

Unused

The HTTP status code is no longer used.

400

Bad Request

The request is invalid.

The client should not repeat the request without modifications.

401

Unauthorized

The authorization information provided by the client is incorrect or invalid.

402

Payment Required

This status code is reserved for future use.

403

Forbidden

The server has received the request and understood it, but refuse to respond to it.

The client should modify the request instead of re-initiating it.

404

Not Found

The requested resource cannot be found.

The client should not repeat the request without modifications.

405

Method Not Allowed

The method specified in the request is not supported for the requested resource.

The client should not repeat the request without modifications.

406

Not Acceptable

The server cannot fulfill the request according to the content characteristics of the request.

407

Proxy Authentication Required

This status code is similar to 401, but indicates that the client must first authenticate itself with the proxy.

408

Request Timeout

The server has timed out waiting for the request.

The client may repeat the request without modifications at a later time.

409

Conflict

The request could not be processed due to a conflict.

For example, an edit conflict between multiple simultaneous updates or the resource that the client attempts to create already exists.

410

Gone

The requested resource has been deleted permanently and is no longer available.

The status code indicates that the requested resource has been deleted permanently.

411

Length Required

The server refuses to accept the request without a defined Content-Length.

412

Precondition Failed

The server did not meet one of the preconditions contained in the request.

413

Request Entity Too Large

The request is larger than the server is willing or able to process. The server may close the connection to prevent the client from continuing the request. If the server is only temporarily unable to process the request, the response will contain a Retry-After header field.

414

Request URI Too Long

The Request-URI is too long for the server to process.

415

Unsupported Media Type

The server is unable to process the media format in the request.

416

Requested Range Not Satisfiable

The requested range is invalid.

417

Expectation Failed

The server has failed to meet the requirements of the Expect request-header field.

422

Unprocessable Entity

The request is well-formed but cannot be processed due to semantic errors.

429

Too Many Requests

The client has sent an excessive number of requests to the server within a given time (exceeding the limit on the access frequency of the client), or the server has received an excessive number of requests within a given time (beyond its processing capability). In this case, the client should resend the requests at any point after the time specified in the Retry-After header of the response.

500

Internal Server Error

The server is able to receive the request but unable to understand it.

501

Not Implemented

The server does not support the function required to fulfill the request.

502

Bad Gateway

The server was acting as a gateway or proxy and received an invalid response from the upstream server.

503

Service Unavailable

The requested service is invalid.

The client should not repeat the request without modifications.

504

Gateway Timeout

The request cannot be fulfilled within a given time. This status code is returned to the client only if the Timeout parameter is specified in the request.

505

HTTP Version Not Supported

The server does not support the HTTPS protocol version used in the request.