What is a DEX in crypto? Decentralized exchanges explained
DEX stands for decentralized exchange: a crypto trading platform run by smart contracts instead of a company. You connect your own wallet and swap one token for another directly on the blockchain, without opening an account, handing over your coins or passing an identity check. Uniswap is the best-known example. The trade-off: there is no company to help you, and no regulator to protect you if something goes wrong.
What is a DEX in crypto?
A decentralized exchange (DEX) is a peer to peer marketplace for crypto tokens and other digital assets that works without a central authority or centralized intermediary. Users trade directly from their own wallets, and smart contracts execute trades without user accounts. Unlike centralized exchanges, which custody user assets, a DEX never takes your tokens: there’s no depositing funds first, the tokens stay in your wallet until the trade is executed, and the swap happens in one blockchain transaction.
DEXs are a core part of decentralized finance (DeFi). Many offer permissionless token swaps: anyone can list a token, and anyone can trade it.
The “exchange” is really a set of smart contracts on a blockchain such as Ethereum, BNB Smart Chain (formerly Binance Smart Chain) or Solana. The website you see is just a user interface through which users access those contracts. Even if the website went offline, the contracts would keep working.
How do decentralized exchanges work?
Most decentralized exchanges work with automated market makers (AMMs) and liquidity pools instead of an order book. Rather than matching individual buyers and sellers, the DEX lets you trade against a pool of tokens that other people have deposited.
Automated market makers (AMMs) and liquidity pools
A liquidity pool holds two or more tokens, for example ETH and a stablecoin. Liquidity providers deposit both tokens and earn a share of the trading fees generated by every swap. An automated market maker uses a mathematical formula to set the pool price: when you buy ETH from the pool, there is less ETH left, so the price of the next ETH goes up. Pools with more trading volume earn liquidity providers more fees, but liquidity providers also take on risks such as impermanent loss.
The more tokens in a pool, the smaller the effect of each trade. That is called liquidity depth. In a small pool, a large trade has a significant price impact, which is why pools offering deep liquidity give better prices.
Order book DEXs and DEX aggregators
Some DEXs use an order book, like traditional exchanges, so you can place limit orders. Others, called DEX aggregators, don’t hold liquidity themselves: they search many DEXs and split your trade to find the best price and minimize slippage. Some also offer cross chain swaps between different blockchains.
How to use a DEX: a swap step by step
Using a DEX takes a few steps, and you need crypto in a self-custody wallet first, because you can’t pay in from a bank account.
- Buy crypto on a licensed exchange. Buy ETH with euros on a centralized exchange authorised under MiCA.
- Withdraw to your own wallet. Send it to your crypto wallet on the right network. For transfers above €1,000, the exchange must check the wallet is yours under the travel rule.
- Open the DEX’s official site. Type the address yourself or use a bookmark, and connect your wallet.
- Choose the tokens. Pick what you sell and what you buy. Check the token contract address against the project’s official sources, because anyone can create a token with the same name.
- Review and confirm. Check the price, the price impact, the slippage setting and the network fee, then sign the transaction in your wallet.
What a DEX swap costs
A DEX swap has three execution costs: the swap fee, the network’s transaction fees and price impact. Say you swap €500 of ETH for another token in a pool with a 0.30% fee, the rate in Uniswap’s original pools. The swap fee is €1.50. If the gas fee is €2 at that moment, you pay €3.50 in total, before any price impact or slippage. On a layer 2 network with lower transaction fees the gas part is usually much smaller; on Ethereum’s main network at a busy time, it can be higher than the swap fee. So a DEX trade can have lower trading fees than some exchanges for large swaps, while gas wipes out those lower fees on small ones.
DEX vs CEX: centralized and decentralized exchanges compared
The difference between a DEX and a centralized exchange (CEX) is who holds your funds and who runs the trading platform.
| DEX | Centralized exchange (CEX) | |
|---|---|---|
| Who holds your crypto | You, in your own wallet | The exchange |
| Account and KYC | Usually none | Required by law |
| Pay with euros | No | Yes, by SEPA, card or iDEAL |
| Tokens available | Almost any token, including scams | A curated list |
| Fees | Swap fee plus gas fees | Trading fees, sometimes a spread |
| Advanced trading tools | Limited | Order types, charts, often derivatives |
| Support if something goes wrong | None | Customer service and complaints |
| EU regulation | Usually outside MiCA | Must be MiCA-licensed |
Centralized exchanges remain the easiest way to change euros into crypto and back, and offer more advanced trading features. DEXs give you more user control, no counterparty risk from an exchange going bust, and access to crypto assets a CEX doesn’t list. Many people use both: a licensed CEX as the on-ramp, a DEX for specific tokens.
Is Coinbase or Binance a DEX?
No. Coinbase and Binance are centralized exchanges: companies that hold customer funds, check identities and run their own order books. Binance has no MiCA licence, so it is not an option we recommend for EU residents. Uniswap and PancakeSwap, by contrast, are DEXs.
Why a decentralized exchange (DEX) matters to you
A DEX matters to you because it gives you full control, but also full responsibility: you keep your private keys, and nobody can undo your mistakes. On a CEX, the company must keep your funds separate, check what it lists and handle complaints. On a DEX, nobody vets the tokens, and decentralized trading falls largely outside MiCA when no company is in between.
Two EU points to keep in mind:
- Reporting obligations stay with you. In Germany, swapping one token for another usually counts as a sale for tax purposes; in the Netherlands, your tokens count towards box 3 wealth. A DEX doesn’t send you a tax statement, so keep records of your DEX transactions.
- Compliance applies at the edges. When you move funds between your wallet and a licensed exchange, the travel rule and the exchange’s anti money laundering checks still apply.
DEX risks to watch
The main risks on decentralized platforms are not about the exchange going bust but about code and your own mistakes. Your risk tolerance should match these:
- Fake tokens and rug pulls. Anyone can list a token. Copycat tokens and rug pulls are common.
- Smart contract vulnerabilities. Bugs and smart contract exploits have drained user funds from DEXs and pools.
- Phishing. Fake DEX sites ask you to approve a transaction that empties your wallet.
- Front-running bots. On public blockchains, bots can see your pending trade and place their own trade ahead of it, so you get a worse price. A tight slippage setting limits this.
- Wrong network. Sending tokens on the wrong network can make them hard or impossible to recover.
The bottom line
A DEX lets you trade crypto without trusting a company: you keep your keys, and smart contracts do the rest. That makes it powerful for experienced users and risky for beginners. If you’re new, start on a licensed centralized exchange, and only try a DEX with a small amount once you understand wallets, gas fees and token addresses.
Related terms
Questions people ask
How do DEXs make money?
Most DEXs charge a small swap fee on every trade, which mainly goes to the liquidity providers whose tokens are in the pool. Some protocols also take a share for their treasury, which token holders govern.
What is the difference between a CEX and a DEX?
A centralized exchange (CEX) is a company that holds your crypto, checks your identity and lets you pay in euros. A DEX is a set of smart contracts: you keep your private keys and trade directly from your wallet, but there is no support desk and no investor protection.
Is Uniswap a DEX or CEX?
Uniswap is a DEX. It runs as smart contracts on Ethereum and other networks, uses automated market makers and liquidity pools, and never holds your funds.
Is Binance a CEX or DEX?
Binance is a centralized exchange: a company that holds customer funds and runs its own order book. Binance has no MiCA licence, so we don't recommend it for EU residents.
Is a decentralized exchange safe?
A DEX removes the risk of an exchange losing your funds, but adds others: smart contract bugs, fake tokens, phishing sites and irreversible mistakes. Use well-known DEXs, check token contract addresses and start with small amounts.