Advanced · Lesson 14

Layer 2, rollups and MEV

A layer 2 is a trade: cheaper execution in exchange for a different trust boundary. MEV is the price of ordering.

Advanced12 min readUpdated 8 Nov 2026

A rollup does the work somewhere else and then files a summary with the chain everyone trusts. Almost everything about a layer 2 follows from that sentence: what gets cheaper, what gets slower, and who you have to believe in the gap between the two.

Three jobs, three places

A blockchain does three things at once, at very different costs: it executes transactions, settles disputes about the result, and makes the data available so anyone can check. A layer 2 moves execution off the base chain and keeps the other two there.

  • Optimistic rollups post the data and a claim about the resulting state, then wait. The claim stands unless someone proves it fraudulent inside a challenge window.
  • Validity rollups post the data and a cryptographic proof. The base chain verifies the proof, so there is no window and no honest watcher required.
  • Validium-style designs keep the data off the base chain with a committee. Cheaper, and a different trust boundary: if the committee withholds data, your balance may be real but unprovable.

The question to ask is never «is it a rollup». It is «who has to be honest, about what, and for how long».

The sequencer decides the order

One node usually receives transactions, puts them in an order, executes them and submits the batch. That role exists because consensus for every transaction is what made the base chain expensive.

The consequences are concrete. A confirmation that arrives in a second is a signature from an operator, not a settlement. The sequencer can delay your transaction, drop it, or put it behind others; most designs offer a slower path through the base chain for exactly that reason, and the useful detail is how long that path takes and whether it always works. When the sequencer is offline the chain looks frozen but balances remain intact.

Ordering is also the raw material of extractable value, and the sequencer stands first in the queue. Whether it extracts that value, sells the right to, or commits to a fixed ordering policy is a property of the network's current design, not a law of rollups.

Finality has three grades

«Confirmed» covers at least three different states.

  • Sequenced. The operator has included your transaction. Reversible by the operator, and cheap to reverse.
  • Posted. The batch is on the base chain with its data. In an optimistic rollup it can still be reverted by a fraud proof during the challenge window.
  • Final. The window has passed, or the proof has verified, and the base chain has finalised the block containing it.

The canonical bridge out of the rollup waits for the last one. A fast bridge does not make settlement faster; it lends you the money and carries the wait itself, which is why it charges a fee and why its solvency is part of your risk. Two different services, often presented under the same word: «withdraw».

Reading a fee

A transaction on a rollup pays two things: execution inside the rollup, and a share of what it costs to post the batch to the base chain.

data share = batch cost on L1 ÷ transactions in the batch total      = data share + execution fee

Take a batch whose data costs 0.02 ETH and that contains 400 transactions. Each one carries 0.02 ÷ 400 = 0.00005 ETH of that cost. Put the same batch together with 40 transactions instead and each carries 0.0005 ETH, ten times more for an identical transfer.

That is the counter-intuitive part. The data share is a fixed bill divided among whoever shows up, so an empty rollup is an expensive one for the people in it. The execution share behaves the opposite way: it is priced by the rollup's own gas market and rises when the rollup is busy. A fee that looks high can be congestion, or it can be an empty batch, and the two call for different responses.

Newer designs post data in a separate market, which decouples the two prices: rollup fees can fall while base-chain fees stay high, and the reverse.

MEV: the price of ordering

MEV is the profit available to whoever decides what goes where. On the base chain it has become an industry with named roles: searchers find opportunities, builders assemble bundles, the block producer chooses one. On a rollup the same supply chain exists in a shorter form, with the sequencer at the end of it.

Not all of it is harmful. Arbitrage closes price gaps between venues and rewards whoever is fastest. Liquidations keep lending markets solvent and pay the keeper for the work. Sandwiching is the one that costs you directly: a transaction is placed before yours to move the price, and another after it to sell into the move you caused.

What protects you on the base chain does not automatically follow you. Private orderflow and builder auctions exist on the base layer; whether a rollup offers an equivalent depends on the operator. Practical defences are unglamorous: a slippage limit you actually mean, splitting a large order, avoiding pools thin enough for one trade to move, and treating «protected» as a claim to verify rather than a feature to trust.

Fast is not final. A pre-confirmation tells you that an operator has promised to include something. It says nothing about whether that promise will still hold after the batch reaches the base chain.

Check yourself

  • A batch costs 0.02 ETH in base-chain data and contains 400 transactions. What does each one pay for data, and what happens if the batch contains 40?
  • Between a soft confirmation and base-chain finality, what are you trusting, and for how long?
  • Name two things a sequencer can do to your transaction that do not involve stealing your funds.

The terms are defined in the glossary: Layer 2 and finality. Smart contracts and dApps covers what actually runs inside the rollup, and Smart contract risk turns the trust boundaries above into a position size.