OpenNext transforms Next.js build output into packages deployable on AWS Lambda and classic Node.js servers while targeting broad Next.js feature coverage.
Overview
OpenNext is an adapter that takes the output of a Next.js build and repackages it for environments beyond the default hosting stack. It natively targets AWS Lambda and traditional Node.js server deployments, letting teams run App Router and Pages Router workloads with API routes, dynamic routes, static generation, SSR, ISR, middleware, server actions, image optimization, NextAuth.js, and edge-oriented setups.
Configuration is optional via an open-next.config.ts file beside next.config.js; otherwise defaults apply. A debug mode controlled by OPENNEXTDEBUG increases logging and disables minification for troubleshooting. The project publishes standard npm releases and automated prerelease builds from main and experimental branches.
Operational notes include a warmer function to reduce cold starts on Lambda, acknowledging that warm instances and lazy-loaded routes can still incur latency. Documented production users include Gymshark UK, Udacity, TUDN, and NHS England. OpenNext sits within a broader multi-platform adapter effort that also involves Cloudflare and Netlify contributors and work toward standardized Next.js deployment adapters.
Teams adopt it when they want Next.js applications portable across infrastructure they control, especially AWS serverless and Node hosting, without reimplementing framework output conventions themselves.
Key features
- Next.js build output conversion
- AWS Lambda deployment support
- Classic Node.js server target
- App and Pages router coverage
- ISR, middleware, and server actions
- Optional open-next.config.ts
- Lambda warmer for cold starts
- Debug build mode for development
Use cases
- Self-hosted Next.js on AWS Lambda
- Running Next.js on your own Node server
- Teams avoiding single-vendor hosting lock-in
- Organizations with existing AWS footprints
- Staging production-like serverless Next.js