What Is Yield Farming?

Learn what yield farming is in DeFi, how it works, where the yield comes from, why APYs vary, and the main risks behind lending and LP strategies.

Sara ToshiMar 21, 2026
Summarize this blog post with:
What Is Yield Farming? hero image

Introduction

yield farming is the practice of moving crypto assets into DeFi protocols to earn returns, usually by supplying liquidity, lending assets, or combining several protocols into a strategy that increases those rewards. It became important because DeFi made financial contracts programmable: instead of just holding a token, a user could deposit it into a smart contract and have that contract route the asset into markets that pay for liquidity, borrowing capacity, or participation. The result is not magic income. It is payment for doing something economically useful in a protocol, or for taking a risk that the protocol wants someone to bear.

That distinction is the key to understanding yield farming. The puzzle is that many farms advertise a single number (APR or APY) as if "yield" were one thing. In practice, that number often combines very different sources of return. Some of it may come from borrowers paying interest. Some may come from traders paying swap fees to liquidity providers. Some may come from the protocol issuing its own token to attract deposits, a mechanism usually called liquidity mining. These sources look similar on a dashboard, but they are not equally durable.

So the right first question is not "What APY does this farm show?" It is who is paying this yield, why are they paying it, and what has to remain true for that payment to continue? Once that clicks, yield farming stops looking like a mysterious crypto trick and starts looking like an on-chain market for capital, liquidity, and risk.

Is yield farming a product or an allocation strategy?

At a first-principles level, yield farming solves a coordination problem. DeFi protocols need capital in the right place at the right time. A lending market needs deposits so borrowers can borrow. An automated market maker needs token reserves so traders can swap without waiting for a counterparty. A new protocol may need early liquidity before it can become useful at all. Users, meanwhile, have idle assets and want compensation for making those assets available. Yield farming is the activity of allocating those assets to whichever on-chain venue pays the best risk-adjusted return.

That is why farming is better understood as a strategy than as a product. A savings account is a product. A farm is often a changing position spread across products. Someone might deposit USDC into a lending protocol, receive an interest-bearing claim token, post that claim token into another vault, and harvest governance-token rewards on top. Or they might provide ETH and USDC to a trading Pool, earn trading fees, and then stake the LP receipt token somewhere else to collect incentive emissions. The common structure is not the interface; it is the search for return across composable contracts.

This also explains why yield farming sits close to, but is not identical with, ordinary yield in DeFi. Yield is the return itself. Yield farming is the active behavior of seeking, comparing, and often rotating among sources of yield. The difference matters because a passive lender and an active farmer may touch the same protocol but have very different goals. The passive lender wants simple exposure to interest. The farmer is often optimizing a moving bundle of interest, fees, token rewards, leverage, and reinvestment.

Where does DeFi yield come from (fees, borrowing, or token emissions)?

SourceWho paysDurabilityMain riskBest for
Borrowing demandBorrowers pay interestDurable if demand persistsUtilization sensitivityLenders seeking steady yield
Trading feesTraders pay swap feesDurable with volumeImpermanent/divergence lossActive fee-seeking LPs
Liquidity miningProtocol mints tokensTime-limited and fragileToken price collapse riskBootstrapping new protocols
Figure 218.1: Sources of yield in farming

To evaluate a farm, it helps to separate the return into its underlying cash-flow logic. Research on DeFi yield aggregators usefully frames the main sources of yield as borrowing demand, liquidity mining, and revenue sharing such as fees. That organizing principle is more useful than any list of platforms, because the platform is just the container; the source of payment is the mechanism.

When yield comes from borrowing demand, the mechanism is familiar. Depositors supply assets to a lending market. Borrowers pay interest to access those assets, and depositors earn a portion of that interest. In a protocol like Compound, the pool exists because borrowers want capital without asking permission, and lenders are willing to make capital available if the rate compensates them. This is the cleanest source of yield because it corresponds to real demand for borrowing. If fewer people want to borrow, the yield falls. The important point is that the return depends on utilization and borrower demand, not on promotional spending by the protocol.

