Sign Up Free
MEV in crypto shown as DeFi swap packets passing through a transaction-ordering gate before block confirmation

MEV in Crypto: Who Profits Before Your Transaction Settles?

defi ethereum intermediate security

MEV, short for maximal extractable value, is the profit a participant can capture by choosing which transactions to include, exclude, or reorder inside a block. Most people see a swap quote and a slippage setting, but never see the hidden market that decides what happens to their transaction between the moment they click Submit and the moment it confirms.

Key Takeaways

  • MEV is value extracted from block production by including, excluding, or reordering transactions, beyond standard block rewards and gas fees.
  • MEV is not a single attack and it is not the same as a gas fee. It is a market built on whoever controls transaction ordering.
  • Some MEV keeps markets working, such as arbitrage and liquidations. Some of it worsens your execution, such as sandwich attacks. Much of it sits in between.
  • Most "MEV protection" does not delete MEV. It changes who can see your order, who competes for it, who keeps the surplus, and who you have to trust.
  • No one can measure the true size of MEV, because private order flow, failed attempts, and different counting methods all distort the numbers.

To understand MEV, it helps to know that a blockchain does not simply run your transaction the instant you send it. Your transaction first has to be selected and placed in a specific position inside a block. Whenever the order of transactions changes who ends up better or worse off, that ordering has a price. According to the Ethereum Foundation's documentation, MEV is the maximum value that can be extracted from producing a block in excess of the normal reward and fees by adding, removing, or changing the order of transactions.

Maximal Extractable Value (MEV)

MEV is the value a block producer or related party can capture by controlling which transactions go into a block and in what order. It exists because transactions must be selected and sequenced, not just executed.

Plain version: if moving your transaction earlier, later, or out of the block changes who profits, that control is worth money. MEV is that money.

The term used to be "miner extractable value." That changed for a concrete reason. Ethereum's move to proof of stake in September 2022, known as the Merge, replaced miners with validators as the people who propose blocks. Once miners were no longer the only actors who could influence ordering, the community widened the term to "maximal" extractable value to cover validators, specialized block builders, sequencers, and other parties. If you want the background on where validator rewards come from in the first place, we cover where Ethereum validator rewards come from in a separate explainer.

One quick clarification before the mechanics. MEV is not a gas fee. A gas fee is the price you pay to get your transaction processed, and we explain how Ethereum gas fees and transaction priority work on their own. MEV is the underlying ordering value that makes some positions in a block worth fighting over in the first place. Gas and priority payments are often how that fight gets paid for. They are the cost of winning, not the prize.

What happens between Submit and Confirmed

Imagine you are swapping one token for another on a decentralized exchange. Your wallet shows a quote, you accept a slippage setting, and you click Submit. From your side, the transaction confirms a few seconds later. Inside those few seconds, your transaction travels through a supply chain of specialized actors, and several of them can profit from how it is handled. Each role below has its own name, and if any term is new, the crypto glossary is a quick place to check it.

A DeFi Swap From Submit to Confirmed

Submit
 
Confirmed
1
Wallet and routing
Your wallet sends the signed transaction to an RPC or order-flow provider. That provider decides whether it goes to a public broadcast pool or a private route.
2
Visibility
If the transaction enters a public mempool, anyone can see it pending. If it is routed privately, only selected parties see it before inclusion.
3
Searchers and solvers
Specialized bots scan for profitable reorderings. A searcher might bundle transactions around yours. A solver might compete to fill your intended outcome.
4
Builders and relays
Block builders assemble candidate blocks to maximize total value. On Ethereum today, relays pass these blocks to validators without revealing the contents early.
5
Proposer and settlement
A validator proposes the most valuable block it is offered. The network confirms it. Your output, the searcher's profit, the builder's margin, and the validator's payment all settle at once.

Framework: Blockready educational synthesis based on Ethereum Foundation MEV documentation and Flashbots MEV-Boost documentation cited in the article. Simplified; real routing varies by wallet, chain, and provider.

This supply chain matters because it separates the people who originate transactions from the people who decide block contents. After the Merge, Ethereum mostly runs this market through external software called MEV-Boost. Flashbots, which builds MEV-Boost, describes it as a way for validators to access a competitive market of externally built blocks, so a small validator can earn block-building revenue without running sophisticated search infrastructure. The European Securities and Markets Authority, in its 2025 analysis of MEV, treats this same chain of searchers, builders, relays, and proposers as a market-structure question, not just a technical curiosity.

