How to use MakerDAO and DAI to create a leveraged long investment in ETH

In mid-2018, having learned how futures trading works on Bitmex, I opened a 2X leveraged perpetual ETH contract. The idea was to generate a boosted return on ETH, at a leverage level I felt was “acceptably” safe. Unfortunately, later in the year, the price of ETH moved downward so dramatically that my position ended up getting liquidated, and I lost my entire collateral.

Recently, I’ve discovered an alternative way to implement a leveraged long position in ETH, involving the MakerDAO system to borrow DAI—a stablecoin that should maintain a value of $1 USD—through the creation of a “Collateralized Debt Position” (CDP). (For a good general introduction to the MakerDAO system, see this article.)

The basic idea is—we can deposit ETH collateral with MakerDAO, borrow some DAI, and then use that DAI to buy more ETH. If our ETH increases in USD value in the future, our gains are leveraged, since we get to keep some of the ETH we purchased after selling enough to repay the DAI.

The best way to understand this, is to walk through a hypothetical example (which isn’t that hypothetical, since I did it myself this morning to figure out how everything works!)

MakerDAO network

To understand our hypothetical investment, we’ll need some data from the MakerDAO network, which we can get from the Maker System Overview page.

Notes:

  • CurrentPrice — is the current value of ETH in USD.
  • LiquidationRatio — is set by Maker, and establishes the collateralization level at which your CDP would be closed and enough collateral removed to repay the DAI loan.
  • StabilityFee — This is an annualized fee charged by MakerDAO for the loan. It’s a running fee computed continually, so that a correct pro-rata charge can be made whenever you close the position.
  • LiquidationPenalty — This is an additional fee charged by MakerDAO, based on your DAI loan amount, if your CDP has to be liquidated.
  • PET — This is calculated by MakerDAO, and is the ratio of “Pooled ETH” to “Wrapped ETH” in the network. (I’m not sure what that means, but it doesn’t seem to matter for what we’re doing here.)

Loan, Fees & Investment

In this section we’re going to look at securing a DAI loan, which starts by connecting a hardware wallet, like the Ledger Nano S, to the Maker Collateralized Debt Position Portal. (It seems like they’ll also let you create a web wallet, if you prefer.) Once connected, you deposit some ETH, generate some DAI, which you can then transfer away, and then later repay the DAI to close the CDP.

  • CollateralETH — This is the amount of ETH I deposited as collateral.
  • CollateralUSD — This is the USD value of that collateral at the time of CDP creation.
  • DAI — The amount of DAI I created (borrowed).
  • CollateralizationRatio — The value of my DAI relative to my collateral. The current minimum ratio is 150% (and the website warns you if you go that low, you can immediately get liquidated with even a small drop in the price of ETH). In my case, I’m using 300% collateralization.
  • PurchasedETH — With my 20 DAI, I was able to purchase 0.166 ETH. This is done elsewhere, of course, at an exchange supporting DAI and ETH. I did it within the Edge Wallet, which is useful, because I can create an ETH wallet just for this investment, which makes it easy to compare its current value with the amount of DAI used for the purchase.

Here is what the MakerDAO CDP Portal shows me after I’ve created my loan:

  • Since ETH has slightly increased since this morning, my CollateralizationRatio is slightly higher.
  • As you can see, I can still withdraw ETH from my collateral or generate additional DAI given that my CollateralizationRatio is still above the minimum of 150%. If I were to actually try to generate another 20 DAI, however, the platform warns me that I’m at risk of immediately losing my collateral.

So at this point, I’ve deposited 0.5 ETH, to borrow $20 in DAI, which I used to buy 0.166 ETH, meaning for each 1% increase in the price of ETH, I’ll be earning 1.33%.

The liquidation case

Let’s now look at what happens should the price of ETH drop to around the liquidation level.

  • PETH — This is a term used in the MakerDAO ecosystem that refers the amount of ETH I’ve “staked” in this loan. It’s simply the amount I deposited, minus the fee I’m charged, and is what I’ll get back after repaying the loan.
  • LiquidationPrice — This is the market price of ETH at which the CDP would be closed, and enough collateral removed to cover the outstanding DAI debt, plus the liquidation fee. (As you can see from the screenshot earlier, there’s a slight inaccuracy of few dollars in my model for determining the liquidation price. The MakerDAO liquidation formula say it’s an “estimate”, so I suppose the actual liquidation price must be more complex.)
  • CoverETH — This is how much ETH I’d need to buy (or have set aside), in order to repay the loan to avoid the liquidation fee. (I could also add ETH to the CDP to increase the LiquidationRatio again.)
  • RecoveredETH — This is PETH returned to me in paying off the loan, minus the ETH I had to spend to purchase enough DAI to repay it.
  • RemainingETH — This is my net ETH left over, which is the above RecoveredETH plus the ETH I bought with my DAI loan.

An important point to note here is that liquidation doesn’t consume all my collateral, as it does at Bitmex. There, as you approach liquidation, it’s hardly worthwhile to close the position. As the price of ETH is dropping, due to the settlement process between longs and shorts, liquidation is simply the point at which your position is worthless.

Liquidation stats

Let’s look at a few numbers of general interest, related to the liquidation case.

  • Allocation — If this were a serious investment I were making, this is the total amount I’d allocate to it. It’s the amount of collateral (0.5 ETH), plus the ETH I’d need to buy enough DAI to avoid liquidation (e.g. CoverETH, or 0.33 ETH).
  • LiquidationPriceDrop — This is the percentage by which the ETH price would need to drop to trigger liquidation. (50% might seem “safe”, but as I learned in my Bitmex experiment, that’s not safe in crypto.)
  • MaxLoss — This is the percent I’d lose on my investment (my collateral), in the case of repaying the loan just prior to liquidation.

Concluding thoughts

I hope you’ve enjoyed this walkthrough of using MakerDAO to borrow some DAI, which you can use to leverage your ETH position. I don’t pretend to be an expert in the Maker system by any means, but I wanted to publish this guide, since I didn’t find anything similar (including a calculation model), when I was trying to understand it.

The Bitmex experience reinforced a saying that in the investment world has proven its wisdom time and time again:

Don’t just do something; stand there!

So I don’t know whether I’ll actually create a significant leveraged position in ETH using MakerDAO, even though I have a long-term conviction around ETH. But it’s good to finally understand how the system works!

If you’ve enjoyed the article, or find any corrections that need to be made, please drop me a note in the comments. Thanks for reading!