Important: Please read the Qt Code of Conduct -

WebSocket Services

  • I have a project i'm currently looking at migrating over to QT for easier cross OS compatibility. Currently it uses Visual C++.

    It's in part a web socket server and it uses "services". Now when I've been trying to look through the Qt Documentation and examples, but do not see anything like it.

    Does QT not support this part of the RFC or am I just blind and can't see it?

  • If you mean this definition:

    Qt can manage XML and JSON natively for SOAP you can use KD SOAP

  • No that is not what i meant.
    I'm more use to create an objects that acts as a Server end points for the Websocket Server. So you would then make a connection to:


    And so on. In side the Visual C++ I have something along these lines

    WebsocketServer server;
    server.registerService(new SomeEndPointClass1, "endpoint1");
    server.registerService(new SomeEndPointClass2, "endpoint2");
    server.registerService(new SomeEndPointClass3, "endpoint3");

    Then the individual class/object would take handle the communication and the Websocketserver is just there to route the incoming packets to the Endpoint.

  • Then you must be looking for the QWebSocketServer & QWebSocket classes.

    You will find some example projects in QtCreator directly if you search for "websocket" (or directly in the documentation).


Log in to reply