How we rebuilt Next.js with AI in one week

This title could be clearer and more informative.Try out Clickbait Shieldfor free (5 uses left this month).

Cloudflare engineers rebuilt Next.js from scratch on top of Vite in under a week using AI (Claude via OpenCode), producing an open-source drop-in replacement called vinext. It builds production apps up to 4.4x faster with Vite 8/Rolldown and produces client bundles 57% smaller than Next.js 16. vinext deploys directly to Cloudflare Workers with a single command, supports both App Router and Pages Router, includes ISR via KV, and covers 94% of the Next.js 16 API surface backed by 1,700+ Vitest tests and 380 Playwright E2E tests. A novel 'Traffic-aware Pre-Rendering' (TPR) feature uses Cloudflare zone analytics to pre-render only the pages that actually receive traffic, avoiding the linear build-time scaling problem of large Next.js sites. The project cost roughly $1,100 in Claude API tokens and raises broader questions about which software abstractions exist for human cognitive limits versus genuine architectural necessity.

15m read timeFrom blog.cloudflare.com
Post cover image
Table of contents
The Next.js deployment problemIntroducing vinextThe numbersDeploying to Cloudflare WorkersFrameworks are a team sportStatus: ExperimentalWhat about pre-rendering?Introducing Traffic-aware Pre-RenderingTaking on the Next.js challenge, but this time with AIWhy this problem is made for AIHow we actually built itWhat this means for softwareAcknowledgmentsTry it
1 Comment

Sort: