Deploy OpenPanel Session Replay

Product analytics with rrweb session replay

Deploy OpenPanel Session Replay

Just deployed

/var/lib/clickhouse

op-redis

redis:8.2.1

Just deployed

/data

Just deployed

Just deployed

/var/lib/postgresql/data

Just deployed

Just deployed

Deploy and Host OpenPanel Session Replay (Open-Source Product Analytics) on Railway

OpenPanel Session Replay is the same OpenPanel 2.3.0 Railway stack (api, dashboard, worker, Caddy, Postgres, Redis, ClickHouse) with the overview aimed at opt-in rrweb session replay plus funnels, retention, cohorts, and profiles. Digest-pinned lindesvard/openpanel-* images, API_HOST=:: for Railway private IPv6, one public domain, zero deploy-time config.

About Hosting OpenPanel Session Replay on Railway (self hosted OpenPanel template)

Seven services: op-proxy (caddy:2-alpine, only public service, :8080; Caddyfile from env; /api/* to api, rest to dashboard), op-api / op-dashboard / op-worker (2.3.0 digests), op-postgres 17, op-redis 8.2.1, op-clickhouse 25.12. Replay is off until you enable it per project in the SDK (sessionReplay: { enabled: true }). The main tracker stays lean; op1-replay.js loads asynchronously only when recording. Recordings are structured rrweb data, not video, with client-side masking before upload.

Why Deploy OpenPanel Session Replay, the Mixpanel alternative on Railway (Railway Free Trial)

SaaS analytics that include replay still park recordings on someone else's disk and meter events. OpenPanel keeps events and replays on your ClickHouse volume under AGPL-3.0. Railway wires the seven services so you are not hand-rolling Compose networking. $5 trial is enough to create a project and enable replay on a staging site.

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying OpenPanel on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.

Railway vs Other Hosting Providers and VPS for OpenPanel Session Replay self hosting

ProviderSetupCostMaintenanceBest for
DigitalOceanManual Compose or dropletPredictable VPS pricingYou own TLS, volumes, upgradesTeams already on DO droplets
AWSECS/EC2 plus data storesGrows with egress and ops timeIAM, networking, ClickHouse opsExisting AWS estates
HetznerManual VPS + ComposeCheap EU compute/storageYou handle backups and updatesCost-sensitive self-hosters

Common Use Cases for hosted OpenPanel Session Replay

Watch the exact session that abandoned a checkout funnel. Mask inputs and sensitive DOM before enabling replay on production. Keep cookieless page analytics on by default and turn replay on only for opted-in cohorts. Correlate custom SDK events with replay timestamps for support. Compare A/B variants with both funnel drop-off and a handful of recordings. Store everything in ClickHouse you control instead of a third-party replay SaaS.

Dependencies for OpenPanel Session Replay Docker hosted on Railway

Seven containers, volumes for Postgres, Redis (/data), and ClickHouse (/var/lib/clickhouse). Secrets: COOKIE_SECRET, POSTGRES_PASSWORD, REDIS_PASSWORD, CLICKHOUSE_PASSWORD. Key wiring: SELF_HOSTED=true, DATABASE_URL(s), REDIS_URL, CLICKHOUSE_URL, DASHBOARD_URL, API_URL (public + /api), API_URL_SSR (private API for dashboard), ALLOW_REGISTRATION=true (closes after first signup), ALLOW_INVITATION=true. Optional: RESEND_API_KEY / EMAIL_SENDER, OPENAI_API_KEY / ANTHROPIC_API_KEY for in-app AI chat.

Deployment Dependencies for Managed OpenPanel Session Replay Service (Product Analytics)

Only op-proxy is public. Health through proxy: /api/healthcheck returns ready with redis, db, ch flags. API runs migrations (pnpm -r run migrate:deploy) then serves. Worker drains Redis-backed jobs. Replay traffic hits the same /api path as events; no extra public service.

Implementation Details for OpenPanel Session Replay (Using OpenPanel official docker images)

API_HOST=:: so api and worker listen on IPv6 for Railway private networking. One public domain keeps cookies and SDK apiUrl simple: point SDKs at https://YOUR-DOMAIN/api. Enable replay in the web init config; masking options such as maskAllInputs / maskAllText / block selectors apply in the browser before batches upload. Do not enable replay on password, payment, or health pages without strict masking and consent.

How does OpenPanel Session Replay compare against other analytics platforms

OpenPanel vs Mixpanel

  • Hosting: OpenPanel self-hosts events and replays; Mixpanel is closed SaaS (replay stays in their cloud).
  • Pricing: Self-host unlimited events; Mixpanel meters after free tier.
  • Privacy: OpenPanel cookieless by default and AGPL; Mixpanel cookie-oriented SaaS.
  • Depth: Mixpanel has deeper enterprise experimentation; OpenPanel covers core product analytics plus rrweb.

OpenPanel vs PostHog

  • Scope: PostHog is a broader suite (flags, experiments, surveys). OpenPanel stays focused on product analytics + replay.
  • Self-host weight: Full PostHog is heavier; hobby self-host is limited. OpenPanel's seven services fit a modest Railway bill.
  • License: OpenPanel AGPL-3.0; PostHog core MIT with a larger commercial surface.
  • Pick: PostHog for flags/experiments; OpenPanel when you want lighter analytics with first-class replay.

OpenPanel vs Plausible

  • Type: Plausible is simple privacy web analytics; OpenPanel is user-level product analytics with funnels and replay.
  • Replay: Plausible has none; OpenPanel includes opt-in rrweb.
  • Ops: Plausible is lighter to run; OpenPanel needs ClickHouse and Redis for events/replay.

OpenPanel vs Google Analytics 4

  • Ownership: GA4 is closed SaaS; OpenPanel is self-hosted AGPL.
  • Replay: GA4 has no rrweb-style product replay; OpenPanel does.
  • Compliance: Self-hosting avoids shipping EU session video-like data to a US SaaS by default.
  • Cost: GA4 is "free" with lock-in; OpenPanel is flat infra cost.

How to use OpenPanel Session Replay (the OSS product analytics platform)?

Open the domain, create the first account (registration closes afterward), create a project, add the web SDK with apiUrl https://YOUR-DOMAIN/api, and set sessionReplay: { enabled: true } when you want recordings. Use masking options before production. Invite teammates with ALLOW_INVITATION; set RESEND_API_KEY if you need email invites/resets.

How to self host OpenPanel Session Replay on other VPS Services (OpenPanel self hosting guide)

Upstream Docker Compose and setup script: openpanel.dev/docs/self-hosting. Same seven-service shape as this template.

Clone the Repository

Clone the official OpenPanel repo (Compose file, env examples, migrations).

Install Dependencies

Docker Engine + Compose plugin. Add TLS via the included Caddy or your own proxy.

Configure Environment Variables

SELF_HOSTED=true, COOKIE_SECRET, database/redis/clickhouse URLs and passwords, DASHBOARD_URL, API_URL, API_URL_SSR. Keep API_HOST=:: if your private network is IPv6-first like Railway.

Start the OpenPanel Session Replay Application

docker compose up -d. Confirm /api/healthcheck shows redis, db, and ch ready. Enable replay in the project SDK config, not by adding another container.

Official Pricing of OpenPanel Session Replay (OpenPanel pricing)

Cloud (openpanel.dev/pricing) meters monthly events: 5K $2.50/mo, 100K $20/mo, 1M $90/mo, 10M $350/mo; yearly gets 2 months free; 30-day trial. Self-hosting is free with unlimited events; you pay Railway (or VPS) only.

OpenPanel Session Replay cloud vs self hosted comparison (Pricing, features, costs, and more)

Cloud trades ops for per-event fees and vendor-held recordings. Self-host keeps rrweb batches on your ClickHouse volume and removes event caps. Feature set for analytics and replay matches; you own upgrades and disk growth.

Monthly cost of self hosting OpenPanel Session Replay on Railway

About $20-40/mo at low volume for four app services plus ClickHouse, Postgres, and Redis. Replay storage grows ClickHouse disk; budget more as session volume rises. Railway $5 trial for smoke tests.

System Requirements for Hosting OpenPanel Session Replay on a VPS

Rough start: 2 vCPU, 4 GB RAM, 50 GB SSD when replay is on. ClickHouse likes RAM; API/worker scale with CPU. Postgres and Redis stay lighter.

Operator note: after the first healthy deploy, confirm the public health endpoint, rotate only the secrets you intend to rotate, and document the bootstrap or pairing step your teammates need before you share the URL more widely.

Self-hosted replay means you choose retention: grow the ClickHouse volume when recordings pile up, and keep replay disabled on environments that should not store DOM snapshots at all.

Frequently Asked Questions (FAQs)

How does session replay data get stored?

The browser loads op1-replay.js only when enabled, records rrweb events, masks client-side, and posts batches to your API. Jobs land on Redis; the worker persists compressed recordings into ClickHouse on the volume.

Can I enable session replay for only some users?

Yes. Gate sessionReplay.enabled in your app for opted-in users or cohorts, and keep it off by default per project.

How do I mask sensitive data in replays?

Use maskAllInputs / maskAllText and block selectors so secrets never leave the browser. Still avoid recording password and payment pages when possible.

When should I NOT enable session replay?

Skip it on pages with passwords, card numbers, or health data unless you have consent and strict masking. Replay increases ClickHouse storage.

Does OpenPanel Session Replay work without cookies?

Yes. Cookieless tracking still records sessions; cross-visit identity is weaker without a cookie.

Why is there a Caddy proxy?

One public domain routes /api/* to the API and the rest to the dashboard so cookies and SDK apiUrl work without a custom domain.


Template Content

More templates in this category

View Template
NEW
Formbricks | Open-Source Typeform & Qualtrics Alternative
Surveys, NPS and in-app feedback on your own Postgres, Hub and Cube

Two Workspaces
2
View Template
Typesense PHP
official PHP client against Railway

onepush
0
View Template
Typesense vs Meilisearch
self-hosted Typesense vs Meilisearch

onepush
0