Servidor WebSocket de eco

Muestra cómo escribir una aplicación sencilla de servidor WebSocket.

Este servidor Echo muestra cómo crear una aplicación de servidor sencilla que envía una respuesta al mensaje que recibe, utilizando la API de WebSocket. A modo de ejemplo, la respuesta es simplemente una copia del mensaje.

Si tu navegador web es compatible con WebSocket, también puedes utilizarlo para abrir el archivo echoserver/echoclient.html{echoclient.html} y seguir los pasos que se muestran en la siguiente captura de pantalla:

Cliente HTML de WebSocket Echo

De lo contrario, utiliza el cliente Echo de WebSocket para conectarte al servidor.

Proyecto de ejemplo en code.qt.io

Véase también Cliente de eco de WebSocket.

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.