A Comprehensive Guide to Swap Contracts

·

This guide explains how BitMEX swap contracts function, covering key concepts like funding rates, premium indices, and position management.

What Are Swap Contracts?

BitMEX swap contracts allow investors to exchange interest payments while gaining exposure to underlying asset volatility. Buyers profit when the asset price rises, while sellers profit when it falls.

Daily Funding Fees

Every 8 hours (04:00, 12:00, and 20:00 UTC), swap buyers pay funding fees in the quote currency and receive fees in the base currency. Sellers do the opposite.

Base Currency vs. Quote Currency Funding Rates

Funding Rate Formula

Funding Rate = Quote Currency Rate - Base Currency Rate

Calculated using 8-hour trailing data, this rate determines payments due after each interval. Maximum rate caps:

Payment Timing

Fees are applied at designated intervals. Positions closed before these times avoid payments.

Position Value

Position Value = Total value of holdings at payment time.

Total Funding Cost

Total Funding = Funding Rate × Position Value

Total FundingAction
PositivePay
NegativeReceive

👉 Learn advanced trading strategies

Premium Index Adjustment

When contract prices deviate significantly from the mark price, the premium index recalibrates funding rates to restore equilibrium.

.XBTUSDPI Calculation

.XBTUSDPI adjusts rates based on:

Formula:
.XBTUSDPI = Funding Rate + (Max(0, Depth-Weighted Bid - Mark Price) - Max(0, Mark Price - Depth-Weighted Ask)) / Spot Price

Threshold: Rates adjust only if the premium index differs by >0.05% from the funding rate.

Underlying Asset Positions

Leverage

Each contract specifies maximum leverage (see individual terms).

Mark Price Calculation

Funding Rate Indicator = Funding Rate × (Time Elapsed / Payment Interval)
Mark Price = Spot Price × (1 + Funding Rate Indicator)

👉 Master risk management techniques

Example: Long ETHXBT Trade

Day 1, 10:00 UTC

Day 1, 12:00 UTC (Payment Interval)

Day 1, 18:00 UTC (Close Position)

Example: Short ETHXBT Trade

Day 1, 10:00 UTC

Day 1, 12:00 UTC (Payment Interval)

Day 1, 18:00 UTC (Close Position)

Key Notes

FAQ

Q: How often are funding fees applied?
A: Every 8 hours at 04:00, 12:00, and 20:00 UTC.

Q: What happens if I close my position before a funding interval?
A: You avoid paying/receiving that interval’s fees.

Q: How is the premium index determined?
A: It combines funding rates with depth-weighted bid/ask spreads relative to the mark price.

Q: Can funding rates turn negative?
A: Yes, if the quote currency rate is lower than the base currency rate.

Q: Are there limits to funding rate changes?
A: Yes—both per-interval and absolute caps apply (see "Funding Rate Formula" section).