Blog

Operations

How to Monitor Stellar Network Health: Ledgers, TPS, Latency, and RPC Availability

Whether you run a Stellar validator, operate a business on the network, or just depend on the infrastructure, monitoring network health is essential. Here is what to watch and how.

Key Metrics

1. Ledger Close Time

Stellar ledgers close every 5-6 seconds under normal conditions.

ValueMeaning
5-6 secondsNormal
7-8 secondsSlight congestion
10+ secondsSignificant issue

2. Transactions Per Second (TPS)

TPS = successful_transaction_count / ledger_close_time
TPS RangeContext
10-30Light activity
30-60Normal load
60-100+High activity (Stellar regularly sustains this)

The network handled 14.1 million transactions in a single day in April 2026.

3. Transaction Success Rate

Success Rate = successful / (successful + failed) * 100

95-100% is healthy. Below 85% warrants investigation — usually fee-related during congestion.

4. Fee Distribution

curl -s https://horizon.stellar.org/fee_stats | \
  python3 -c "import sys,json; d=json.load(sys.stdin); \
  print('P50:', d['fee_charged']['p50'], 'P95:', d['fee_charged']['p95'])"

If P95 is much higher than the base fee, the network is congested.

5. Protocol Version

Track upgrades through validator voting:

curl -s https://horizon.stellar.org/ | python3 -c "import sys,json; print(json.load(sys.stdin)['current_protocol_version'])"

6. Horizon API Health

MetricTarget
Response time (`/ledgers?limit=1`)<500ms
Availability200 OK
Ingestion lag<5 ledgers
Error rate<1%

7. Soroban RPC Health

curl -s -X POST https://mainnet.sorobanrpc.com \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"getHealth"}' | python3 -m json.tool

Alert Thresholds

AlertConditionAction
**Ledger stall**No new ledger in 30sCheck SDF status
**Success rate**Below 85% for 10 minCheck fee market
**Fee spike**P95 fee 10x baseAdjust fee strategy
**Horizon lag**>10 ledgers behindCheck server health
**RPC unhealthy**getHealth returns unhealthyFailover to backup

Data Collection Script

import requests, time

def collect_metrics():
    ledger = requests.get("https://horizon.stellar.org/ledgers?limit=1&order=desc").json()
    latest = ledger["_embedded"]["records"][0]
    fees = requests.get("https://horizon.stellar.org/fee_stats").json()

    return {
        "ledger": latest["sequence"],
        "closed_at": latest["closed_at"],
        "tx_count": latest["successful_transaction_count"],
        "failed_tx": latest["failed_transaction_count"],
        "fee_p50": fees["fee_charged"]["p50"],
        "fee_p95": fees["fee_charged"]["p95"],
    }

LumenQuery Network Analytics

LumenQuery provides a pre-built dashboard at /analytics — public, no auth required:

  • Real-time metrics: Ledger sequence, TPS, success rate, protocol version
  • Historical charts: 24-hour trends
  • Fee tracking: Current fee distribution
  • Soroban metrics: Contract invocation counts and gas usage

  • *Monitor Stellar network health without building your own dashboard. LumenQuery provides real-time analytics — free and public.*