> For the complete documentation index, see [llms.txt](https://docs.aftermath.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aftermath.finance/farms/tutorials/creating-a-farm.md).

# Creating a Farm

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2FQpyIxfAnttzNxbggen5g%2FCreateFarm2.mp4?alt=media&token=244366d1-a297-4a40-a0c7-bbeaa5a13e1a>" %}

Farm creation is permissionless: anyone can set up a Farm on Aftermath to reward their community with token emissions.

First, you will need to have a Liquidity Pool on Aftermath for which you would like to create a farm. If you have not yet set a Pool up, follow the instructions in [Creating a Pool.](https://docs.aftermath.finance/pools/tutorials/creating-a-pool.md) If you want to create a Farm for a token, not a Pool, you can skip this step.

Once your pool is set up, navigate to the Farms page. Click the + Create Farm button at the top right, above the list of active Farms.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2Fgit-blob-5bae073d9c353d625241eb49d7778baf627a4e23%2Ffarms-list.png?alt=media" alt=""><figcaption><p>+ Create Farm button at top right of Farms page</p></figcaption></figure>

The first step is to specify the Stake Coin Type for the pool. This is the coin users will stake into the Farm, typically it is the LP token for the pool you have created. Paste the coin type into the Stake Coin Type field, or click **Browse** to pick a coin from the list.

The Stake Coin then displays at the bottom of the screen so you can confirm it is the correct one.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2Fgit-blob-5f82493ff315f2769fbfc7c3eeb593010820547a%2Fcreate-farm-page.png?alt=media" alt=""><figcaption><p>Create Farm menu. Paste the Stake Coin Type in the field at the top left.</p></figcaption></figure>

Set these parameters before creating your Farm:

**Minimum Stake Amount**: The smallest amount of coins a user can stake into your Farm. We suggest setting this to 1, though you may choose a different value if it better suits your LP token.

**Maximum Lock Multiplier (1-18)**: You have the option to provide a higher rewards emission rate for LPs who lock their tokens in the Farm for a specific duration. This rewards users who commit liquidity to your Pool for longer, and is optional. If you do not want the option to lock Farming positions, set this value to 1.

If you would like the option to lock for a higher rewards rate, decide on the magnitude of the multiplier you would like. The value you enter is the multiplier a user receives for locking for the longest time you allow.

For example, if you set the Maximum Lock Multiplier to 2, and the Maximum Lock Duration to 1 Month, a user who locks for 1 month will receive rewards at twice the rate a user who does not lock at all will. A user who locks for 2 weeks will receive rewards at 1.5x the rate as a user who does not lock at all. The emissions rate scales linearly from no lock to maximum lock.

**Minimum Lock Duration**: The shortest amount of time users can Lock for. We recommend setting this to 0 months 0 days, as this makes Locking optional to users. If you want every user who deposits into the Farm to have to Lock for some duration, you can specify that minimum duration here.

**Maximum Lock Duration**: The longest period of time a user can lock for. Locking for this duration will provide the Maximum Lock Multiplier and result in the greatest possible rewards emissions rate. If you do not want to have the option to Lock at all, set these fields to 0.

Click Create Farm to deploy your Farm.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2FYpT6VWW7yKYZw1bbo1wS%2FScreenshot%202025-02-24%20at%2010.48.30%E2%80%AFAM.png?alt=media&amp;token=ebee2717-405c-4bba-b876-7e18093b2a01" alt=""><figcaption><p>Farm User View and Owner Settings</p></figcaption></figure>

Once your Farm is created, you are taken to its page where you can access both the User View and Owner Settings of your farm. You can also access it from the Farms page on Aftermath. Next to the Official and Community tabs, you will now see an Owned tab which lists all the farms you have created. Click your farm to open its page.

You will see two tabs at the top right of the page, the User View and the Owner Settings. Select Owner Settings to manage your Farm. You must be connected with the Sui address that created the Farm to access Owner Settings. You can also share the Admin Cap, covered below.

Before your farm can emit rewards, you must initialize and deposit them.

**Reward Initial Deposit:** Initialize Rewards by specifying the coin the Farm will emit, for example SUI or your project's own token. Using the Select Coin dropdown menu, choose the coin you wish to emit. Your farm can emit more than one token if you initialize them one at a time.

**Total Emission Duration:** The length of time it will take for all deposited rewards to be emitted. You can always add more rewards if you would like the farm to continue emitting tokens.

**Emission Frequency (Ms)**: Once you have specified the reward coin, you must specify the Emission Frequency for the Farm: how often, in milliseconds, the farm emits a batch of rewards. Each batch is split pro rata between all stakers. If there are two stakers, one who max locked for a 2x multiplier and one who didn't lock, then the max locker would receive 2x more of the emitted tokens.

To determine what your Emission Frequency ought to be, you must consider how much liquidity you expect to be staked into the Farm, and what your desired APR is. You can increase the emissions rate, but not decrease it. If you are unsure, you can increase the rate later if the APR is lower than you want. If you have questions about this step, reach out to us in Discord.

**Start Delay(Ms)**: This provides you the option to delay the start of Emissions by some duration of time. Use it to set the Farm up before announcing it, so no one earns rewards before you are ready.

Click Initialize Rewards. Next, click on the Deposit Rewards tab to add your reward coins to the vault.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2FL2c4uXY77BNQ4o80YmwV%2FScreenshot%202025-02-24%20at%2010.55.06%E2%80%AFAM.png?alt=media&amp;token=1a11682a-69b9-43f5-9852-d7b9fbaf9c47" alt=""><figcaption><p>Farm Admin Settings - InitialiizeRewards</p></figcaption></figure>

You can now deposit the reward coin or coins into your Farm. You will see each coin you have initialized listed; to add another coin, follow the previous steps to initialize another reward coin.

To determine the amount of reward coins to deposit into your Farm, consider your Emissions Rate and the length of time you would like the Farm to run for before you will need to deposit more rewards.

Then click Deposit Rewards to add the coins to the Vault.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2FXnZK1iyA9TTz4zydNi57%2FScreenshot%202025-02-24%20at%2010.58.20%E2%80%AFAM.png?alt=media&amp;token=6935e40a-67bf-4554-b235-361a6b04bd94" alt=""><figcaption><p>Farm Owner Settings</p></figcaption></figure>

Once you initialize rewards, you will see them in the Owner Settings. Both the amount remaining to Emit, and the amount that have already been emitted but not yet claimed, are shown.

As the Total Value Locked in your Farm increases, the APR each user receives will decrease. To keep incentivizing your Pool's growth, you may wish to increase your emissions rate. Open the Increase Emissions tab and enter the new emissions rate you would like to set for your Farm. You cannot decrease emissions.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2Fy1puyIpOVhzoL3jk0kFS%2FScreenshot%202025-02-24%20at%2011.04.04%E2%80%AFAM.png?alt=media&amp;token=6131dbb5-618f-40ed-a36d-8f95417c48fa" alt="" width="375"><figcaption><p>Farm Admin Settings - Grant Admin Cap</p></figcaption></figure>

Finally, you can share admin access to your Farm by granting a `OneTimeAdminCap` to another Sui address. The recipient can use the cap once to perform a permissioned action, such as adding rewards or changing emissions. This can help a teammate or partner sponsor your Farm with their token. Enter and confirm the recipient's Sui address before clicking Grant Admin Cap. If the interface flags the recipient as an object address, proceed only if you intend to send the cap there: you might not be able to recover it.

<figure><img src="https://3284144787-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmeKfXaQnIP3bbI1AdlVX%2Fuploads%2F8fdGxnLACg94RQMLAVS2%2FScreenshot%202025-02-24%20at%2011.04.56%E2%80%AFAM.png?alt=media&amp;token=8fb70f78-54c6-474e-88a6-68755e25c8eb" alt="Grant Admin Cap form with a recipient address field and an object-address recovery warning" width="375"><figcaption></figcaption></figure>

If you have any questions about these steps, reach out to us in Discord.
