MEV

Maximal Extractable Value (MEV) — formerly Miner Extractable Value — is the maximum value that can be extracted from users by a party with control over transaction ordering within a blockchain block (originally miners in proof-of-work Ethereum; validators and block builders in proof-of-stake Ethereum). MEV represents a structural feature of public, ordered blockchains: since all pending transactions are visible in the mempool before inclusion, and since block producers can insert, reorder, or omit any transaction, they (or parties that pay them for inclusion priority via priority fees) can systematically profit at users’ expense. The most common MEV forms: frontrunning (detecting a user’s large AMM trade in the mempool; submitting an identical trade first at higher gas; profiting from the price impact the user’s trade will cause), sandwich attacks (buy before + sell after a user’s AMM trade; capture the price movement), arbitrage (scan DEX prices across the pool; insert profitable trades between other transactions), and liquidation MEV (monitor lending protocols; trigger liquidations first; capture liquidation bonuses). The term was introduced by Philip Daian et al. in Flash Boys 2.0 (2019) — named after Michael Lewis’s Flash Boys about HFT frontrunning in traditional markets. Flashbots (launched 2020) transformed MEV from chaotic, gas-war-driven extraction into an organized marketplace (MEV-Boost, PBS) that redirects most MEV value from validators to an efficient builder ecosystem.


Key Facts

  • Concept introduced: “Flash Boys 2.0” paper (Daian et al., 2019)
  • Renamed: Miner → Maximal (post-Merge; validators replaced miners)
  • Cumulative MEV extracted (Ethereum): $1.38B+ (tracked by mev-explore; Flashbots dashboard)
  • Daily MEV (2024): $1-5M per day (varies significantly with market conditions)
  • Major categories: Arbitrage (~60-70% of MEV), sandwich attacks (~20-30%), liquidations (~5-10%)
  • Ecosystem response: Flashbots (MEV ordering marketplace), MEV-Boost (PBS), MEV-Blocker (private RPC)
  • Ethereum state: MEV persists post-Merge; PBS: separated builder and validator roles

MEV Categories

The following sections cover this in detail.

1. Arbitrage MEV (Benign)

Mechanism: When TOKEN_A/ETH price differs across DEXes (Uniswap vs. Curve vs. Balancer), arbitrage bots trade until prices equalize.

Who benefits: Arbitrageur + block builder/validator (receives priority fee)

Who is harmed: No one directly (prices are corrected; service provided)

Volume: ~60-70% of all MEV

Atomic arbitrage example:

  1. USDC/ETH: Uniswap price: 1 ETH = $3,000; Curve price: 1 ETH = $3,010
  2. Arbitrageur (flash loan): buy 100 ETH on Uniswap @ $3,000 → sell 100 ETH on Curve @ $3,010 → $1,000 profit – gas

Benefit to DeFi: Arbitrage MEV is the mechanism that keeps DEX prices aligned with market price; without it, DEXes would have significant stale pricing.

2. Sandwich Attacks (Harmful)

Mechanism: Searcher sees user’s large AMM trade in mempool → inserts buy before + sell after → profits from user’s price impact

Victim: User (receives worse price than expected; sandwich extractor pockets the slippage)

Who benefits: Sandwich bot operator + block builder

Example:

  1. User: submits “buy 100 ETH of PEPE on Uniswap v3; max slippage: 2%”
  2. Sandwich bot: sees in mempool
  3. Bot: submits “buy 50 ETH of PEPE” (high gas; frontrun)
  4. User’s buy: executes (PEPE price: now higher due to bot’s frontrun)
  5. Bot: submits “sell 50 ETH of PEPE” (immediately after user’s buy)
  6. Bot: profit from price movement caused by user

User loss: 0.5-2% of trade value (varies by pool liquidity and slippage setting)

Annual user loss from sandwich attacks: $200-500M estimate

3. Liquidation MEV

Mechanism: Monitor lending protocols (Aave, Compound) for underwater positions → trigger liquidation → capture liquidation bonus first

Liquidation bonus: 5-15% (protocol incentive for liquidators)

Competition: Multiple bots competing → gas wars historically (now: builder APIs)

Who benefits: Liquidation bot + validator

Who is harmed: No one directly (liquidation is necessary for protocol solvency)

4. JIT Liquidity MEV

See JIT Liquidity.


The Dark Forest

Phil Daian et al. characterized Ethereum mempool as a “dark forest” (2019):

  • Everything visible: all pending transactions: public in mempool
  • Predators lurking: bots watching every transaction for MEV opportunities
  • Generalized frontrunners: copy any profitable transaction and frontrun it
  • Users: unprotected (standard transactions are vulnerable)
  • Casualties: users losing millions per year to sandwich bots

