Deployment

Deployment

This guide explains how to build the web application and deploy it either to a traditional Node.js server or to Vercel.

Build

Run the build script from apps/web (or with --filter web from the repo root):

pnpm build

This executes NODE_ENV=production react-router build and outputs files to build/.

Deploying to Node.js

  1. Copy the build/ directory and package.json to your server.
  2. Install production dependencies:
pnpm install --prod
  1. Start the server:
pnpm start # or node build/server/index.js

Ensure your environment variables are configured (see .env.example). Common variables include BETTER_AUTH_SECRET, RESEND_API_KEY, and DATABASE_URL.

Deploying to Vercel

Set the VERCEL environment variable when building:

VERCEL=1 pnpm build

The Vercel preset generates .vercel/output with serverless functions. Deploy this directory using the Vercel CLI or Git integration.