An Analysis of the Performance of WebSockets in Various Programming Languages

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. uWebSockets.js

    μWebSockets for Node.js back-ends :metal:

    Interesting that https://github.com/uNetworking/uWebSockets.js outperforms the raw C++ uWebSockets implementation.

    It's also interesting that https://github.com/websockets/ws does not appear in this study, given that in the node ecosystem it is ~3x more likely to be used (not a perfect measurement but ws has 28k github stars vs uWebSockets 8k stars)

  2. CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  3. Go-Gorilla_Websocket-Benchmark-Server

    This is a Go (Gorilla) variation of websocket servers designed to benchmark the performance of both reliability and speed of various websocket implementations.

    https://github.com/matttomasetti/Go-Gorilla_Websocket-Benchm...

    Also, this paper is from Feb 2021.

  4. Go-Gorilla_Websocket-Benchm

    Discontinued [GET https://api.github.com/repos/matttomasetti/Go-Gorilla_Websocket-Benchm: 404 - Not Found // See: https://docs.github.com/rest/repos/repos#get-a-repository]

    https://github.com/matttomasetti/Go-Gorilla_Websocket-Benchm...

    Also, this paper is from Feb 2021.

  5. ws

    Simple to use, blazing fast and thoroughly tested WebSocket client and server for Node.js

    Interesting that https://github.com/uNetworking/uWebSockets.js outperforms the raw C++ uWebSockets implementation.

    It's also interesting that https://github.com/websockets/ws does not appear in this study, given that in the node ecosystem it is ~3x more likely to be used (not a perfect measurement but ws has 28k github stars vs uWebSockets 8k stars)

  6. µWebSockets

    Simple, secure & standards compliant web server for the most demanding of applications

    NodeJS beating C++ in these benchmarks makes me suspect the methodology / server setup since the NodeJS library[0] used is just a wrapper around the C++ library[1].

    [0]: https://github.com/uNetworking/uWebSockets.js

  7. NodeJS_Websocket-Benchmark-Client

    This is a NodeJS websocket client designed to benchmark the performance of both reliability and speed of various websocket implementations.

    Yes _however_ the nodejs benchmark at least is handling each message asynchronously, whereas the go implementation is only handling connections asynchronously.

    The client fires off all the requests before waiting for a response: https://github.com/matttomasetti/NodeJS_Websocket-Benchmark-... so the comparison isn't quite apples to apples.

  8. NodeJS_Websocket-Benchmark-

    Discontinued [GET https://api.github.com/repos/matttomasetti/NodeJS_Websocket-Benchmark-: 404 - Not Found // See: https://docs.github.com/rest/repos/repos#get-a-repository]

    Yes _however_ the nodejs benchmark at least is handling each message asynchronously, whereas the go implementation is only handling connections asynchronously.

    The client fires off all the requests before waiting for a response: https://github.com/matttomasetti/NodeJS_Websocket-Benchmark-... so the comparison isn't quite apples to apples.

  9. SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  10. event-loop

    ReactPHP's core reactor event loop that libraries can use for evented I/O.

    It uses reactphp event-loop library:

    https://github.com/reactphp/event-loop

    That library can use either select, libuv, libev or libevent if I'm not mistaken. Fibers are not used at this point, although other libraries have explored the idea (revoltphp).

    If we're assuming the paper author installed a typical PHP, then it's using select for async I/O. It's the slowest implementation of the event loop.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • I have done a full benchmark of a POST REST API on my computer: Node.js vs Fastify vs Express.js vs Deno vs Bun vs GO. Node.js is used WITH and WITHOUT clustering on 6-core I7 processor

    6 projects | /r/node | 22 May 2023
  • Socketify.py - Maybe the fastest web framework for Python and PyPy

    3 projects | /r/Python | 8 Nov 2022
  • Data fetching on the web still sucks

    3 projects | news.ycombinator.com | 27 Jan 2021
  • Uwebsockets.js

    1 project | news.ycombinator.com | 4 Mar 2025
  • Real-Time Data Streaming with AWS Kinesis, Spring Boot, and React

    3 projects | dev.to | 5 Nov 2024

Did you know that C++ is
the 7th most popular programming language
based on number of references?