What is yield farming?

TL:DR. It’s like depositing your assets in a bank where you earn interest. In the world of Crypto it works much the same, you deposit your assets and earn other tokens back in return. Different types of yield farming are available, and it involves different levels of risk. 

Purpose of yield farming

As explained, yield farming sees users depositing their assets, then receiving back protocol tokens in return as rewardIt is considered one of the major methods of distributing tokens to users, outside of private token sales. When a project protocol is considering the tokenomics, they need to send those tokens to community members that really care and have a passion for the protocols. Those users then become members of a DAO to vote about changes of protocol design or to share the protocol revenue. Protocol tokens can also be called governance tokens, where the valuation is sometimes subjective and speculative. There is absolutely no guarantee regarding how much a token is valued or how it will be valued.

Mind map of a yield farming

Yield farming pool types

There are three types of yield farming that can typically be observed: 

  • Single token yield farming
  • Liquidity pair yield farming
  • Pool2 yield farming.

The main difference of those three are risks versus rewards. If you take more risks, you will typically be rewarded with more tokens (Higher APY usually). Be reminded, you are getting tokens, and the token value is actually volatile and speculative in nature itself.

Single token yield farming. You can deposit single tokens to farm “protocol tokens”. The most common tokens that are accepted as “base tokens” for “reward tokens” are typically the most "valued" tokens such as: BTC, ETH, USDT, USDC, BNB, MATIC, and SOL. Most times the purpose for this type of yield farming is to get more exposure and boost TVL.

Liquidity pair. This usually includes BTC+stablecoins, ETH+stablecoins, BNB+Stablecoins, or similar combination. The purpose here to is to boost TVL.

Pool2 yield farming. This is a pool that is paired with a “reward token” and “base token”(like ETH + stable coins). It usually gives the highest “protocol token” as rewards but you put yourself at greater risk of impermanent loss. The purpose of Pool2 is usually to get liquidity in the AMM so people can trade with larger orders and minimal price impact. A healthy ratio for the liquidity pair is essential to ensure a lesser price impact.

Illustration of different type of liquidity pool

Benefits of yield farming

First we need to know what makes yield farming possible by explaining AMM (Automated Market Maker). On the contrary to AMM, traditional finance uses order book design to facilitate a trade, where a trade is only possible when a “sell order” matches a “buy order” in both the price and quantity. Unlike order book design, you can always make a trade if there is liquidity available in the pool (reserve) for the AMM.

In AMM, a liquidity pair needs to be created as a pool (reserve). The pool includes for example token "A" and token "B" where they share the same ratio value of a pool (50:50). The illustration below indicates “100 Token "A” will have the same value as 10 Token "B” in the reserve. When you want to get "B" tokens, you need to use "A" tokens in exchange of "B" tokens. Meanwhile the pool ratio still remains the same at 50:50. Since the liquidity pool (reserve) is always there, you can always make a trade. Once a token can be traded freely in the market, people can start to get financial benefits by selling their tokens to the ones who are investing in the protocol. Keep in mind this is a simplified explanation of AMMs but it will help give you a better overview of their function and basic purpose.

An example of AMM design (source: Uniswap)

You can refer more detail on the Uniswap website here.

As protocolsthere are benefits of yield farming events, which is due to the design of the AMM. There will be a liquidity pool for the protocol that everybody can trade in the market. Unlike orderbook design in Centralized Exchanges or traditional Finance, most DeFi DEX's use an AMM (pioneered by Uniswap) to facilitate token swapping (trading).

As community, there are benefits too. Community members can get high APY/APR% (intertest) based on their investment in yield farming, which is based on token standards. It means the dollar value could be potentially unlimited on both the upside and downside. Additional reward tokens could be used for yield farming as well (like Pool2 farming), therefore it creates new possibilities. Participation in a DAO model to make proposals and to vote on proposals, revenue shares, etc. are all made possible.

Risks of Yield Farming

