Making money with delta-neutral trading using perpetual swaps

A practical guide to milk the funding rate on Mango Market

Here is how I made 6’400 USDC in the last 30 days by trading on Mango Markets with no directional risk. I will explain you how to do the same trade that market makers do not want you to know about. This is called “funding arbitrage”, take out your notebook and follow me in the rabbit hole.

First some definitions you need to understand the trade.

Spot trade: a trade that result in the immediate delivery of the underlying. I pay USD, I receive SOL. Also the opposite, I sell SOL and I receive USD. No derivatives.

Swap trade: a financial derivative where the underlying asset is not exchanged between the parties, only a cashflow. For example, if I long SOL-PERP at 80 I do not own spot Solana but I am exposed to its price fluctuations. Swaps are subject to the payment (or reception) of a funding rate (more on this below), the funding rate anchors the price of the derivative to the spot instrument.

Mango Markets 🥭: fully on-chain trading venue to lend, borrow, swap, and leverage trade cryptoassets all at the same time. Mango is built on Solana blockchain and utilizes Serum DEX for spot margin trading while perpetual futures are traded on Mango’s own orderbook. Mango is governed by MNGO holders via the Mango DAO.

Delta-neutral trade: a trading strategy with multiple position that balance each others delta, this is such that the trade PnL is not impacted by the direction of the underlying going up/down, but by other factors. Examples of delta neutral trades are:

  • Basis trade: buy spot + short future -> exposure to basis risk
  • Funding trade: buy spot + short swap -> exposure to funding risk
  • Option trade: buy call option + short underlying -> exposure to volatility risk

Notice that in all the above trades you are always buying AND selling the same asset, although using different financial instruments, for example: spot+future, spot+swap, spot+options, etc

By doing so you are not exposed to the up/down fluctuations of the underlying (delta), although you have exposure to other factors such as basis, funding, vol, etc

Funding rate: This is the most important element of the strategy so I will spend more time to describe what it is and how it affects you.

The funding rate is a cash payment exchanged between longs and shorts.

  • If price of the swap contract > spot instrument, longs pay the funding rate to shorts
  • If price of the swap contract < spot instrument, longs receive the funding rate from shorts

The more the swap contract price deviates from the spot instrument, the larger the funding fee exchanged. The image below is a visual representation of the funding mechanism, different exchanges might have different methods to calculate the index price and the funding fee but the main concepts are similar.

Funding rate VS Index (Bitmex methodology)

And now let’s dive in the “funding arbitrage trade”

Let’s observe the funding rate for SOL-PERP swap below, notice it is negative most of the time, which means when we go long we also receive the funding rate from shorts.

funding rate for SOL-PERP on Mango Markets
Rate at the time of writing this article

Mango funding rate is exchanged every 1 hour, so -0.0031% per hour implies -27.30% annualized. We are setting up the trade targeting twice as much, that is 54.60%.

The trade setup

  • Deposit some collateral on Mango (USDC, mSOL, or others), I go with 10mSOL
  • Buy (LONG) 20 contracts of SOL-PERP
My long position of 20 contracts
  • Sell (SHORT) the same amount (20) of SOL/USDC spot
My portofolio after the trades

My trading book now has

  • 10mSOL (as collateral)
  • LONG 20 SOL-PERP
  • SHORT 20 SOL
  • 1670 USDC (received by selling the SOL above)

I did not deposit SOL so I borrow them, Mango does all of this automatically in the background. Because you are long 20 contracts and sold 20 SOL spot you are not impacted by price movements, you are thus delta-neutral. Why?

If SOL drops by 10% you lose 10% on your swap position but still own 1670 USDC so can buy 10% more SOL spot.

Vice-versa, if SOL goes up 10% we earn 10% on the swap positions and buy 10% less SOL spot with USDC.

What to do now? Sit back and relax, you are now receiving USDC every 1 hour from the long SOL-PERP position plus you are earning interests from your USDC. Here’s how it looks like

Funding payments received every hour

Is it to good to be true? Yes and no. No trade strategies is analyzed properly without mentioning the risks associated with it, so..

Let’s review what are the main risks

  • Funding rate risk if the funding rate on the perpetual swap flips and goes back to positive you are not receiving anymore the funding rate, instead you are the one who PAYS it. Pay attention, this is the main risk-factor for this trade!
  • Execution risk for this trade to be properly setup you need to have an average entry price on the perpetual equal to the average sell price on the spot trade. This can be achieved by an algo that trade small lots with marker orders.
Mango Markets risk calculator
  • Leverage risk You might think that by being long 20 contracts and short 20 spot #solana your leverage is 2X but that’s not the way leverage is calculated, the actual leverage here is 3.85X, if it reaches 20X your position gets closed out (liquidation). For more information check out the docs and play with the risk calculator (https://trade.mango.markets/risk-calculator). You can get liquidated if the funding rate flips positive and you start paying the funding rate instead of receiving it!
  • Shadow delta risk you are borrowing SOL, which is accruing interest payment and this means your SOL liability keeps increasing, this means if you keep the trade open long enough you become increasingly SHORT SOL although at a very velocity. In a scenario where your SOL liability baloons and SOL price too, you might find yourself being liquidated. Remember, you are receiving USDC from the swap and from the USDC lending, and paying out SOL from your SOL borrowing. If you initially deposited mSOL as collateral you are partially mitigating this risk as mSOL is appreciating too, whereas if you initially deposit USDC as collateral you more affected.

This list is not exhaustive and there are other risks that might show up, when trading you need to be aware there exist both known risks (which we can hedge) and unknown risks (by definition we can do less against it).

Conclusions

That’s it, lads. You just learned how to do the funding arbitrage trade when funding is negative. The opposite can be done too (long spot, short swap) when the funding is positive. There are some platforms that attempt to automatize this strategy in a “Vault” like format, although I prefer to do it by myself for obvious reasons.

To get such high funding as myself you need a large positions, 20 SOL notional is not enough, you can get higher funding by:

  • Keeping the same collateral and increasing leverage (risky)
  • Adding collateral and increasing the position at the same leverage (less risky)

This trade can be done on those exchanges that offer cross-margining and swaps, Mango does it in a flawless way with a neat UI, it is completely on-chain and decentralized and — last but not least — it has a deep negative funding rate on the SOL-PERP contract which is the main requirement for this trade. I will explain why the rate is so negative in another article, if you think you know the answer feel free to get in touch.

Mango King

DISCLAIMER: WE OR A COMPANY OR PERSON CONNECTED OR ASSOCIATED WITH US HOLD A LONG POSITION AS A PRINCIPAL IN MNGO 🥭🥭 ALSO YOU MIGHT LOSE YOUR SHIRT WHEN TRADING SO BE SURE TO UNDERSTAND WHAT YOU ARE DOING BEFORE TRADING.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store