WebSocket Tester

Connect to any ws:// or wss:// endpoint, send messages, and inspect live events with timestamps. 100% client-side.

Last reviewed: April 2026

New to this tool? Click here for instructions

No events yet.
Events will appear here after connecting.
Recent connections (saved locally)
No history yet. Connect to a WebSocket URL to save it.

WebSocket Event Reference

Event Description
OPENConnection established. Ready to send and receive messages.
RECVMessage received from the server. JSON is auto-detected and pretty-printed.
SENDMessage sent to the server from this client.
ERRORA connection error occurred. Often followed by a CLOSE event.
CLOSEConnection closed. Shows close code and reason if provided by the server.

Close Codes

Code Meaning
1000Normal Closure - clean, intentional close
1001Going Away - server shutting down or page navigation
1002Protocol Error - invalid framing
1003Unsupported Data - binary data when text expected
1006Abnormal Closure - connection lost without close handshake
1007Invalid Frame Payload Data - not valid UTF-8
1008Policy Violation - server rejected the message
1009Message Too Big - payload exceeds server limit
1011Internal Error - server encountered unexpected condition
1015TLS Handshake - TLS failure (not sent over the wire)

Public Test Endpoints

  • wss://echo.websocket.org - echoes back everything you send
  • wss://ws.postman-echo.com/raw - Postman echo server
  • wss://socketsbay.com/wss/v2/1/demo/ - public demo channel
Enter a WebSocket URL and click Connect.

How to Use the WebSocket Tester

To use the WebSocket Tester, follow these steps:

1. Enter a URL: Type or paste a ws:// or wss:// URL in the field at the top.

2. Connect: Click the 'Connect' button. The indicator will turn green when the connection is established.

3. Watch the log: Open, receive, send, error, and close events will appear in the event log with timestamps.

4. Send messages: Type any text or JSON in the send box and click 'Send'. JSON will be auto-detected and pretty-printed in the log.

5. Disconnect: When done, the connection will be closed cleanly, and the log will show the close code.

When to Use the Tool in Real Workflows

Use the WebSocket Tester when you need to test WebSocket connections for real-time applications, such as chat, stock price feeds, or any other application that requires frequent updates.

It's particularly useful for developers who need to debug connection issues, test gRPC-Web and GraphQL subscriptions, or ensure that their WebSocket servers are functioning correctly.

How It Works

The WebSocket Tester establishes a direct WebSocket connection from your browser to any URL you enter. It logs all lifecycle events, including onopen, onmessage, onerror, and onclose, with precise timestamps.

Messages are inspected, and if the server sends valid JSON, the tool automatically pretty-prints it for easy reading.

Your connection history is saved to localStorage, so frequently used endpoints are just a click away.

Frequently Asked Questions

WebSocket is a communication protocol providing full-duplex communication over a single TCP connection. Unlike HTTP which is request-response, WebSocket keeps a persistent connection open so both the client and server can send data at any time. It is widely used for chat apps, live dashboards, financial tickers, and multiplayer games.
ws:// is unencrypted WebSocket (like http://). wss:// is encrypted WebSocket Secure (like https://), using TLS. In production, always use wss://. Browsers on HTTPS pages block connections to unencrypted ws:// endpoints due to mixed content policy.
WebSocket close events include a numeric code. Key codes: 1000 (Normal Closure), 1001 (Going Away), 1006 (Abnormal Closure - connection lost), 1008 (Policy Violation), 1011 (Internal Server Error). The Reference tab lists all standard codes and their meanings.
Yes, using ws://localhost:PORT/path. Note that browsers may block ws:// from an https:// page (mixed content). If blocked, access this page via http:// locally, or configure your dev server with TLS and use wss://.
No. This tester connects directly from your browser to the WebSocket URL you enter. The tool runs entirely in your browser. Message history is saved only to your browser's localStorage and never leaves your device.