---
title: "WebSocket"
description: "WebSocket connections, messages, and lifecycle."
icon: "zap"
---

## Available functions

<div className="byte-function-directory">
<CardGroup cols={2}>
  <Card title="WebSocket.connect" href="/reference/websocket/websocket-connect">
    Opens a ws:// or wss:// connection and creates heartbeat-driven event delivery.
  </Card>
  <Card title="WebSocketObject.Close" href="/reference/websocket/websocketobject-close">
    Closes the socket and stops its message pump.
  </Card>
  <Card title="WebSocketObject.Send" href="/reference/websocket/websocketobject-send">
    Sends a text or binary message over an open WebSocket.
  </Card>
</CardGroup>
</div>

[View types and behavior](/reference/websocket/types)
