Self-host Formbricks surveys on Railway

By Tracklayer · Updated 2026-11-24

Short answer: Formbricks is an open-source survey and experience-management platform for link surveys, website and in-app surveys, and NPS or CSAT tracking. Version 6 is a set of services, not one container. Tracklayer’s template runs Formbricks 6.2.2 on Railway with the full stack: the web app, SpiceDB, the Formbricks Hub API and worker, Cube, PostgreSQL 18, Redis 8.2 and a Railway Bucket for uploads. It creates the first admin from your variables before the site answers requests.

Deploy Formbricks on Railway

When Formbricks makes sense

Formbricks fits when you want surveys and feedback data on your own infrastructure rather than in a hosted survey tool. The template documentation lists uses such as:

If you want chat-style forms and lead-capture bots instead, see the Typebot guide. For product analytics such as funnels and session replays, see the PostHog guide. More about the software is on the Formbricks app page.

What the template deploys

Service Source Role Public
Formbricks ghcr.io/formbricks/formbricks:6.2.2 plus start script Web app and APIs; migrations, first admin, Bucket CORS, SpiceDB schema yes
SpiceDB SpiceDB 1.57.0 binaries on Alpine 3.22 Authorization graph over gRPC with a preshared key no
Hub ghcr.io/formbricks/hub:0.14.3 Feedback-record API; runs its own migrations no
Hub Worker same image as Hub Webhook delivery and enrichment jobs no
Cube ghcr.io/formbricks/cube:1.8.8-3 plus upstream’s config Analytics queries for dashboards no
Postgres postgres-ssl:18.6 Formbricks, Hub and SpiceDB data; volume no
Redis redis:8.2.11 Cache, rate limits, job queues; volume no
Bucket Railway Bucket Uploaded images and files; private no

Every image is pinned by digest, and no third-party repositories are used. Formbricks, SpiceDB, Hub and Cube have healthchecks.

The start order matters, and the template handles it. Every component waits for Postgres. SpiceDB creates its own spicedb database, because it must not share a schema with Formbricks. Formbricks migrates the shared database first; Hub waits for Formbricks’ /health before it runs its own migrations, and Hub Worker waits for Hub. This mirrors the order in upstream’s production compose file.

First login

  1. Enter your e-mail in ADMIN_EMAIL when you deploy. ADMIN_PASSWORD is generated (8 to 128 characters are accepted if you set your own).
  2. Wait for the first deploy. Migrations take a few minutes.
  3. Open the Formbricks URL and sign in with ADMIN_EMAIL and ADMIN_PASSWORD from the Formbricks service’s Variables tab.
  4. Create your organization. Onboarding creates the default workspace.
  5. Add teammates under Organization settings > Members.

There is no public sign-up. The template’s tests confirmed that the setup wizard requires login and that Better Auth’s own sign-up route is not available to strangers.

E-mail, uploads and domains

Data and backups

All survey, response, Hub and SpiceDB data is in Postgres, on a volume. Redis has a volume for its queues, and uploads are in the Bucket. The template has no scheduled backup job, so back up Postgres yourself, at least before upgrades; see Postgres backups on Railway. Keep ENCRYPTION_KEY from the Formbricks service: it encrypts fields such as 2FA secrets and tokens and must not change after first use.

Cost

Measured idle on Railway on 2026-11-24, after login, organization creation and SpiceDB preparation:

Service Idle RAM
Formbricks 0.50 to 0.72 GB
Postgres 0.14 to 0.19 GB
Cube 0.09 GB
SpiceDB and Redis 0.05 GB each
Hub Worker and Hub 0.03 GB and 0.01 GB

That is about 1.13 GB in total with near-zero idle CPU. The template documentation puts it at about $12 a month idle plus Bucket storage, and the author estimates $15 to $25 a month with real traffic. Each service is under the Trial plan’s 1 GB limit at idle, but the web service can exceed 1 GB under load (upstream sizes it for 2 GB), so Hobby is recommended. See Railway pricing.

Upgrades

Formbricks and Cube are pinned in services/*/Dockerfile, Hub in the template and SpiceDB in services/spicedb/Dockerfile. To upgrade, read the Formbricks release notes, back up Postgres, move the images to the matching release and redeploy; migrations run on start. Hub and Hub Worker must use the same image.

Limits and licence

The template page shows the services and variables, and the Formbricks self-hosting docs cover the upstream setup. For website traffic analytics without cookies, see the Plausible and Umami guide. More walkthroughs are listed under guides.

FAQ

How do I log in to Formbricks after deploying?

Enter your e-mail in ADMIN_EMAIL when you deploy. After the first deploy, open the Formbricks URL and sign in with that e-mail and the generated ADMIN_PASSWORD from the Formbricks service's Variables tab, then create your organization. The admin is created before the site answers requests, so nobody can claim the setup wizard first.

Why does Formbricks 6 need SpiceDB, Hub and Cube?

Formbricks 6 asks SpiceDB for every authorization decision and refuses to authorize without it. Hub stores and processes feedback records, with a worker for webhooks and enrichments, and Cube answers the analytics dashboards. A single Formbricks container is not enough for version 6.

Can Formbricks send e-mails on Railway?

Only with SMTP, which Railway allows on the Pro plan. Without SMTP the template turns off e-mail verification and password reset so that logins work. On Pro, set MAIL_FROM and the SMTP_* variables on the Formbricks service.

What does it cost to run?

Measured idle on Railway, the seven services used about 1.13 GB of RAM in total, most of it the web app at 0.5 to 0.72 GB. The template documentation puts that at about $12 a month idle plus Bucket storage, and the author estimates $15 to $25 a month with real traffic.

What licence is Formbricks under?

The template's NOTICE lists the Formbricks core as AGPL-3.0, its SDK packages as MIT and apps/web/modules/ee under the Formbricks Enterprise license. Enterprise features need a license key and are not unlocked by the template. This is a community template, not affiliated with or endorsed by Formbricks GmbH or Railway.