Skip to main content
Config files use one assignment per line. Comments start with #. Whitespace around = is ignored.

Basic syntax

# Comments on their own line
key = value
name = "my-application"
port = 8080
enabled = true
log_level = Info

Supported types

Zig typeExample
booldebug = true
Integers (i8..u64)port = 8080, negative = -42
f32 / f64timeout = 30.5
[]const u8host = "127.0.0.1"
Enummode = Production (exact field name)
Fixed arrayrgb = [255, 128, 0]
Slicehosts = ["a", "b"] (heap allocated)
OptionalOmit key to keep default null

String escapes

Inside quoted strings: \", \\, \n, \r, \t.

Struct rules

  • All fields must have defaults.
  • Partial configs are valid: only changed keys need to appear on disk.
  • Field names must be ASCII identifiers.

Limitations

  • No inline comments (comment lines only).
  • No multiline strings (use \n).
  • Nested structs support one level of flattening (no deep paths).