2 · Create the app
Scaffold ACME with create-next-app, add knext, and point Next.js at the adapter.
Nothing in this chapter touches a cluster. You can do all of it now.
Scaffold ACME
npx create-next-app@latest acme --ts --app
cd acmeAny Next.js 16 app works. This is just to have something real to deploy.
Add knext
npm i @getknext/core
npx @getknext/core --version@getknext/core is the whole deploy path in one package: the official Next.js adapter, the typed
config, and the knext CLI. The CLI lands on your PATH via node_modules/.bin, so
npx @getknext/core <command> works without a global install.
Point Next.js at the adapter
This is the line that makes it a knext app:
import type { NextConfig } from 'next';
const config: NextConfig = {
adapterPath: '@getknext/core/adapter',
};
export default config;On Next.js 16.0.x–16.1.x this option lives under experimental
(experimental: { adapterPath: '@getknext/core/adapter' }). 16.2+ accepts it at the top level.
What just happened
You used Next.js's official Deployment Adapter API. That deserves a sentence, because it is the main architectural claim knext makes.
knext's default build (build: 'turbopack') is Next's own next build, using knext's adapter on
the official Deployment Adapter API — the lane its compatibility credential (still in progress) is being earned on.
adapterPath is a supported extension point that Next.js itself provides for deployment targets.
A selectable vinext target — an open-source, Vite-based implementation of the Next.js
framework, compiled into one executable — does not use this adapter; see
the adapter and the compiled build. At build time the adapter:
- defaults
outputto'standalone', sonext buildemits a self-contained server — you do not add this yourself. If you setoutput: 'export', the adapter leaves it alone and the knext CLI refuses the build (Next.js or vinext target), because a static export is not a server deployment: remove it, or host theout/folder on a static host; - uploads your static assets after the build, keyed by build ID.
The practical consequence: your app is a normal Next.js app. If you removed knext tomorrow, the same source builds and runs on anything that runs Next.js. There is no lock-in to undo, which is also why knext can be verified against Next.js's own compatibility suite rather than asking you to take its word.
Check it still builds
npm run buildIf that succeeds, the adapter is wired correctly. You should see standalone output — Next.js
reporting a .next/standalone directory — which is the adapter doing its first job.