Notice what is happening to your single swap. You have not done anything unusual. You accepted a quote and signed a transaction. But because that action becomes visible or inferable, and because it changes on-chain prices, it creates an opportunity that other parties can compete to capture. The swap mechanics themselves, such as how a pool prices your trade, are a separate topic. We cover how liquidity pools and AMMs price a swap in detail, so this article stays on the ordering market that sits on top of them.

Price impact, slippage, and MEV are not the same thing

These three ideas get blended together constantly, and the confusion is expensive because it hides who is actually responsible for a bad fill. They describe different things.

Three Things People Confuse

 
Price Impact
Slippage Tolerance
MEV
What it is
Price movement your own trade causes against the pool
The worst price you agree to accept before the trade fails
Value captured by controlling transaction order
Caused by
Your trade size versus available liquidity
A setting you or your wallet choose
Other parties acting on your visible transaction
Who controls it
You, by sizing the trade
You, by setting the limit
Whoever orders the block

Framework: Blockready educational synthesis based on AMM and MEV sources cited in the article. For pool pricing mechanics, see the linked liquidity pool explainer.

Here is the connection that trips people up. A loose slippage setting is what gives a sandwich attacker room to work. Price impact is unavoidable physics of trading against a pool. MEV is what someone else does with the gap your slippage setting leaves open. Tightening slippage shrinks the attacker's room, but it also makes your transaction more likely to fail in a fast market. There is no free setting that removes all of this at once, which is part of why MEV is a tradeoff rather than a bug to be patched.

Who gains and who pays

The single most useful question to ask about any MEV strategy is not "is this allowed." It is "where does the value come from, and where does it go." Once you trace that, the moral simplicity disappears. Some MEV is genuinely useful. Some of it lands directly on you. Most of it depends on the details.

Who Gains and Who Pays, by MEV Type

Arbitrage

A pool price drifts away from the wider market.

Who gains: the searcher who corrects the price, and indirectly traders who then get fairer prices. Who pays: liquidity providers exposed to that stale price, and sometimes the user whose trade created the gap.

Verdict: useful for markets, but still a transfer of value, not free money.

Liquidations

A borrower's position becomes unhealthy and must be closed.

Who gains: the searcher who executes the liquidation and earns a bonus. Who pays: the borrower, through the liquidation penalty. Who benefits structurally: the lending protocol, which stays solvent.

Verdict: functional and often necessary, but harsh during volatility.

Sandwich attack

A visible swap will move a price, and slippage tolerance leaves room.

Who gains: the attacker, who buys just before you and sells just after. Who pays: you, through a worse fill than you would have gotten alone.

Verdict: direct user harm. This is the form most people picture when they think MEV is theft.

Back-running and JIT liquidity

A large trade or pending swap creates a follow-on opportunity.

Who gains: a searcher placing a trade right after yours, or a provider adding liquidity for one block to capture your fees. Who pays: passive liquidity providers, or no one in particular.

Verdict: genuinely ambiguous. The effect depends on design and on who receives the surplus.

Framework: Blockready educational synthesis based on Ethereum Foundation MEV documentation, DeFi protocol mechanics, and academic research cited in the article. Not financial advice.

The liquidation example connects to a much larger market dynamic. When prices move sharply, liquidations can cascade and searchers race to execute them, which is its own subject. We explain how crypto liquidations work and why they cluster, so here it is enough to see that the bonus paid to a liquidator is a real example of ordering value with a clear winner and a clear payer.

This is also where a common and understandable mistake shows up. A lot of newcomers conclude, after one bad swap, that every bot in crypto is stealing from them, and that the answer is to crank slippage down to almost nothing. That instinct is half right. Sandwich attacks are real, and loose slippage invites them. But pushing slippage too tight in a volatile pool mostly produces failed transactions and wasted gas, while doing nothing about arbitrage or liquidations, which are not attacks on you at all. The fix is understanding the mechanism, not fearing every bot.

Functional, harmful, ambiguous, and systemic

It helps to sort MEV into four buckets rather than a good-versus-bad split. Functional MEV, such as arbitrage and liquidations, keeps prices aligned and lending markets solvent. Harmful MEV, such as sandwich attacks, transfers value away from a specific user through worse execution. Ambiguous MEV, such as back-running, just-in-time liquidity, and solver surplus, depends on transparency, competition, and who keeps the surplus.

