Cloudflare, the global internet security giant, revealed in a blog post that one engineer working with an AI model rebuilt the core API surface of Next.js in under a week, producing an experimental alternative called ‘vinext’.
The company said vinext is a drop-in replacement for Next.js, built on Vite, that can deploy directly to Cloudflare Workers with a single command.
According to Cloudflare, early internal benchmarks show that production builds run up to 4.4x faster and client bundles shrink by as much as 57% compared to Next.js 16 using Turbopack. The total cost of development, the company revealed, was roughly $1,100 in AI model tokens across more than 800 coding sessions.
Cloudflare explained that existing efforts to deploy Next.js beyond its default ecosystem often require adapting bespoke build outputs, which the company described as fragile and version-sensitive.
Instead of wrapping or reverse-engineering Next.js output, the company stated it reimplemented the framework’s routing, server rendering, React Server Components, middleware, caching, and server actions directly as a Vite plugin.
“This is not a wrapper around Next.js and Turbopack output. It's an alternative implementation of the API surface,” Cloudflare wrote.
The company emphasised that vinext currently targets Cloudflare Workers but said roughly 95% of the framework is platform-agnostic Vite code. Cloudflare revealed it had already tested a proof-of-concept deployment on another major hosting platform in under 30 minutes and invited other providers to contribute.
Cloudflare described the project as experimental and not yet battle-tested at scale. However, it said the framework passes more than 1,700 unit tests and 380 end-to-end tests, including ports of official Next.js test cases. Coverage currently reaches 94% of the Next.js 16 API surface, the company stated.
The blog also introduced an experimental feature called Traffic-aware Pre-Rendering, which Cloudflare said uses zone analytics data to pre-render only high-traffic pages during deployment rather than building all static routes upfront.
Reflecting on the development process, Cloudflare wrote, “Almost every line of code in vinext was written by AI.”
The company added that human oversight remained critical, noting: “When you give AI good direction, good context, and good guardrails, it can be very productive. But the human still has to steer.”
The announcement has since drawn scrutiny from Guillermo Rauch, CEO of Vercel, the company that created Next.js.
In a post on X, Rauch said Vercel had “identified, responsibly disclosed, and confirmed two critical, two high, two medium and one low security vulnerabilities” in vinext. “We believe the security of the internet is the highest priority, especially in the age of AI,” he added.
Rauch further stated that Vercel’s security and framework teams were extending assistance to Cloudflare “in the interest of the public internet's security.”
Cloudflare described vinext as experimental and not yet battle-tested at scale, though it said the project includes more than 1,700 unit tests and 380 end-to-end tests, including ports from the official Next.js suite. The company reported 94% API surface compatibility with Next.js 16.


Your reaction
Discussion
What's your take on this story?
No comments yet — be the first to share your view.