AMM (Automated Market Maker)
On chain pools that set prices from token balances.
An automated market maker, or AMM, is a smart contract system that lets users trade digital assets against a liquidity pool instead of matching buyers with sellers in an order book. A pricing formula updates quotes as pool balances change. Liquidity providers deposit assets into the pool and typically receive a share of trading fees in return.
A common design is the constant-product formula, often summarized as x multiplied by y equals k. If a pool contains ETH and a stablecoin, buying ETH removes ETH and adds stablecoins. The changed ratio makes the next unit of ETH more expensive. Arbitrage traders compare that pool price with other markets and trade price gaps, helping bring the AMM back toward the wider market price.
AMMs enable permissionless trading and continuous on-chain liquidity, including for assets that may not qualify for a centralized exchange. Different designs serve different markets. Stable-swap curves aim for cheap trades between closely priced assets. Concentrated liquidity lets providers allocate capital to chosen price ranges. Weighted pools can hold more than two assets in unequal proportions.
AMMs matter because they are core infrastructure for decentralized exchanges, token launches, lending liquidations, and other DeFi applications. A user can swap directly from a self-custody wallet, while any eligible participant can supply liquidity. Composability allows other smart contracts and aggregators to route trades through the pools without a manual listing process.
Trading still has costs and risks. Price impact grows when an order is large relative to available liquidity. Slippage occurs when execution differs from the expected quote. Smart contract bugs, malicious tokens, front-running, and sandwich attacks can also cause losses. Users should verify token addresses, review the minimum output, limit approvals, and be cautious with pools that show extreme yields or shallow reserves.
Liquidity providers face additional exposure. Relative price changes can create impermanent loss compared with holding the assets. Concentrated positions may stop earning fees when the market leaves their range, and incentive tokens may fall in value. Before depositing, estimate fee income after gas and protocol charges, examine trading volume and volatility, understand withdrawal rules, and consider contract, oracle, depeg, and admin-key risk. An AMM is automated, but providing liquidity is not passive or risk-free income.
Frequently asked questions
- An AMM uses a mathematical rule and the assets available in a liquidity pool. In a constant-product pool, reserve balances approximately follow x multiplied by y equals k. A swap changes the balances and therefore the quoted price. Concentrated-liquidity designs let providers choose price ranges, which can improve capital efficiency but require more active management.
- Impermanent loss is the difference between the value of a liquidity position and the value of simply holding the deposited assets, caused by relative price changes and pool rebalancing. The loss can become permanent when liquidity is withdrawn. Trading fees and incentives may offset it, but high advertised returns do not guarantee a profitable position after all risks and costs.
- Use a pool with deep liquidity, trade a smaller amount, split a large order, or compare routes through a reputable DEX aggregator. Set a reasonable slippage limit, but avoid an unnecessarily high setting because it permits worse execution and may increase MEV exposure. Check price impact, gas fees, token taxes, and the minimum amount received before signing.
