What Is Bun? The All-in-One JavaScript Runtime Explained

A fast all-in-one JavaScript and TypeScript runtime, bundler, test runner, and package manager built on JavaScriptCore, not V8 — and now backed by Anthropic.

Bun's dumpling mascot logo beside the tagline 'The fast JavaScript runtime: runtime, package manager, bundler, test runner'
Image: Bun.

Bun is a single executable that replaces three or four separate tools in a typical JavaScript or TypeScript project: it is a runtime that runs your code, a package manager that installs your dependencies, a bundler that packages your app for production, and a test runner, all built around the JavaScriptCore engine rather than Google's V8. It aims to be a drop-in replacement for Node.js, meaning most existing Node.js code and npm packages should run on Bun without changes. The project was created by Jarred Sumner under a company called Oven, and in December 2025 Bun was acquired by Anthropic, the AI company behind Claude, which now funds its development.

Bun at a glance
  • What it is: an all-in-one JavaScript/TypeScript runtime, package manager, bundler and test runner
  • JavaScript engine: JavaScriptCore (the engine Safari/WebKit use), not V8
  • Written in: Rust, after a 2026 rewrite from the original Zig codebase
  • Created by: Jarred Sumner / Oven; now developed under Anthropic (acquired December 2025)
  • License: MIT (the bundled JavaScriptCore/WebKit components are LGPL-2)
  • Current release line: Bun 1.4.x, the first stable series built on the Rust core

What is Bun, exactly?

Bun describes itself as "an all-in-one toolkit for JavaScript and TypeScript apps," shipped as a single bun executable. Instead of installing Node.js plus separate packages for bundling (webpack, esbuild, Vite), testing (Jest, Vitest) and package management (npm, Yarn, pnpm), a Bun-based project can lean on one binary for all of it. Running bun run index.tsx executes TypeScript and JSX files directly, with no separate compile step; bun install installs dependencies from the standard npm registry; bun test runs a Jest-compatible test suite; and bun build bundles and minifies code for deployment.

Under the hood, Bun's runtime executes JavaScript using JavaScriptCore, the engine built by Apple for WebKit and Safari, instead of the V8 engine that powers both Node.js and Chrome. Bun's own project documentation says this choice, combined with the core being a native-compiled binary rather than a scripting-language layer on top of an engine, is what lets it start up faster and use less memory than tools built the conventional way.

Who makes Bun?

Bun was created by developer Jarred Sumner, who wrote the first line of what became Bun back in April 2021 as a line-for-line port of esbuild's JavaScript/TypeScript transpiler from Go into the Zig programming language. Sumner's company, Oven, grew the project from a transpiler into a full runtime, package manager, bundler and test runner, and the oven-sh/bun repository on GitHub became one of the most-starred JavaScript tooling projects there.

On December 2, 2025, Sumner announced on Bun's own blog that Bun had been acquired by Anthropic. The post explained that Bun had raised $26 million in seed and Series A funding but made no revenue, and that Anthropic's Claude Code ships to millions of users as a Bun executable — giving Anthropic a direct incentive to keep Bun fast and stable as the underlying infrastructure for its coding tools. The announcement stressed that Bun remains open-source and MIT-licensed, that the same team keeps building it in public on GitHub, and that its roadmap — fast JavaScript tooling and full Node.js compatibility — is unchanged. What's new is that Anthropic is hiring more engineers for the project and that Bun now gets an earlier look at upcoming developer-tooling needs inside Claude Code and the Claude Agent SDK.

How Bun is built: from Zig to Rust

For most of its life, Bun's core was written in Zig, a systems programming language that compiles to fast native code but requires manual memory management. In a detailed post on Bun's blog published July 8, 2026, Sumner explained that the team spent 11 days in May 2026 (May 3–14) porting the entire Zig codebase — 535,496 lines across 1,448 files — into Rust, merging it as Bun v1.4.0, the first stable release built on the new core. Bun v1.3.14 was the final release still running on Zig.

The stated motivation wasn't raw speed but memory safety: the post says many of Bun's historic bugs came from mixing manual memory management with JavaScriptCore's garbage collector, producing use-after-free errors, double frees and memory leaks that style guides and tooling like AddressSanitizer couldn't fully catch. Rust's ownership model turns those bug classes into compile-time errors. The rewrite kept Bun's architecture, feature set and JavaScriptCore engine unchanged — it was a deliberately literal, file-by-file port rather than a redesign — and the project reports concrete results: peak memory during 2,000 repeated builds in one process fell from about 6.7 GB to roughly 609 MB, Linux binary size dropped from 88 MB to 70 MB, and HTTP throughput improved by roughly 3–5% on the same hardware. The post also states that 128 known bugs from the Zig era were fixed in v1.4.0, with 19 regressions introduced by the port and since resolved.