When yield comes from trading fees, the mechanism changes. In an AMM such as Uniswap or Curve, users deposit token pairs into a pool that traders use for swaps. Every trade pays a fee, and that fee is distributed to liquidity providers according to the pool’s accounting rules. Here the economic service is not lending but making inventory available for trade. The yield depends on trading volume, fee tier, and how the AMM design allocates fee income among liquidity providers. A pool with heavy trading can generate meaningful fees even without token subsidies. But fee income is not pure gain: it comes bundled with price exposure and, often, impermanent or divergence loss.

When yield comes from liquidity mining, the protocol itself is paying. Instead of users paying interest or traders paying fees, the protocol mints or distributes a native token to attract capital. Compound’s COMP incentives became the canonical example: supplying or borrowing in the protocol could earn COMP, and because COMP also carried governance rights, the token had both market value and political value inside the protocol. This was powerful because it let a protocol bootstrap liquidity quickly. It was also fragile because the displayed yield then depended on the market continuing to value the reward token.

These sources can stack. A single position may earn lending interest, plus trading fees somewhere else, plus governance-token emissions on top. That stacking is why DeFi dashboards sometimes show spectacular numbers. But stacking does not eliminate the need to ask where each layer comes from. It just hides the answer behind aggregation.

How is a yield farm constructed from lending, LPs, and staking?

Imagine a user holding USDC who wants more than idle exposure. They deposit the USDC into a lending market. That first step makes the asset available to borrowers, so the user begins earning interest funded by borrowing demand. If the protocol also runs a token incentive program, the deposit may additionally earn a governance token. Already there are two distinct revenue streams: one from users of the market, one from the protocol’s own subsidy budget.

Now imagine the user takes a different route. Instead of lending, they pair USDC with ETH and provide both to an AMM pool. Their capital now performs a different job: it becomes standing inventory for traders. As traders swap between ETH and USDC, the pool charges fees, and the liquidity provider earns a share. If the protocol wants more depth in that pair, it may also distribute incentive tokens to LPs. So again, two streams may appear together, but now the first is fee income rather than lending interest.

A more aggressive farmer may then stake the LP receipt token in another contract that auto-harvests rewards and reinvests them. Research on yield aggregators describes this as a recurring workflow: funds enter a pool, a strategy may borrow or collateralize if leverage is involved, the strategy deploys capital into yield-producing venues, and then rewards are harvested and often reinvested. The reinvestment step matters because it turns simple yield into compounding yield. The mechanism is straightforward: harvested rewards are sold or redeployed into more principal, which then earns the next round of returns.

Nothing in that story required a centralized manager to move the money. Smart contracts did the routing, accounting, and distribution. That is the genuine novelty of yield farming: not that yield exists, but that users can compose multiple open financial primitives into automated strategies.

What are the common yield‑farming strategy types (lending, leverage, LP)?

StrategyComplexityReturn driverMain riskBest for
Simple lendingLowInterest from borrowersCounterparty and protocol riskPassive income seekers
Leveraged borrowingHighAmplified emissions and interestLiquidation and reflexivityYield hunters seeking boost
Liquidity provisionMediumTrading fees plus incentivesImpermanent/divergence lossTraders and active LPs
Figure 218.2: Common yield-farming strategy shapes

Most farming activity reduces to a small number of strategy shapes because there are only a few basic ways to turn capital into protocol revenue.

The simplest shape is simple lending. Deposit an asset into a lending market and earn the variable rate paid by borrowers, possibly with token incentives layered on top. This strategy is mechanically simple and relatively easy to reason about. The main variables are utilization, collateral quality, and the health of the lending protocol.

A second shape is leveraged borrowing, sometimes built as a recursive loop. A user deposits collateral, borrows against it, redeposits the borrowed asset or a related asset, and repeats until they approach the protocol’s collateral limits. The point is not leverage for its own sake. It is to amplify exposure to a reward stream, often token emissions. If the protocol rewards both supplying and borrowing, a loop can increase the amount of subsidized activity a user controls. This can boost returns when token incentives are rich, but it makes the position much more sensitive to collateral-value changes, funding-rate changes, and liquidation thresholds.

