Encyclopedia Classification
Category: Decentralized Finance • Market Infrastructure • Trading Algorithms
Discipline: Financial Engineering • Mathematics • Smart Contracts • Economics
Prerequisites
- Article 95 — Decentralized Finance (DeFi)
- Article 96 — Decentralized Exchanges (DEXs)
- Article 57 — Smart Contracts
- Article 94 — Liquid Staking
- Article 86 — Merkle Trees
Related Articles
Liquidity Pools • Impermanent Loss • Decentralized Exchanges • Trading Algorithms • DeFi Economics
Definition
An Automated Market Maker (AMM) is a decentralized trading mechanism that uses mathematical formulas and liquidity pools to determine asset prices and execute trades without requiring traditional buyers and sellers to match orders.
Beginner Explanation
Traditional markets work through:
Buyers and sellers.
Example:
Someone wants to buy Bitcoin.
Another person wants to sell Bitcoin.
An exchange matches them.
This is called:
An order book model.
AMMs work differently.
Instead of matching people:
They use a pool of assets.
Example:
A pool contains:
ETH + USDC
A trader swaps one asset for another.
The AMM automatically calculates:
- Price
- Amount received
- Fees
The formula replaces the human market maker.
Why AMMs Were Created
Before AMMs:
Decentralized exchanges struggled.
Problems:
- Low liquidity
- Slow order matching
- Poor user experience
- Expensive transactions
AMMs solved a major problem:
How can markets exist without centralized market makers?
The answer:
Liquidity pools + mathematics.
The History of AMMs
Traditional Market Makers
In traditional finance:
Market makers provide liquidity.
They continuously offer:
- Buy prices
- Sell prices
They profit from:
The spread.
Example:
Buy:
$99
Sell:
$101
Difference:
$2 spread.
Early Crypto Exchanges
Early crypto markets relied on:
Order books.
Challenges:
- Few traders
- Low liquidity
- Large price spreads
The AMM Breakthrough
AMMs introduced:
Algorithmic liquidity.
Instead of relying on companies:
Users provide liquidity.
This created:
A permissionless financial market.
How an AMM Works
A basic AMM contains:
1. Liquidity Pool
A smart contract holding assets.
Example:
ETH/USDC Pool
Contains:
- ETH
- USDC
2. Liquidity Providers
Users deposit assets.
They earn:
Trading fees.
3. Mathematical Formula
The formula determines:
- Exchange rate
- Pool balance
- Trade output
The Basic Constant Product Model
The most famous AMM formula:
x × y \= k
Where:
x \= Amount of one asset
y \= Amount of another asset
k \= Constant value
Example:
A pool contains:
100 ETH
and
300,000 USDC
The formula:
100 × 300,000
\=
30,000,000
The pool must maintain this relationship.
How a Trade Changes the Pool
A trader buys ETH.
They add:
USDC
They remove:
ETH
The formula adjusts the price.
As ETH becomes scarcer:
The price increases.
This creates:
Automatic price discovery.
Price Curves
AMMs create mathematical curves.
Small trades:
Small price changes.
Large trades:
Larger price movement.
This protects liquidity providers from sudden depletion.
Liquidity Providers (LPs)
Definition
Users who deposit assets into AMM pools to enable trading.
Example:
A user provides:
50 ETH
150,000 USDC
The pool becomes deeper.
Traders pay fees.
LPs receive a portion.
Why People Provide Liquidity
The incentive:
Earn yield from trading activity.
Revenue sources:
Trading Fees
Every swap generates fees.
Protocol Rewards
Some systems distribute additional tokens.
Governance Benefits
LPs may receive voting power.
Impermanent Loss
One of the most important AMM concepts.
Definition
The difference between holding assets separately and providing them as liquidity when prices change.
Example:
You own:
1 ETH
$3,000 USDC
ETH price:
$3,000.
You provide liquidity.
ETH rises to:
$6,000.
The AMM automatically adjusts your position.
You may now own:
Less ETH.
More USDC.
Compared with simply holding ETH:
You may have earned less.
Why Impermanent Loss Happens
The AMM always maintains balance.
When prices move:
Arbitrage traders rebalance the pool.
LPs absorb the change.
Impermanent Loss Example
Starting pool:
50 ETH
+
150,000 USDC
ETH doubles.
External market:
ETH \= $6,000.
Arbitrage traders buy cheaper ETH from the pool.
Pool changes:
Less ETH.
More USDC.
The LP earns fees.
But may underperform holding.
Concentrated Liquidity
A major AMM innovation.
Older AMMs:
Liquidity exists across all possible prices.
Problem:
Much liquidity sits unused.
Concentrated liquidity allows:
LPs to choose price ranges.
Example:
Instead of providing liquidity:
$0–$1,000,000 ETH range.
A provider chooses:
$2,500–$3,500.
Benefits:
- Higher capital efficiency
- More trading fees
Risks:
- More management complexity
- Liquidity can become inactive
Uniswap and AMM Innovation
One of the most influential AMM designs came from:
Uniswap
Major innovations:
- Permissionless pools
- Automated pricing
- User-provided liquidity
It became a foundation of DeFi.
AMM vs Order Books
| Category | AMM | Order Book |
|---|---|---|
| Liquidity Source | Pools | Buyers/sellers |
| Pricing | Formula | Market bids |
| Market Makers | Users | Professionals |
| Speed | Blockchain dependent | Exchange dependent |
| Capital Efficiency | Lower historically | Higher |
| Decentralization | Higher | Variable |
AMM Risks
1. Smart Contract Risk
A bug can affect pool funds.
2. Impermanent Loss
Asset price changes impact LP returns.
3. Low Liquidity
Creates:
- High slippage
- Poor execution
4. Oracle Dependence
Some systems require external price information.
5. Economic Attacks
Attackers may exploit:
- Pool design
- Incentives
- Pricing mechanisms
AMMs and Arbitrage
Arbitrage keeps AMM prices aligned.
Example:
DEX price:
ETH \= $2,950
Other exchange:
ETH \= $3,000
Trader buys cheap ETH.
Pool adjusts.
This process keeps markets efficient.
AMMs and MEV
Because trades are visible before confirmation:
Bots can exploit ordering.
Common strategies:
- Arbitrage
- Sandwich attacks
- Liquidation competition
Future AMMs may use:
- Private transaction systems
- Better ordering mechanisms
- Fair sequencing
AMMs Beyond Exchanges
AMM concepts are expanding into:
Lending
Automated interest rates.
Derivatives
Automated pricing.
Prediction Markets
Continuous liquidity.
Insurance
Risk pools.
The Future of AMMs
Better Capital Efficiency
Future AMMs may improve:
- Liquidity usage
- Pricing
- Risk management
Cross-Chain AMMs
Users may trade across:
Multiple blockchains.
AI-Optimized Liquidity
AI may help:
- Select price ranges
- Manage risk
- Optimize returns
Institutional AMMs
Traditional finance may use:
Automated liquidity systems for tokenized assets.
Common Misconceptions
"AMMs eliminate market makers."
Not exactly.
They replace traditional market makers with:
Liquidity providers and algorithms.
"Providing liquidity always earns money."
False.
Returns depend on:
- Fees
- Price movement
- Impermanent loss
"AMM prices come from nowhere."
False.
Prices emerge from:
Pool balances + external arbitrage.
Key Takeaways
- AMMs allow decentralized trading without traditional order books.
- Liquidity pools replace centralized market makers.
- Mathematical formulas determine prices automatically.
- Liquidity providers earn fees but face impermanent loss.
- Concentrated liquidity improved capital efficiency.
- AMMs are one of the most important innovations in DeFi.
- Automated markets are turning financial systems into programmable infrastructure.
Related Encyclopedia Articles
- Decentralized Exchanges
- Liquidity Pools
- Impermanent Loss
- DeFi
- Smart Contracts
- Yield Farming
- Tokenomics
- Market Structure
Encyclopedia Notes
Automated Market Makers changed the foundation of financial markets.
Traditional finance:
Humans create liquidity.
AMMs:
Algorithms create markets.
The innovation was not simply removing an intermediary.
The innovation was creating a system where:
Mathematics.
Code.
And economic incentives.
could operate together to create a global trading system.