The fourth bucket is the one that gets the least attention and may matter most: systemic MEV. This is not about your single swap. It is about whether the chase for ordering value quietly pushes block production into the hands of a few powerful intermediaries. The Ethereum Foundation's roadmap on proposer-builder separation frames MEV as a centralization risk, because sophisticated builders, relays, and order-flow deals can concentrate the ability to decide what goes into blocks. Related concerns include censorship, where some transactions get excluded, and time-bandit incentives, where reorganizing recent blocks to grab past MEV could threaten consensus stability. The real long-term worry is not one sandwich. It is who controls the ordering machine.

Why nobody can measure the true size of MEV

If you have seen a headline claiming a precise dollar figure for "total MEV," treat it with caution. Several different quantities get lumped together. Theoretical MEV is the most that could have been extracted under perfect play, and it is not directly observable. Detected MEV is whatever a particular analytics tool's heuristics can spot, which misses private and novel strategies. Realized value is what actually got captured. And gross revenue is not net profit, because failed bundles, gas, builder payments, and inventory risk all eat into it.

Regulators say the same thing. ESMA's 2025 report stresses that MEV is difficult to quantify, and the figures it cites come from third-party dashboards rather than its own measurement. As an illustration of scale, one historical post-Merge dashboard tracked more than 526,000 ETH in realized extractable value on Ethereum from the Merge through early June 2024, a figure ESMA reproduced from upstream Flashbots data in its MEV report. That number is useful only with its caveats attached. It is historical, it depends on one provider's methodology, the dashboard was later discontinued, and it does not equal net profit or the true total. The honest summary is that MEV is large enough to fund an entire industry and impossible to pin to a single trustworthy number.

What "MEV protection" actually changes

This is where most guides oversell. A private RPC, a protected route, or a fair-ordering scheme rarely deletes MEV. It moves where the value can be captured and changes who you have to trust. Reading a protection claim well means asking four plain questions: does it stop harmful reordering, does it hide your order until it commits, does it return extracted value to you, or does it simply shift extraction into a less visible venue run by a trusted party.

Protection Claims vs Reality

Myth

Private transactions are MEV-free

If the public mempool cannot see it, no one can profit from it.

Reality

Private routing changes who can see it, not whether value exists

A private route hides your order from the public crowd, but the builder, solver, or provider you routed through can still hold privileged access.

Myth

MEV-Boost solved MEV

Validators use it, so the problem is handled.

Reality

MEV-Boost reorganized who captures block revenue

It opened block building to a competitive market and shared revenue more widely. It did not remove ordering value, and it introduced builder and relay dependence.

Framework: Blockready educational synthesis based on Ethereum Foundation and Flashbots documentation cited in the article.

Some systems go further and try to give value back. Flashbots describes its Protect and MEV-Share design as a way to keep transactions out of the public mempool and return part of any resulting backrun value to the user. That is a real and interesting shift, and it is worth understanding it correctly: it redistributes MEV rather than eliminating it, and it relies on trusting the routing infrastructure. We should read provider documentation as a description of what a product is designed to do, not as independent proof that it removes all extraction. There is a difference between a stated design goal and a guarantee.

Protection is not something you can learn from a single feature toggle, because every option trades one kind of exposure for another. Blockready's DeFi module, which is Module 11 in the curriculum, treats execution risk as its own topic alongside liquidity, lending, and impermanent loss, because mixing these ideas together is exactly how people end up trusting a route they do not understand. The useful skill is not memorizing product names. It is asking, for any route, who sees the order, who competes for it, who keeps the surplus, what new trust you are adding, and what happens if the route fails.

MEV beyond Ethereum: Layer 2 and cross-chain

MEV is not an Ethereum-only phenomenon, and Layer 2 networks do not erase it. They change the architecture of who orders transactions. Many rollups currently rely on a single operator, called a sequencer, to order transactions, with decentralization still in progress across the ecosystem. That sequencer holds real ordering power. Research on rollups has found substantial arbitrage and liquidation activity, while the prevalence of sandwich attacks varies sharply by design, because chains with private mempools or different sequencing behave very differently from Ethereum's public model. Studies that apply naive Ethereum-style detection to those chains can overstate what is actually happening.

