TGViewer
C++ - Reddit C++ - Reddit @r_cpp · 229 subscribers
Post #24654 23
I wrote a tiny header-only WebSocket library in C++20 because I apparently hate myself

Hey folks 👋

I’m fully aware the world does not need another C++ WebSocket library.. but after fighting with existing ones for way too long, I ended up writing my own instead of touching grass.

It’s called wspp, and it’s a header-only, C++20 WebSocket client/server library. No Boost, no ASIO dependency soup, no macro gymnastics. Just modern C++ and a reactor-style async loop.

I’m not claiming it’s revolutionary or better than your favorite library. It’s mostly the result of:

“this should be simpler”
“why does this need 5 dependencies?”
“surely RFC 6455 isn’t that bad” (it was)

Some highlights (if you’re still reading):

Header-only (drop it in and move on)
WS and WSS (OpenSSL optional)
Async / non-blocking
Windows + Linux
Passes Autobahn tests (this surprised me the most)
Designed around C++20 instead of pretending it’s 2008

I’ve been using it for my own projects and figured I’d share it before it rots on my SSD forever. If nothing else, maybe it’s useful as:

a lightweight alternative
a reference implementation
or something to yell at in the comments 😄

Repo + examples + docs are here:
https://github.com/pinwhell/wspp

Feedback, nitpicks, “why didn’t you just use X”, or “this is terrible and here’s why” are all genuinely welcome. I’m still learning, and I’d rather hear it now than after someone builds something important on top of it.

Thanks for reading ❤️

https://redd.it/1q8thtd
@r_cpp
GitHub GitHub - pinwhell/wspp: Modern, Async, Non-Blocking, zero-dependency C++20 RFC 6455 Compliant WebSocket client & server, cross… Modern, Async, Non-Blocking, zero-dependency C++20 RFC 6455 Compliant WebSocket client & server, cross-platform, single-header, WS/WSS support. - pinwhell/wspp
More from @r_cpp
  1. Oct 8, 2026Profiles for simplicity and guarantees - Bjarne Stroustrup - CppCon 2026 https://youtu.be/…
  2. Oct 8, 2026How to Fix autoconf-style Configuration Probing https://build2.org/blog/fix-autoconf.xhtml…
  3. Oct 8, 2026owl – a header-only C++23 HTTP framework where route patterns and handler extractors are c…
  4. Oct 8, 2026Removed by Reddit Removed by Reddit on account of violating the [content policy. ] https:/…
  5. Oct 8, 2026Is there a way to search across all P and N papers throughout standardization history? It…
  6. Oct 8, 2026CppCast Episode 412 : Safety and Interoperability with Rust and C++ https://cppcast.com/sa…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →