Skip to content
TypeScript
5.6 KB
Raw Blame
---
title: Frontend frameworks
description: Deploy Vite, Foldkit, Astro, Next.js, vinext, Nuxt, SvelteKit, Waku, or any static build to Cloudflare Workers with first-class Website resources.
sidebar:
  label: Overview
  order: 1
---

Alchemy deploys frontends to Cloudflare with a family of
`Cloudflare.Website` resources. Each one builds your project
programmatically and deploys it as a Worker — server bundle plus
static assets — with no Cloudflare-specific configuration: no
`wrangler.json`, no adapter setup. Your framework's own config file
(`vite.config.ts`, `astro.config.*`, `nuxt.config.ts`, ...) loads
natively; Alchemy layers its Cloudflare integration on top.

- [`Vite`](/cloudflare/frontend/vite) — any pure-Vite app: SPAs and
  Vite-plugin frameworks like TanStack Start, React Router, Vue, and
  SolidStart; your `vite.config.ts` loads natively.
- [`Foldkit`](/cloudflare/frontend/foldkit) — Foldkit apps; one
  `vite build` emits the client bundle and, for a server-rendered or
  prerendered app, the fetch handler that becomes the Worker.
- [`Astro`](/cloudflare/frontend/astro) — Astro sites, server-rendered
  or fully static, with an auto-provisioned session KV namespace;
  your `astro.config.*` loads natively.
- [`Nextjs`](/cloudflare/frontend/nextjs) — Next.js apps built through
  the OpenNext pipeline, with writable ISR on KV; your `next.config.*`
  is honored as-is.
- [`Vinext`](/cloudflare/frontend/vinext) — vinext (Next.js API on Vite)
  apps, with KV-backed ISR; your `vite.config.ts` loads natively.
- [`Nuxt`](/cloudflare/frontend/nuxt) — Nuxt apps built through
  nitro's `cloudflare_module` preset; your `nuxt.config.ts` loads
  natively.
- [`SvelteKit`](/cloudflare/frontend/sveltekit) — SvelteKit apps with
  a wrangler-free in-memory Cloudflare adapter; your `vite.config.ts`
  loads natively.
- [`Waku`](/cloudflare/frontend/waku) — Waku (React Server
  Components) apps.
- [`Octane`](/cloudflare/frontend/octane) — OctaneJS fullstack apps
  built for Workers with native Octane and Vite configuration; no hosting
  adapter required.
- [`StaticSite`](/cloudflare/frontend/static-site) — any build
  command's output directory, for static generators like Zola and
  Hugo.

Every resource returns a plain `Worker`, so everything a Worker
supports applies: `domain`, `env` bindings (KV, R2, Durable Objects,
secrets), `compatibility` flags, and asset routing config. All builds
are memoized by content-hashing the input files — an unchanged
project skips the build and deploy entirely.

## What's supported

| Framework | Resource | Guide |
| --- | --- | --- |
| React / Vite SPA | `Vite` | [Vite SPA](/cloudflare/frontend/vite-spa) |
| TanStack Start (React & Solid) | `Vite` | [TanStack Start](/cloudflare/frontend/tanstack-start) |
| React Router (incl. RSC) | `Vite` | [React Router](/cloudflare/frontend/react-router) |
| Vue | `Vite` | [Vue](/cloudflare/frontend/vue) |
| Foldkit | `Foldkit` | [Foldkit](/cloudflare/frontend/foldkit) |
| SolidStart / SolidJS SSR | `Vite` | [SolidStart](/cloudflare/frontend/solidstart) |
| Astro | `Astro` | [Astro](/cloudflare/frontend/astro) |
| Next.js | `Nextjs` | [Next.js](/cloudflare/frontend/nextjs) |
| vinext | `Vinext` | [vinext](/cloudflare/frontend/vinext) |
| Nuxt | `Nuxt` | [Nuxt](/cloudflare/frontend/nuxt) |
| SvelteKit | `SvelteKit` | [SvelteKit](/cloudflare/frontend/sveltekit) |
| Waku | `Waku` | [Waku](/cloudflare/frontend/waku) |
| OctaneJS (fullstack) | `Octane` | [Octane](/cloudflare/frontend/octane) |
| OctaneJS (SPA) | `Vite` | [Octane](/cloudflare/frontend/octane#octane-spas-use-vite-instead) |
| Zola, Hugo, or any static generator | `StaticSite` | [Static sites](/cloudflare/frontend/static-site) |

Every row is backed by a checked-in example or a live deploy test in
the Alchemy repository. The last row is deliberately open-ended:
StaticSite runs any build command that produces a directory, so any
static generator works the same way.

## How to choose

Use the resource named after your framework. `Astro`, `Nextjs`,
`Vinext`, `Nuxt`, `SvelteKit`, `Waku`, and `Octane` each drive their
framework's own programmatic build and know its output layout, config
surface, and dev server.

Use `Vite` when the framework is a plugin in your `vite.config.ts`
and a single `vite build` produces the whole app — TanStack Start,
React Router, Vue, SolidStart, or a plain SPA. See
[what "pure Vite" means](/cloudflare/frontend/vite#what-pure-vite-means).

Use `Foldkit` for a Foldkit app. It is `Vite` with Foldkit's
defaults: one `vite build`, and asset routing derived from what that
build wrote down, because the same project can ship client-only,
prerendered, server-rendered, or hybrid.

Use `StaticSite` when the build is an arbitrary shell command that
emits a directory of files — Zola, Hugo, or any other generator
without a dedicated resource.

## Where next

- [The Vite resource](/cloudflare/frontend/vite) — build model, env
  inlining, runtime bindings, dev mode.
- [The StaticSite resource](/cloudflare/frontend/static-site) — build
  commands, custom Workers in front of assets, framework-native dev
  servers.
- Framework guides:
  [Vite SPA](/cloudflare/frontend/vite-spa),
  [TanStack Start](/cloudflare/frontend/tanstack-start),
  [React Router](/cloudflare/frontend/react-router),
  [Vue](/cloudflare/frontend/vue),
  [Foldkit](/cloudflare/frontend/foldkit),
  [SolidStart](/cloudflare/frontend/solidstart),
  [Astro](/cloudflare/frontend/astro),
  [Next.js](/cloudflare/frontend/nextjs),
  [vinext](/cloudflare/frontend/vinext),
  [Nuxt](/cloudflare/frontend/nuxt),
  [SvelteKit](/cloudflare/frontend/sveltekit),
  [Waku](/cloudflare/frontend/waku),
  [Octane](/cloudflare/frontend/octane).