Decoding a Paper: the stETH loop
Homemade leverage in DeFi
First article of Decoding a Paper: in this series I take a piece of research, read it and explain it again, filtering out the hard words academics use to feel smart.
We start with the paper “Leverage Staking with Liquid Staking Derivatives (LSDs): Opportunities and Risks”, by Xiong, Wang, Chen, Knottenbelt and Huth. I swear the title makes it sound more complicated than it is.
The loop
As you probably know, Ethereum runs on proof of stake The way Ethereum picks who validates blocks: instead of burning energy as in proof of work, validators lock up ETH as collateral. Those who do the job well get rewards, those who cheat lose part of the locked ETH. Ethereum switched to it with the Merge, on 15 September 2022. The token Lido gives you when you stake ETH. On Lido it’s worth 1 ETH by design and accrues the staking rewards; on the market its price can drift. Locking up ETH to help validate the Ethereum network, in exchange for a yield paid by the network itself. If you don’t want to run a validator, you can do it through a liquid staking protocol, which gives you a token like wstETH in return. A token that represents staked ETH and carries its yield, but stays transferable and usable elsewhere, for example as collateral. wstETH (Lido) and weETH (ether.fi) are the most widely used. The asset you deposit to secure a loan, and that can be sold if the loan becomes too risky.
How the loop A strategy that repeats deposit and borrow on the same asset several times to increase exposure: for example depositing wstETH, borrowing ETH, converting it into wstETH and depositing it again. It pays as long as the asset’s yield beats the cost of the loan.
There’s no real limit to how many times you can repeat this, but obviously each round adds less ETH than the one before.
Did I just tell you the secret to getting rich?
I wish!
The loop can boost the yield on your staked ETH, but it does it with homemade leverage: more yield, more risk.
The authors distinguish two kinds of loop: the direct one, built the way I just explained, and the indirect one, where you buy the stETH on the Curve A decentralized exchange specialized in trades between assets of similar value, like stETH and ETH. A contract that collects funds from many users and acts as the single counterparty: depositors and borrowers (or traders) deal with the pool, not directly with another person.
How much leverage?
Each round only gives you back part of what you put in, because of the loan to value The ratio between what you borrow and the value of the collateral. The protocol sets a maximum LTV for each asset.
- maximum leverage = 1 / (1 − LTV)
Even with infinite rounds, leverage tends to a limit that only depends on how much Aave lends you. At 69% the ceiling is about 3.2x. If you studied economics, it’s the same mechanism as the deposit multiplier: the bank lends out part of it, the loan comes back as a deposit that the bank lends out again, and so on.
In the chart below you can see how leverage grows round after round. Keep in mind that every round has costs, like gas fees The fee you pay the network for every on-chain operation, in ETH on Ethereum. It depends on how complex the operation is and how congested the network is at that moment: a strategy made of many steps pays it many times.
A real case from the paper: in April 2022 a whale An address that moves very large amounts compared to the market it trades in, big enough to move prices on its own.
The most interesting part is something else: the rounds, in themselves, don’t bring you closer to liquidation The forced sale of part of the collateral to pay back a debt that has become too risky. A third party, the liquidator, carries it out and gets a discount as an incentive. The debt-to-collateral ratio beyond which the position can be liquidated. It sits above the maximum LTV, to leave some room.
What changes is how much you lose when you get there. Leverage doesn’t make you fall more easily: it decides how badly you get hurt if you fall.
Is it worth it?
- loop yield = staking + (leverage − 1) × (staking − cost of borrowing)
You collect the normal staking yield, plus the difference between what staking yields and what you pay on the loan, multiplied by the leverage. It’s a carry trade Borrowing an asset at a low rate to put it into one that yields more, pocketing the difference as long as rates and prices stay favorable.
For example, assuming staking at 2.5%, borrowing at 2% and LTV at 69%, the loop takes the yield up to around 4% at most.
Between December 2020 and August 2023, Xiong et al. find 442 loop positions on Aave V2, spotted from the sequence of on-chain Recorded directly on the blockchain, and so verifiable by anyone. The opposite is off-chain: whatever happens outside, for example on a centralized exchange or at a bank.
- Most stop at one round: 55% of direct loops and 83% of indirect ones.
- Few go all in: 12 addresses with more than 8 rounds move 102,998 ETH, about 35% of the direct volume.
Looking at the returns on these trades, the authors note that 81.7% of the 289 closed positions beat plain staking.
May 2022: when the mechanism jams
On Lido, 1 stETH is worth 1 ETH by design. On the market, though, supply and demand set the price. Before Ethereum’s “Shapella” upgrade (April 2023) you could get into Lido but not out: if you wanted to turn your stETH into ETH, you had to sell it to someone else.
After the Terra ecosystem collapsed in May 2022, people who had moved stETH to Terra (as bETH) bring it back: 614,000 bETH return to Ethereum and 98% of it is converted back into stETH. Along with it come the sales on Curve. The excess supply sinks the price: between May and June stETH falls to about 0.93 ETH, around −7%.
On Aave V2 the oracle The service that brings data from outside into the blockchain, usually a price. Lending protocols use it to know what the collateral is worth: if the oracle price drops, so does the health factor of the loans backed by that asset. A number that sums up how far a position is from liquidation. Above 1 the position can’t be liquidated, below 1 it can. The closer it is to 1, the less room is left. Cutting a position’s leverage: you sell part of the collateral to pay back the debt. In a loop it means running the loops backwards.
Loops almost completely stop: between May and August 2022 monthly staking from direct loops goes from 93,661 to 11 ETH.
The stress test
Between 2020 and 2023 only 9 loop positions were liquidated: stETH never fell much below 0.93. That’s why the authors decided to simulate an extreme case.
They took the Curve pool as it was on 17 June 2023 and decided to turn it into a massacre by simulating a market sale of 170,000 stETH on it.
The price drops to 0.905 and the chain reaction starts:
- The health factor of every position is recalculated at the new price;
- Positions with a health factor below 1 get liquidated: the liquidator repays the debt, receives stETH and sells it on Curve;
- These sales push the price down further, and the cycle starts again.
This death spiral goes on until there are no positions left to liquidate.
The authors study this cascading liquidation with three questions.
How much does leverage weigh?
They take the 442 loop positions found in the data and run the simulation twice: once with the loops as they really were, once as if each one had stopped at the first round. The positions are the same, only the leverage changes:
| Scenario | Final stETH price (ETH) | ETH liquidated |
|---|---|---|
| With the loops | 0.01 | 497,375 |
| Stopped at the first round | 0.84 | 28,201 |
With the real leverage, stETH ends up worth one hundredth of an ETH, and almost 18 times more ETH gets liquidated. If everyone stops at the first round, the price holds at 0.84.
Do loopers put non-loopers at risk too?
On Aave there are also people who deposit stETH, borrow ETH and stop there, without looping. The authors take 442 of them, as many as the loop positions, and count how many get liquidated in two cases: on their own, and with the loop positions alongside.
On their own, 75 get liquidated. With the loops alongside, the contagion effect sweeps them away: 440 out of 442, practically all of them.
What happens to people who try to get out of a loop position?
When the health factor gets close to 1, someone in a loop has two options: wait, or unwind the position before a liquidator does it for them. Unwinding means running the loop backwards: you sell stETH on Curve, use the ETH to repay part of the debt, withdraw some collateral, and start over. That’s what the 18 users did in May 2022.
For the individual it works: the health factor goes back up and liquidation moves further away. But every backwards round is another sale of stETH on the same pool.
In the simulation, if people in a loop try to get out right away, the chain doesn’t stop: it speeds up. The sales of those running away add up to the liquidators’ sales, and the price crashes faster.