Cover photo

Liquidity Pools (and the Word 'Impermanent')

Dev had been quiet all week.

He'd been quiet on Tuesday, when he didn't reply to a hodl meme I sent him. He'd been quiet on Thursday, when we crossed paths in Shibuya station and he hugged me for slightly too long without saying why. By the time we got to the bench on Sunday - clear cold morning, snow on the rooftops but the path swept dry - I had figured out, with the kind of slow inevitability you get when you've known someone for fifteen years, that he was about to confess something.

Moolah figured it out faster.

"Dev." She didn't look up from her latte. "You're going to tell us about the lemonade stand."

"How did you -"

"Because I have been listening to people say I'd rather not get into it for six hundred years, and they all have the same posture. Sit down. Tell Priya. She needs to hear this and you need to say it."

He sat down. He looked at the pond. He told us.

"Two summers ago," he said, "I put about eight thousand dollars into a liquidity pool. ETH and USDC. Fifty-fifty. Same kind of pool Priya swapped against last week - there are buckets, and the pool needs to be filled, and the pool pays you a fee on every trade that happens. It seemed like free money. The pool was advertising fifteen percent annual yield. I thought - okay, I'll let it ride for a year, take the fifteen percent, that's twelve hundred dollars for doing nothing."

"And?"

"After a year, the pool had paid me about seven hundred dollars in fees. So I figured, great. I withdrew. And when the money came back to my wallet, it was -" he held up his hands as if measuring something - "about a thousand dollars short of what I would have had if I'd just held the ETH and the USDC separately."

"Even after the fees?"

"Even after the fees. So I made seven hundred in fees and lost a thousand in something I couldn't see. Which means I paid three hundred dollars to provide liquidity, on top of giving up the upside I would have had if I'd just done nothing."

I looked at Moolah. "Explain."

She set her latte down. She was, I thought, taking some quiet pleasure in this - not in Dev's loss, but in the fact that he was finally telling the story properly.

"Dev encountered the most-misunderstood concept in DeFi. It's called impermanent loss, which is a terrible name, because the loss is often quite permanent. Let me show you what happens."

She turned to face me.

"Picture a lemonade stand. You set it up with two things - a basket of lemons, and a stack of dollar bills as float for change. The price of lemons is one dollar each. So you start with, say, a hundred lemons and a hundred dollars. Two hundred dollars of total stuff. Are you with me?"

"Yes."

"Now: people come and trade with the stand. Some buy lemons with dollars. Some sell lemons for dollars. The stand has a rule - every trade has to keep the total value balanced between the two sides. If someone buys a lemon, the lemon basket has fewer lemons; the cash drawer has more dollars. The stand automatically rebalances. So far, so good."

"Yes."

"Now suppose, while you're running the stand, lemons become very popular. Their price doubles. A lemon now costs two dollars on the open market. Everyone outside your stand is paying two dollars per lemon. But your stand, because of how the buckets balance, doesn't know this. People come to your stand and trade with it until your lemon price catches up to two dollars. The way they do that - the only way - is by taking lemons out of your basket and leaving dollars in the drawer."

"So my basket runs out of lemons."

"Not quite. Your basket has fewer lemons than it started with. Your drawer has more dollars. The total value of the stand is still - by design - balanced. But the mix has shifted. You started the day with a hundred lemons and a hundred dollars. By the end of the rally, you have, let's say, seventy lemons and a hundred and forty dollars."

"And what's that worth?"

"The hundred and forty dollars in the drawer, plus seventy lemons at two dollars each - that's a hundred and forty more. Two hundred and eighty dollars total. The stand grew. So that's good, right?"

"I think so."

"Now compare it to what would have happened if you had just held a hundred lemons and a hundred dollars without running the stand at all. The lemons doubled. So a hundred lemons, at two dollars each, is two hundred. Plus your hundred dollars in cash. That's three hundred dollars."

The math hit me in the chest.

"By running the stand," I said slowly, "I had two hundred and eighty dollars. By doing nothing, I would have had three hundred. I lost twenty dollars by running the stand."

"That," Moolah said, "is impermanent loss. The pool gave you the trades and the fees, but it took something from you in exchange - it took your upside on the asset that went up. Because every time someone wanted to buy lemons from you, the pool had to sell them. You were forced to sell into the rally. You were forced, by the rule of the buckets, to give away your appreciating asset to anyone who wanted it."

"But Dev made fees."

"He did. And if the fees outpace the loss, the LP wins. But the fees on his pool didn't outpace the loss. He was, in essence, paying the world to take ether off his hands during a period when ether was getting more valuable."

Dev was looking at the pond. "And when one of them goes down instead of up, the math runs the other way. The pool forces you to buy the falling asset. So you end up holding more of whatever's losing value. The buckets never let you ride a trend. They drag you back to fifty-fifty, no matter what's happening in the world outside."

"Why is it called impermanent?"

"Because if the price returns to where it started - exactly where it started - the loss disappears. The buckets rebalance back to the original mix and you've earned only the fees. So technically, the loss only crystallizes when you withdraw, or when prices stay moved. In practice, prices rarely return exactly to where they started, so the loss is real almost every time."

"Then who should provide liquidity?"

"Three kinds of people. First, professionals who model it carefully and only enter pools where they expect the fees to outpace the divergence. Second, people who are providing liquidity on two assets they expect to move together - two stablecoins, for example, where the divergence is structurally tiny. Third, people who don't understand the math, who see the advertised yield and not the cost. There are a great many of those." She glanced sideways at Dev. "We forgive them. They're learning."

"Including me," Dev said.

"Including you."

I was scribbling fast. The lemonade stand was becoming a small picture in the margin of my notebook, with arrows showing what happened to lemons and dollars during a rally.

"There's one more thing I want you to understand," Moolah said. "Liquidity pools are necessary. The whole DEX system we talked about last week only works because somebody filled the buckets. Without LPs, there are no swaps. Without swaps, there is no DeFi. They're providing a real service. They're paid for it. The question isn't whether the pools are bad, because they're essential. The question is whether the fees they earn justify the divergence loss for any given pair of assets in any given market. That math is harder than it looks, and most people who try it lose. That's the lesson."

I wrote it down. Liquidity pools are necessary. Impermanent loss is the price of being a market maker. Fees may or may not cover it. Mostly they don't, for amateurs.

The wind came up off the pond. Dev shivered. Moolah produced - from somewhere - a small piece of melonpan, broke it in half, and gave one half to him without commentary.

He took it. He ate it.

It was, I noticed, the first thing I had ever seen him eat in front of Moolah.

"Same bench next week?" I said.

"Same bench."

We walked home in the cold. Dev didn't say anything for a while. Then, somewhere near the station, he said: "Thanks for letting me tell that."

"Anytime."

"It's easier to say it once it's a story. While you're losing the money it just feels like math."

"I think," I said, "that's why she had you tell it."