-- Rustia

Luau, embedded in Rust.

Rustia runs Luau scripts in Rust applications. Edit the Luau below to change what the garden draws.

Rustia features

Hot reload
Try script edits while your Rust app keeps running. If a module fails to install, the app can keep using the previous version.
Deterministic execution
Replay recorded inputs or reproduce a bug in the browser. In deterministic mode, the same script, seed, and inputs give the same results on native and WebAssembly.
Pure Rust runtime
Embed the same Luau interpreter on desktop and in the browser. Building the runtime requires no C++ toolchain.
Rust functions and objects
Expose the functions and objects your scripts need. Use Serde to read Luau tables into Rust structs.
Script execution limits
Set a budget for instructions and VM memory so a runaway script returns an error to your app.
Experimental LLVM compilation
We’re exploring compiling Luau to native code ahead of time to reduce the cost of running scripts.

How Rustia compares

Compare Luau runtimes by platform and workflow, and see how Rustia performed alongside other scripting options for Rust.

Luau runtimes

Capability snapshot checked 20 November 2026. Under Replay, Tested means native and browser results matched. Controls means the host can fix the seed and clock. A dash means the linked sources did not establish support.

ProjectEngineDesktopBrowser WasmHot reloadReplay
RustiaRustLinux macOS Windows 1DemoRollback✓ Tested
luaurRustLinux macOS Windows 2PlaygroundRun code—
uluaRustLinux macOS Windows 3PlaygroundRun code—
ruauRustLinux 4—Reload module◐ Controls
luau-rs/luauRustLinux 5CI testsRun code—
mluaUpstream Luau (C++)Linux macOS Windows 6BuildReplace module—
LuneUpstream Luau (C++)Linux macOS Windows 7—Load script—

Luau comparison sources and notes

Runtime speed

Microseconds per work unit (lower is better). Best observed steady-state interpreter times on Linux x86-64 on 2026-10-22 UTC. The measurements cover scripts already running. Each engine uses its own version of the workload.

Work unitRustiamlua + LuauKotoRhai
Build, sum, and sort a 256-item array51.65718.919262.217313.191
Fill and read 128 hash entries87.55522.485146.082348.085
One closure call updating a captured value0.1970.0510.3461.478
Custom, keyed, and array iteration pass14.0354.1707.3919.566
Math library calls and buffered appends1.4210.2371.5363.174

Benchmark methodology and results for more engines