Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
L

LiteNetLib

> 数据库
Open source

Lite reliable UDP library for Mono and .NET

3.6K stars0 likes0 views
WebsiteGitHub

About

Lite reliable UDP library for Mono and .NET

LiteNetLib 2

Lite reliable UDP library for .NET Standard 2.1 (Mono, .NET) HighLevel API Part: LiteEntitySystem

Matrix chat: Matrix

Discord chat:

OLD BRANCH (and examples) for 1.x

Little Game Example on Unity

Documentation

Build

NuGet

Release builds

DLL build from master

( Warning! Master branch can be unstable! )

Features

  • Lightweight
    • Small CPU and RAM usage
    • Small packet size overhead ( 1 byte for unreliable, 4 bytes for reliable packets )
  • Simple connection handling
  • Peer to peer connections
  • Helper classes for sending and reading messages
  • Multiple data channels
  • Different send mechanics
    • Reliable with order
    • Reliable without order
    • Reliable sequenced (reliable only last packet)
    • Ordered but unreliable with duplication prevention
    • Simple UDP packets without order and reliability
  • Fast packet serializer (Usage manual)
  • Automatic small packets merging
  • Automatic fragmentation of reliable packets
  • Automatic MTU detection
  • Optional CRC32C checksums
  • UDP NAT hole punching
  • NTP time requests
  • Packet loss and latency simulation
  • IPv6 support (using separate socket for performance)
  • Connection statistics
  • Multicasting (for discovering hosts in local network)
  • Unity support
  • Support for .NET8 optimized socket calls (much less gc)
  • Supported platforms:
    • Windows/Mac/Linux (.NET Framework, Mono, .NET Core, .NET Standard)
    • Lumin OS (Magic Leap)
    • MonoGame
    • Godot
    • Unity 2021.2 (Desktop platforms, Android, iOS, Switch)

Support developer

  • USDT TRC20: TE5eBgq8SyEeZFKtCgZG9GwL34sANmbc67

  • USDT BEP20/ERC20: 0x4c0D6DC76c6A6B354f5ec6c9e51893fFC6510d1E

  • Bitcoin: bc1q269ecs8r5vnrum5qr5j98sdglhnxlulv0f6egd

Unity notes!!!

  • Minimal supported Unity is 2021.2. For older Unity versions use 1.x library versions
  • Always use library sources or OpenUPM package instead of precompiled DLL files ( because there are platform specific #ifdefs and workarounds for unity bugs )

Usage samples

Client

csharp
var listener = new EventBasedNetListener();
var client = new NetManager(listener);
client.Start();
client.Connect("localhost" /* host IP or name */, 9050 /* port */, "SomeConnectionKey" /* text key or NetDataWriter */);
listener.NetworkReceiveEvent += (fromPeer, dataReader, channel, deliveryMethod) =>
{
    Console.WriteLine("We got: {0}", dataReader.GetString(100 /* max length of string */));
    dataReader.Recycle();
};

while (!Console.KeyAvailable)
{
    client.PollEvents();
    Thread.Sleep(15);
}

client.Stop();

Server

…

Issues· 7 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C#cross-platformcsharpdot-netmono

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category数据库
PricingOpen source

> Related tools

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库