# How to use farm

<figure><img src="/files/4PyuRiRvPFHYsnocr9pA" alt=""><figcaption></figcaption></figure>

Unlike staking, Farms require you to stake two tokens to provide liquidity and receive the LP Tokens. These LP Tokens are then staked in the Farm to earn rewards. This allows you to earn CAB while retaining a position in your other tokens!

{% hint style="info" %}
Yield farming can offer better rewards than staking, but it carries the risk of **Impermanent Loss**. It’s not as scary as it sounds, but it is worth learning about the concept before you get started.

Take a look at this informative [article about Impermanent Loss ](https://academy.binance.com/en/articles/impermanent-loss-explained)from Binance Academy to delve deeper into the topic.
{% endhint %}

**Getting set up to farm**

Before farming with LP Tokens, you need to set up your wallet and connect it to CabbageSwap, you also need:

* Some ETH for gas fee.
* The LP tokens which our farm support: CAB-ETH-LP, CAB-USDC-LP, CAB-USDT-LP

Learn how to get start [here](/cabbageswap/get-started/get-started-on-ancient8.md)

**Get LP token** (if you don't already own them)

Farms can only accept their own exact LP Tokens, the CAB-ETH Farm will exclusively accept CAB-ETH LP Tokens. Therefore, you'll need to first provide liquidity for the CAB-ETH pair.&#x20;

Now, you just need to follow this guide to [add LP.](/cabbageswap/features/liquidity/how-to-add-lp.md)

**How to farm**

1. Access <https://cabbageswap.com/earn/farming>
2. Unlock your wallet and connect to the app by clicking the "Connect wallet" button.
3. Find the pool you wish to stake in (ensure you own the LP token for that pool).
4. You need to enable the contract first, Once a contract for the LP token is enabled, you can stake it by clicking the "**Stake LP**" button.

<figure><img src="/files/nWJRV7doznD8sbhDTebn" alt="" width="531"><figcaption></figcaption></figure>

5. A popup will show up, where you can input the desired staking amount and then click the "**Confirm**" button.

<figure><img src="/files/j7m5WiA9txJHNdb3FNyu" alt="" width="432"><figcaption></figcaption></figure>

Your wallet will request confirmation for the transaction. To authorize the transaction in your wallet, click "Confirm."

After a brief moment, the window will close, and you will see your updated staked LP Token balance in the details.

<figure><img src="/files/CYOZhib9Rcas3wirkoS0" alt="" width="222"><figcaption></figcaption></figure>

Your staked LP tokens are continuously earning you CAB tokens as rewards as well as trading fees every second. You can harvest farming yields any time by click the "**Harvest**" button.

6. Whether you intend to stake additional tokens or unstake, simply click on the (+) symbol to stake more and the (-) symbol to unstake.

<figure><img src="/files/EGaj8cYR0qNFQ1j3TnEP" alt="" width="432"><figcaption></figcaption></figure>

* Make sure your information is correct. When you are ready, click the **Confirm** button and confirm the action in your wallet.
* After a short wait, your new balance will show in the details section of your LP Token pair. If you've unstaked your LP Tokens, any unharvested rewards you had will automatically have been collected


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cabbageswap.com/cabbageswap/features/farming/how-to-use-farm.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
