Skip to main content

Liquidity Fees Explained

On Alpaca DEX, every trade incurs a small fee. This fee is not paid to Alpaca LLC; instead, it is paid directly into the Liquidity Pool.

This mechanism is the primary incentive for users to become Liquidity Providers (LPs). By depositing assets into a pool, you earn a passive share of every single trade that occurs in that pair.


How the Fee is Set

Unlike many exchanges with a fixed fee (e.g., 0.3%), Alpaca gives Token Creators control. When you launch a token—whether by or raising funds via PacaLaunch—you define the Liquidity Fee percentage.

  • Fixed at Creation: This rate is set when the pool is initialized.
  • Publicly Visible: The fee is displayed on the token's trading page. Traders can see exactly how much they are contributing to the pool.
Choose Responsibly

A higher fee is not always better.

  • High Fee: Increases earnings for LPs but makes trading expensive. This can reduce trading volume and damage trust.
  • Low Fee: Encourages high trading volume but offers lower margins for LPs.

How Liquidity Providers Earn

When a trader swaps Token A for Token B, the fee is deducted from the input token and added immediately to the pool's reserves.

This process makes the pool "thicker" or larger over time.

  1. No Manual Claiming: You do not need to click "Harvest" or "Claim Rewards."
  2. Auto-Compounding: The fees are added to the pool, meaning the pool's total value grows automatically with every trade.
  3. Ownership Share: Your earnings are realized when you withdraw your liquidity.

The Withdrawal Mechanics

Your LP Tokens represent a percentage share of the pool (e.g., 1%).

  • When you Deposit: The pool has 1,000 Tokens. You own 1% (10 Tokens).
  • During Trading: Fees are added. The pool grows to 1,100 Tokens.
  • When you Withdraw: You burn your LP tokens to claim your 1%. You now receive 11 Tokens.

Note: You receive the underlying assets in their current proportion at the moment of withdrawal, which may differ from your original deposit ratio due to price shifts.


Example Scenario

Let's look at a practical example of how a Liquidity Provider benefits from the fee.

The Setup

  • Pool: KTA / COOL
  • Liquidity Fee: Set by Creator at 1%.
  • Alice's Position: Alice provides liquidity and receives 10% of the total LP Tokens.

The Activity

Over the next month, there is high trading activity. Traders swap back and forth, paying the 1% fee on every transaction.

  • Total Volume: 1,000,000 KTA worth of trades.
  • Fees Generated: 10,000 KTA (1% of volume).

The Result

These 10,000 KTA in fees are added directly to the pool's reserves.

  • Alice owns 10% of the pool.
  • Therefore, Alice's share of the pool has grown by 1,000 KTA.

The Payday

When Alice decides to withdraw her liquidity:

  1. She returns her LP tokens.
  2. The liquidity engine calculates 10% of the current total pool (Original Deposit + 10,000 KTA Fees).
  3. She receives her original funds PLUS the 1,000 KTA earned from fees.
Summary

The more volume a pool has, the more fees are added to the pile. As an LP, you simply hold your LP tokens to capture your share of this growth.