Automated Market Maker
Published Last updated
Key Takeaway
An automated market maker is a decentralized protocol that enables cryptocurrency trading using algorithm-controlled liquidity pools instead of traditional order books and human or institutional market makers.
Learn These First
What Is Automated Market Maker?
An automated market maker is a decentralized protocol that enables cryptocurrency trading using algorithm-controlled liquidity pools instead of traditional order books and human or institutional market makers.
How Automated Market Maker Works
Frequently Asked Questions
What is an automated market maker in crypto?
An automated market maker (AMM) is a decentralized trading protocol that allows users to swap cryptocurrencies directly against algorithm-managed liquidity pools, without needing a traditional order book or a human counterparty. Prices are set automatically by a mathematical formula based on the current ratio of tokens in the pool. When you buy a token from a pool, you add the paired token, shifting the ratio and pushing the price of the purchased token higher. AMMs are the foundation of decentralized exchanges like Uniswap and PancakeSwap, enabling permissionless trading of any token pair around the clock.
How does an AMM determine the price of a token?
An AMM determines token prices using a mathematical formula applied to the quantities of tokens held in the liquidity pool. The most common formula — the constant product model — maintains the product of the two token quantities as a fixed constant. When a trader buys one token from the pool, they deposit the other token in return, changing the ratio between the two. The formula automatically recalculates the price based on the new ratio. Buying a large amount of a token rapidly shifts the ratio and pushes its price up significantly — a phenomenon known as price impact.
What are the risks of using an AMM compared to a centralized exchange?
Using an AMM carries several risks not present on centralized exchanges. Price impact can be significant on low-liquidity pools, meaning large trades execute at considerably worse prices than displayed. Liquidity providers face impermanent loss — a reduction in the value of their deposited assets relative to simply holding them — when token prices diverge significantly after deposit. Smart contract risk is also present: bugs or exploits in the AMM's code can result in fund losses with no recourse. Additionally, AMMs typically lack advanced order types like limit and stop-loss orders, making precise entry and exit management more difficult than on centralized platforms.
Common Misconceptions About Automated Market Maker
AMMs always provide better prices than centralized exchanges.
AMMs frequently offer worse prices than centralized exchanges, particularly for larger trades or when pool liquidity is shallow. The mathematical pricing curve of an AMM means that every trade moves the price against the buyer, with price impact scaling rapidly as order size grows relative to pool size. Deep centralized exchanges with competitive market makers often provide tighter effective spreads and lower total execution cost for standard trade sizes. AMMs are most competitive for accessing tokens unavailable on centralized platforms, not for achieving the best possible execution price on commonly traded assets.
AMMs are only used by experienced DeFi developers.
AMMs are accessible to any user with a crypto wallet and an internet connection. Platforms like Uniswap, Curve, and PancakeSwap have user-friendly interfaces that allow token swaps in a few clicks without requiring coding knowledge or technical expertise. Connecting a wallet such as MetaMask and approving a transaction is all that is needed to trade. While the underlying mechanisms are technically complex, the user experience has been deliberately simplified for broad accessibility. Understanding the basics of how AMMs work helps users make informed decisions about trade size, slippage tolerance, and platform selection.
AMMs are completely safe because they use smart contracts instead of human custodians.
Smart contracts eliminate the risk of human custodian misconduct, but they introduce their own distinct category of risk. AMM smart contracts can contain coding bugs or design vulnerabilities that malicious actors exploit to drain pool funds. Several major AMM protocols have suffered significant hacks resulting in hundreds of millions of dollars in losses. Smart contracts are also immutable once deployed — errors cannot be easily patched after the fact. Users interacting with AMM protocols should verify that the protocol has undergone reputable third-party security audits and has an established track record before depositing significant funds.