“Protocol tokens” might bring you gains but have much higher possibilities to bring you unlimited downside if you happen to have not chosen your investment wisely, or possibly affected by factors outside of your control (project abandonment, etc.). There are at least three risks besides the “protocol token” price variations.

Impermanent loss is occurs when your token price of “adding liquidity pair” and “removing liquidity pair” is different in the relative ratio. We won’t go to the full details here, but for example you may gain reward tokens when providing liquidity then losing the liquidity pair (LP) value if the ratio of your “entry price LP” and “exit price LP” is different. This is especially serious when you invest in Pool2, since the “protocol tokens” (reward tokens) price is very volatile during the TGE (Token genesis event). If your “protocol token” price plummets, it is very likely all your Pool2 liquidity becomes useless. If your LP Token "A" and Token "B" rise or fall in the same direction with the same ratio, there is no impermanent Loss. Please read the detailed article from Binance Academy for further details as it's a key component in DeFi farming. You can use the impermanent loss calculator and try different factors to get a feel for what it looks like and to make sure you understand it.

Illustration of Impermanent Lost

A "Rug pull" in the crypto space means that the project you invested in has essentially ended by the team itself either deliberately or surprisingly. Website, Discord, Twitter, Telegram Groups, all gone with a click. Most times the team plans to steal your investment from the inception, so they make the Dapp (or not), Whitepaper, Discord, Twitter, Telegram and everything and fill them with fake members and followers to give the illusion of a hyped up project, however there is no intention to actually launch the project at all, or run it long term. Most times investors will lose everything they had invested and there is no way to get it back. In other cases, they are sometimes able to obtain a small fraction of their initial investment back before the liquidity is drained and trading halted. Fortunately, there are some crypto communities that have shown their expertise and interest in pursuing available legal actions in cases where identity is known

Exploit- meaning there is usually a flaw in the smart contract that a hacker or malicious user can then use as a loophole to get assets which are stored on chain (through smart-contract interactions). It could be as simple as transferring assets from the protocol to the hacker’s wallet, or a more in-depth economic attack where a hacker dumps all tokens he got from the smart contract flaw. (So your holding value decrease)

Yield farming protocols

There are two kinds of options when participating in yield farming of a protocol. First, you can manually harvest your reward and sell it for profit (stable coins or other coins). Secondly, you can sell it into the same token as you deposited, and do yield farming with more deposited tokens. You will need to manually harvest/invest daily or regularly which is time consuming but can be negated by the lucrative APY. There are also several protocols that provide services of yield farming for you.

Instead of manual harvesting/investing, some yield farming protocols do the hard work for you automatically with a bit of a twist. We define different types of yield farming protocol into categories such as:

  • Optimal strategy
  • Auto compound
  • Leverage compound

Protocols usually charge what is called a "performance fee" which is a percentage based fee from your gained profit. This could range between 3.4% to 20% depending on the protocol. Two benefits of these protocols include automatic compounding and also some cost savings from gas fees seen in manual claims (since funds are pooled together). There is however, some additional smart contract risk associated with these platforms. If you choose a prestigious and highly secure platform, those risks will be minimized.

Optimal strategy type (Such as ETH based protocols Yearn and Convex)

Just like the bank deposit example we made earlier, users will choose the "bank" with the best interest rates (meaning rewards) or reputation (meaning trust) to deposit into. The same scenario applies to the crypto space. Users tend to seek a balance between risk and reward. Yearn as an example, is the pioneer for this type of protocol and leads to the incredible DeFi Summer in 2020. You could choose which vault to deposit in Yearn, and Yearn has different strategies in each vault that brings users the optimal yield automatically. Some strategies will involve lending, minting, and farming while some might be designed specifically for Curve.fi. You can find more details on YFI document and their Medium articles. On the other hand, Convex is designed specifically for Curve.Fi which optimizes the returns based on the mechanism of Curve.fi.

Yearn website

Auto compound (Such as BSC based protocol Autofarm)

