What Is an Automated Market Maker? How AMMs Price Crypto Without an Order Book

Key Takeaways
- An automated market maker trades against a pool of tokens instead of matching buyers with sellers.
- Most pools use a constant product formula, so the price of each asset moves as the reserves change.
- Liquidity providers earn trading fees and receive tokens representing their share of the pool.
- Large trades against thin pools cost more through price impact, separate from the trading fee.
- Concentrated liquidity and custom pool hooks have made AMMs more capital-efficient and more complex.
Ask someone how a trade happens on a traditional exchange and the answer involves two parties: one posting an order, another taking it. An automated market maker removes one of those parties. Instead of matching a buyer with a seller, it lets you trade against a pool of tokens that anyone can contribute to, at a price a formula calculates on the spot.
That single change is why a token with no listing department, no market maker contract and no minimum volume can still be traded the moment someone seeds a pool. It is also why on-chain prices can move in ways that surprise people who are used to order books.
An AMM Is a Pool, Not a Matching Engine
A liquidity pool is a smart contract holding at least two assets, usually a token pair such as ETH and USDC. Traders swap one side for the other directly with the contract. Nobody on the other side of the trade needs to be waiting.
Pricing comes from the balance of the pool rather than from bids and asks. When you buy ETH from an ETH/USDC pool, you add USDC and remove ETH. The pool now holds less ETH and more USDC, so ETH inside that pool becomes more expensive for the next trade. The contract does not decide this; the arithmetic does.
The idea is not new, but the implementation that made it mainstream is. Uniswap deployed its first version to Ethereum mainnet on 2 November 2018, with a small, audited contract that paired every token against ETH. Bancor had published a 2017 whitepaper proposing reserve-backed tokens with continuously calculated prices. What Uniswap added was permissionless simplicity: anyone could create a market for any token, and anyone could supply the inventory.
The Formula That Sets Every Price
Most pools use a constant product rule, written as x × y = k. Here x and y are the amounts of the two tokens in the pool, and k stays constant through trades, ignoring fees.
The numbers are easier than the algebra. Imagine a pool holding 100 ETH and 200,000 USDC. That makes k equal to 20,000,000, and the implied price of ETH is 2,000 USDC, because 200,000 divided by 100 is 2,000.
Now buy with 10,000 USDC. The pool receives the dollars, so it holds 210,000 USDC. To keep k at 20,000,000, its ETH balance has to fall to 20,000,000 ÷ 210,000, which is about 95.24 ETH. You receive roughly 4.76 ETH for 10,000 USDC, an average price near 2,100. The pool's new spot price is 210,000 ÷ 95.24, or about 2,205.
Two things happened in that trade. You paid about 5 percent more than the pre-trade price on average, and you pushed the pool price up by roughly 10 percent. Both effects grow quickly with trade size, which is why large orders are usually split across several pools and venues.
What Liquidity Providers Actually Do
A pool needs inventory, and that inventory comes from liquidity providers. They deposit both tokens in the ratio the pool currently requires and receive LP tokens, which are claims on their share of the reserves. Every swap pays a fee into the pool, so the reserves grow slightly with each trade. When a provider withdraws, they burn LP tokens and take back their share of the larger pool.
On Uniswap's first version the fee was 0.30 percent per swap. Later designs made fees a choice: Uniswap v3 introduced tiers of 0.01, 0.05, 0.30 and 1.00 percent, letting volatile pairs charge more and tightly pegged pairs charge less.
Here is the part that catches new providers. Fees are revenue, not profit. The pool's two assets drift in value relative to each other, and a provider can end up holding more of the asset that fell and less of the one that rose. That divergence, usually called impermanent loss, can exceed the fees earned. Our guide to impermanent loss walks through the arithmetic.
Where the Price Comes From
A pool does not know what ETH costs elsewhere. It only knows its own reserves. If ETH trades at 2,400 on the wider market while a pool implies 2,205, arbitrageurs buy from the pool and sell elsewhere until the gap closes. That activity is what keeps on-chain prices honest, and it is profitable for whoever gets there first.
The practical consequence is that AMM prices are always a few basis points behind the market, and the trading bots doing the correcting are the same bots that compete for ordering within each block. Cheap, deep pools narrow the gap. Thin pools leave it wide, which is a hidden cost for anyone trading in them.
Slippage, Fees and the Cost of a Swap
Three separate costs get confused with each other.
- **Fee** is the fixed percentage the pool charges and pays to liquidity providers.
- **Price impact** is the movement your own order causes in the pool, and it depends on your size relative to the reserves.
- **Slippage** in the strict sense is the difference between the quote you saw and the price you got, which also includes other trades landing first.
In the example above, a 10,000 USDC order into a 200,000 USDC pool carried a 5 percent average premium before any fee. Halve the order and the premium falls to roughly 2.5 percent; double it and the cost climbs faster than the size does. This is why the same swap can cost a fraction of a percent on one venue and several percent on another.
Concentrated Liquidity Changed the Math
The original constant product curve spreads liquidity evenly from a price of zero to infinity. In practice, almost none of that capital is ever used. Uniswap's own research noted that the v2 DAI/USDC pair kept only about 0.50 percent of its capital available for trading between $0.99 and $1.01, the range where a stablecoin pair actually trades.
Uniswap v3, deployed on 5 May 2021, let providers choose a price range. Capital inside the range behaves like a much larger position, so the same deposit can earn more fees, and each position became a non-fungible token because ranges differ. Providers can also set narrower ranges to charge more per dollar of liquidity.
The trade-off is real. If the price leaves your range, your position converts entirely into the weaker asset and stops earning. Concentrated liquidity rewards active management and punishes set-and-forget deposits, especially in volatile pairs.
Different Pools Solve Different Problems
Constant product is a default, not a rule of nature. Curve built its StableSwap pools around an invariant that keeps pegged assets close to parity, which is why stablecoin and wrapped-asset pools there trade with very low slippage. Balancer generalised the idea to pools with more than two tokens and custom weights.
Uniswap v4, live on mainnet since 30 January 2025, took a different route: a singleton contract that holds all pools, plus hooks that let developers attach custom logic to a pool's lifecycle. Dynamic fees, on-chain limit orders and other behaviour can now be built without forking the core protocol. Uniswap has said the singleton design can cut pool creation gas costs by up to 99 percent compared with deploying a separate contract per pool.
What Can Go Wrong
An AMM is only as safe as its design and its inventory.
Smart contract bugs and oracle assumptions have drained pools before, and a pool holding a newly launched token inherits that token's risks, including the possibility that its contract can mint or freeze balances. Sandwich attacks, where a bot places trades on both sides of yours, are a form of value extraction that pool design and private transaction routing try to reduce but do not eliminate. Very thin pools are also easy to push around, which makes the quoted price unreliable for anything larger than a test trade.
None of this is exotic. Anyone supplying liquidity should assume they are underwriting both assets in the pair and the code holding them.
Why AMMs Matter Beyond Swapping
AMMs turned liquidity into something a contract can hold, which made a long list of other products possible: collateralised lending, on-chain derivatives, and yield strategies that route deposits between pools. Our explainer on decentralised exchanges covers how these venues fit together.
Their market share is growing but still modest. CoinGecko's Q2 2026 report put DEX spot volume at 13.6 percent of total spot trading in January 2026, up from 6.9 percent in January 2024, with monthly DEX volume rising from $95.86 billion to $231.29 billion over the same period. Centralised exchanges still handle the large majority of spot volume; AMMs dominate where permissionless listing and self-custody matter more than raw throughput.
How to Judge a Pool Before You Use It
Four numbers tell most of the story. Total value locked shows the depth available, and comparing it with daily volume shows how hard the pool is working. The fee tier tells you what a swap costs and what providers earn. The token pair tells you what you are exposed to. And for concentrated positions, the range tells you how much movement the position can absorb before it goes idle.
An automated market maker is a simple machine with complicated edges. The formula is a few lines of arithmetic; the skill is in reading the pool around it.
DISCLAIMER
This article is for informational purposes only and does not constitute financial advice. Cryptocurrency investments involve substantial risk and extreme volatility - never invest money you cannot afford to lose completely. The author may hold positions in the cryptocurrencies mentioned, which could bias the presented information. Always conduct your own research and consider consulting a qualified financial advisor before making any investment decisions.









