This guide moves a static site or single-page application (SPA) from Vercel to Cloudflare Workers. Use it if your project does not render pages on the server. Workers Static Assets serves your build output, so you do not need a framework adapter.
Review the steps in Before you begin that apply to every framework.
-
In the Vercel dashboard, go to your project's Settings > Build & Development settings. Note the Build Command and Output Directory values.
-
In the root of your project, create a Wrangler configuration file. Replace
<your-project-name>with your project name, and<your-build-directory>with the output directory, for example./dist.For a static site:
{ "name": "<your-project-name>", // Set this to today's date "compatibility_date": "2026-11-06", "assets": { "directory": "<your-build-directory>", }, }name = "<your-project-name>" # Set this to today's date compatibility_date = "2026-11-06" [assets] directory = "<your-build-directory>"For a single-page application, add
not_found_handling:{ "name": "<your-project-name>", // Set this to today's date "compatibility_date": "2026-11-06", "assets": { "directory": "<your-build-directory>", "not_found_handling": "single-page-application", }, }name = "<your-project-name>" # Set this to today's date compatibility_date = "2026-11-06" [assets] directory = "<your-build-directory>" not_found_handling = "single-page-application" -
Build your project, then deploy it:
npx wrangler deployyarn wrangler deploypnpm wrangler deploy -
To deploy on every push, connect your repository to Workers Builds. Use the same build command as on Vercel, and use
npx wrangler deployas the deploy command.