Funding fee mechanism
At OKX, our perpetual futures adopt a funding fee mechanism designed to align the market price of the perpetual market with the index price.
When the funding rate is positive, traders with long positions pay a funding fee to traders with short positions. Conversely, when the funding rate is negative, traders with short positions pay a funding fee to traders with long positions. Note that our platform only facilitates the exchange of funds between traders and doesn’t charge any service fees under this mechanism.
The funding fee will be charged or paid out every 8 hours (00:00, 08:00, and 16:00 UTC) by default, unless specified otherwise (i.e. every 2 or 4 hours). For each perpetual futures contract, fees are assessed within milliseconds and trading won’t be interrupted. You’re obligated to pay or receive the funding fee if you hold open positions at the point of fee assessment. If you close your position before the funding fee assessment, you’re exempt from paying or collecting the fee. Additionally, if a perpetual futures contract is delisted before the assessment, the current cycle’s funding fee becomes void. The actual fee assessment may take up to a minute. For example, if you open a position at 00:00:20 UTC, you could still be subject to the funding fee (either collecting or distributing the funding fee) if the fee assessment has yet to end.
The funding fee settlement time may be adjusted in real-time according to market conditions.
Funding rate calculation
Original funding rate calculation
Funding rate = Clamp [MA (Premium index – Interest rate), Funding rate cap, Funding rate floor]
Interest rate is zero.
For more information on the cap and floor, refer to this page.
Premium index = [(Best bid + Best ask) / 2 – Index price] / Index price
MA, also known as the moving average, refers to the average value of the premium index over the past 8 hours
For example: MA (Premium index at Tn) = (Premium index at T1 + Premium index at T2 + ... + Premium index at Tn) / n. The funding rate at 07:59 will be calculated using the premium index for every minute in the 00:00 to 07:59 time period. In other words, n = 480.
The funding rate used to calculate the funding fee during fee assessment will be the most recent funding rate.
For example, the fee assessment at 16:00 will use the funding rate calculated at 15:59.
New funding rate calculation
To provide you with a better experience, we'll be changing the funding rate calculation logic in 3 batches, more details can be found in this announcement.
Funding rate = clamp [Average premium index + clamp (Interest rate – Average premium index, 0.05%, -0.05%), Funding rate cap, Funding rate floor]
Interest rate = 0.03% / (24 / Settlement interval)
Taking a BTCUSDT perpetual futures contract as an example, the settlement interval is 8 hours, so the interest rate is 0.01% at each settlement.
For more information on the cap and floor, refer to this page.
Premium index = [Max (0, Impact bid price – Index price) – Max (0, Index price – Impact ask price)] / Index price
The average premium index is calculated using an exponential moving average of the premium index over the last settlement interval.
For example: Average premium index at Tn = (1 × Premium index at T1 + 2 × Premium index at T2 + ... + n × Premium index at Tn) / (1 + 2 + ... + n). Assuming the settlement interval of a perpetual futures contract is 8 hours, the funding rate at 07:59 will be calculated using the premium index for every minute between 00:00 to 07:59. In other words, n = 480.
Impact bid/ask price is the average fill price to execute the impact value on the bid/ask price.
Impact bid/ask price = Impact value / Total base amount required to meet impact value
Impact value = 200 × Max leverage allowed for this perpetual
The funding rate used to calculate the funding fee during fee assessment will be the most recent funding rate that was calculated in the previous minute before fee assessment.
For example, the fee assessment at 16:00 will use the funding rate calculated at 15:59.
Impact bid price calculation using BTCUSDT perpetual as an example:
Assuming impact value = 20,000 USDT
Bid order book level | Bid price | Base amount in each order book level (BTC) | Calculation |
1 | 90,000 | 0.02 | Value of orders up to this level = 90,000 × 0.02 = 1,800 USDT The entire base amount of 0.02 BTC at this level will be used for impact bid price calculation. |
2 | 89,900 | 0.06 | Value of orders up to this level = Value of orders in bid 2 + Value of orders in bid 1 = 89,900 × 0.06 + 1,800 = 7,194 USDT The entire base amount of 0.06 BTC at this level will be used for impact bid price calculation. |
3 | 89,700 | 0.16 | Value of orders up to this level = Value of orders in bid 3 + Value of orders in bid 1 and 2 = 89,700 × 0.16 + 7,194 = 21,546 USDT Impact value required for this level = 20,000 – 7,194 = 12,806 USDT Amount required from this level (BTC) = 12,806 / 89,700 = 0.14276 BTC Impact bid price = 20,000 / (0.02 + 0.06 + 0.14276) = 89,780.8 USDT |
Impact ask price calculation using BTCUSDT perpetual as an example:
Ask order book level | Ask price | Base amount in each order book level (BTC) | Calculation |
1 | 90,000 | 0.02 | Value of orders up to this level = 90,000 × 0.02 = 1,800 USDT The entire base amount of 0.02 BTC at this level will be used for impact bid price calculation. |
2 | 90,100 | 0.06 | Value of orders up to this level = Value of orders in ask 2 + Value of orders in ask 1 = 90,100 × 0.06 + 1,800 = 7,206 USDT The entire base amount of 0.06 BTC at this level will be used for impact bid price calculation. |
3 | 90,200 | 0.16 | Value of orders up to this level = Value of orders in ask 3 + Value of orders in ask 1 and 2 = 90,200 × 0.16 + 7,206 = 21,638 USDT Impact value required for this level = 20,000 – 7,206 = 12,794 USDT Amount required from this level (BTC) = 12,794 / 90,200 = 0.14184 BTC Impact ask price = 20,000 / (0.02 + 0.06 + 0.14184) = 90,154.9 USDT |
Funding fee calculation
Funding fee = Position value × Funding rate
USDT-margined/USDC-margined perpetual futures
Position value = Number of contracts × Contract size × Contract multiplier × Mark price
Example:
You have a long position of 10 BTCUSDT perpetual futures contract with a current mark price of 60,000 USDT, 0.01 BTC face value per contract, and the funding rate is 0.1%.
Position value = 60,000 × 10 × 0.01 × 1 = 6,000 USDT
Funding fee (platform collects) = 6,000 × 0.1% = 6 USDT
Crypto-margined perpetual futures
Position value = Number of contracts × Contract size × Contract multiplier / Mark price
Example:
You have a short position of 100 ETHUSD Perpetual contracts with a current mark price of 4,000 USD, 10 USD face value per contract, and the funding rate is 0.1%.
Position value = 100 × 10 × 1 / 4,000 = 0.25 ETH
Funding fee (platform distributes) = 0.25 × 0.1% = 0.00025 ETH
Collection and distribution of funding fees
Collection of funding fees by platform | When collecting funding fees, OKX will collect the full amount of outstanding funding fees, even if this goes beyond the liquidation threshold (i.e. where margin level falls below 100%). Partial or full liquidation will be carried out thereafter if required. Isolated margin mode Funding fee will be collected solely from the margin balance of your isolated positions, instead of the transferable balance in your cross-margin account. Orders will not be canceled during collection. If the margin balance is insufficient, partial or full liquidation will be carried out thereafter if required. Cross-margin mode (single-currency, multi-currency, portfolio margin) Funding fees are collected from cross-margin equity. Orders will not be canceled during collection. If the cross-margin equity is insufficient, partial or full liquidation will be carried out thereafter if required. |
Distribution of funding fees by platform | The platform will distribute the full amount to you during settlement. Isolated margin mode For isolated margin positions, the funding fee will be added into the margin balance of the position. Cross-margin mode (single-currency, multi-currency, portfolio margin) For cross-margin positions, the funding fee will be added to their cross-margin equity. |