We use cookies to understand how DevToolsHub is used and to improve your experience. You can choose which types of cookies to allow.
Search and reference HTTP status codes with descriptions and use cases.
Loading...
Loading...
HTTP status codes are three-digit numbers returned by a server in response to a client’s HTTP request. They are a fundamental part of the HTTP protocol, defined in RFC 9110, and they tell the client whether a request was successful, whether it needs to take further action, or whether something went wrong. Every HTTP response — whether from a web page load, a REST API call, or a fetch request in JavaScript — includes one of these status codes.
Status codes are grouped into five categories based on their first digit. The 1xx range provides informational responses, 2xx indicates success, 3xx handles redirections, 4xx signals client errors, and 5xx indicates server errors. Understanding these codes is essential for web developers, API designers, DevOps engineers, and anyone working with HTTP-based systems.
For developers building or consuming REST APIs, HTTP status codes are the primary means of communicating the outcome of a request. Returning the correct status code is a best practice that helps clients handle responses appropriately — whether that means displaying a success message, retrying a failed request, authenticating the user, or showing a meaningful error. Using the wrong status code can lead to confused clients, broken retry logic, and poor developer experience.
The five categories of HTTP status codes each serve a distinct purpose. Knowing what each category represents helps you quickly diagnose issues when debugging API responses or web applications:
Some HTTP status codes are encountered far more frequently than others. Here are the most commonly seen status codes in everyday web development and API design:
Loading...