Home / Companies / Vercel / Blog / Post Details
Content Deep Dive

Bun runtime on Vercel Functions

Blog post from Vercel

Post Details
Company
Date Published
Author
-
Word Count
1,101
Language
English
Hacker News Points
-
Summary

Vercel has introduced Bun as a new runtime option for Vercel Functions, available in Public Beta alongside the existing Node.js option, allowing developers to select the best runtime based on their workload needs. Bun is particularly advantageous for compute-intensive applications, demonstrating a 28% reduction in latency for CPU-bound Next.js rendering workloads compared to Node.js, thanks to its efficient runtime architecture built in Zig. The Bun runtime currently supports frameworks such as Next.js, Express, Hono, and Nitro, with more to be added, and integrates with Vercel's observability and monitoring tools. While Bun offers significant performance improvements, especially in streaming and CPU-intensive tasks, Node.js remains the most compatible and widely supported option. Developers can switch between Bun and Node.js via a simple configuration change in the vercel.json file, with Bun suited for performance-critical applications and Node.js for broad compatibility. Recent benchmarks highlighted Bun's potential to enhance server-side rendering performance, and ongoing developments are expected to further optimize its capabilities.