ChainScore Labs
LABS
Guides

Providing Liquidity: A Beginner's Guide to Yield Farming

A technical primer on the mechanics, risks, and strategies of supplying assets to decentralized exchanges.
Chainscore © 2025
core-concepts

Core Concepts of Liquidity Provision

A foundational guide to understanding how you can supply your crypto assets to decentralized exchanges to earn rewards, covering the essential mechanics, benefits, and risks of becoming a liquidity provider.

01

Automated Market Makers (AMMs)

Automated Market Makers (AMMs) are the core protocol that powers decentralized exchanges, replacing traditional order books with liquidity pools. They use mathematical formulas to set asset prices automatically.

  • Constant Product Formula: Uses x*y=k (like Uniswap) to maintain pool balance.
  • Price Impact: Large trades cause slippage as they alter the pool ratio.
  • Use Case: Providing ETH/DAI liquidity lets users swap between the tokens, with fees distributed to you.
02

Liquidity Pools & LP Tokens

A Liquidity Pool is a smart contract holding pairs of tokens, like ETH and USDC. When you deposit, you receive LP Tokens representing your share and granting fee rights.

  • Pool Share: Your stake determines your portion of trading fees.
  • Receipt & Redemption: LP tokens are needed to withdraw your original funds.
  • Example: Adding to a SUSHI/ETH pool earns fees from every trade and may yield extra SUSHI rewards.
03

Impermanent Loss (IL)

Impermanent Loss is the potential loss compared to simply holding assets, occurring when the price ratio of your pooled tokens changes. It's 'impermanent' until you withdraw.

  • Cause: Volatility; if ETH surges vs. your paired stablecoin, the pool rebalances.
  • Mitigation: High fee rewards can offset IL, common in stablecoin pairs.
  • Real Risk: Providing LINK/ETH could see loss if LINK outperforms ETH dramatically.
04

Yield Farming & Incentives

Yield Farming is the practice of earning additional tokens by staking your LP tokens in a protocol's incentive program. This boosts overall returns beyond basic trading fees.

  • Reward Tokens: Platforms like Curve issue CRV for locking LP tokens.
  • Liquidity Mining: Protocols distribute new tokens to attract capital.
  • Use Case: Staking Uniswap LP tokens on a farm like SushiSwap to earn SUSHI.
05

Concentrated Liquidity

Concentrated Liquidity allows LPs to allocate capital within a specific price range, increasing capital efficiency and potential fees compared to full-range provisioning.

  • Custom Ranges: Set a price bracket (e.g., ETH between $1,800-$2,200) for your funds.
  • Higher Fees: Earn more from trades occurring within your chosen range.
  • Example: On Uniswap V3, providing USDC/ETH liquidity only where you expect most trading activity.

How Automated Market Makers (AMMs) Function

A Beginner's Guide to Yield Farming: Providing Liquidity

1

Step 1: Understanding the Liquidity Pool

Learn the core concept of a liquidity pool and the role of a liquidity provider (LP).

Detailed Instructions

A liquidity pool is a smart contract that holds reserves of two or more tokens, enabling decentralized trading. As a liquidity provider (LP), you deposit an equal value of two tokens (e.g., ETH and USDC) into this pool. In return, you receive LP tokens, which represent your share of the pool and act as a receipt for your deposit. These tokens are crucial as they accrue trading fees and must be burned to reclaim your underlying assets.

  • Sub-step 1: Choose a Pair: Select a token pair on a platform like Uniswap V3 (Ethereum mainnet address: 0x1F98431c8aD98523631AE4a59f267346ea31F984).
  • Sub-step 2: Assess Risk: Understand impermanent loss, which occurs when the price of your deposited assets changes compared to when you deposited them.
  • Sub-step 3: Check Ratios: You must deposit tokens in a 50/50 value ratio. For example, if 1 ETH = $2,000 and you deposit 1 ETH, you must also deposit $2,000 worth of USDC.

Tip: Always verify the smart contract address of the pool on a block explorer like Etherscan to avoid scams.

2

Step 2: Preparing Your Wallet and Assets

Set up a Web3 wallet and ensure you have the required tokens and gas fees.

Detailed Instructions

