Towards Fairer DEXs on Ethereum

This article is a summary of the talk @fleupold_ presented at Devcon VI.


  • Many are unaware of the issue as they use AMMs without noticing the toxic MEV happening behind the scenes
  • A fair market should protect from the dangers of MEV — but, currently, decentralized exchanges are not fair to their users because they settle multiple transactions in the same block at different prices
  • In order for DeFi to reach its full potential, we must fix MEV. We can start by designing DEXs that enforce the principal of “one price per token per block”
Towards Fairer DEXs on Ethereum, presented by Felix Leupold at Devcon VI

Towards Fairer DEXs on Ethereum

DeFi has a lot of room to grow, but in order to achieve its full potential, it must first ensure its markets are fair — which means fixing MEV.

Figure 1: Table showing daily trading volume in billions for each asset class.

The art of designing markets

  • Thickness — a large enough number of buyers and sellers need to be brought together;
  • Safety — participants should be incentivized to truthfully reveal their preferences;
  • The ability to overcome congestion — market participants should have the means to make satisfactory choices when faced with a variety of options

While DEXs can rely on Ethereum scaling as a way to overcome congestion, protocols can help increase market thickness and safety. Market participants must honestly express their trading preferences to ensure a safe market.

Figure 2: Uniswap trade highlighting the slippage tolerance.

Building safety on top of AMMs

The current issue with DEXs is that they are susceptible to MEV, and therefore inherently unsafe. When a user submits a transaction on Uniswap, they need to add a discount on the fair market price called slippage tolerance. This communicates how much volatility a user is willing to accept for a given trade — set it too little and your trade will not go through (which in turn costs ETH), set it too high and your trade will be vulnerable to an MEV attack.

The root cause of MEV on Ethereum is that one asset can have many different prices in the same block. Let’s take, for example, block 14673043, where a whopping 11 trades of the ETH/USD pair were performed in a single block with eight different prices. When prices depend on intra-block ordering, the market can become unsafe.

Figure 3: Slippage used across exchanges.

Providing one price per token per block is the solution to ensure fairness in the market. Instead of executing the transactions sequentially one after another, batching transactions together ensures a uniform clearing price so each block has a consistent price. The root cause of the majority of MEV in the market is that a single asset can have many different prices, one price per token per block solves this. It is a crucial principle that must exist, for a safe market to function effectively and reduce the overall MEV captured back to its users.

How do CoW Swap batch auctions work?

CoW Protocol aims to find the uniform clearing price and the best execution path where demand equals supply. Batch builders are required to find the best path for the batch by optimizing for maximum user surplus. A permissionless competition allows for distributed solving based on different heuristics and algorithms. The best solution for a given batch is then rewarded in the form of $COW.

Figure 4: Slippage used across exchanges.

For example, the traders below (Figure 5) are exchanging $FOLD for $USDC, and vice versa. A Coincidence of Wants (COW) is formed because the users can directly trade against one another. The remainder of the trade is swapped on Sushiswap and Uniswap. By matching COWs together the overall saving for the batch was $2300 ($800 from reduced LP fees and $1500 in reduced price impact as the majority of the trade was not routed through a DEX).

Figure 5: Two traders exchanging $FOLD and $USDC on Cowswap.

The future of DEXs on Ethereum

CoW Protocol along with batch builders can create a liquid and safe market for the average crypto user. Traditional finance models do not work in a decentralized world and the crypto community needs to work together to encourage MEV minimization.

The current market share of the global trading volume is tiny in comparison to what is possible. It is mutually beneficial for everyone in the Ethereum ecosystem to work together and grow the Ethereum TVL and take a higher market share in the global trading volume.

To find out more about the future of DEXs, watch Felix Leupold’s talk from DevCon VI.

About CoW DAO

Check out our website

🐦 Twitter| 📒 Documentation| 💬 Discord | 📊 Analytics | 📸 Snapshot



CoW Protocol finds the lowest price for your trade across all exchanges and aggregators, such as Uniswap & 1inch — and protects you from MEV, unlike the others

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
CoW Protocol

CoW Protocol finds the lowest price for your trade across all exchanges and aggregators, such as Uniswap & 1inch — and protects you from MEV, unlike the others