This kind of protocol simply performs the harvest/compound task on behalf of users. You do not have to do the "heavy lifting" and the protocol will perform tasks regularly for users. There are similar protocols on each blockchain, or like Autofarm, support multiple chains. The key to finding the best auto-compound protocol for you is to check the necessary protocol fees, and to find ones with the best reputation. Try them out for yourself to see which user interface works best for you. Some protocols provide portfolio management tools and additional on-chain analysis data for users, while some focus on bringing other options to users.

Autofarm user interface and vaults

Leverage Compound (Such as BSC protocol Alpaca or ETH/BSC protocol Alpha)

Leverage compound protocol is an automatic compound yield farming protocol which integrates lending into the protocol. Alpaca and Alpha have their own native lending protocol that allow users to deposit their single assets (such as BTC, ETH, BNB, or other supported tokens). The lenders (you) will get “protocol tokens” as incentives in addition to the lending APR (which is paid by the borrower). Unlike other lending protocols (i.e. AAVE) which users can borrow assets, the liquidity in the lending pool can only be borrowed by "farmers" within the platform.

Farmers will then be able to farm their own capital with additional borrowed assets to farm/generate a high return. For example, you can use 100 $USDC out of your pocket and borrow an additional 200$USDC from the protocol to farm on a total capital worth 300 $USDC. Naturally, your $300 farming position will bring you more profits than your $100 position. When you close your position, you will pay back the loan (with interest/fees) to the lending pool at the same time.

Alpaca and Alpha finance

Leverage compound yield farming is a much more complex concept since you are borrowing and leveraging at the same time. If you farm with more than 2x leverage, your position will be partially “long” and partially “short” depending on your leverage token selection. All leverage yield farming protocols provide comprehensive guidelines to help users, but it can still be an advanced topic for some. If you didn’t keep a healthy safety buffer of your position, you will be liquidated and lose part of your capital, so it's important to understand the risks as well as the benefits.

Where did your yield come from?

The most common question asked is where did the yield you receive from farming actually come from? The first question to be answered is that DeFi yields usually come from (1) demand from leverage (2) Reward tokens and (3) Trading fee shares.

Reward tokens are often the most challenging.

When we talk about the benefit of yield farming, we explained that in the AMM design, people can trade as long as there is a liquidity pair (if slippage is ignored). In Pool2, KYC Finance as an example, provides most of $KYC as rewards to the Pool2 liquidity pair, i.e. $KYC+$BNB pair. When the liquidity pair is added, the community can swap their $KYC into $BNB. Three things will happen:

  • There will be more $KYC and less $BNB in the pool
  • User “sell” their $KYC into $BNB that drives down $KYC price and pushes up $BNB price
  • $BNB can be swapped to other tokens since $BNB is paired into liquidity pools with almost all tokens (includes stable coins)

When 90% of the community members sell their $KYC tokens, the $KYC tokens become worthless, therefore, people who still have Pool2 liquidity will be owning much more $KYC than $BNB to maintain the 50:50 value. If we deposit a $KYC+$BNB into Pool2 (and still in), we will get only a few $BNB back with a chunk of $KYC when we remove liquidity. We will be the ones that are contributing to your yield in the above example as our $BNB becomes yours.

Conclusion

Yield farming is a must-learn lesson in DeFi. Those protocol tokens were usually governance tokens with value, and it also depends on what kind of problems those protocols solve. A protocol that really solves a pain point and has real utility can be really valuable, while it is sometimes hard for "fork type" projects to survive in the long term. We recommend you to really understand and use these protocols before you invest. As the age-old saying goes, never invest more than you're willing to say goodbye to.


Note 1: Some protocols provide options rather than 50:50 ratios for LP


Author: Grayson

Editor: Crypto MJ

Join

advertise

DISCLAIMER: The information presented here is for educational purposes only and is not financial advice. Always investigate crypto projects fully and never invest more than you are willing to lose. The DeFi District is not responsible for the accuracy or reliability of information presented. Projects presented on the daily launch list are not to be considered vetted or approved by The DeFi District.