Liquidity Provision

Note: Liquidity pool deposit and withdrawal functionality is part of the upcoming next release of Alpaca DEX.
For now, all traders who create new tokens automatically receive LP tokens, which remain locked for the first month after token creation. This ensures fair market stability and prevents early liquidity manipulation.

What Are Liquidity Pools? #

Liquidity pools are the backbone of any automated market maker (AMM) system.
Instead of relying on centralized order books, trades on Alpaca DEX happen directly against these on-chain pools of tokens. Each pool contains two tokens — a base token and a paired token — and follows the constant-product formula:

x × y = k

Here, x and y represent the quantities of each token in the pool, and k remains constant. This mathematical relationship ensures that prices automatically adjust based on supply and demand.

How Users Provide Liquidity #

When liquidity provision launches, users will be able to deposit equal values of two tokens into a pool (for example, 100 KTA and 50 COOL if their prices are 1:2).
By doing so, they become liquidity providers (LPs) — helping ensure that trades can occur smoothly without large price swings or “slippage.”

In return, the DEX automatically issues LP tokens, which act as proof of your ownership in that pool.

What LP Tokens Represent #

LP tokens are digital receipts that represent your share of the total pool.
If you provide 10% of a pool’s liquidity, you receive LP tokens equal to 10% of the total supply of LP tokens for that pool. These tokens track your claim over:

  • The two tokens you deposited
  • The trading fees the pool accumulates over time
  • Any price appreciation or impermanent loss that results from market movement

As the pool grows through trading activity, the value of each LP token increases, reflecting your earned fees and your proportional share of the total reserves.

How Liquidity Providers Earn #

Every time a trade happens in a pool, a small liquidity fee is collected and added back to the pool’s reserves.
Unlike most DEXs with a fixed rate (such as 0.3%), we allow each token creator to define the liquidity fee percentage when launching their token.
This means the rate at which LPs earn trading fees can vary between pools depending on the token’s configuration.

Because liquidity providers collectively own the pool’s reserves, these accumulated fees automatically increase the total pool value — and by extension, the value of each LP token. No manual claiming is needed.

Your rewards remain proportional to your share of the pool.
For example, if you provide 10% of the liquidity in a pool, you’ll earn 10% of all trading fees that pool generates, based on the liquidity fee percentage defined by the token creator.

Withdrawing Liquidity #

When liquidity withdrawals become available, you’ll be able to redeem your LP tokens to withdraw your share of the pool — including your original deposit plus any earned fees.

Upon withdrawal, your LP tokens are burned (destroyed), and you receive the two underlying assets back in proportion to their current pool ratio.

Because pool ratios shift as trades occur, the number of tokens you get back may differ from your initial deposit — reflecting market movement during your liquidity provision period.

Example #

Let’s say you deposit 100 KTA and 50 ALPA into a liquidity pool.
You receive LP tokens representing your ownership share.

As traders swap between KTA and ALPA, the pool grows with collected fees.
As soon as withdrawals are enabled, you can redeem your LP tokens for your share of the pool — now slightly larger because of accumulated trading fees.

Updated on November 16, 2025