/api/* with the static assets and is free for personal use.
Vercel (recommended)
Fork and import
Fork the repo, then on Vercel pick Add New → Project and import the fork.
Set env vars
Add the following in Project Settings → Environment Variables:
Do not set any LLM API key env vars. Keys live in user browsers.
| Name | Example value |
|---|---|
DATABASE_URL | postgresql://user:pass@host:5432/probot |
NEXTAUTH_SECRET | <openssl rand -base64 32> |
NEXTAUTH_URL | https://probot.vercel.app (your assigned domain) |
Deploy
Vercel auto-detects Next.js. First deploy applies the build; runtime errors surface in Deployments → [deploy] → Functions.
Run migrations
Vercel doesn’t run migrations automatically. Either:
- Locally: point
DATABASE_URLat the production database in.env.localand runnpm run db:migrate, or - Postdeploy hook: add a script that runs migrations as part of your build (advanced).
Render, Fly.io, Railway
Same shape as Vercel - all three run Node 20 and Postgres. Build command:npm run build. Start command: npm start. Set the three env vars above.
AWS Lightsail (Node.js blueprint)
Free credit covers a year on a 1 GB instance - fine for small-scale self-hosting.Docker
One-command self-host is tracked for Stage 7 (see Roadmap). Until then, here’s a minimal Dockerfile shape:Dockerfile
docker-compose.yml that wires postgres:16 alongside.
Database choices
Any Postgres 13+ works (needsgen_random_uuid(), available via pgcrypto).
| Host | Free tier? | Notes |
|---|---|---|
| Supabase | Yes - 2 free projects, 500MB each | Recommended. Same Postgres you can self-host locally. |
| Neon | Yes - generous free tier | Branch-per-deploy is nice for previews. |
| Render PG | Yes - small free tier | |
| Local Docker | Free | postgres:16 works; not for production traffic. |
Environment variables reference
Required:| Variable | Purpose |
|---|---|
DATABASE_URL | Postgres connection string; used by Drizzle + pg.Pool |
NEXTAUTH_SECRET | JWT signing secret for NextAuth. Generate with openssl rand -base64 32 |
NEXTAUTH_URL | Canonical URL for callback construction (e.g. https://probot.vercel.app) |
ANTHROPIC_API_KEY/OPENAI_API_KEY/AZURE_OPENAI_KEY. ProBot is BYO-key; setting these server-side defeats the whole model. The key path explicitly readsx-llm-api-keyfrom the request header and does not fall back to env.
Troubleshooting
npm run db:migrate fails with “function gen_random_uuid() does not exist”
Your Postgres is missing pgcrypto. Run as a superuser:
NextAuth redirect loop
NEXTAUTH_URL doesn’t match the host the browser is actually using. Set it to the exact origin (no trailing slash).
Chat returns 502 provider_unavailable
The provider rejected the request. Check the browser network tab for the response body - invalid_llm_key means the pasted key was wrong; provider_unavailable with no further detail usually means the provider is down or the model id is wrong.