Coinlocally Docs
Perpetual Contracts
Perpetual Contracts
  • Introduction
  • Overview
    • Funding Rate
    • Mark Price
    • Index Price
    • Ladder Balancing Mechanism
    • Insurance Fund
    • Auto-Deleveraging (ADL)
  • USDT Margined Perpetual Contract
    • Introduction
    • Leverage and Position Limit
    • Ladder Maintenance Margin Rate
    • Margin and Profit/Loss Calculations
  • Coin Margined Perpetual Contracts
    • Currency Standard Perpetual Contract
    • Leverage and Position Limit
    • Ladder Maintenance Margin Rate
    • Margin and Profit/Loss Calculations
  • Functions
    • Perpetual Contract User Guide
    • One-way and Two-way Positions
    • Conditional Order
    • Take Profit, Stop Loss TP/SL
    • Take Profit Stop Loss Order
    • Contract Grid
    • Futures Copy
      • How to Carry Out a Transaction
      • Profit Sharing
      • How to Copy Trade
      • Futures Copy Trading Rules
Powered by GitBook
On this page
  • Overview
  • Funding Fee Settlement Rules
  • Funding Rate Components
  • Depth-Weighted Prices
  • Premium Index Calculation
  • Average Premium Index
  • Final Funding Rate Formula
  1. Overview

Funding Rate

Overview

The funding rate is a mechanism used in perpetual contracts to keep their prices aligned with the spot market. Unlike traditional futures contracts, which converge to the spot price at expiration, perpetual contracts have no expiration or delivery. Instead, they use the funding rate to maintain price anchoring.

Funding Fee Settlement Rules

  • Funding is settled every 8 hours:

    • 00:00 GMT+8

    • 08:00 GMT+8

    • 16:00 GMT+8

  • Only traders holding a position at the time of settlement are subject to funding fees.

  • Funding direction:

    • If the funding rate F > 0: Longs pay funding fees, and Shorts receive

    • If the funding rate F < 0: Shorts pay funding fees, Longs receive

The platform does not charge any funding fees. All fees are peer-to-peer.

Funding Fee Calculation

Funding Fee=Position Value×Funding Rate\text{Funding Fee} = \text{Position Value} \times \text{Funding Rate}Funding Fee=Position Value×Funding Rate
Position Value=Position Size×Contract Size×Mark Price\text{Position Value} = \text{Position Size} \times \text{Contract Size} \times \text{Mark Price}Position Value=Position Size×Contract Size×Mark Price

Funding Rate Components

1. Composite Rate

For a contract pair (e.g., BTC/USDT):

  • Underlying asset: BTC

  • Quote asset: USDT

Composite Rate=rq−ruN\text{Composite Rate} = \frac{r_q - r_u}{N}Composite Rate=Nrq​−ru​​

Where:

  • rq​: Quote currency interest rate

  • ru​: Underlying currency interest rate

  • N: Number of funding settlements per day

Example:

rq=0.06%,ru=0.03%,N=3r_q = 0.06\%, \quad r_u = 0.03\%, \quad N = 3rq​=0.06%,ru​=0.03%,N=3
Composite Rate=0.06%−0.03%3=0.01%\text{Composite Rate} = \frac{0.06\% - 0.03\%}{3} = 0.01\%Composite Rate=30.06%−0.03%​=0.01%

2. Funding Rate Basis Rate

This reflects the decay of the funding impact over the settlement cycle:

Basis Rate=F×(tT)\text{Basis Rate} = F \times \left( \frac{t}{T} \right)Basis Rate=F×(Tt​)

Where:

  • F: Funding rate of the current period

  • t: Time remaining until next settlement (in minutes)

  • T: Total duration of the funding cycle (480 minutes)

Example:

F=0.01%,t=450,T=480F = 0.01\%, \quad t = 450, \quad T = 480F=0.01%,t=450,T=480
Basis Rate=0.01%×(450480)=0.009375%\text{Basis Rate} = 0.01\% \times \left( \frac{450}{480} \right) = 0.009375\%Basis Rate=0.01%×(480450​)=0.009375%

3. Reasonable Price

Reasonable Price=Pindex×(1+Basis Rate)\text{Reasonable Price} = P_{\text{index}} \times (1 + \text{Basis Rate})Reasonable Price=Pindex​×(1+Basis Rate)

Example:

Pindex=10,000,Basis Rate=0.005%P_{\text{index}} = 10,000, \quad \text{Basis Rate} = 0.005\%Pindex​=10,000,Basis Rate=0.005%
Reasonable Price=10,000×(1+0.00005)=10,000.5\text{Reasonable Price} = 10,000 \times (1 + 0.00005) = 10,000.5Reasonable Price=10,000×(1+0.00005)=10,000.5

Depth-Weighted Prices

Let:

  • Pb​: Depth-weighted bid price (buy orders)

  • Pa​: Depth-weighted ask price (sell orders)

  • Pr​: Reasonable price

Premium Index Calculation

Premium Index=max⁡(0,Pb−Pr)−max⁡(0,Pr−Pa)Pindex+Basis Rate\text{Premium Index} = \frac{\max(0, P_b - P_r) - \max(0, P_r - P_a)}{P_{\text{index}}} + \text{Basis Rate}Premium Index=Pindex​max(0,Pb​−Pr​)−max(0,Pr​−Pa​)​+Basis Rate

Cases:

  1. If Pa ≥ Pr ≥ Pb​, then:

Premium Index=Basis Rate\text{Premium Index} = \text{Basis Rate}Premium Index=Basis Rate

Premium Index=Basis Rate\text{Premium Index} = \text{Basis Rate}Premium Index=Basis Rate
  1. If Pb > Pr​, then:

Premium Index=Pb−PrPindex+Basis Rate\text{Premium Index} = \frac{P_b - P_r}{P_{\text{index}}} + \text{Basis Rate}Premium Index=Pindex​Pb​−Pr​​+Basis Rate
  1. If Pr > Pa​, then:

Premium Index=Pa−PrPindex+Basis Rate\text{Premium Index} = \frac{P_a - P_r}{P_{\text{index}}} + \text{Basis Rate}Premium Index=Pindex​Pa​−Pr​​+Basis Rate

Average Premium Index

The average premium index at time ttt is the arithmetic mean of all premium index values from t - 60 minutes to t.

Final Funding Rate Formula

The final funding rate is constrained within predefined bounds:

F=clamp(AvgPremium+clamp(C−AvgPremium,Dmax,Dmin),Fmax,Fmin)F = \text{clamp} \left( \text{AvgPremium} + \text{clamp}(C - \text{AvgPremium}, D_{\text{max}}, D_{\text{min}}), F_{\text{max}}, F_{\text{min}} \right)F=clamp(AvgPremium+clamp(C−AvgPremium,Dmax​,Dmin​),Fmax​,Fmin​)

Where:

  • F: Final funding rate

  • C: Composite rate

  • Dmax, Dmin​: Premium deviation bounds

  • Fmax, Fmin: Funding rate bounds

Clamp Function:

clamp(x,max,min)={max,if x>maxmin,if x<minx,otherwise\text{clamp}(x, \text{max}, \text{min}) = \begin{cases} \text{max}, & \text{if } x > \text{max} \\ \text{min}, & \text{if } x < \text{min} \\ x, & \text{otherwise} \end{cases}clamp(x,max,min)=⎩⎨⎧​max,min,x,​if x>maxif x<minotherwise​
PreviousOverviewNextMark Price

Last updated 1 month ago