An automated market maker, or AMM, is the system many decentralized exchanges use to enable trading without a traditional order book. Instead of matching buyers and sellers, an AMM prices trades using a mathematical formula and a liquidity pool of funds supplied by users.
The formula adjusts the price automatically based on the balance of tokens in the pool. When someone buys one token, its share of the pool shrinks and its price rises slightly; selling does the reverse. This lets trades happen at any time, as long as there are funds in the pool.
AMMs made much of DeFi possible by removing the need for a central party to match orders. They also introduce their own dynamics, such as slippage on large trades and impermanent loss for liquidity providers. Understanding them helps explain how decentralized exchanges work.
Frequently Asked Questions
How does an AMM set prices?
It uses a mathematical formula based on the balance of tokens in its liquidity pool. Buying a token shifts the balance and nudges its price up; selling nudges it down.
How is an AMM different from an order book?
An order book matches individual buyers and sellers, while an AMM prices trades against a pool of funds using a formula, allowing trades without a direct counterparty.