# Self-host Langfuse

> Trace, evaluate, and debug LLM applications with prompt management and cost analytics.

- Page: https://levelrail.com/templates/langfuse/
- JSON: https://levelrail.com/templates/langfuse.json
- Category: AI
- Licence: MIT (Permissive license)
- Source: https://github.com/langfuse/langfuse
- Upstream docs: https://langfuse.com/self-hosting

## Requirements
- Memory: about 4 GiB
- amd64: published, arm64: published
- Needs configuration before start: no
- Pinned image tag: 24.12-alpine

## Services

| Service | Image | Tag | Ports | Volumes |
| --- | --- | --- | --- | --- |
| clickhouse | clickhouse/clickhouse-server | 24.12-alpine | none | langfuse_clickhouse_data -> /var/lib/clickhouse |
| db | postgres | 16-alpine | none | langfuse_db_data -> /var/lib/postgresql/data |
| langfuse-web | langfuse/langfuse | 3.225.11 | 3000 | none |
| langfuse-worker | langfuse/langfuse-worker | 3.225.11 | none | none |
| minio | ghcr.io/coollabsio/minio | RELEASE.2025-10-15T17-29-55Z | none | langfuse_minio_data -> /data |
| redis | redis | 7-alpine | none | langfuse_redis_data -> /data |

## Environment

| Service | Variable | Kind |
| --- | --- | --- |
| clickhouse | CLICKHOUSE_PASSWORD | generated |
| clickhouse | CLICKHOUSE_USER | preset |
| db | POSTGRES_DB | preset |
| db | POSTGRES_PASSWORD | generated |
| db | POSTGRES_USER | preset |
| langfuse-web | CLICKHOUSE_CLUSTER_ENABLED | preset |
| langfuse-web | CLICKHOUSE_MIGRATION_URL | preset |
| langfuse-web | CLICKHOUSE_PASSWORD | generated |
| langfuse-web | CLICKHOUSE_URL | preset |
| langfuse-web | CLICKHOUSE_USER | preset |
| langfuse-web | DATABASE_URL | generated |
| langfuse-web | ENCRYPTION_KEY | generated |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_ACCESS_KEY_ID | preset |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_BUCKET | preset |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_ENDPOINT | preset |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_FORCE_PATH_STYLE | preset |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_REGION | preset |
| langfuse-web | LANGFUSE_S3_EVENT_UPLOAD_SECRET_ACCESS_KEY | generated |
| langfuse-web | NEXTAUTH_SECRET | generated |
| langfuse-web | NEXTAUTH_URL | preset |
| langfuse-web | REDIS_HOST | preset |
| langfuse-web | SALT | generated |
| langfuse-worker | CLICKHOUSE_CLUSTER_ENABLED | preset |
| langfuse-worker | CLICKHOUSE_MIGRATION_URL | preset |
| langfuse-worker | CLICKHOUSE_PASSWORD | generated |
| langfuse-worker | CLICKHOUSE_URL | preset |
| langfuse-worker | CLICKHOUSE_USER | preset |
| langfuse-worker | DATABASE_URL | generated |
| langfuse-worker | ENCRYPTION_KEY | generated |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_ACCESS_KEY_ID | preset |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_BUCKET | preset |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_ENDPOINT | preset |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_FORCE_PATH_STYLE | preset |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_REGION | preset |
| langfuse-worker | LANGFUSE_S3_EVENT_UPLOAD_SECRET_ACCESS_KEY | generated |
| langfuse-worker | REDIS_HOST | preset |
| langfuse-worker | SALT | generated |
| minio | MINIO_ROOT_PASSWORD | generated |
| minio | MINIO_ROOT_USER | preset |

## Deploy

### CLI

```bash
levelrail-cli templates deploy langfuse --name my-langfuse
```

### API

```bash
curl -X POST -H "Authorization: Bearer $TOKEN" \
  https://levelrail.example.com/api/v1/service-templates/langfuse/deploy
```

Create a token in the dashboard first. This one-click route deploys it as a trial app you can keep or remove.

## Questions

### Can I deploy Langfuse on Dokploy or Dokku?

The services and pinned images on this page can be run on any Docker host. The public Dokploy templates list has an entry with the id langfuse for this app, so check that entry as well. Dokku deploys container images with its own commands, so the pinned image clickhouse/clickhouse-server:24.12-alpine, postgres:16-alpine, langfuse/langfuse:3.225.11, langfuse/langfuse-worker:3.225.11, ghcr.io/coollabsio/minio:RELEASE.2025-10-15T17-29-55Z, redis:7-alpine is what you deploy there.

Self-host Langfuse, Langfuse docker compose file, deploy Langfuse on a VPS: this page lists the pinned image, ports, volumes and the commands for each.
