Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.zerct.com/llms.txt

Use this file to discover all available pages before exploring further.

Zerct full-stack apps use two deployable projects:
  • Rust backend: APIs, auth callbacks, writes, server-side rules, managed Postgres.
  • Static frontend: TanStack, Vite, or another TypeScript app built to files.

One Command

Put a zerct.toml in each app directory:
api/zerct.toml
web/zerct.toml
Deploy from the repo root:
npx @zerct/zerct deploy --database
Zerct deploys Rust backends first, then static frontends. Managed Postgres is attached only to Rust backends.

CORS

When frontend and backend use different hostnames, the Rust backend must allow the frontend origin. The starter Rust API handles OPTIONS and sends CORS headers. For production, prefer setting an explicit frontend origin in an environment variable. The starter reads FRONTEND_ORIGIN.
npx @zerct/zerct env set --app api FRONTEND_ORIGIN=https://web.zerct.app
npx @zerct/zerct deploy api
For a same-origin product URL, connect a custom domain and route frontend and backend paths from your own domain design. Keep the frontend static at runtime and send dynamic work to the Rust backend.
Last modified on May 26, 2026