A third shape is liquidity provision. The user supplies assets to a DEX pool and earns fees, often with extra token rewards. This is common on Ethereum-based AMMs, on Solana venues like Raydium, and on Cosmos-based systems like Osmosis. The chain differs, but the economic mechanism is the same: the protocol pays you for making trades possible. What changes across designs is how precisely you can place liquidity, how fees are computed, and what price risk you absorb.

These shapes can be combined, but it is useful to distinguish them because each one has a different failure mode. Lending farms are primarily exposed to borrower behavior and collateral design. Leveraged farms are exposed to liquidation and funding reflexivity. Liquidity-provision farms are exposed to trading conditions and inventory rebalancing losses.

Why did protocols use governance tokens as farming rewards?

Liquidity mining worked especially well in DeFi because the reward token was often not just a coupon but a governance token. That gave the reward an extra story: by farming today, users might accumulate influence over the protocol tomorrow. Compound made this structure famous with COMP. COMP holders can delegate voting rights, proposals are managed through Governor Bravo, and passed proposals move through a Timelock before execution. In other words, the reward token was linked to real control over parameters, upgrades, and incentives.

That governance link matters economically. A protocol can attract liquidity by saying, in effect: help us bootstrap the market, and we will pay you not only with tradable tokens but with a stake in future control. This can be sensible when a protocol is young and needs to solve the cold-start problem. Deep liquidity and active markets make the protocol more useful; token incentives buy time until organic usage appears.

But there is a tension here. Governance tokens can create value because they direct fee flows, emissions, or upgrades. Yet they can also create circularity. A high token price makes farming APYs look attractive, which attracts more capital, which can support the token story, at least temporarily. If the token price falls, the reverse happens. So governance-token rewards are real only to the extent that the market continues to believe those tokens are worth holding, selling, or using in governance.

Curve shows the same idea in a different form. Its ecosystem centers governance and voting rights around veCRV, which shape incentive allocation. That means the yield available to farmers is not just the result of pool mechanics; it is also the result of governance-directed emissions. In mature DeFi, farming often becomes a market not only for liquidity but for political influence over where rewards go.

How do AMM designs (constant‑product vs concentrated liquidity) change LP returns and risk?

AMM typeCapital efficiencyFee outcomePrice exposureManagement burden
Constant-productLow capital efficiencyLower per-capita feesSteady symmetric exposureLow management
Concentrated liquidityHigh capital efficiencyHigher fees when in-rangeHigh out-of-range riskActive rebalancing
Discretized binsVery high efficiencyTargeted fee captureDiscrete slippage patternsRequires range planning
Figure 218.3: How AMM design affects farming

It is tempting to treat "provide liquidity and earn fees" as a single generic action. But the design of the AMM changes the economics enough that the same phrase can describe very different positions.

In a classic constant-product pool, liquidity is spread across the entire price curve. That is simple, but much of the capital sits far from the current trading price and is rarely used. Uniswap v3 changed this by introducing concentrated liquidity: LPs can choose a bounded price range in which their capital is active. This improves capital efficiency because more of the deposited capital sits where trading actually happens. If price stays inside the range, fees per unit of active capital can be much higher.

The tradeoff is that concentrated liquidity is not passive in the old sense. When price leaves the chosen range, the position becomes inactive and stops earning fees until price re-enters. At that point the LP is also fully converted into one asset. So the mechanism that improves fee efficiency also increases management burden and path dependence. The farmer is no longer just renting out inventory; they are making a view about where price will spend time.

You can see similar tradeoffs on other chains. Raydium on Solana offers concentrated-liquidity market maker pools where LPs choose a price range, and constant-product pools for broader distribution. Osmosis provides cross-chain pool primitives in the Cosmos ecosystem, and developers can automate interactions using its SDKs and pool libraries. The important lesson is not that every chain copied the same interface. It is that yield farming generalizes across architectures because the underlying economic need (paying for usable liquidity) appears everywhere.

Why use yield aggregators and vaults for farming?

If yield farming were just "deposit and wait," there would be less need for specialized vaults and aggregators. They exist because the operational problem is harder than the economic idea. Rewards accrue in different tokens. Fees may need manual collection. The best venue changes over time. Gas or transaction costs can eat small positions. Some strategies need borrowing loops, collateral management, or periodic rebalancing. A yield aggregator packages those tasks into smart contracts that pool user funds and execute pre-programmed strategies automatically.

