How to yield farm?
Yield farming is an umbrella term that describes the act of finding yield in the DeFi space. In this web3 guide, we'll cover what is yield farming and an example.
Yield farming is an umbrella term that describes the act of finding yield in the DeFi space. In this web3 guide, we'll cover what is yield farming and an example.
By Alan
Yield farming is an umbrella term that describes the act of finding yield in the DeFi space.
As users explore the DeFi space, some will begin to craft strategies to achieve a higher yield on their assets. We call this Yield Farming.
In this guide, we’ll cover:
What follows is not investment advice.
Yield farming doesn’t refer to a specific process but rather the overall idea of seeking out returns through some combination of staking, lending, and borrowing. These strategies give “farmers” additional return. The opportunity for high rewards comes with risks.
The simplest way to yield farm is by using yield aggregators, such as Yearn, which will do the behind-the-scenes work for you. You can deposit a variety of assets into Yearn and they will use strategies to earn yield passively.
If you are interested in a more active strategy, you’ll be able to choose your own path to balance risk and reward. DeFi users are not locked into one protocol. This enables users to create a yield strategy across different protocols. We will walk through examples of yield farming strategies, as well as the risks.
Yield Farming is a more advanced topic within DeFi. Let’s review a few terms:
A common type of yield farming is when liquidity providers are incentivized to add liquidity to a platform. Let’s explore a simple example:
Odyssey wants to launch a token $ODY. Users can go to a DEX like Sushiswap and add $ODY and ETH to a liquidity pool. If this is a new token, volatility will likely be high, leading to higher risk.
If Odyssey can’t increase liquidity, then its token won't be usable in the market. Odyssey wants to offset the risk for LPs and puts up a reward of 100,000 $ODY/day for 20 days. This reward is split between liquidity providers. Initially, if it is only a few providers, they will each get a large reward.
Savvy yield farmers will see this high return and will add liquidity to get a slice of those rewards. This will increase the liquidity of $ODY. It may not be sustainable, as the rewards are limited. LPs are not locked in, so if they find better rewards elsewhere, they can sell their tokens and move on any time.
This is referred to as liquidity mining. In addition to protocols offering rewards on certain pools, DEXs can offer rewards in their native token to attract capital to their platform. On SushiSwap, you will see pools paying out rewards of the Sushi token.
Protocols adding incentives in their native token is not exclusive to DEXs. Lending and borrowing platforms use a similar incentive. Compound pays out their native $COMP token to depositors and borrowers to incentivize users.
These strategies mentioned above are simple versions of yield farming, some folks choose to increase the complexity to achieve a higher return. Let’s see an example.
We will build on the example mentioned in the article: How to lend and borrow assets?
In that example, we deposited 10 DAI on Aave Polygon and borrowed 2.5 MATIC. Instead of simply holding the Matic, let’s see how we can earn additional yield on it.
1. Add borrowed Matic to SushiSwap Farm
We head to SushiSwap and see a MATIC and ETH farm with an APY of over 14%. The term “farm” means a liquidity pool where you can stake your LP tokens to earn additional rewards. The fields below are TVL, farm rewards, and APY.
The farm rewards column shows additional incentives to staking your LP tokens beyond the trading fees. In this farm, a daily reward of 725.2 Sushi and 12.09 Matic is split between all “farmers” who stake LP tokens.
First we will swap half of our MATIC tokens (1.25 MATIC) into WETH as seen below.
Then will will take the equal amounts of MATIC and WETH and deposit it into the liquidity pool.
Once we confirm adding liquidity, we will be prompted in our wallet to confirm the transaction and gas fee. We will then recieve SLP, which are the tokens representing our portion of the liquidity pool.
The final step is staking our SLP tokens as seen above. This will enable us to earn the farm rewards of Sushi and MATIC.
In this yield farming example, we have earned yield in the following ways:
Our costs for this example are:
This example shows the portability in DeFi. We can use multiple protocols and tokens to find additional yield, but it is not without risk.
The more protocols and smart contracts you interact with, the more risk you take on.
Yield farming risks include:
Yield farming is a delicate act of balancing risk versus return on your capital. It is important to understand the risks associated with advanced strategies and leverage. Proceed carefully!
Up next: How to avoid getting rekt in DeFi?