Lightning Nodes
Managing Lightning Network liquidity is critical for successful node operation. This guide covers strategies for optimizing channel liquidity for routing, payments, and receiving.
Estimated reading time: 9 minutes
Managing Lightning Network liquidity is critical for successful node operation. This guide covers strategies for optimizing channel liquidity for routing, payments, and receiving.
Understanding Liquidity
Liquidity = ability to send and receive Bitcoin through payment channels.
Local vs Remote Balance
Every channel has fixed capacity divided between participants:
Local balance (outbound liquidity) - Your side, for sending payments
Remote balance (inbound liquidity) - Partner's side, for receiving payments
Key: Sending decreases local, increases remote. Receiving does opposite. Total capacity never changes.
Reserve Requirements
Channels enforce 1% reserve on each side to prevent cheating.
Example: 10M sat channel requires 100k sat minimum reserve per side.
Max send: 9.9M sats
Max receive: 9.9M sats
Common Liquidity Problems
Depleted Outbound Liquidity
Symptoms:
Cannot send payments through channels
"Insufficient local balance" errors
Channels show 0% local balance
Cause: Sent too many payments without receiving or rebalancing.
Insufficient Inbound Liquidity
Symptoms:
Lightning invoices fail
Customers cannot pay you
Channels show 100% local balance
Cause: New channels or too many received payments without sending.
Routing Failures
Symptoms:
Low routing volume
Frequent failures
Channels at 0% or 100% balance
Cause: Imbalanced channels prevent routing in one or both directions.
Liquidity Management Strategies
Opening Balanced Channels
Dual-Funded Channels
Both parties contribute funds when opening, providing immediate bi-directional liquidity.
Available via Dashboard: Channels → Open Channel → Enable "Dual-Funded" option, or via API.
Note: Requires LND 0.17.0+ and peer support.
Push Amount
Single-funded channel with immediate push to create balance.
Available via Dashboard: Channels → Open Channel → Specify push amount, or via API.
Cost: Routing fees paid to intermediate nodes.
Balance of Satoshis (Automated)
Fee Management
Setting Channel Fees
Formula: Total fee = base_fee + (amount × fee_rate / 1,000,000)
Parameters:
Base fee: Fixed fee (millisatoshis)
Fee rate: Proportional fee (parts per million, ppm)
Example: Base 1000 msat, Rate 500 ppm
100k sat payment: 1 + (100,000 × 500 / 1,000,000) = 51 sats
Set fees: Available via Dashboard: Channels → Select Channel → Edit Policy → Update Base Fee and Fee Rate, or via API.
Fee Optimization Strategies
Balanced Policy (Simple):
Base: 1000 msat
Rate: 100 ppm (0.01%)
Same across all channels
Directional Policy (Advanced):
Low local balance channel: High fees (5000 ppm) - discourage depletion
High local balance channel: Low fees (100 ppm) - encourage usage
Routing Optimization
Becoming a Routing Node
Requirements:
Channels to high-volume, well-connected nodes
Balanced liquidity (40-60% local)
Competitive fees
High uptime
Find good peers:
1ML.com - Node rankings
Amboss.space - Analytics
LNRouter.app - Route visualization
Channel Selection Criteria
Centrality: Nodes frequently in successful routes
Capacity: 5-10M sats for routing, 1-3M for personal
Uptime: Check peer reliability on Amboss/1ML
Fee Policies: Reasonable, consistent fees
Peer Management
Available via Dashboard:
Channels → View all channels with detailed statistics
Channels → Select Channel → Close Channel
Replace closed channels with connections to better peers.
Tools
Comet Dashboard
Channel Balance Visualization - Bar charts
Liquidity Alerts - Imbalance notifications
Rebalancing Wizard - Guided interface
Fee Policy Manager - Visual editor
Routing Analytics - Performance metrics
Access: Dashboard → Channels → Liquidity Management
API Access
All liquidity management operations are available via the Comet Platform API. See API Reference for detailed documentation.
Third-Party Tools
Balance of Satoshis:
Automated rebalancing
Channel health reports
Routing analysis
ThunderHub:
Web-based management
Integrated rebalancing
Fee optimization
Ride the Lightning (RTL):
Channel visualization
Circular rebalancing
Fee management
Monitoring and Alerts
Setting Up Alerts
Configure in Dashboard:
Monitoring → Alerts
Low Inbound: inbound_liquidity < 10%
Low Outbound: local_balance < 1000000 sats
Channel Imbalance: abs(local_balance_pct - 50) > 40
Key Metrics
Channel-Level:
Local/remote balance percentages
Total capacity
Activity level
Last update timestamp
Node-Level:
Total outbound/inbound liquidity
Active channels count
Routing success rate
Fee revenue
Monitor via Dashboard:
Dashboard → Channels → View channel balances and percentages
Dashboard → Analytics → Liquidity metrics and reports
Or use the API for programmatic monitoring - see API Reference
Best Practices
Payment Nodes
Open 2-5 channels to reliable, well-connected peers
Request inbound liquidity from LSPs
Use Loop Out regularly for excess outbound
Monitor payment failures
Keep emergency on-chain reserves
Routing Nodes
Open 10-30 strategically selected channels
Maintain 40-60% balance ratios
Rebalance proactively
Implement dynamic fee policies
Monitor channel performance monthly
Close underperforming channels
Mix channel sizes (3-10M sats)
Merchant Nodes
Maximize inbound liquidity via LSPs
Automate Loop Outs to maintain capacity
Monitor during peak traffic times
Offer on-chain fallback for large payments
Display available Lightning capacity to customers
Troubleshooting
Payment Failed: Insufficient Local Balance
Solutions:
Check balances via Dashboard: Channels → View channel balances
Rebalance to increase outbound liquidity
Open additional channels
Invoice Cannot Be Paid: No Inbound
Solutions:
Use Loop In
Request LSP channel
Ask peer to open channel to you
Send payments to shift balance
Routing Failures
Solutions:
Rebalance channels to 40-60% local
Verify competitive fees
Ensure high uptime
Connect to better peers
High Rebalancing Costs
Solutions:
Find lower-fee routes: bos rebalance --max-fee
Use submarine swaps (Loop)
Adjust fee policies for natural rebalancing
Open channels with better-connected peers
Code Examples
Check Channel Balances (Python)
Automated Rebalancing (Node.js)
Related Resources
Node Management - Comprehensive node operations
API Reference - Complete API docs
LND Documentation - Official LND docs
Balance of Satoshis - CLI tool
Lightning Loop - Submarine swaps