This solves two problems at once. First, it lowers the skill threshold for users who do not want to micromanage positions. Second, it creates scale. A pooled strategy can harvest and reinvest rewards more efficiently than many tiny accounts acting independently. The workflow described in the academic literature is useful here: funds are pooled, optional leverage or collateralization is established, the strategy is deployed into yield sources, then rewards are harvested and brought back into the original fund for reinvestment.

But aggregation also creates concentration. The strategy may depend on several protocols at once: a lending market, a DEX, an oracle, a reward distributor, and the vault itself. DeFi people often call these "money legos," which is a useful phrase because it emphasizes modularity. The analogy helps explain how strategies can be built quickly from reusable pieces. Where it fails is that legos in a toy box do not usually liquidate you, reprice your collateral, or inherit hidden assumptions from another contract. In DeFi, composability increases both capability and the number of ways something upstream can fail.

Why is headline APY misleading when comparing farms?

A smart reader’s most likely mistake is to compare farms by the headline yield alone. That can hide several crucial differences.

A fee-based yield and a token-emission-based yield may display the same annualized number today, but they behave differently tomorrow. Fee yield has a plausible economic anchor in trading activity. Interest yield has one in borrowing demand. Token-emission yield depends on continued subsidy and token valuation. If the reward token price falls, the APY can collapse even when the protocol itself is functioning exactly as designed.

There is also a mechanical issue with annualization. APY often assumes reinvestment at the same rate for a full year. In DeFi, that assumption is often unrealistic. Rates move rapidly as new capital enters, incentives expire, or trading activity changes. So APY is best read as a current-state projection, not a promise.

This is why many DeFi researchers warn that native-token-emission yield may be time-limited. Incentive schedules end. Reward tokens dilute. Once the subsidy weakens, only the organic sources of yield remain. A farm that is attractive only under heavy emissions may not be attractive at equilibrium.

What are the main risks of yield farming?

Yield farming fails where its assumptions fail. The most obvious risk is Smart Contract Risk: a bug in the protocol can lock, leak, or destroy funds. The more contracts a strategy touches, the more code paths it inherits.

The second major risk is liquidation risk, especially in leveraged farms. If collateral value falls or borrowed exposure becomes more expensive, a position can cross its safety threshold and be forcibly unwound. What looked like yield enhancement then becomes a mechanism for crystallizing losses.

A third risk comes from oracle and pricing dependence. Flash Loan make this especially important. Because on-chain transactions are atomic, an attacker can borrow a large amount of capital with no collateral, manipulate thin liquidity or a weak price source within the same transaction, exploit a protocol that trusts that manipulated price, and repay the loan before the transaction ends. The bZx attacks became a famous example of how fragile oracle assumptions and composability can be. The lesson is not that flash loans are inherently bad. They are a neutral primitive. The lesson is that a yield strategy is only as sound as the prices and invariants it relies on.

A fourth risk is impermanent loss or, more generally, divergence loss in AMMs. If the relative price of the pooled assets moves, the LP may end up with a worse outcome than simply holding the assets outside the pool. Fee income may offset that loss, but not always. Concentrated liquidity can intensify this tradeoff because capital is more sensitive to where price travels.

Finally, there is governance and control risk. Incentive programs, fee splits, and upgrade paths can change. Compound’s governance architecture illustrates that protocol changes often pass through delegated voting, proposal thresholds, and timelock delays rather than happening instantly. That can be a safety feature, but it also means farmers are exposed to decisions made by governance-token holders. Emergency controls such as pause functions can limit some actions during an incident, which may protect the system, but they also remind users that "decentralized" often still includes specific control surfaces.

Why does yield farming continue to exist in DeFi?

Yield farming persists because it performs a real market function. DeFi protocols need liquidity, collateral, and early participation. Users want compensation for providing them. Token incentives, fee sharing, and interest rates are ways of pricing that contribution. Even when the speculative excess fades, the underlying need does not disappear.

What does change over time is the mix. In early phases, token emissions often dominate because protocols are buying growth. In more mature systems, sustainable yield has to lean more heavily on actual usage; borrowers paying interest, traders paying fees, protocols sharing real revenue. That transition is one of the clearest tests of whether a farm was a bootstrapping device or a durable business model.

