Perpetual Futures is a futures contract with no expiry date. To reflect the basis between the spot and futures prices, funding payment is implemented every hour.
The Funding Rate is calculated in 3 steps:
Basis = Futures Mark Price - Underlying Index Price
Basis Rate = ( Basis / Index ) * 100% / 24 (calculated every minute)
Funding Rate = 1-hour TWAP (Time Weighted Average Price) of Basis Rate
Funding is paid every hour on the hour to traders with open positions, and is calculated based on the USD notional value of the position (using Mark Price). Generally, when the Funding Rate is positive, longs pay shorts; when the Funding Rate is negative, shorts pay longs.
i.e. Futures Mark Price = $10,050 , Index Price = $10,000 ,
Basis = $50 , Basis Rate = 0.5% / 24 = 0.02083%
if the price stays the same over 60 minutes, the funding rate for that hour will be 0.02083%.
Closed Markets / Maintenance
When a market is closed due to predefined market hours or maintenance, the mark price of the contract will be fixed to the index price. This causes the funding rate to be zero - or trending towards zero - for funding periods that include a market closure.