Meta-frameworks
Already using a meta-framework? Keep its routes and rendering. Add the SDK for databases, storage, jobs and deploys. This section has one setup guide per framework.
On this pageFind the guide for your framework · Compare which SDK features each framework supports · Learn the shared configuration and deploy steps
Add voidPlugin() to the framework's Vite config. The plugin finds the resources you use and generates database types. It also manages migrations and prepares the app for void deploy.
TanStack Start and React Router use the SDK's Cloudflare Vite plugin. SvelteKit, Nuxt, Analog and Astro use their own Cloudflare adapters. The setup differs, but your framework still handles routing and rendering.
Supported frameworks
| Framework | Package | Integration |
|---|---|---|
| TanStack Start | @tanstack/react-start | Vite plugin composition. voidPlugin() runs alongside the framework plugin. |
| React Router v7 | @react-router/dev | Vite plugin composition. Setup matches TanStack Start. |
| SvelteKit | @sveltejs/kit | Vite-based, uses its own Cloudflare adapter |
| Nuxt | nuxt | Own CLI and build toolchain |
| Analog | @analogjs/platform | Vite-based, uses Nitro with Cloudflare preset |
| Astro v6+ | astro | Own CLI and Cloudflare adapter (v6 required) |
The CLI detects your framework from the package.json dependencies.
Feature support
With voidPlugin() in the Vite config, a framework gets most of the backend features of SDK apps:
- Binding inference: the SDK detects D1, KV, R2, AI and queues in your code.
- Typed database: query types come from your Drizzle schema.
- Migrations: local D1 updates when dev starts.
void deploychecks and applies migrations. - Runtime helpers:
void/db,void/kv,void/storageandvoid/aigive typed access to Cloudflare bindings in dev and production. - Auth: framework mode does not support SDK-managed auth yet. Use Better Auth's official integration for your framework.
- Cron jobs: add scheduled handlers in the
crons/folder. - Queue consumers: add typed producers and consumers in the
queues/folder. - Revalidation and prerendering: set them with
routing.revalidateandrouting.prerenderinvoid.config.ts. SDK apps can also set these per page in companion.server.tsfiles.
In framework apps, SDK revalidation caches public HTML responses. This works with void deploy and void deploy --platform cloudflare. Client data requests keep the framework's own behavior. A response with Set-Cookie, or with Cache-Control: private, no-store or no-cache, is never shared.
Frameworks can also read bindings in their own way. Examples: env from cloudflare:workers in SvelteKit 3 and Analog, platform.env in SvelteKit 2, event.context.cloudflare.env in Nuxt, Astro.locals.runtime.env in Astro.
Configuration
void.config.ts
The SDK infers most settings. Use void.config.ts to override the defaults:
import { defineConfig } from 'void/config';
export default defineConfig({
inference: {
build: 'nuxt build',
scanDirs: ['src', 'server', 'lib'],
bindings: { db: 'MY_DB' },
},
routing: {
prerender: ['/', '/about', '/pricing'],
revalidate: 60,
},
});| Field | Purpose |
|---|---|
inference.build | Override the default build command |
inference.scanDirs | Directories to scan for binding inference (defaults vary by framework) |
routing.prerender | Paths to prerender as static HTML at deploy time |
routing.revalidate | Default revalidation TTL in seconds for cached responses |
inference.bindings | Override inferred bindings. You only need this if auto-detection is not doing what you want. Accepts true or a custom binding name such as "db": "MY_DB". |
routing.notFound | Ignored. SvelteKit, Nuxt, Analog, and Astro pin not_found_handling to "none" — the framework worker owns unmatched HTML. void deploy warns if set. |
See Configuration for the full reference.
Cloudflare settings
Frameworks that use Cloudflare's dev runtime must point their adapter at the SDK's generated .void-wrangler.jsonc. Each setup guide shows the adapter options. Put your Cloudflare settings in void.config.ts:
import { defineConfig } from 'void/config';
export default defineConfig({
cloudflare: {
name: 'my-app',
compatibility_date: '2026-02-24',
compatibility_flags: ['nodejs_compat'],
},
});Existing bindings are kept. D1, KV and R2 use local placeholder IDs until you deploy. In a project connected directly to Cloudflare, importing void/ai adds a remote Workers AI binding in dev. Cloudflare login is required to use it. Direct deploys also include the inferred AI binding.
The SDK merges these settings with inferred bindings. It records new resource IDs in void.lock.json. Commit both files.
Deployment
Run void deploy to build with your framework and deploy to the selected target. See Deployment for setup and CI.