Stockertim Dictionary · Crypto
Decentralised exchange
Also called DEX
In short
A crypto trading venue run by smart contracts on a blockchain, where users swap tokens directly from their own wallets without an operator holding their funds.
- Intermediate
- Institution
- Checked
In detail
A decentralised exchange, or DEX, replaces the company in the middle with code. Most use an automated market maker: liquidity providers deposit pairs of tokens into a pool, and a formula sets the price according to the ratio of the two tokens held. A trader who wants to swap sends one token to the pool and receives the other, paying a small fee that goes to the liquidity providers. Other DEXs run on-chain order books or route orders across many pools to find the best price.
Because trades settle from the user's wallet, there is no account to open and no custodian that can fail or freeze funds. Anyone can create a market for any token, which is why new tokens often trade first on DEXs. The same openness means fake and scam tokens are listed alongside genuine ones.
DEX trading has its own costs and risks. Each swap pays gas as well as the pool fee. Large trades move the price, called price impact, and prices can shift between signing and execution, called slippage. Bots watch pending transactions and can trade ahead of users in sandwich attacks. Liquidity providers face impermanent loss when prices move. Smart contract bugs can drain pools, and some DEX front ends are controlled by an identifiable team that regulators may treat as an operator.
Worked example
A pool holds 100 ETH and 300,000 stablecoins, and a trader swaps 1 ETH in, ignoring fees, using the constant product rule x × y = k.
- Constant: 100 × 300,000 = 30,000,000
- Stablecoins left after the swap: 30,000,000 / 101 = 297,029.70
- Stablecoins paid out: 300,000 − 297,029.70 = 2,970.30
The trader receives about 2,970 stablecoins, slightly less than the 3,000 implied by the starting price, because of price impact.
In practice
Users connect a wallet to a DEX interface, choose tokens, set a slippage tolerance and sign the swap. Aggregators split orders across several DEXs to reduce price impact.
Watch out
- Check the token's contract address; anyone can list a copy with the same name.
- No custodian also means no one to reverse a mistaken trade.
Learn it properly
Lessons about decentralised exchange
- What is the NGX (Nigerian Exchange)?
- What are ETFs (exchange-traded funds)?
- How crypto exchanges work
- Futures exchanges and contract specifications
- Crypto custody and exchange security
- How derivatives markets are organised: exchanges, over the counter and clearing
- Quoting obligations and designated market makers on exchanges
- How the naira exchange rate affects Nigerian stocks
Official sources
- Decentralized finance (DeFi) · Ethereum open-source project
- Crypto-assets and global stablecoins · Financial Stability Board
Facts last checked on 1 November 2026.
Education, not advice: the Stockertim Dictionary explains what terms mean. It never recommends buying or selling anything.