Funding Rate System

The funding rate system is a crucial mechanism in MegaTAO that keeps perpetual futures prices aligned with spot prices. Understanding how funding works is essential for effective trading and risk management.

What is the Funding Rate?

The funding rate is a periodic payment between long and short positions that keeps the perpetual futures price close to the spot price.

Core Concept

  • Purpose: Maintain price alignment between futures and spot markets

  • Calculation: Calculated dynamically based on market conditions

  • Direction: Determines who pays whom

  • Basis: Based on the difference between futures and spot prices, and market imbalances

How Funding Works

  • Positive Rate: Longs pay shorts (futures price > spot price)

  • Negative Rate: Shorts pay longs (futures price < spot price)

  • Zero Rate: No payment (futures price = spot price)

  • Payment: Automatic deduction/addition to margin balance

Funding Rate Calculation

Basic Formula

The funding rate is calculated based on the difference between the perpetual futures price and the spot price:

Rate Determination

  • Price Difference: Difference between futures and spot prices

  • Market Conditions: Supply and demand for long/short positions

  • Volatility: Market volatility affects funding rates

  • Time Decay: Rates tend to normalize over time

Example Calculation

  • Spot Price: $100

  • Futures Price: $101

  • Funding Rate: ($101 - $100) / $100 = 0.01 (1%)

  • Payment: Longs pay shorts 1% of position value

Funding Rate Calculation

Dynamic Calculation

Funding rates are calculated dynamically based on:

  • Market Imbalance: Difference between long and short open interest

  • Price Difference: Difference between futures and spot prices

  • Vault Utilization: Current utilization of protocol vault

  • Time Elapsed: Time since last funding update

Payment Timing

  • Calculation: Rate calculated continuously as positions are opened/closed

  • Payment: Applied automatically when positions are modified or closed

  • Accumulation: Funding accumulates over time based on the current rate

Funding Rate Direction

Positive Funding Rate

When the funding rate is positive:

Who Pays Whom

  • Longs Pay Shorts: Long position holders pay short position holders

  • Reason: Futures price is higher than spot price

  • Market Condition: Excess demand for long positions

  • Example: 0.05% positive rate = longs pay shorts 0.05%

Market Implications

  • Bullish Sentiment: Market expects price to rise

  • Long Premium: Longs pay premium for exposure

  • Short Incentive: Shorts receive payment for providing liquidity

  • Price Pressure: May put downward pressure on futures price

Negative Funding Rate

When the funding rate is negative:

Who Pays Whom

  • Shorts Pay Longs: Short position holders pay long position holders

  • Reason: Futures price is lower than spot price

  • Market Condition: Excess demand for short positions

  • Example: -0.03% negative rate = shorts pay longs 0.03%

Market Implications

  • Bearish Sentiment: Market expects price to fall

  • Short Premium: Shorts pay premium for exposure

  • Long Incentive: Longs receive payment for providing liquidity

  • Price Pressure: May put upward pressure on futures price

Funding Rate Impact on Trading

Cost Considerations

Funding rates directly impact trading costs:

Short-term Trades (< 24 hours)

  • Minimal Impact: Funding accumulates based on time held

  • Cost: Depends on current funding rate and holding period

Medium-term Trades (1-7 days)

  • Moderate Impact: Funding costs accumulate over time

  • Cost: Depends on current funding rate and holding period

Long-term Trades (> 1 week)

  • Major Impact: Funding costs can accumulate significantly

  • Cost: Depends on current funding rate and holding period

Profit Calculations

Always factor funding costs into profit calculations:

Including Funding in P&L

Example Calculation

  • Position Size: $10,000

  • Funding Rate: Varies based on market conditions

  • Holding Period: 7 days

  • Funding Cost: Accumulates based on current rate and time held

  • Price P&L: $200

  • Total P&L: Price P&L minus accumulated funding costs

Last updated