Bun vs. Node.js vs. Deno

Bun isn't the only project trying to modernize server-side JavaScript. Deno, created by Node.js's original author Ryan Dahl, takes a different approach: it's also a single binary with built-in TypeScript and tooling, but it defaults to a security sandbox that blocks file, network and environment access unless a script is explicitly granted permission. Node.js itself remains the default and by far the most widely deployed runtime, with the broadest ecosystem of native-addon and tooling support. The table below summarizes how the three compare on points documented by each project.

FeatureBunNode.jsDeno
JavaScript engineJavaScriptCoreV8V8
Runtime written inRust (Zig before 2026)C++Rust
Built-in package managerYes — bun installNo (uses npm/Yarn/pnpm)Yes, plus npm-specifier support
Built-in bundlerYes — bun buildNoLimited (single-file executables via deno compile)
Built-in test runnerYes — bun test (Jest-style)Yes — node:test (since Node 18)Yes — deno test
TypeScript supportNative, no configRequires a transpiler/flagNative, no config
Default security modelOpen, like Node.jsOpen (full system access)Sandboxed; permissions granted explicitly
LicenseMITMITMIT

The built-in package manager — and why installs are fast

One of the features developers notice first is bun install. Bun's own homepage reports self-measured results (medians of three runs on a Linux x64 server) showing a warm-cache install of a Next.js app completing in 0.21 seconds versus 1.76 seconds for Yarn, 1.92 for pnpm and 4.45 for npm, and a first install with no cache at all completing in 1.41 seconds versus 13.49 for pnpm and 18.12 for npm — a gap the project describes as "up to 30x faster than npm." These are Bun's own published benchmark figures, not independently verified numbers, but the architecture behind them is documented: every package Bun downloads is stored once in a global cache (by default at ~/.bun/install/cache), keyed by package name and version. When a project needs that same package again, Bun links the cached files into node_modules using hardlinks on Linux and Windows, or copy-on-write clonefile operations on macOS, instead of copying the bytes a second time. That avoids re-downloading from the registry and avoids duplicating file contents on disk across projects, which is also why Bun's documented peak memory use during installs is far lower than tools that build an in-memory dependency graph before writing files out.

Bun's package manager is designed to be compatible with the existing npm ecosystem: it reads and writes standard package.json files, supports workspaces, overrides and lifecycle scripts, and can generate a Yarn-compatible lockfile when needed. For a broader look at how Bun's installer stacks up against npm, Yarn and pnpm specifically, Pandromeda's pnpm vs. npm vs. Yarn vs. Bun comparison covers install-speed and compatibility differences between all four package managers in more depth.

The built-in bundler, test runner and type checker

Bun's bundler (invoked as bun build or via the Bun.build() API) bundles JavaScript, TypeScript, JSX, CSS and HTML without needing a separate tool like webpack or Vite, and it bundles by default rather than requiring a flag the way esbuild does. Bun's documentation comparing it to esbuild states that its bundler is 1.75 times faster than esbuild on esbuild's own three.js benchmark (bundling ten copies of the three.js library from scratch, with sourcemaps and minification). The bundler also ships a development server with hot module reloading, and bun build --compile can package an app into a single standalone executable.

The test runner, bun test, implements a Jest-compatible expect() API along with mocks and snapshot testing, so many existing Jest test suites run with little or no modification. Bun v1.4.3 also introduced bun check, a built-in TypeScript type checker that the project says matches the error output of "tsc 7" (the next major TypeScript compiler release) while running several times faster and using less memory on large codebases, according to Bun's own release notes. Because TypeScript and JSX are supported natively across all of these tools, Bun avoids the separate tsc/ts-node compile step that a plain Node.js project typically needs — a convenience Pandromeda's explainer on TypeScript covers from the language side.

Node.js API compatibility

