⚡ Zig Guide LiveUnofficialbut fully verified
✓ Zig 0.18.0-dev.349+d924f83bfWhat's newOn an older Zig?Blograylib-zig

Zig Guide Live

A tutorial for the Zig programming language. Each build compiles and runs every snippet against current Zig master. If an example on this site were out of date, the build would fail.

The snippets run in your browser as WebAssembly. Your browser runs the same artifact that CI verified. There is no server, and you install nothing.

Zig changes fast. If people only proofread documentation, it becomes out of date, and nobody sees the problem. Every night, CI verifies this guide again against a new compiler. The site publishes again only when every snippet still passes. For the exact mechanism, read how this guide is verified. That page also tells you what occurs to the snippets that a browser cannot run. If you use a tagged release, read what changed.

Read the guide → or select a reading path.

What is in it

The guide has 272 chapters in seven tracks, in one reading order. The arrows at the bottom of every page follow that order. Thus you can read the guide from the start to the end.

Every section, in order →

Riddle breaks

Short videos from the author of this guide. Most are riddles: each riddle asks the question first and shows the answer at the end. Some are jokes. The videos play here, on this page.

More from Riddle Masti on YouTube →

What your browser needs

To run a snippet, your browser needs WebAssembly and JavaScript, and nothing else. The scripts here are built for Chrome and Edge 111, Firefox 114, and Safari 16.4 (iOS and iPadOS 16.4) or newer. On an older browser, or with JavaScript off, you can still read every chapter. Every snippet is on the page, highlighted and complete. Only the Run button is missing.

Who writes it

Rajesh Pillai writes this guide, with AI assistance. It is an unofficial community guide, and is not affiliated with the Zig Software Foundation. The documentation of the foundation is at ziglang.org. Read more about what this guide is and what it is not, and how to report an error in a chapter.