Github url


by uNetworking

uNetworking /uWebSockets

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

11.6K Stars 1.2K Forks Last release: 11 days ago (v18.9.0) Apache License 2.0 520 Commits 82 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:

Simple, secure[1] & standards compliant[2] web server for the most demanding[3] of applications. Read more...

Language grade: C/C++

:closed_lock_with_key: Optimized security

Being meticulously optimized for speed and memory footprint, µWebSockets is fast enough to do encrypted TLS 1.3 messaging quicker than most alternative servers can do even unencrypted, cleartext messaging[3].

Furthermore, we partake in Google's OSS-Fuzz with a ~90% daily fuzzing coverage with no sanitizer issues. LGTM scores us flawless A+ from having zero CodeQL alerts.

:arrow_forward: Rapid scripting

µWebSockets is written entirely in C & C++ but has seamless integrations for both Python3 and Node.js backends. This allows for rapid scripting of powerful apps, in your favorite environment.


:battery: Batteries included

Designed around a convenient URL router with wildcard & parameter support - paired with efficient pub/sub features inspired by MQTT. µWebSockets should be the obvious, complete starting point for any real-time web project with high demands.

Start building your Http & WebSocket apps in a swift; read the user manual and see examples. You can browse our TypeDoc for a quick overview.

uWS::SSLApp({ /\* There are tons of SSL options, see uSockets \*/ .cert\_file\_name = "cert.pem", .key\_file\_name = "key.pem" }).get("/hello", [](auto \*res, auto \*req) { /\* You can efficiently stream huge files too \*/ res-\>writeHeader("Content-Type", "text/html; charset=utf-8")-\>end("Hello HTTP!"); }).ws<userdata>("/*", {

    /* Just a few of the available handlers */
    .open = [](auto *ws, auto *req) {
        /* MQTT syntax */
    .message = [](auto *ws, std::string_view message, uWS::OpCode opCode) {
        ws-&gt;send(message, opCode);

}).listen(9001, [](auto *listenSocket) {

    if (listenSocket) {
        std::cout &lt;&lt; "Listening on port " &lt;&lt; 9001 &lt;&lt; std::endl;


:briefcase: Commercially supported

uNetworking AB is a Swedish consulting & contracting company dealing with anything related to µWebSockets; development, support and customer success.

Don't hesitate sending a mail if you're building something large, in need of advice or having other business inquiries in mind. We'll figure out what's best for both parties and make sure you're not stepping into one of the many common pitfalls.

Special thanks to BitMEX, Bitfinex, Google, Coinbase, Bitwyre and deepstreamHub for allowing the project itself to thrive on GitHub since 2016 - this project would not be possible without these beautiful companies.

:jigsaw: Pluggable architecture

µWebSockets builds on µSockets, a foundation library implementing eventing, networking and cryptography in three different layers. Every layer has multiple implementations and you control the compiled composition with flags.

In a nutshell:

  • WITH\_WOLFSSL=1 WITH\_LIBUV=1 make examples
    builds examples utilizing WolfSSL and libuv
  • WITH\_OPENSSL=1 make examples
    builds examples utilizing OpenSSL and the native kernel

See µSockets for an up-to-date list of flags and a more detailed explanation.

:handshake: Permissively licensed

Intellectual property, all rights reserved.

Apache License 2.0 is a permissive license with few limitations. Make sure you properly understand the concept of licenses and how they relate to copyright & trademark laws. If you're uncertain about your permissions, please ask before assuming.

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.