Because Bun positions itself as a drop-in replacement for Node.js, compatibility with existing Node.js code and npm packages is central to the project. Bun's own compatibility page, benchmarked against Node.js v26, rates each core module as fully implemented, partial, or not implemented, and runs thousands of tests from Node.js's own test suite before each release. Widely used modules such as fs, http, net, path, stream, events and buffer are listed as fully implemented, with reported Node test-suite pass rates such as 98% for fs and 95% for events. Modules Bun lists as only partially implemented include crypto (built on BoringSSL rather than Node's OpenSSL build, so a handful of key types and ciphers are missing), tls, worker_threads and cluster. Bun's documentation states its policy plainly: "if a package works in Node.js but doesn't work in Bun, we consider it a bug in Bun," and it specifically cites Next.js and Express as frameworks that run on Bun unmodified. Pandromeda's coverage of Node.js 26 becoming Active LTS has more on the Node release that Bun is now tracking for compatibility testing.

Where developers actually use Bun

Bun's own guides point to several concrete use cases beyond "replacing Node.js" in the abstract. For continuous integration, the project maintains an official GitHub Action, oven-sh/setup-bun, that installs a pinned Bun version on a CI runner in a single step; teams use it to run bun install, execute test suites with bun test, and run the new bun check type-checker, which annotates type errors directly on a pull request's diff in GitHub. Because installs and test runs are a large share of CI wall-clock time, swapping a Node.js-plus-npm CI step for Bun's built-in equivalents is one of the more common adoption paths, even in codebases that still deploy on Node.js in production.

For deployment, Bun publishes first-party guides for running production apps on Vercel, Railway, Render, AWS Lambda, Google Cloud Run and DigitalOcean, alongside guides for containerizing a Bun app with Docker and running it as a long-lived process with systemd or PM2. Bun also ships built-in clients for Postgres, MySQL, SQLite, Redis and S3-compatible storage, plus a native HTTP/WebSocket server (Bun.serve()), which lets small services and APIs run without pulling in separate database-driver or web-framework packages. Framework-level guides cover pairing Bun with Next.js, Astro, Remix, SvelteKit, Qwik, Nuxt, Vite and several lightweight server frameworks such as Hono and Elysia, reflecting that most real-world Bun usage sits inside an existing framework rather than against the bare runtime.

Current version and stability

As of its most recent stable release, Bun is on the 1.4.x line — version 1.4.3 at the time of writing — which is also the first stable series running on the Rust-based core rather than the original Zig implementation. Canary builds are published automatically on every commit to Bun's main branch and can be installed with bun upgrade --canary for developers who want the newest changes before they reach a tagged release. The project describes itself as under active, full-time development by the same team that built it before the Anthropic acquisition, with the stated roadmap continuing to focus on closing remaining Node.js compatibility gaps and improving performance. Because Bun 1.4 was a from-scratch rewrite of the entire Zig codebase into Rust, the project's own blog post is candid that a handful of regressions appeared during the transition — it reports 19, all fixed before general release — which is worth knowing if a team is deciding whether to upgrade a production workload immediately or wait for a later patch release.

What's next for Bun

Bun's public roadmap, repeated across its release notes and the Anthropic acquisition announcement, centers on two goals: closing the remaining gaps in Node.js API compatibility (the project tracks this against each new Node.js release, currently Node 26) and continuing to improve startup time, memory use and raw execution speed now that the runtime's core is written in Rust. The bun check type checker introduced in v1.4.3 suggests Bun is also expanding beyond "replace Node.js" into replacing more of the TypeScript tooling chain directly. With Anthropic now funding full-time development and using Bun as the executable format for Claude Code and the Claude Agent SDK, the project has more committed engineering resources than at any point in its history — though, as with any young runtime, teams adopting it in production should watch each release's changelog for compatibility notes, particularly around native Node.js addons, TLS/crypto edge cases, and worker threads, where Bun's own documentation still lists only partial support.

Frequently asked questions

What is Bun used for?

Bun is used to run, bundle, test, and manage dependencies for JavaScript and TypeScript projects. Developers use it as a faster, all-in-one alternative to running Node.js alongside npm, a separate bundler like webpack or esbuild, and a test runner like Jest.

Is Bun a replacement for Node.js?

Bun aims to be a drop-in replacement: it implements most of Node.js's core APIs and runs most existing npm packages unmodified. Some modules, such as parts of crypto, tls, and worker_threads, are only partially implemented, according to Bun's own compatibility documentation.

What is Bun written in?

Bun was originally written in Zig. Starting with version 1.4.0 in 2026, its core runtime was rewritten in Rust, a change the project says was made primarily for memory safety rather than speed.

Does Bun use the same JavaScript engine as Node.js?

No. Bun runs JavaScript on JavaScriptCore, the engine built for Safari and WebKit, while Node.js and Deno both run on Google's V8 engine.

Who owns Bun now?

Bun was created by developer Jarred Sumner and his company Oven. In December 2025, Bun was acquired by Anthropic, which now funds its development while the project remains open-source under the MIT license, built by the same team.

Is Bun stable enough for production use?

Bun has been under active development since 2021 and is now on its 1.4.x release line. Its own documentation tracks Node.js compatibility and known limitations module by module, so teams evaluating it for production should review that compatibility page against their specific dependencies first.

Sources

More on Bun →BunJavaScript runtimeNode.jsTypeScriptpackage manager
Felix Moreau
Written byFelix Moreau

Felix Moreau writes Pandromeda's software coverage and how-to guides. He covers Windows, macOS and Linux updates, the apps people rely on, emulators and developer tools, and turns official documentation into clear, numbered steps that work on the current version.

More from Software & Guides

See all