Counter-strategy:

  • Private mempool (Flashbots, MEV-Blocker): send transaction directly to builder (not public mempool)
  • Slippage settings: tight slippage → sandwich attack unprofitable
  • Aggregators (CowSwap, 1inch Fusion): route through protected order flow

MEV Economics

The following sections cover this in detail.

Pre-Flashbots (2020)

  • Priority Gas Auctions (PGAs): bots: continuously raise gas → chain congested; gas prices: sky-high for everyone
  • Validators: captured MEV indirectly via priority fees (but: inefficiently; much wasted on gas wars)

Post-Flashbots (2020 onwards)

  • Searchers: submit “bundles” (ordered tx sets) to Flashbots relay
  • Bundles: include “bid” to block builder (portion of MEV as bribe)
  • Builder: orders bundles for maximum profit; pays validator via MEV-Boost
  • Gas wars: eliminated (off-chain coordination)
  • Result: MEV: better organized; less wasteful; more efficient

MEV Distribution (Ethereum post-Merge, 2023)

  • Block builders: ~20% of MEV (for ordering and block construction service)
  • Validators: ~10% of MEV (via MEV-Boost bids from builders)
  • Users: 0% (victims, not beneficiaries)

MEV Protection Solutions

Solution Mechanism Who it helps
MEV-Blocker Private RPC → Flashbots auctions user tx to searchers who refund gas Users (refund)
CowSwap Batch auction (CoW = Coincidence of Wants) → solver competition Users (better price)
1inch Fusion Off-chain resolver auction → best price discovery Users
Flashbots Protect Private mempool → no frontrunning Users
Slippage tuning Tight slippage → sandwich unprofitable Users

Related Terms


Sources

  1. “Flash Boys 2.0: Frontrunning, Transaction Reordering, and Consensus Instability in Decentralized Exchanges” — Daian et al. / Cornell Tech (2019). The original academic paper that identified MEV as a systemic risk on Ethereum — coining the term “Miner Extractable Value,” documenting the scale of mempool-based frontrunning on early DEXes (0x, Bancor, Kyber), modeling the “Priority Gas Auction” (PGA) game theory where bots continuously raise gas prices to frontrun each other, and raising the concern that large MEV could destabilize consensus (validators could be bribed to reorg blocks to recapture large MEV).
  1. “Quantifying MEV: $1.38 Billion Extracted on Ethereum and the Ongoing Challenge of MEV Measurement” — Flashbots / MEV Explore Research (2024). Comprehensive analysis of cumulative MEV extraction on Ethereum — examining the methodology for MEV measurement (transaction graph analysis, profit calculation, on-chain attribution), the major MEV categories and their relative sizes (arbitrage: largest; sandwich: second; liquidation: third), how MEV extraction has changed over time (pre/post-Flashbots; pre/post-Merge), and the challenges in precisely quantifying MEV (some MEV: private and never attributed; JIT liquidity: contested whether it’s MEV or service).
  1. “The MEV Supply Chain: Searchers, Builders, Relays, and Validators in Post-Merge Ethereum” — Paradigm / MEV Ecosystem Research (2024). Analysis of the complete MEV supply chain in post-Merge, post-PBS Ethereum — mapping all participants (searchers: find MEV; builders: aggregate MEV bundles into full blocks; relays: transmit winning blocks to proposers; validators/proposers: select highest-bid block), their economic relationships, the centralization concerns in each layer (builder centralization: top 3 builders: >80% of blocks; relay centralization: Flashbots relay: dominant), and what Ethereum’s ePBS (enshrined PBS) upgrade would change about this supply chain.
  1. “MEV on Non-Ethereum Chains: Solana, Cosmos, and Bitcoin’s MEV Landscape” — Cross-Chain MEV Research (2024). Analysis of how MEV manifests differently on alternative blockchains — examining Solana’s MEV (parallel execution + QUIC-based mempool: different dynamics; Jito Labs: Solana’s Flashbots equivalent; leader-based MEV in Solana’s deterministic leader schedule), Cosmos IBC MEV (cross-chain arbitrage across IBC-connected chains; DEX arbitrage on Osmosis), and whether Bitcoin has MEV (ordinals inscription ordering; Lightning Network HTLC expiry MEV; generally: much less MEV due to absence of AMM DEXes).
  1. “MEV and Ethereum Consensus: The Time-Bandit Attack Threat and Why It Hasn’t Materialized” — Academic / Consensus Security Research (2024). Analysis of the theoretical threat that large MEV poses to Ethereum consensus — examining the “time-bandit attack” (validator reorgs recent blocks to steal MEV from other validators when MEV in a recent block exceeds the cost of reorging it), why this attack is theoretically possible but hasn’t been observed at scale, what concrete mitigations Ethereum has implemented (attestation schedule making reorgs expensive; LMD-GHOST fork choice rule; proposer boost), and whether future MEV growth could eventually make the time-bandit attack economically rational.