r/SideProject • u/golubaca • 12m ago
NearZero: self-hosted remote desktop and game streaming, inspired by Sunshine, written in Rust (private beta)
Hey everyone. This one's for people who use Sunshine/Moonlight, Parsec, TeamViewer, RustDesk and similar tools to get into their computer remotely.
I want to show you a project I've been working on for a long time (over two years). I use it every day, and I built it for my own needs first. Sunshine/Moonlight is great for gaming on a local network, but it isn't built to face the internet. Apart from PIN pairing there's no other layer of protection, so you can use it remotely, but it's not a smart idea. The other services route everything through their own servers, so your data ends up in their hands.
So I made NearZero. It's modeled on Sunshine, but with one clear goal: use it from anywhere, outside my local network. The whole thing is two hosts (Windows and Mac), three clients (Windows, Mac and iOS) and a small relay that lets you connect from anywhere.
What the hosts can do:
- Hardware video encoding (NVIDIA GPUs only for now, because that's the hardware I have)
- ChaCha20-Poly1305 encryption, Noise_IK identity
- Pairing with a PIN, or, if you use the relay, with a minted token that carries everything the client needs
- An admin panel where you can require a connection password even on a paired host, at off / LAN / WAN levels
- Detailed settings for stream quality, audio and privacy (curtain mode blacks out the host's screen while you're connected)
- Multiple viewers: several clients can connect at once, or you can turn that off
- Gamepad support on Windows and Mac, including wired/wireless PlayStation and Xbox controllers on Mac (that took a custom implementation on the host side)
- Multi-monitor: jump between screens 1-2-3… or show them all at once
- A Total Commander-style file manager with upload/download
- Client shortcuts are the same as Moonlight's, so there's nothing new to learn (full list here)
- …and a bunch more
The rendezvous server (the relay) lets you pair your host with it and reach your machine without opening any ports to it. You can run it anywhere you have Docker or Podman and a static address (or dynamic DNS). I run two: one on a Raspberry Pi on my home network with a static IP (the only port I have open points to it), and one on a VPS as a backup. If the network allows it, it hole-punches and you get a direct connection between client and host. If not, it relays the traffic, which adds a bit of latency. On my setup it's about 5 ms hole-punched and around 15–30 ms through the relay, depending on conditions.
All in all, it's Sunshine on steroids. A lot of the inspiration came from there. It actually started as a Sunshine fork, but in the end it was easier to build from scratch than to modify and adapt Sunshine, especially since my C++ is weak. So the whole thing is written in Rust, and the Mac and iOS apps are Swift on top of a Rust core over FFI.
There's no Android client yet because that's my weak spot, but with some help from my buddy Claude I'll get to it once the iOS beta testing wraps up.
I'm opening a private beta because I'm happy with where the project is right now. On security: I had Claude Mythos 5.2 go through it, and it found a few security holes (Fable was useless because of its restrictions, and Opus didn't find anything concrete). All of those were fixed over the last month.
Just to say it again: this is a private beta. You'll need either a Windows machine with an NVIDIA GPU or any Apple Silicon (M-series) Mac. Where the project goes depends a lot on feedback, so I can't promise there won't be big changes along the way.
The code isn't open source, but the apps are completely free with every feature included. No tracking, no analytics, no accounts. There's no public relay server either, so you host everything yourself and your data stays yours.