# SNET – a networking interface for Lua over UDP

> SNET (Networking Interface): a Lua networking module on LuaSocket over UDP with delivery acks, packet priorities and no client limit. LuaJIT and MoonLoader; born from SL:MP.

- URL: https://pakulichev.com/en/projects/snet
- Author: Pakulichev (https://pakulichev.com/)
- Language: en
- Updated: 2026-10-15
- Whole site for LLMs: https://pakulichev.com/llms.txt (index), https://pakulichev.com/llms-full.txt (full text)

## Facts

- **Type:** Networking library
- **Language:** Lua (LuaJIT)
- **Transport:** UDP, LuaSocket
- **Platforms:** Windows, Linux, MoonLoader
- **Published:** September 24, 2020
- **Origin:** SL:MP networking code

**SNET** is a Lua networking module that runs over **UDP** via LuaSocket. I published a guide to it on BLAST.HK on **September 24, 2020**. The library grew out of the networking code of the **[SL:MP](https://pakulichev.com/en/projects/sl-mp)** multiplayer.


![SNET logo](https://pakulichev.com/img/snet/snet-logo.png "SNET logo from the BLAST.HK guide")

## What it adds to UDP

UDP is fast but guarantees nothing: packets get lost or arrive out of order. A game needs low latency, but it can't afford to lose key events either. So SNET has **delivery acknowledgement** for important packets and **priorities**: some data can go "best effort", other data has to arrive. The library itself puts no limit on the number of clients.

## Where it runs

- **LuaJIT** on Windows and Linux, for servers;
- **MoonLoader**, for client scripts in GTA: San Andreas.

The protocol is the same on the client and the server, so you can write a network mod entirely in Lua, whether it's a chat, player sync or a multiplayer of your own.

## Ports

The community made a **Node.js** port (node-snet), and there was also an experimental **Go** port.

## FAQ

### How is SNET related to SL:MP?

SNET grew out of the networking part of the SL:MP multiplayer – in the project description, SL:MP is explicitly named as the predecessor of SNET.

### Are there ports of SNET to other languages?

Yes, the community made a Node.js port (node-snet), and there was also an experimental Go port.
