OKX to optimize funding rate calculation

تم النشر في ‏25 يناير 20242 دقيقة قراءة

To continually improve the trading experience for our traders, OKX will adjust the calculation for average premium index. The update is scheduled for 8:00 am UTC on March 5, 2024 and will not affect other calculation logic or change the outcome during funding rate settlement.


Funding rate formula:

Funding rate = Clamp[Average premium index, Funding cap, Funding floor]
To elaborate further,
Average premium index = MA(Premium index – Interest rate)  
Interest rate = 0  
Premium index = [(Best bid + Best offer) / 2 – Index price] / Index price  
MA refers to the moving average and it is calculated every minute


Before the switch:

Funding rate will be calculated using the premium index of each minute from the start of the period to present.Example (in 24-hour time):

Most recent settlement time

Current time

Timeframe used to calculate funding rate

16:00

16:10

16:00 - 16:10

16:00

17:00

16:00 - 17:00

16:00

23:59

16:00 - 23:59

00:00

01:00

00:00 - 01:00


After the switch:

Funding rate will be calculated using premium index of each minute over the last N hours till present.
To elaborate further,
“N hours” refers to the number of hours between each settlement period. If funding fees are settled every 8 hours, N = 8.

Most recent settlement time

Current time

Timeframe used to calculate funding rate

16:00

16:10

08:11 - 16:10

16:00

17:00

09:01 - 17:00

16:00

23:59

16:00 - 23:59 (Same timeframe is used before and after the switch)

00:00

01:00

17:01 - 01:00


Impact after the switch:

For perpetual futures that use current-cycle settlement, the current funding rate at 23:59 will be used to settle funding fees at 00:00. There will not be any difference in the outcome before and after the switch during settlement.
For perpetual futures that use cross-cycle settlement, it will only affect the next funding rate calculations and will not affect how the current funding rate is calculated.

API interface

Post-adjustment, the API endpoint (/api/v5/public/funding-rate) and the Websocket channel (funding-rate) will follow the rules mentioned above.

Method

Field

next_period

nextFundingRate

current_period

fundingRate


Thank you for your understanding and support. We’ll be committed to providing you with superior products and services!


OKX team
January 25, 2024