Yield farming is a way for people to generate passive income by providing liquidity, i.e. cryptocurrency deposits, to DeFi liquidity pools or staking pools. In short, users lock up their money into a participating DeFi app, and in exchange for this service the project automatically pays these “yield farmers” in crypto rewards over time.
These rewards are paid out in the form of governance tokens, which DeFi projects use as equity-like instruments to facilitate community governance, and sometimes fees, like the trading fees earned by all liquidity providers (LPs) on decentralized exchanges like Sushi and Curve.
Notably, DeFi projects incentivize yield farms to bootstrap themselves by winning over LPs. These projects need to attract liquidity in an increasingly crowded DeFi ecosystem in order to grow and actualize, which is why yield farming is synonymous with liquidity mining.
In other words, a DeFi team runs a liquidity mining program to incentivize LPs to bring their capital over, and LPs do so to “farm” these programs by “planting” their crypto deposits into incentivized pools. The ensuing yield harvests are token rewards and/or fees!
Brief history of yield farming
Synthetix, the on-chain synthetic assets protocol, pioneered yield farming in July 2019 when it started awarding its SNX governance token to LPs for the project’s sETH/ETH liquidity pool on Uniswap V1.
One year later lending protocol Compound Finance kicked off the contemporary yield farming phenomenon when it announced the launch of its liquidity mining program centered around its COMP governance token. The program, which remains ongoing, awards COMP tokens to Compound’s borrowers and lenders in accordance with these users’ activity levels.
Compound’s rollout of COMP yield farms catalyzed a surge of interest in liquidity mining, with this interest having ramped up ever since as these types of passive income opportunities have started appearing routinely all over DeFi. Indeed, yield farms are now the primary means for upstart DeFi projects to bootstrap their projects with liquidity.
How does yield farming work?
There are two main styles of yield farming opportunities: LP farms and staking farms.
Fundamentally, both of these farming opportunities entail users depositing cryptocurrency into smart contracts. The differentiating factor is the type of smart contract involved.
In an LP farm, a user deposits crypto into a smart contract that programmably facilitates a liquidity pool. Such a pool functions as a decentralized trading pair between two, or sometimes more, cryptocurrencies, and the trading is made possible by the crypto supplied by LPs.
In exchange for deposits, DeFi apps reward LPs with what are called LP tokens — e.g. SLP tokens for Sushi liquidity providers. These tokens can be used to retrieve your underlying deposits from the liquidity pool at any time plus any interest you’ve accrued by way of trading fees.
These LP tokens are important, because DeFi apps that run liquidity mining programs set up “staking” interfaces for depositing these LP tokens. This locks in your liquidity and automatically and continuously earns you governance token rewards for as long as your LP tokens are staked.
In a stake farm, users deposit crypto into a smart contract that programmably facilitates a staking pool. Rather than being a decentralized trading pair, a staking pool is akin to a decentralized vault for a single kind of asset. It doesn’t facilitate trades but rather secures deposits.
These farms provide an easier experience for people compared to LP farms. That’s because stake farms only require users to deposit a single asset to earn passive income in contrast to serving as an LP on a DEX and thereafter staking LP tokens, too.
For example, Alchemix, a protocol for tokenizing future yields, launched with a staking farm for its governance token ALCX. The idea? You supply ALCX to that staking pool to earn more ALCX. This incentives users to support the ALCX price via holding, and it helps Alchemix distribute its native token to its community of users.
Other kinds of yield farming
When people say yield farming, they’re most often referring to the practice of LPing or staking your crypto to receive passive income. Yet as an increasingly large range of DeFi projects have launched liquidity mining programs, we’ve also begun to see other types of participatory DeFi activities get incentivized with governance tokens.
Arbitrage mining refers to yield farms that specifically incentivize arbitrageurs, i.e. traders who capitalize on market inefficiencies across DeFi. For instance, decentralized liquidity underwriter KeeperDAO was the first DeFi project to roll out an arbitrage mining program. Arbitrageurs, known as “Keepers” in KeeperDAO’s verbiage, earn the project’s ROOK governance token for trading through the protocol amid its rewards campaign.
Insurance mining refers to yield farms that reward users who deposit assets into decentralized insurance funds.
These funds are risky, since successful insurance claims will be paid out against them. In exchange for putting funds on the line to help projects from going underwater, such depositors are awarded governance tokens. An example of this system is the Liquity Stability Pool. People supply the LUSD stablecoin to the pool as a backstop for Liquity’s lending protocol, and they earn the project’s LQTY tokens for doing so.
Trading mining is similar to arbitrage mining, except you only have to undertake simple trades to earn token rewards rather than conduct arbitrage strategies. One early adherent to this type of yield farming campaign is Integral, a hybrid orderbook/AMM decentralized exchange. Since the project launched in March 2021, it’s awarded ITGR governance tokens to traders who have used its incentivized pools.
Fuel for yield aggregators
Yield farming has given rise to yield aggregators, which are decentralized protocols that deploy users’ deposits across multiple top DeFi yield farms. The result? Depositors can earn optimized yields in automated and auto-compounding fashion.
This is made possible courtesy of the “vault” system used by yield aggregators. These smart contract vaults are specialized around a goal, e.g. accumulating depositors the most ETH possible.
In such a vault, users’ deposits are deployed across performant yield farms according to strategies devised by an aggregator’s yield strategists. For example, the aforementioned “accumulate-ETH” vault could deploy crypto deposits into Compound to farm COMP and then dump this COMP for ETH on a continuous basis, with the ensuing ETH earnings going back to depositors.
What is TVL?
TVL stands for “total value locked.” In the context of yield farming, TVL is used to indicate the amount of crypto that has been deposited into a yield farm’s underlying liquidity pools or staking pools.
Accordingly, people in DeFi use TVL similarly to how the assets under management (AUM) metric is used in traditional finance. If you see that a particular yield farm has a $500 million TVL, that means there’s currently $500 million deposited into that farm.
Understanding APY vs. APR
In the DeFi ecosystem, projects use annual percentage rate (APR) or annual percentage rate (APY) calculations to show users how much interest they earn on their deposits into yield farms.
APR simply tracks how much interest a depositor will earn on their crypto over the course of a year. If a yield farm consistently offers 5% APR and you supply $100 to it, after one year you’ll have $105.
On the other hand, APY tracks how much a deposit will earn in a yield farm over the course of the year if its interest earnings are reinvested continuously in the yield farm along the way.
Whether a project uses APR or APY to track its yield opportunities, keep in mind that yield farms’ earnings fluctuate constantly per changes in participants, token distribution schedules, and trading fees. In this sense, think of a yield farm’s APR or APY as just a snapshot of current yield performance rather than a static interest rate.
The pros and cons of yield farming
Yield farming has its share of benefits and risks. For DeFi farmers, the main advantages and disadvantages are as follows.
- Lets people easily earn passive income on crypto.
- Offers a range of opportunities, from conservative low-yield farms to aggressive high-yield farms.
- Gives users the ability to participate in DeFi protocol decisions via governance token rewards.
- Helps users gain DeFi literacy, which builds a base layer of skills that will help people master future DeFi innovations.
- Can be vulnerable to economic attacks or software exploits, depending on the project.
- Can be vulnerable to “rug pulls,” in which a liquidity pool creator (typically a rogue admin or admins) drains most of the ETH from their liquidity pool
- Depositing funds into farms means you won’t enjoy immediate access to that liquidity until you’ve unstaked your underlying crypto.
- Some projects use token vesting schedules, so in those cases you won’t be able to access your farmed token rewards until weeks, months, or sometimes years in the future.
The future of yield farming
As DeFi and yield farming continue to grow more popular, users will gravitate toward opportunities where they can transact affordably and quickly.
In the Ethereum ecosystem, a handful of layer-two (L2) scaling solutions like Arbitrum, Optimism, and zkSync are currently coming of age and are offering such ultra-cheap, ultra-fast transactions. These L2s, which inherit their security directly from Ethereum and denominate fees in ETH, will become hubs for yield farming because of their powerful scaling capabilities.
Moreover, alternative scaling solutions like the Polygon sidechain, which explicitly caters to Ethereum users, will remain prominent as more DeFi users start yield farming across multiple chains and L2s.