Platforms

Deployment recipes for Railway, Vercel, Fly.io, Render, and bare metal.

You can self-host Hyperbolic anywhere Node runs. Here are recipes for the platforms we've tested.

Railway + Vercel + Neon (reference)#

This is what hyperbolic.sh itself runs on. Best fit for: you want zero infra, free tiers, and TLS managed for you.

  1. Neon — create a database, copy the pooled DATABASE_URL.
  2. Railway — deploy apps/server with the included railway.toml and apps/server/Dockerfile. Set DATABASE_URL and CORS_ORIGINS in variables. Add a custom domain api.yourdomain.com.
  3. Vercel — import the repo, set Root directory to apps/web. Set NEXT_PUBLIC_API_URL, NEXT_PUBLIC_SSE_URL, API_SERVER_URL to your Railway API URL. Deploy.
  4. Cloudflare — DNS-only (grey cloud) A record for root + CNAMEs for api and www. Both platforms manage their own certs.

Fly.io#

fly.toml
app = "hyperbolic-api"
primary_region = "iad"
 
[build]
dockerfile = "apps/server/Dockerfile"
 
[env]
PORT = "3111"
 
[[services]]
internal_port = 3111
protocol = "tcp"
 
[[services.ports]]
handlers = ["tls", "http"]
port = 443

Then:

fly launch --no-deploy
fly secrets set DATABASE_URL=postgres://... CORS_ORIGINS=https://app.example.com
fly deploy

Render#

  • New → Web Service → Docker.
  • Point at apps/server/Dockerfile.
  • Set DATABASE_URL and CORS_ORIGINS in the environment section.
  • Add a managed Postgres or point at Neon.

Bare metal / VPS#

Use the Docker Compose setup with Caddy in front for automatic TLS:

api.example.com {
  reverse_proxy localhost:3111 { flush_interval -1 }
}
app.example.com {
  reverse_proxy localhost:3222
}

One VPS, one Caddyfile, one compose file — done.

Things to watch for on any platform#

  • SSE buffering — disable response buffering on your reverse proxy / CDN.
  • IPv6 Postgres — Neon and some providers require IPv6-capable egress. Railway handles this; some smaller VPSes do not.
  • Memory — the server is small (~150 MB RSS idle), but SSE subscribers are in-memory. 512 MB is plenty for hundreds of concurrent watchers.
  • Websockets not used — don't configure "websocket upgrade" on your proxy; SSE is plain HTTP streaming.