MO

Moonlight

Open-source game streaming client for low-latency desktops

Remote Access & VPN ★ 18.7k stars Easy setup GPL-3.0

Moonlight is an open-source client implementation of NVIDIA's GameStream protocol that streams games and full desktops from a host PC. Paired with Sunshine, it enables a fully self-hosted remote desktop and gaming setup.

Key features

  • Low-latency desktop streaming
  • Works with Sunshine host
  • Hardware-accelerated decoding
  • Many client platforms

Pros & cons

Strengths

  • Very low latency
  • Wide client platform support
  • HDR and 4K streaming

Trade-offs

  • Requires separate host software
  • Best on strong networks

Moonlight replaces

Last reviewed Aug 26, 2026 · 727 words

Moonlight is only half of the setup, and installing it on your phone does nothing until a host is running. The host is Sunshine, the open-source server that speaks NVIDIA's GameStream protocol from any GPU (NVIDIA, AMD, Intel, and software encoding at a pinch); Moonlight is the client that decodes the stream on Windows, macOS, Linux, Android, iOS, Apple TV, Steam Deck, Raspberry Pi, ChromeOS, Xbox and a homebrew Switch. Together they do 1080p at 60 fps on a home LAN with end-to-end latency in the low tens of milliseconds, 4K HDR if host and client can encode and decode it, and none of it touches a relay server. Parsec's convenience without Parsec's account.

Install the host first: Sunshine in 10 minutes

Sunshine installs as a normal application on Windows, macOS or Linux and exposes its configuration UI at https://localhost:47990. Set a username and password on first visit; that page controls the encoder, resolution and frame rate, the list of applications (a Desktop entry streams the whole screen; a Steam Big Picture entry launches straight into it), and pairing. On Windows the GPU encoder is picked automatically. On Linux you want a real graphical session with hardware encoding available, and on a headless machine you need something to capture: a cheap HDMI dummy plug or a virtual display driver, because a GPU with no monitor attached renders nothing.

Pairing, and the 7 ports Sunshine listens on

On the client, Moonlight scans the LAN with mDNS and shows the host; select it and Moonlight displays a 4-digit PIN to enter in Sunshine's web UI. That pairing creates a client certificate, so it survives reboots and IP changes. The ports the host needs reachable from the client are TCP 47984, 47989 and 48010, plus UDP 47998, 47999, 48000 and 48010. The Windows installer creates the firewall rules; on Linux you add them yourself.

Latency is a network problem, not a software one

Moonlight's default is 1080p60 at 20 Mbps; on Ethernet or Wi-Fi 6 in the same room that gives a stream hard to distinguish from local, with total latency dominated by the encoder and decoder (a few milliseconds each) and the display itself. Over 2.4 GHz Wi-Fi it stutters; through a wall and a floor on 5 GHz it is playable but you will feel it in a shooter. The stats overlay (Ctrl+Alt+Shift+S on desktop clients) shows decode time, network jitter and dropped frames, and any sustained jitter above about 5 ms is your access point, not Moonlight. Codec choice matters more on the client than the host: HEVC needs less bandwidth than H.264 for the same quality and AV1 less again, but only if the client has a hardware decoder for it; an older phone falls back to software decoding and drops frames at anything above 1080p.

Over the internet: Tailscale, not port forwarding

Sunshine's ports on your public IP are a bad idea; the web UI alone is a login page you do not want scanned. The pattern that works is Tailscale (or self-hosted Headscale) on both host and client: Moonlight then connects to the host's tailnet address as if on the LAN, and direct WireGuard paths keep latency close to your ISP's round trip. Expect 40 to 80 ms total from a hotel on a decent connection, which is fine for anything except competitive shooters and rhythm games. The broader view of ways in is in remote access, three ways. If you want a remote desktop for work rather than play, RustDesk is the more appropriate tool: multiple monitors, clipboard and file transfer, no GPU encoder assumed. Moonlight's job is frames, fast.

What I'd do

Sunshine on the gaming PC with a dummy plug if it runs headless, Moonlight on the TV box and the Steam Deck, Ethernet to the TV, and the default 20 Mbps raised to 40 once the LAN proves clean. Tailscale on host and clients for travel, and the Sunshine ports never forwarded. Enable wake-on-LAN on the host and you have a console that lives in the office and follows you around the house, which is the use case this pair is best at.

Compare Moonlight

4 head-to-head comparisons.

Similar remote access & vpn apps