Skip to main content

WebSocket Debugging

Debug WebSocket connections by connecting to any WebSocket server and inspecting the message flow in real time.

Creating a WebSocket session

  1. Navigate to Realtime in the dashboard
  2. Click New Session
  3. Select WebSocket as the protocol
  4. Enter the WebSocket URL (e.g., wss://echo.websocket.org)
  5. Optionally configure:
    • Custom headers — for authentication or other purposes
    • Subprotocols — WebSocket subprotocol negotiation
  6. Click Connect

Inspecting messages

Once connected, the dashboard displays:

Message stream

A chronological list of all messages with:

  • Direction — sent (outgoing) or received (incoming)
  • Timestamp — when the message was sent or received
  • Content — the message payload (JSON is syntax-highlighted)
  • Frame type — text or binary

Connection info

  • Connection status — connected, disconnected, or error
  • Server URL — the connected WebSocket endpoint
  • Connection duration — how long the connection has been open
  • Close code and reason — when the connection closes

Sending messages

Type a message in the input field and click Send to send a text frame to the server. Useful for:

  • Testing echo servers
  • Triggering server-side events
  • Debugging request/response protocols

Use cases

  • API development — debug WebSocket APIs during development
  • Integration testing — verify WebSocket behavior from third-party services
  • Protocol debugging — inspect raw WebSocket frame exchange
  • Load testing prep — understand message patterns before load testing