Conclusion

Yield farming is the active practice of placing crypto assets where DeFi protocols will pay for them most. The essential question is not how high the displayed APY is, but what mechanism creates that return: borrower demand, trading fees, token emissions, or some combination. Once you separate those sources, the subject becomes much easier to reason about. The yield is never free; it is payment for liquidity, capital, governance bootstrapping, or risk-bearing; and the quality of the farm depends on which of those you are actually being paid for.

How do you trade through a DEX or DeFi market more effectively?

Trade through a DEX or DeFi market more effectively by verifying pool liquidity, choosing an execution type that matches your price sensitivity, and controlling slippage and trade size. Use Cube Exchange to fund your account and submit trades while you compare on-chain depth and quoted execution terms before you send the transaction.

  1. Fund your Cube account with the on‑ramp or a supported crypto transfer.
  2. Check the target market’s on‑chain liquidity and recent 24h volume in a block explorer or DEX UI to estimate price impact.
  3. Choose an order type in Cube: use a limit order for price control on larger trades or a market order for immediate execution on small fills.
  4. Set slippage tolerance and split large amounts into multiple trades if pool depth suggests high impact, then review estimated fees and submit.

Frequently Asked Questions

Why is the APY shown on a farm not a reliable measure of future returns?
+
Headline APYs often combine different revenue streams — borrower-paid interest, trading fees, and protocol token emissions — and those streams behave differently over time, so the displayed APY is a current-state projection that assumes reinvestment and may collapse if an emission or token price changes.
Is yield farming the same thing as a savings account or passive yield?
+
yield farming is best understood as strategies that allocate assets across protocols to capture interest, fees, or token rewards; the same deposited asset can be routed, redeployed, and stacked across contracts rather than being a single passive product.
How do the economic sources of yield differ and which are most durable?
+
A lending-based yield is anchored to borrower demand and utilization, fee-based yield depends on trading volume and pool mechanics, and liquidity-mining yield depends on the protocol minting or distributing tokens — the latter is often time-limited and fragile because it relies on token valuation and ongoing emissions.
How does concentrated liquidity change the risks and management required for LPs?
+
Concentrated-liquidity designs (e.g., Uniswap v3) increase fee efficiency by placing capital into bounded price ranges, but they make positions more path-dependent and inactive when price exits the range, increasing management needs and exposure to divergence loss.
Why do leveraged yield strategies offer higher returns but also higher risk?
+
Leverage often amplifies protocol reward exposure by recursively borrowing and redeploying assets, but it also magnifies liquidation risk and sensitivity to collateral-value changes, funding-rate moves, and protocol limits.
What problem do yield‑aggregators solve, and what new risks do they introduce?
+
Aggregators and vaults exist because farming requires frequent harvesting, token swaps, rebalancing, and gas‑efficient execution; pooling solves operational and cost inefficiencies but concentrates exposure to the strategy’s smart contracts and their upstream dependencies.
How do flash loans make some yield‑farming strategies vulnerable to exploit?
+
Atomic flash loans let attackers borrow large capital within a single transaction and, if a protocol relies on manipulable price sources or fragile invariants, that can enable price‑manipulation exploits that drain funds even when contracts are auditable.
What is impermanent loss and when can fees fail to compensate for it?
+
Impermanent loss (or divergence loss) occurs when the relative price of pooled assets moves and can leave an LP worse off than simply holding the assets; fee income may offset it but not always, and concentrated positions typically increase this sensitivity.
Why did protocols issue governance tokens as farming rewards, and what are the downsides?
+
Governance tokens tied to liquidity mining can bootstrap liquidity because they confer protocol influence as well as tradable value, but that creates circularity: token price supports APYs, and falling token value or ended emissions can sharply reduce farmer returns.
What are the primary ways yield‑farming strategies can fail?
+
The main operational and economic failure modes are smart‑contract bugs, oracle or price‑feed manipulation, liquidation cascades in leveraged positions, impermanent/divergence loss for LPs, and governance or policy changes that alter incentives or emissions.

Related reading

Keep exploring

Your Trades, Your Crypto