Error Codes Wiki

HTTP 101 Switching Protocols — What It Means & How to Fix It

Informational1xx informational

Overview

The HTTP 101 Switching Protocols status code indicates the server is switching to a different protocol as requested by the client via the Upgrade header.

Key Details

  • This status code is sent in response to a client request that includes an Upgrade header.
  • It is most commonly seen when upgrading from HTTP/1.1 to WebSocket connections.
  • The server agrees to switch protocols and the connection transitions immediately.
  • After this response, communication continues using the new protocol.

Common Causes

  • Client requests a WebSocket connection upgrade via the Upgrade header.
  • Client requests an upgrade to HTTP/2 from HTTP/1.1.
  • Application protocols that require a protocol switch after initial handshake.

Steps

  1. 1Ensure the client correctly sends the Upgrade header with the desired protocol.
  2. 2Verify the server supports the requested protocol upgrade.
  3. 3Check that firewalls and proxies allow WebSocket or other upgraded protocol traffic.
  4. 4Inspect the Connection and Upgrade response headers for correctness.

Tags

httpinformationalwebsocketprotocol-upgrade

Related Items

More in 1xx Informational

Frequently Asked Questions

It means the server acknowledges the client request to switch protocols and is transitioning to the new protocol specified in the Upgrade header.