Description
Matchbox is an open source Rust project for peer-to-peer WebRTC networking in WebAssembly and native applications, aimed mainly at low-latency multiplayer games. It provides UDP-like, unordered and unreliable connections between peers, and also reliable data channels with configurable ordering and retransmits. It is made of several crates: matchbox_socket, a socket abstraction for Wasm or native with an optional GGRS-compatible socket; matchbox_signaling, a library for building signaling servers; matchbox_server, a ready-to-use full-mesh signaling server; and bevy_matchbox, which integrates the socket with the Bevy game engine. A signaling server is only needed to set up connections: peers join through it, negotiate with offers and answers, and then send data directly to each other without passing through the server. A Bevy and GGRS tutorial is included.…
Highlights
- Peer-to-peer WebRTC for Rust Wasm and native
- Unreliable or reliable data channels
- GGRS-compatible socket for rollback netcode
- Ready-made full-mesh signaling server
- Bevy integration via bevy_matchbox
Ratings & Reviews
No ratings yet
Be the first to rate Matchbox.
People also visit
Netflux
JavaScript client and server side transport API based on WebRTC & WebSocket
Matchbox FAQ
What is Matchbox?
A Rust library set for peer-to-peer WebRTC networking in browsers (Wasm) and native apps, designed for low-latency multiplayer games.
Does traffic go through a server?
Only connection setup goes through the signaling server. After that, data flows directly between peers.
Does it work with Bevy?
Yes. bevy_matchbox integrates it with Bevy, and the README lists which version matches each Bevy release.
Can I use it with GGRS?
Yes, matchbox_socket has a ggrs feature, and there is a tutorial for Bevy and GGRS.
Do I have to write my own signaling server?
No. matchbox_server is ready to use, and matchbox_signaling helps if you want a custom one.
What are the best Matchbox alternatives?
Popular alternatives to Matchbox include P2pt, Peerjs and Rust Libp2p. See all Matchbox alternatives

