# The Mathematics of Perpetual Funding Rate Arbitrage

The concept of funding rate arbitrage is simple; take a position on a perpetual exchange that receives funding and an offsetting position elsewhere.  The analysis below shows how this is a lot more complex to actually implement and not riskless.

On closer analysis it should be clear that a key element of the arbitrage is capturing price differentials that are expected to normalise.  It is also clear that it is unlikely for prices to diverge enough for this to be profitable after fees that the positive funding will need to persist for a while for this strategy to show a profit.  There is unlikely to be many completely risk-free funding rate arbitrages and arbitrageurs will need to predict future funding rates to execute this strategy.

The other major risk of funding rate arbitrage is collateral management.  Positions on both sides of the trade need to remain sufficiently collateralised at all times.

# Arbitrage against Another Perpetual Exchange

There are many perpetuals exchanges and this creates the potential for arbitrage of funding rates between exchanges.  This is the cleanest form of arbitrage and the simplest to model.  It is important that both exchanges used have index prices that use the same or similar feeds and that margin happens against this index to prevent divergences in unrealised P&L that could drain overall collateral.

The trades are simple, when the funding rate on one exchange is sufficiently different from that on another go long the lower rate and short the higher rate.  The rates could both be positive or both negative, as long as they are far enough apart.

$$Profit = p^S_1 – P^B_2 + \sum{(F_1-F_2)} + P^S_2 – P^B_1 – 2 \times fees_1 – 2 \times fees_2$$

Where

$$P^{B/S}_i:= \text{Price bought/sold on exchange i}$$
$$F_i:= \text{Funding rates on exchange i}$$
$$fees_i:= \text{taker fee on exchange i}$$

It follows that to ensure the trade does not suffer a loss the entry price difference needs to be at least:

$$P^S_1-P^B_2 > s \times fees_1 + 2 \times fees_2$$

There will be slippage when exiting so there should be an additional buffer for this.  This also assumes that at the time the position is initiated the expected funding rate is higher on the sell exchange than the buy exchange, but this should be a given, otherwise there is no arbitrage.

Given that fees on most exchanges are 3-6bps in the higher volume tiers, prices need to be at least 6-12bps apart at initiation just to cover fees.  There is the additional risk of the spread at exit.  At a $1900 ETH price that is over$2 difference between prices on the exchanges and unlikely in most situations.

Arbitrage is still possible if the difference in initial prices is narrower, it just means that the funding rate differential will need to persist for longer to show a profit and adds a path dependency to the trade.  This turns the arbitrage into a probabilistic arbitrage where the likelihood of funding receipts needs to be modelled.

# Arbitrage Against Spot

The major difference when arbitraging against a spot instrument is the cost of funding the spot position.  The classic example given when discussing funding rate arbitrage is to buy a spot instrument and go short the associated perp, capturing the funding rate of the perp which is typically positive.

The cost of capital needed to buy the spot instrument affects this strategy by imposing a cost of carry to the spot leg that the funding rate needs to overcome.  This should be relatively stable and predictable however.

Otherwise the profit function looks very similar to perps.

$$Profit = p^S_1 – P^B_2 + \sum{(F_1-IR)} + P^S_2 – P^B_1 – 2 \times fees_1 – 2 \times fees_2$$

Where:

$$P^{B/S}_i:= \text{Price bought/sold on exchange i}$$
$$F_i:= \text{Funding rates on exchange i}$$
$$IR:= \text{Cost of capital on spot instrument, usually interest rate on margin trading}$$
$$fees_i:= \text{taker fee on exchange i}$$

Once again an arbitrageur needs to decide whether the funding rate is likely to exceed their cost of capital by enough for long enough to overcome trading fees and slippage.

# Summary

The possibility for funding rate arbitrage if prices diverge sufficiently plays an indirect role in keeping perp prices in line with their underlying.  True arbitrages are rare and it is more the reflexive expectation that prices will reconverge if they do drift apart that keeps them in line.