About the WebSocket Tester
The WebSocket Tester opens a connection from your browser to any ws:// or wss:// server so you can send messages and watch replies in a live log. Use it to check that an endpoint accepts connections or to debug a real-time API without writing client code.
The connection goes directly from your browser to the server, not through our server. The log timestamps every sent and received message to the millisecond, pretty-prints JSON, shows binary frames as a byte count and hex preview, and records the close code and reason when the connection ends. You can also request subprotocols; the one the server accepts is shown once connected.
How to use it
- Enter a WebSocket URL starting with
ws://orwss://, or pick a preset. - Optionally check "Set subprotocols" and enter a comma-separated list.
- Click Connect and wait for the Connected badge.
- Type a message and press Enter to send it (Shift+Enter adds a new line).
- Click Disconnect when done; the log shows the close code.
Examples
- Connect to the echo server at wss://echo.websocket.org: it sends back whatever you send.
Common questions
Why does my WebSocket connection fail?
Check the URL, that the server is running, and that its TLS certificate is valid for wss://. Browsers do not expose the reason for a failed connection, so check the server logs. Servers that check the Origin header will see this site's origin and may reject it.
Should I use ws:// or wss://?
Use wss://. This page is served over HTTPS, and browsers usually block unencrypted ws:// connections from secure pages as mixed content.
Can I send custom headers such as Authorization?
No. The browser WebSocket API does not allow custom handshake headers. Pass a token in the query string or first message if your server supports it.
Related tools
- SSL Certificate Checker: verify the certificate on your
wss://host. - JSON Formatter & Validator: format and validate a message payload.
- Open Port Checker: confirm the server's port is reachable.