---
title: "Deploy SigNoz Observability"
description: "Self-hosted observability with ClickHouse and OpenTelemetry."
category: "Observability"
url: https://railway.com/deploy/signoz-observability
---

# Deploy SigNoz Observability

Self-hosted observability with ClickHouse and OpenTelemetry.

**[Deploy SigNoz Observability on Railway](https://railway.com/template/signoz-observability)**

- **Creator:** leodev
- **Category:** Observability
- **Total deploys:** 5

## Template content

### signoz

- **Image:** signoz/signoz:v0.122.0
- **Health check:** /api/v1/health
- **Public domain:** Yes

### zookeeper-1

- **Image:** signoz/zookeeper:3.7.1

### otel-collector

- **Image:** signoz/signoz-otel-collector:v0.144.3
- **Start command:** `/bin/sh -lc '
set -eu

cat >/tmp/otel-collector-config.yaml <<YAML
connectors:
  signozmeter:
    metrics_flush_interval: 1h
    dimensions:
      - name: service.name
      - name: deployment.environment
      - name: host.name
receivers:
  otlp:
    protocols:
      grpc:
        endpoint: 0.0.0.0:4317
      http:
        endpoint: 0.0.0.0:4318
  prometheus:
    config:
      global:
        scrape_interval: 60s
      scrape_configs:
        - job_name: otel-collector
          static_configs:
          - targets:
              - localhost:8888
            labels:
              job_name: otel-collector
processors:
  batch:
    send_batch_size: 10000
    send_batch_max_size: 11000
    timeout: 10s
  batch/meter:
    send_batch_max_size: 25000
    send_batch_size: 20000
    timeout: 1s
  resourcedetection:
    detectors: [env, system]
    timeout: 2s
  signozspanmetrics/delta:
    metrics_exporter: signozclickhousemetrics
    metrics_flush_interval: 60s
    latency_histogram_buckets: [100us, 1ms, 2ms, 6ms, 10ms, 50ms, 100ms, 250ms, 500ms, 1000ms, 1400ms, 2000ms, 5s, 10s, 20s, 40s, 60s]
    dimensions_cache_size: 100000
    aggregation_temporality: AGGREGATION_TEMPORALITY_DELTA
    enable_exp_histogram: true
    dimensions:
      - name: service.namespace
        default: default
      - name: deployment.environment
        default: default
      - name: signoz.collector.id
      - name: service.version
      - name: browser.platform
      - name: browser.mobile
      - name: k8s.cluster.name
      - name: k8s.node.name
      - name: k8s.namespace.name
      - name: host.name
      - name: host.type
      - name: container.name
extensions:
  health_check:
    endpoint: 0.0.0.0:13133
  pprof:
    endpoint: 0.0.0.0:1777
exporters:
  clickhousetraces:
    datasource: tcp://clickhouse.railway.internal:9000/signoz_traces
    low_cardinal_exception_grouping: \${env:LOW_CARDINAL_EXCEPTION_GROUPING}
    use_new_schema: true
  signozclickhousemetrics:
    dsn: tcp://clickhouse.railway.internal:9000/signoz_metrics
  clickhouselogsexporter:
    dsn: tcp://clickhouse.railway.internal:9000/signoz_logs
    timeout: 10s
    use_new_schema: true
  signozclickhousemeter:
    dsn: tcp://clickhouse.railway.internal:9000/signoz_meter
    timeout: 45s
    sending_queue:
      enabled: false
  metadataexporter:
    cache:
      provider: in_memory
    dsn: tcp://clickhouse.railway.internal:9000/signoz_metadata
    enabled: true
    timeout: 45s
service:
  telemetry:
    logs:
      encoding: json
  extensions:
    - health_check
    - pprof
  pipelines:
    traces:
      receivers: [otlp]
      processors: [signozspanmetrics/delta, batch]
      exporters: [clickhousetraces, metadataexporter, signozmeter]
    metrics:
      receivers: [otlp]
      processors: [batch]
      exporters: [signozclickhousemetrics, metadataexporter, signozmeter]
    metrics/prometheus:
      receivers: [prometheus]
      processors: [batch]
      exporters: [signozclickhousemetrics, metadataexporter, signozmeter]
    logs:
      receivers: [otlp]
      processors: [batch]
      exporters: [clickhouselogsexporter, metadataexporter, signozmeter]
    metrics/meter:
      receivers: [signozmeter]
      processors: [batch/meter]
      exporters: [signozclickhousemeter]
YAML

/signoz-otel-collector migrate bootstrap
/signoz-otel-collector migrate sync up
/signoz-otel-collector migrate async up
/signoz-otel-collector migrate sync check
exec /signoz-otel-collector --config=/tmp/otel-collector-config.yaml --copy-path=/var/tmp/collector-config.yaml
'`
- **Public domain:** Yes

### clickhouse

- **Image:** clickhouse/clickhouse-server:25.5.6
- **Start command:** `/bin/bash -lc '
set -euo pipefail

base="${SIGNOZ_CONFIG_BASE:-https://raw.githubusercontent.com/SigNoz/signoz/v0.122.0/deploy}"
mkdir -p /etc/clickhouse-server/config.d /var/lib/clickhouse/preprocessed_configs /var/lib/clickhouse/user_scripts

wget -q -O /etc/clickhouse-server/config.xml "$base/common/clickhouse/config.xml"
wget -q -O /etc/clickhouse-server/users.xml "$base/common/clickhouse/users.xml"
wget -q -O /etc/clickhouse-server/custom-function.xml "$base/common/clickhouse/custom-function.xml"
wget -q -O /etc/clickhouse-server/config.d/cluster.xml "$base/common/clickhouse/cluster.xml"

sed -i "s/<host>zookeeper-1<\/host>/<host>zookeeper-1.railway.internal<\/host>/g; s/<host>clickhouse<\/host>/<host>127.0.0.1<\/host>/g" /etc/clickhouse-server/config.d/cluster.xml
cat >/etc/clickhouse-server/config.d/listen.xml <<XML
<clickhouse>
  <listen_host>0.0.0.0</listen_host>
  <listen_host>::</listen_host>
  <listen_try>1</listen_try>
</clickhouse>
XML

if [ ! -x /var/lib/clickhouse/user_scripts/histogramQuantile ]; then
  version="v0.0.1"
  node_os="$(uname -s | tr "[:upper:]" "[:lower:]")"
  node_arch="$(uname -m | sed s/aarch64/arm64/ | sed s/x86_64/amd64/)"
  wget -q -O /tmp/histogram-quantile.tar.gz "https://github.com/SigNoz/signoz/releases/download/histogram-quantile%2F${version}/histogram-quantile_${node_os}_${node_arch}.tar.gz"
  tar -xzf /tmp/histogram-quantile.tar.gz -C /tmp
  mv /tmp/histogram-quantile /var/lib/clickhouse/user_scripts/histogramQuantile
  chmod +x /var/lib/clickhouse/user_scripts/histogramQuantile
fi

chown -R clickhouse:clickhouse /var/lib/clickhouse
exec su -s /bin/bash clickhouse -c "clickhouse-server --config-file=/etc/clickhouse-server/config.xml"
'`

## Documentation

# Deploy and Host SigNoz Observability on Railway

SigNoz is an open-source observability platform for traces, metrics, logs, dashboards, and alerts. This template deploys the SigNoz UI, OpenTelemetry Collector, ClickHouse, and Zookeeper as separate Railway services with persistent volumes and private networking.

## About Hosting SigNoz Observability

The template runs SigNoz with a public UI on port 8080 and a public OTLP HTTP collector endpoint on port 4318. ClickHouse and Zookeeper stay private. The collector runs SigNoz migrations before starting and writes telemetry into ClickHouse.

## Common Use Cases

- Application performance monitoring
- Centralized logs and traces
- Open-source Datadog or New Relic alternative

## Dependencies for SigNoz Observability Hosting

- SigNoz
- OpenTelemetry Collector
- ClickHouse
- Zookeeper

### Deployment Dependencies

- https://signoz.io
- https://opentelemetry.io
- https://clickhouse.com

## Why Deploy SigNoz Observability on Railway?

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 SigNoz Observability on Railway, you are one step closer to supporting a complete full-stack observability stack with minimal burden.

## Similar templates

- [Pyroscope profiling](https://railway.com/deploy/pyroscope-profiling) — Protected continuous profiling with durable Pyroscope storage.
- [SigOnly](https://railway.com/deploy/sigonly) — Deploy SigNoz with a working demo app & config in one click
- [Unwrapped Spotify Music Stats](https://railway.com/deploy/wide-bold) — Unwrapped Spotify Music Stats, Estatísticas de músicas disponíveis

Open this page in a browser: https://railway.com/deploy/signoz-observability
