Published in


DeFi Pooling

Bringing Scalability to Existing L1 Projects


  • DeFi’s original values were about financial inclusion and open access. As gas price rises, DeFi is turning into a whale game.


DeFi aims to improve financial inclusion thanks to its composability and permissionless nature. Nevertheless, when gas is too expensive, only whales can participate.

If we want DeFi to remain inclusive and reach the next 10M users, we need to address the scalability problem, in order to allow transaction costs to remain low.

We’ve already seen a movement toward scalability in the context of Yield Optimizer. Projects like YFI and Harvest enable smaller traders to participate in advanced and more expensive trading strategies. Let’s consider the YFI USDt Curve Strategy for example.

As a regular trader, optimizing the yield of lending on Curve is rather complex. One needs to deposit into a specific pool, stake their LP tokens into the Curve gauge, define its lockup to increase its CRV rewards, and vote on-chain to select the reward proportion allocated to their pool.

With YFI, all the above is abstracted away. One simple deposit into the YFI USDt yVault, and the protocol takes care of the rest. In exchange, the protocol charges a 20% management fee on profits.

For most traders, this 20% fee is cheaper than the hassle and transaction cost of implementing this strategy independently.

In addition, by pooling YFI customers’ voting rights, YFI behaves like an investment fund and influences Curve to benefit all YFI stakeholders: traders and token holders alike.

Nevertheless, YFI is not optimal gas-wise as depositing and withdrawing from the pool, as well as rebalancing funds, remain L1 operations. As such, these operations are often prohibitively expensive.

Defi Pooling fixes this by bringing these operations — depositing, withdrawing, and rebalancing, into a scalable and low-cost L2!

What is DeFi Pooling?

This new mechanism enables users to trade from the comfort of their L2 account, gas-free: they can lend money on Aave and Compound, invest in YFI or Harvest, or become an LP on Uniswap, Balancer, or Curve.

A Stepwise Flow

Let’s take one simple DeFi operation: Investing in the USDt yVault.

The participants are:

Traders/Users/End Users
Alice, Bob, and Carol are traders with funds on L2

An Operator, and the StarkEx System that powers their service


  • The DeFi destination (E.g. yUSDt Vault)

In the example above, Alice and Bob want to deposit to YFI and Carole wants to withdraw from YFI. Alice and Bob can be matched against Carole, and only the difference is transacted on-chain.

From Alice and Bob’s perspective, DeFi Pooling is a two-step operation. They:

  1. Swap their USDt against shares (e.g syUSDt) that the StarkEx Operator minted from the Broker Pool.

Step I: Demand Aggregation

  1. Broker mints Pool shares (e.g syUSDt)

Step II: Pool Activation

  1. Broker withdraws the pool’s funds from the StarkEx smart contract.

Step III: L2 Traders Receive Their LP Tokens

  1. L2 Traders swap shares (e.g. syUSDt) for LP tokens (e.g. yUSDt).

Step IV: Rebalancing — The Cherry on Top

As one may have noticed, a strategy is represented off-chain as a token. Rebalancing, for example from yUSDt to yETH, is as simple as finding another trader to swap with, all conducted in a gas-free environment.

What’s Missing? L1 Limit Orders

What is missing to support DeFi Pooling on StarkEx? Limit orders on L1. StarkEx has three native operations: Transfer, Conditional Transfer, and (L2) Limit Order. In the upcoming StarkEx V3, we will support L1 Limit Order, enabling smart contracts on L1 to submit a trade on L2. This is the missing piece to support DeFi Pooling.


To bring back DeFi’s primary goal of financial inclusion, we need to offer massive scale and lower gas costs. DeFi Pooling is such a solution. It is the DeFi equivalent of taking a commercial flight instead of a private jet. If DeFi wants to scale to the next 10M traders, this is the way to go.

Louis Guthmann