The HTTP Sec-WebSocket-Accept response header indicates a willingness of the server to initiate a WebSocket connection.

Table of Contents


The Sec-WebSocket-Accept response header is sent by the server to the client to agree that it will initiate a WebSocket connection. Only a single directive is used, which is a hashed key.

The hashed key is based on the value of the HTTP Sec-WebSocket-Key that was sent by the client in the handshake request.


Sec-WebSocket-Accept: OWQ4NjdjMDFhN2FiOGUwYzA4ZjYxNDc5MWFlMDQ2ZTViZDA1OWIzOA==


The Sec-WebSocket-Accept header is used to inform the client that the server is willing to initiate a WebSocket connection.

See also

Last updated: June 20, 2022