Pretty great with https://github.com/ratchetphp/Ratchet tbh. But yeah, different runtime. Ratchet is built on top of ReactPHP which is an event-loop runtime (think nodejs).
It's helpful to be able to reuse some domain code between the two if necessary, but IO cannot be done the same in ReactPHP because it needs to be async. Good news is ReactPHP has a ton of really great async libs (mysql, redis, etc.) https://reactphp.org/
As others have said, Swoole is also an option, it's more like Go (coroutine style). Personally, I think it's super cool, but not something I want to use, because the majority of the userbase is chinese and the docs and ecosystem suffer from the language barrier.
fyi on swoole, this book [1] just came out (I cannot comment on the quality, haven't read yet) which hopefully will help bridge the English documentation gap. I've been using swoole for a couple of years and google-translating my way through the Chinese wiki and git issues/comments/etc.
Swoole (module) is extremely performant in anything networking, including as a websocket server. There are other php-only options (amphp/websocket-server, ratchetphp/Ratchet) but if performance is your need, stick with swoole.
There isn't direct support for WebSocket in PHP like there is for HTTP requests. But there are WebSocket servers written in PHP that work in a similar way to node.js.
It's helpful to be able to reuse some domain code between the two if necessary, but IO cannot be done the same in ReactPHP because it needs to be async. Good news is ReactPHP has a ton of really great async libs (mysql, redis, etc.) https://reactphp.org/
As others have said, Swoole is also an option, it's more like Go (coroutine style). Personally, I think it's super cool, but not something I want to use, because the majority of the userbase is chinese and the docs and ecosystem suffer from the language barrier.