You need a Web3 wallet like MetaMask connected to the correct network (e.g., Ethereum, Polygon). Ensure you have sufficient gas fees (paid in the network's native token like ETH) to cover transaction costs, which can vary. You must also hold the exact tokens you wish to provide as liquidity. If you don't have them, you may need to swap for them first using the DEX itself.

  • Sub-step 1: Fund Wallet: Transfer ETH for gas and the token pair (e.g., 1 ETH and 2000 USDC) to your wallet address.
  • Sub-step 2: Approve Tokens: Before depositing, you must grant the pool contract permission to spend your tokens. This is a separate transaction for each token.
  • Sub-step 3: Execute Approval: A typical approval transaction in MetaMask will call the approve function. For a USDC contract, the call data might look like:
code
approve(spender: 0x1F98431c8aD98523631AE4a59f267346ea31F984, amount: 2000000000)

Tip: Use a gas tracker like Etherscan's Gas Tracker to submit transactions when network fees are lower.

3

Step 3: Depositing Liquidity via the Interface

Execute the transaction to add your tokens to the pool and receive LP tokens.

Detailed Instructions

Navigate to the "Pool" or "Liquidity" section of the DEX interface (e.g., app.uniswap.org). Select the token pair and enter the amount for one asset; the interface will automatically calculate the required amount of the paired token to maintain the 50/50 value ratio. Confirm the details, including the estimated LP tokens you will receive and the projected annual percentage yield (APY) from fees.

  • Sub-step 1: Input Amount: Enter the amount of the first token (e.g., 1 ETH). The interface shows you need ~2000 USDC.
  • Sub-step 2: Review Details: Check the price impact and share of pool you will own. A high price impact indicates your deposit is large relative to the pool.
  • Sub-step 3: Confirm & Sign: Click "Add Liquidity," review the transaction in your wallet (ensuring the contract address is correct), and sign to broadcast the transaction. You will receive LP tokens in your wallet upon confirmation.

Tip: For initial testing, consider using a testnet or providing liquidity to a stablecoin pair (e.g., USDC/USDT) to minimize impermanent loss risk.

4

Step 4: Staking LP Tokens for Additional Rewards

Maximize returns by depositing your LP tokens into a yield farming contract.

Detailed Instructions

Many protocols offer extra incentive tokens (e.g., UNI, SUSHI) for staking your LP tokens in their farm or gauge. This process is often called yield farming. You must approve and deposit your LP tokens into a separate staking contract, which will then distribute rewards over time based on your share.

  • Sub-step 1: Locate Farm: On a platform like SushiSwap, find the farm for your LP pair (e.g., ETH/USDC SLP).
  • Sub-step 2: Approve LP Tokens: Grant the farm contract permission to stake your LP tokens, similar to the initial token approval.
  • Sub-step 3: Stake Tokens: Execute the deposit function. For example, to stake 10 LP tokens:
code
deposit(pid: 12, amount: 10000000000000000000, account: yourAddress)
  • Sub-step 4: Claim Rewards: Regularly claim your reward tokens using the harvest or claim function. You can then compound by staking these rewards or swapping them.

Tip: Monitor APR/APY rates as they fluctuate. Use a portfolio tracker like DeBank to monitor all your positions and rewards in one place.

Comparing Common Liquidity Pool Types

Key characteristics of popular Automated Market Maker (AMM) pool models for liquidity providers.

Pool TypeTypical Fee TierImpermanent Loss RiskCapital EfficiencyCommon Use Case

Constant Product (Uniswap V2)

0.30%

High

Low

General trading pairs (e.g., ETH/DAI)

Concentrated Liquidity (Uniswap V3)

0.05%, 0.30%, 1.00%

Very High (if range narrow)

Very High

Active management of major pairs

StableSwap (Curve Finance)

0.04%

Low

High for stables

Stablecoin pairs (e.g., USDC/USDT)

Weighted Pool (Balancer)

Variable (e.g., 0.05% - 1%)

Medium to High

Medium

Index funds or custom asset ratios

Kriya DEX (Orderbook AMM)

0.10% - 0.25%

Medium

High

High-volume, low-slippage trades

A Practical Walkthrough: Providing Liquidity

A step-by-step guide to depositing crypto assets into a decentralized exchange liquidity pool to earn yield.

1

Step 1: Setting Up Your Wallet and Acquiring Tokens

Prepare your digital wallet and obtain the required token pair for the liquidity pool.

Detailed Instructions

Before you can provide liquidity, you need a non-custodial Web3 wallet like MetaMask and the specific tokens for the pool. For this walkthrough, we'll use the popular ETH/USDC pool on Uniswap V3.

  • Sub-step 1: Install and Fund MetaMask: Download the MetaMask extension, create a wallet, and securely store your seed phrase. Send at least 0.1 ETH to your wallet address (e.g., 0x742d35Cc6634C0532925a3b844Bc9e...) from an exchange to cover gas fees and initial capital.
  • Sub-step 2: Acquire Pool Tokens: You need an equal value of both ETH and USDC. If you only have ETH, you must swap half of it for USDC. Connect your wallet to Uniswap, and swap 0.05 ETH for USDC at the current market rate.
  • Sub-step 3: Verify Balances: Check your wallet to confirm you hold both assets. You should see your ETH balance and a USDC balance (approximately $X based on swap).

Tip: Always use official links to avoid phishing sites. Bookmark app.uniswap.org.

2

Step 2: Selecting and Analyzing a Liquidity Pool

Choose a suitable pool by evaluating key metrics like APR, volume, and impermanent loss risk.

Detailed Instructions

Not all pools are equal. Your goal is to find a pool with a good balance of Annual Percentage Rate (APR) and manageable risk. Navigate to the 'Pool' section on Uniswap.

  • Sub-step 1: Research Pool Metrics: For the ETH/USDC 0.3% fee tier, examine the 24h volume (e.g., $50M), total value locked (TVL) (e.g., $200M), and the current APR (e.g., 12%). Higher volume often means more fee revenue.
  • Sub-step 2: Understand Fee Tiers: Uniswap V3 offers tiers like 0.05%, 0.3%, and 1%. The 0.3% tier is standard for major pairs like ETH/USDC. Choosing the wrong tier can result in minimal fee earnings.
  • Sub-step 3: Assess Impermanent Loss Risk: Use an online calculator to simulate impermanent loss if ETH price changes by ±50%. For a volatile pair, this risk is higher.

Tip: Start with a major, stable pair for your first time to reduce complexity and risk.

3

Step 3: Adding Liquidity with a Concentrated Range

Deposit your tokens into the pool by defining a specific price range for your capital.

Detailed Instructions

On Uniswap V3, you provide liquidity within a custom price range, a feature called concentrated liquidity. This increases capital efficiency but requires active management.

  • Sub-step 1: Initiate Deposit: Click 'Add Liquidity', select the ETH/USDC pair and the 0.3% fee tier. Input the amount of ETH you wish to deposit (e.g., 0.05 ETH). The interface will show the required USDC amount.
  • Sub-step 2: Set Your Price Range: Define the min and max price where your liquidity is active. For a beginner, you might set a wide range around the current price (e.g., Min: 1500 USDC/ETH, Current: ~3000, Max: 4500). A narrower range earns more fees but risks your liquidity becoming inactive if the price moves out of range.
  • Sub-step 3: Approve and Supply: First, approve the USDC contract for spending. Then, review the details and click 'Add'. Confirm the transaction in MetaMask, paying a gas fee (e.g., 0.003 ETH).
code
// Example of a typical transaction hash after submission: 0x88da3d8c6c6b6a5c5e4d3c2b1a0f9e8d7c6b5a4f3e2d1c0b9a8f7e6d5c4b3a2f1
4

Step 4: Managing Your Position and Claiming Rewards

Monitor your liquidity position, collect earned fees, and understand the exit process.

Detailed Instructions

After depositing, your position will start earning trading fees proportional to your share of the liquidity within the active price range. You must actively manage this position.

  • Sub-step 1: Track Your Position: View your position under the 'Pool' tab. You'll see your liquidity provider (LP) NFT representing the position, its current value, and accumulated fees in both ETH and USDC.
  • Sub-step 2: Collect Fees: Fees accrue in real-time but are not automatically compounded. You can click 'Collect Fees' at any time to execute a transaction and send the earned tokens to your wallet.
  • Sub-step 3: Remove Liquidity (Exit): To withdraw your capital, select your position and click 'Remove Liquidity'. You can remove a percentage or all of it. You will receive your proportional share of the pool's current reserves, which may differ from your initial deposit due to impermanent loss and earned fees.

Tip: Regularly check if the market price is approaching your set range boundaries. You may need to adjust your range to stay active and earning.

Understanding the Risks: Impermanent Loss and Beyond

Impermanent loss is the temporary loss of value a liquidity provider experiences compared to simply holding assets, caused by price divergence in a trading pair. It occurs because automated market makers (AMMs) like Uniswap require pools to maintain a constant product formula (e.g., x*y=k). When one asset's price changes relative to the other, arbitrageurs trade to rebalance the pool, altering your share's composition. For example, if you provide 1 ETH ($2,000) and 2,000 USDC into a pool and ETH's price doubles, arbitrageurs will buy your ETH until the pool ratio reflects the new price, leaving you with less ETH and more USDC. While the total dollar value of your share increases, it's less than if you had just held the original assets. This loss is 'impermanent' only if prices return to their original ratio.

Strategic Considerations for Different Participants

Getting Started

Yield farming is the practice of providing liquidity to decentralized exchanges (DEXs) or lending protocols in exchange for rewards, typically in the form of additional tokens. For newcomers, the primary goal is to earn passive income while minimizing risk.

Key Points

  • Start with Stablecoins: Use pairs like USDC/DAI on platforms like Curve Finance to reduce exposure to impermanent loss, which occurs when the price of your deposited assets changes relative to each other.
  • Understand APY vs. APR: Annual Percentage Yield (APY) includes compound interest, while Annual Percentage Rate (APR) does not. A high APY on a new farm might be enticing but often carries higher risk.
  • Use Established Protocols: Begin with well-known, audited platforms like Uniswap V3 or Aave to avoid smart contract vulnerabilities and rug pulls.

Example

When using Uniswap V2, you would deposit an equal value of two tokens (e.g., ETH and USDC) into a liquidity pool. In return, you receive LP (Liquidity Provider) tokens, which represent your share and can be staked in a separate farm to earn additional rewards like UNI tokens.