138k req/sec · 0.66ms p50 · 5MB RSS on Apple silicon
When to use Fairyfly
- Cold start matters (CLI tools, edge functions, short-lived jobs)
- Memory is capped (strict container limits)
- You want the whole runtime to fit in your head (~32k lines of Zig across 73 files)
When NOT to use Fairyfly
- Browser parity — no DOM, no
windowobject - Full npm ecosystem — only pure-JS ESM packages work (
ff imprint; no CommonJS, nonode:builtins)
What’s inside
Everything ships in a single binary. Nonpm install needed for core features.
Three rules
Rule 1: ESM only, extensions optional
Imports are ESM (there is norequire). A relative specifier may omit
the .js extension — the loader then probes X.js, then X/index.js:
.js extensions (.mjs, …) are not probed — write those out.
Bare specifiers like import "lodash" resolve by walking up node_modules/ directories, but only pure-JS ESM packages work.
Rule 2: No CommonJS, no require()
There is norequire() function. No module.exports. No __dirname or __filename globals.
Use import/export and import.meta.url instead.
Rule 3: No process.nextTick
UsequeueMicrotask() instead. It runs before the next timer or I/O event, just like process.nextTick in Node.js.