1xx Informational
Last updated Jun 09, 2026

What is HTTP Status Code 101? - Switching Protocols

Benjamin Bouchet
Benjamin Bouchet
Get your free
Abstract
 API key now
stars rating
4.8 from 1,863 votes
See why the best developers build on Abstract
START FOR FREE
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
No credit card required

The HTTP Status 100 (Switching Protocols) means that the client has asked the server to change protocols and the server has agreed to do so.

Note that when a Status 101 is returned the server must generate an Upgrade header in its response indicating which protocol it has switched to. Also note that the server should only accept switching protocols (and thus return Status 101) when it's advantageous to do so, such as when it upgrades to a newer version of HTTP.

Frequently Asked Questions

What does HTTP 101 mean?

HTTP 101 Switching Protocols is an informational response indicating that the client requested a protocol change and the server has agreed to it. It belongs to the 1xx class of status codes, which are purely informational and do not represent a completed request or an error.

When does a server return a 101 status code?

A server returns 101 when a client sends an HTTP request with an Upgrade header specifying a different protocol — most commonly to initiate a WebSocket connection or to switch to a newer HTTP version. The server must include its own Upgrade header in the 101 response to confirm which protocol it has switched to.

What happens after the server sends a 101 response?

Once the 101 response is sent, the original HTTP connection is replaced by the newly negotiated protocol. All further communication between client and server happens over that protocol — for example, the WebSocket frame format instead of standard HTTP framing. The 101 response itself has no body.

Is HTTP 101 an error code?

No. HTTP 101 is not an error. It is an informational status code in the 1xx range, signaling a successful protocol negotiation between client and server. Errors in HTTP are indicated by 4xx (client errors) and 5xx (server errors) codes.

What is the difference between HTTP 101 and HTTP 200 during a WebSocket upgrade?

A 101 response confirms the server accepted the upgrade and switched protocols, allowing WebSocket communication to begin. A 200 response means the server ignored the Upgrade header and handled the request as a normal HTTP request, so the protocol switch did not occur.

Can a client force a server to switch protocols?

No. The server decides whether to accept or ignore the upgrade request. The protocol switch is only advantageous — and therefore only performed — when it benefits the handling of the request, such as enabling a persistent WebSocket connection. If the server does not wish to switch, it can respond with a different status code and continue over the existing protocol.

Get your free
API
key now
stars rating
4.8 from 1,863 votes
See why the best developers build on Abstract
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
No credit card required