Back to the chart

natecraddock/ziglua

Zig bindings for the Lua C API

Chart
Not on a chart right now
Stars
545

Open on GitHub

What it is

Ziglua provides Zig bindings for the Lua C API, supporting Lua 5.1 through 5.5, LuaJIT, and Luau. It compiles Lua from source and links it against Zig code without requiring system Lua libraries.

Who it is for

Zig developers who want to embed a Lua VM in their applications or build shared Lua modules.

Why it is trending

It recently released v0.7.0 with Zig 0.16.0 support and has 543 stars. It mirrors the Lua C API closely while improving ergonomics through Zig error unions, type-checked enums, and comptime helpers.

Main features

  • Supports both static embedding and shared Lua module creation
  • Wraps C types with Zig error unions and null-terminated slices
  • Provides comptime convenience functions such as toAny and pushAny
  • Integrates via build.zig.zon with optional system Lua linking

Summarized on November 17, 2026 from the README and repository data. It can be wrong; check the source before relying on it. Report a wrong summary