Software & AI

Claude Code Now Runs on Bun — The Rust Runtime Behind Anthropic's AI Agent

Anthropic's Claude Code agent has moved onto the Bun JavaScript runtime, while Bun itself is in the middle of being rewritten in Rust with AI assistance. The result is a striking loop: Claude is being used to improve the very tool that helps run Claude.

To understand why this story resonated with programmers, it helps to separate three layers. The top layer is Claude Code, Anthropic's agent that can edit code, run tests, and navigate codebases for a developer. Underneath it sits Bun, a JavaScript runtime designed to be a fast, batteries-included replacement for Node.js. And underneath Bun, engineers have been replacing the original Zig implementation with Rust.

Rust is a systems programming language prized for its performance and memory safety. Rewriting a runtime in Rust means the underlying engine — the part that translates JavaScript code into real computation — can run faster and with fewer crashes, especially under the demanding workloads that an AI coding agent generates. Bun's original Zig author, Jarred Sumner, made the Rust port, and once the rewrite was merged it became the new foundation.

The timing is what makes the headline so vivid. By the time Claude Code adopted the Rust port, the agent itself had already participated in writing the rewrite. Engineers used Claude to produce large portions of the new code and to build the test suite that validated it. In other words, a single tooling change became a demonstration of a broader trend: large language models are increasingly the accelerators behind the software they will soon be running on.

This has a quiet implication for how developers think about infrastructure. Runtimes, toolchains, and agents that were once improved only by dedicated specialist teams are now being rebuilt in weeks rather than years. For a programming community used to gradual, human-paced evolution, that speed is both an opportunity and a responsibility — the software stack can change while you are still learning how to use it.