cloudflare /vinext

Vite plugin that reimplements the Next.js API surface — deploy anywhere

★ 9,373⑂ 475👁 40⑃ 3,635● 963▤ 117
TypeScriptMITCreated 2026-02-24vinext.dev
下载:@vinext/[email protected]@vinext/[email protected] ↓1.3.42026-11-10
+4
日增长
9,373
stars
475
forks
40
watchers
3,635
prs
963
issues
117
releases

README

vinext

Run Next.js applications on Vite, with Cloudflare Workers as the primary deployment target.

Website: vinext.dev

Documentation: vinext.dev/docs

 Read the announcement: How we rebuilt Next.js with AI in one week

 Under active development. vinext supports substantial Next.js applications today, but it is not yet a drop-in replacement for every application or production workload. Expect compatibility gaps, especially in newer App Router features, and evaluate it against your own application before adopting it.

vinext reimplements the Next.js API surface on Vite rather than consuming next build output. It supports both the App Router and Pages Router, React Server Components, Server Actions, middleware, route handlers, ISR, static export, and the most commonly used next/ modules. Cloudflare Workers has the deepest integration; Node.js and other platforms are available with different levels of support.

 Project status

 What works today

- App Router and Pages Router in development and production builds
- React Server Components, Server Actions, route handlers, and middleware
- Static generation, ISR, output: "export", and standalone Node.js output
- Core Next.js APIs and modules, including next/link, next/image, next/navigation, next/headers, next/cache, and the Metadata API
- Cloudflare Workers deployment with bindings, cache adapters, and image optimization support
- Migration tooling through vinext check, vinext init, and the vinext Agent Skill

 Known gaps we're working on

These are active compatibility areas, not permanent exclusions:

- Cache Components and Partial Prerendering: "use cache" is partially implemented, but full cacheComponents behavior is still incomplete. Cache profiles, tags, partial shells, resume behavior, prefetching, and some dev/build cache semantics do not yet match Next.js in every case.
- Build-time image and font optimization: images can be optimized at request time on Cloudflare, but vinext does not yet reproduce Next.js's complete build-time image pipeline. Google Fonts are loaded from the CDN, and local font CSS is injected at runtime rather than extracted during the build.
- Native modules in App Router development: packages such as sharp, resvg, satori, lightningcss, and @napi-rs/canvas can fail in Vite's RSC development environment. Production builds support more of these cases than development mode.
- Platform-specific and advanced Next.js behavior: preferredRegion route config is ignored, and runtime doesn't choose where a route runs (outside cacheComponents, a runtime = "edge" App Router page is never ISR-cached, as in Next.js), and some recently introduced or undocumented Next.js behavior may not yet be reproduced.

Run vinext check against an existing application before migrating. If a gap is not listed here, check the open issues or file a focused reproduction.

 Quick start

Use the official setup commands below. They are the recommended way to create or migrate a vinext project because they c

Top issues

Latest release

@vinext/[email protected] @vinext/[email protected] 2026-11-10
This release changes the @vinext/cloudflare previews deploy command to use a --preview-name flag instead of a positional arg for preview names, to align with an upstream breaking change that the cf CLI did.

 Bug Fixes

 Cloudflare

- pass the Preview name with --preview-name like cf (4572)
- never store a Range request's 206 in the Response Store (4622)
- read the log cf writes to stderr during version deploys (4609)

 Misc

- Init: stop adding nodejs_compat now that compat dates enable it (4580)

 Contributors

- @james-elicx

Snapshot: 2026-11-16T09:23:14Z · Data license Apache-2.0 · JSON