Deploy to Cloudflare

This puts the chat website on your own Cloudflare account. The chat engine and database run on your own Supabase project. We do not host your room or your fans.

A one-click GitHub button isn't available yet because the source lives in a private repo. Use the zip and the steps below. It takes about 15 minutes and stays on the free tier.

1. Download the chat

Download creator-chat.zip

Unzip it and open a terminal in the creator-chat folder.

2. Create your free Supabase project

Sign up at supabase.com, create a free project, and copy the project ref from the dashboard URL.

Then, in the unzipped folder:

./selfhost/setup-cloud.sh <project-ref>

In Supabase, go to Authentication → Sign In / Providers and turn on Anonymous sign-ins.

3. Deploy the website to your Cloudflare account

In the same folder:

npm ci
npm run build
npx wrangler login
npx wrangler deploy

When Wrangler asks, set:

Your site will be at https://creator-chat.<your-account>.workers.dev.

4. Finish the hookup

  1. Put that address in ALLOWED_ORIGINS inside selfhost/chat.env, plus your LICENSE_KEY and your own Stripe keys. Leave GATEKEEPER_PUBLIC_KEY and GATEKEEPER_URL as they came in the zip.
  2. Run npx supabase secrets set --env-file selfhost/chat.env.
  3. In your Stripe dashboard, add a webhook to https://<project-ref>.supabase.co/functions/v1/stripe-webhook for checkout.session.completed, checkout.session.expired, payment_intent.canceled and charge.refunded.
  4. Create your dashboard login:
    SUPABASE_URL=https://<ref>.supabase.co SUPABASE_SERVICE_ROLE_KEY=<service_role> node selfhost/create-admin.mjs

The full walkthrough, including the own-PC Docker path, is in the setup guide.