Cross-chain MEV adds another layer of risk, because trades that span two chains usually cannot settle in one atomic step. A searcher arbitraging between chains faces price movement while assets bridge, bridge delays, and inventory exposure on both sides. Academic work has documented hundreds of thousands of cross-chain arbitrage events over a defined period, with bridges involved in a meaningful share, though those figures are period-specific and best read as lower bounds. The mechanics of moving assets across chains, and where the trust assumptions break, are a topic of their own. We explain why cross-chain execution introduces bridge and timing risk in a dedicated piece.

Is MEV legal?

There is no single rule that says MEV is legal or illegal. Legal treatment depends on the jurisdiction, the specific conduct, and whether there was deception, fraud, manipulation, or unauthorized access. Ordinary arbitrage and protocol-driven liquidations are not, on their face, treated as crimes. Some forms of conduct can intersect with market-abuse, fraud, or manipulation rules depending on the facts.

The most-watched test of this is the United States case against Anton and James Peraire-Bueno. The Department of Justice alleged in 2024 that the brothers used an MEV-related exploit to take roughly 25 million dollars from the Ethereum blockchain, charging conspiracy to commit wire fraud and money laundering. These are allegations. The first trial ended in a mistrial in November 2025 after the jury could not reach a verdict, and prosecutors then sought a retrial in early 2026. As of early 2026, the matter remained unresolved, with no conviction and no acquittal. The case is important because it tests whether traditional fraud theories apply to an alleged MEV exploit. It is not a ruling that ordinary arbitrage or sandwiching has been declared criminal. In the European Union, ESMA has discussed MEV as a market-integrity issue, while noting that the bloc's crypto rulebook does not define MEV as its own category.

Our View

Based on how we sequence DeFi in Blockready's curriculum, the right mental model for MEV is not "good or bad" but "who holds the discretion." Every protection method moves some combination of visibility, competition, value, and trust, so the question that protects users is not "does this stop MEV" but "who can now see my order, who competes for it, who keeps the surplus, and who do I have to trust." For that reason we do not recommend treating any private RPC or protection product as MEV-free, because that framing replaces a real tradeoff with a false guarantee. Understanding the tradeoff is the durable skill. A product name is not.

If you finish here able to ask who sees your order, who controls its ordering, whether competition is open, who receives the surplus, and what trust a protection method adds, you understand MEV better than most of the internet does. That set of questions, not a single tool, is what keeps you out of trouble.

Frequently Asked Questions

What is the difference between MEV and gas fees?

A gas fee is the price you pay to get a transaction processed, while MEV is the value other parties can capture by controlling the order of transactions in a block. Gas and priority payments are often how participants compete for favorable ordering, so they are the cost of pursuing MEV, not MEV itself.

Is MEV always harmful?

No. Some MEV, such as arbitrage and liquidations, helps keep prices aligned across markets and keeps lending protocols solvent. Other MEV, such as sandwich attacks, directly worsens a user's execution. Many forms sit in between and depend on the design and on who receives the surplus.

What is a sandwich attack?

A sandwich attack is when a bot places one transaction just before your visible swap and another just after it, so your trade executes at a worse price and the bot profits from the difference. A loose slippage tolerance is what creates the room for it, which is why very large trades on thin liquidity are more exposed.

Can a private RPC eliminate MEV?

No, a private RPC does not eliminate MEV. It hides your transaction from the public mempool, which can reduce public front-running, but the builder, solver, or provider you route through may still hold privileged access. Private routing changes who can see and act on your order and who you have to trust, rather than removing ordering value.

Does MEV exist on Layer 2 networks?

Yes, MEV exists on Layer 2 networks, but it works differently than on Ethereum's mainnet. Many rollups order transactions through a single sequencer, which holds real ordering power, and cross-chain trades add bridge and timing risk. The prevalence of specific strategies like sandwich attacks varies sharply by each chain's architecture.

Is MEV illegal?

There is no single law that makes MEV legal or illegal, because treatment depends on the jurisdiction and the specific conduct. Ordinary arbitrage and liquidations are not treated as crimes on their face, while conduct involving fraud, deception, or unauthorized access can raise legal exposure. The 2024 United States case against the Peraire-Bueno brothers ended in a November 2025 mistrial and remained unresolved in early 2026, so it has not settled the question.

Go Deeper on DeFi With Structure

Blockready's masterclass covers transaction ordering, execution risk, and DeFi mechanics as part of a structured crypto curriculum, from blockchain fundamentals to market structure. Built for clarity, not hype.

Explore the Full Course