Chapter 4

Sandwich Attacks

Sandwich attacks are the most visible MEV harm to retail users. A searcher frontruns your DEX swap, then backruns it — extracting value from your slippage tolerance.

You receive fewer tokens than you would at the pre-attack price. Liquidity providers earn extra fees from the attacker's trades — LPs benefit slightly while swappers pay the hidden tax.

Mitigation includes lower slippage tolerance, private transaction submission through Flashbots Protect or MEV Blocker RPCs, and batch auctions through intent-based protocols like CoW Swap and UniswapX.