How to use a DEX safely: wallet, contract, slippage, approvals, MEV
A decentralized exchange has no support desk and no undo button. Here is what to check before a swap so your tokens do not end up with scammers or bots.
5 min read · Updated: 2026-10-19
In short
A DEX is an exchange made of smart contracts: you swap tokens straight from your wallet, usually through a liquidity pool and an AMM. Nobody vets the tokens, and nobody refunds you if you make a mistake.
The main risks:
- a fake token with the same ticker;
- a slippage tolerance set too wide, and a sandwich attack;
- unlimited approvals that later drain the wallet;
- phishing sites and wallet drainers;
- tokens you cannot sell (honeypots).
If you are not yet comfortable with a wallet and gas, start with how to buy your first crypto and come back later.
Step 1. Set up the wallet
- Create a separate "working" wallet for DeFi and keep only what you need for current activity in it. Keep your main savings at another address, ideally on a hardware wallet.
- Install the wallet extension only from the link on its official site. Never enter your seed phrase anywhere except the wallet itself during a restore.
- Hold a little of the network's native coin (ETH, BNB, SOL and so on) for gas.
- Open the DEX from a bookmark. Links from search ads, DMs and comments are a common source of phishing.
- When connecting the wallet, check the site address and which network you are on.
Step 2. Check the token contract
Anyone can create a token with the name and ticker of a popular coin. Only the contract address tells the real one apart.
- Take the contract address from the project's official source (website, docs) or a major coin data aggregator, and confirm it in a block explorer.
- Paste the address into the DEX token selector instead of picking by name from search.
- Look at the contract's age, the number of holders, trading volume and pool liquidity. A new token with tiny liquidity is high risk.
- Check whether the contract code is verified and whether it had an audit. An audit lowers risk but does not guarantee safety.
For new tokens, run a honeypot scanner and check the buy and sell tax. If you cannot sell or the tax is 50%+, it is a trap.
Step 3. Set slippage tolerance
Slippage tolerance is how much worse than expected the final price can be before the transaction cancels.
| Situation | Typical tolerance |
|---|---|
| Major pairs, stablecoins | About 0.1–0.5% |
| Regular tokens with good liquidity | About 0.5–1% |
| Volatile tokens with thin liquidity | Higher, but that is a warning sign |
Too low, and transactions often fail while gas is still charged. Too high, and you let bots and the market take the difference.
Example: you swap $1,000 with 10% tolerance. In the worst case you get $900 of tokens and the transaction still goes through. At 0.5%, the worst case is $995.
Also watch the price impact: if your trade alone moves the price several percent, the pool is too small for that amount. A DEX aggregator can help by splitting the swap across pools.
See it in a pictureTap to play the animation
Slippage tolerance is the worst price you accept. At 10% a $1,000 swap can return only $900 of tokens; at 0.5% no less than $995.
Step 4. Approvals and revoking them
Before a DEX can take your tokens for a swap, you give its contract permission: a token approval. Many interfaces suggest an unlimited approval by default.
- Where possible, set the limit to exactly the swap amount.
- Read what you sign. A request for "setApprovalForAll", a "permit" or a signature with no clear description is a reason to stop. Permit signatures also grant spending rights, even though they look like a plain message with no gas.
- Once a month, open an approval checker (block explorers and dedicated revoke tools have them) and revoke everything you do not need. Revoking is a transaction and costs gas.
A hacked or malicious contract with an unlimited approval can take your tokens even a year after the swap. This is how most drainers work.
See it in a pictureTap to play the animation
An unlimited approval lets the contract take all of that token at any time. An approval for exactly the swap amount only puts that amount at risk.
Step 5. MEV and sandwich attacks
MEV is profit that validators and bots make by reordering transactions in a block. The biggest threat to you is a sandwich: a bot sees your buy in the mempool, buys right before you, you buy at a higher price, and the bot sells straight after.
- Keep slippage tolerance as low as works: that is exactly what a sandwich takes.
- Use a protected RPC or an MEV-protection mode if your wallet or the DEX offers one. The transaction goes straight to block builders and never shows up in the public mempool.
- Split large swaps or route them through an aggregator.
- On layer 2 networks MEV works differently, but the risk is not zero.
See it in a pictureTap to play the animation
A bot sees your buy in the mempool, buys right before you and sells right after. You pay more, and the difference goes to the bot.
Scam tokens and other traps
- Honeypot. You can buy but not sell, because the contract blocks sales.
- Rug pull. The creators pull the liquidity from the pool and the price drops close to zero.
- Unknown airdropped tokens. Tokens you never bought appear in your wallet with a site "to claim your reward". Do not touch them and do not connect your wallet to that site.
- Fake support and "wallet sync". No service ever needs your seed phrase.
- Pump and dump in chats. "Buy now before it's too late" is the classic line.
If in doubt, do not sign. A missed opportunity costs less than an empty wallet.
Questions and answers
What slippage should I set on a DEX?
For major pairs and stablecoins, 0.1–0.5% is usually enough, and 0.5–1% for liquid tokens. If a swap only goes through at 5–10%, that points to thin liquidity or a tax in the contract, so better stop.
How do I revoke a token approval?
Open the approval checker in your network's block explorer or a revoke tool, connect your wallet, find the approvals you do not need and revoke them. Each revoke is a separate transaction that costs gas.
How can I tell a real token from a fake one?
Only by the contract address. Take it from the project's official site, confirm it in a block explorer, and paste the address into the DEX instead of searching by ticker.
What is a sandwich attack?
A bot buys a token right before your trade and sells right after, pocketing the price difference within your slippage tolerance. Low slippage and MEV protection help.
Related terms
Read next
An exchange's Earn section pays you for letting your coins work instead of sitting idle. Here is what the products are, where…
Read →Breakout and retest: how to read the setupThe classic scenario: level, breakout, return, and a trade plan with entry, stop and target.
Read →