nullClaw on Zig outperformed OpenClaw in memory and startup in local AI agent tests
NullClaw — a single-binary agent runtime on Zig — showed notably lower memory usage and faster startup in a local comparison with OpenClaw. In the --help…
AI-processed from Habr AI; edited by Hamidun News
NullClaw — an agent runtime on Zig as a single binary — shows that a local AI agent doesn't have to carry a heavy stack with it. In comparative tests with OpenClaw, the project started faster and consumed an order of magnitude less memory, especially in parallel tasks.
Why Zig Here
The main idea of the article is not to declare NullClaw the absolute winner among all agent platforms. The author compares it with OpenClaw only in short local scenarios: service commands, a single agent-run, a small coding task, and a batch of parallel runs. Against this background, it becomes clear how expensive a typical AI agent is as a process today.
Most such systems have Node.js, Python, dependencies, background services, and a gateway layer under the hood. NullClaw offers a different approach: a maximally compact runtime without unnecessary overhead.
Hence the choice of Zig. The language is needed here not for fashion's sake, but for engineering straightforwardness: a single binary, explicit memory control, the absence of a heavy managed runtime, and more understandable builds. In build.
zig the author separately notes compile-time switches for channels and memory engines, meaning the build can be tailored to a specific scenario. This is important not only for startup speed, but also for self-hosted and edge deployments, where every extra megabyte and every dependency quickly become a practical problem.
Numbers Without Noise
Measurements were taken on a Mac mini M4 with 16 GB RAM and macOS arm64. Both projects used the same model via OpenRouter, and metrics were calculated across series of runs: separately for "fresh" processes, separately for warm scenarios, separately for coding-runs and parallel tasks. The author deliberately separates pure runtime overhead from network latency to the model, because in the latter case even a very lightweight runtime hits the external round-trip.
- --help command: NullClaw — 0.002 s and about 1.9 MB RSS, OpenClaw — 0.621 s and about 308 MB
- short agent-run: 2.55 s and approximately 7.7 MB vs 3.37 s and approximately 567 MB
- small coding-run: 4.86 s and approximately 7.7 MB vs 6.64 s and approximately 572 MB
- 10 parallel coding tasks: 9.3 s and about 54 MB total RSS vs 13.14 s and about 523 MB
The strongest difference is visible precisely in memory. In terms of speed, NullClaw is often faster, but not always dramatically, because some scenarios are limited by the model's response over the network. At the same time, in short and parallel runs, OpenClaw consistently remains at the level of hundreds of megabytes, while NullClaw — at the level of single or tens of megabytes. For local use, this means cheaper multi-agent runs, more predictable load, and less friction when moving between machines.
Practical Meaning of the Comparison
The article also provides a more telling example than dry tables: the ClawWatch project for smartwatches. It uses NullClaw as a static ARM binary together with offline speech recognition Vosk and built-in TTS, and can handle some requests without calling the model. Here, compactness stops being just a pleasant optimization. For a device with a hard memory limit, the difference between a few megabytes and hundreds of megabytes determines whether it's possible to embed the agent in the product at all, rather than just run it on a developer's laptop.
"On a smartwatch, the difference between 'a few megabytes' and
'hundreds of megabytes' is the question of 'does this fit at all'."
The author separately notes that there's no magic with binary size here either. In the README for ReleaseSmall, 678 KB is claimed, but the published release artifacts are noticeably larger: about 3.9 MB for macOS arm64 and 3.1 MB for Linux arm64, with a local build yielding approximately 2.6 MB. But the main conclusion doesn't change: the value of NullClaw lies not in the headline number from the README, but in the combination of fast startup, low RSS, and a narrow functional surface that is easier to control both from an operational and security perspective.
What This Means
NullClaw brings the conversation about AI agents back to a grounded question: how much should one process run cost? If agent infrastructure moves toward edge, self-hosted, and mass-parallel tasks, the runtimes that save memory, start without pause, and don't drag along half a server's worth of dependencies will win out.
Want to stop reading about AI and start using it?
AI News is a curated feed of AI/tech news. Hamidun Academy teaches you to use AI systematically in your work.