In this track: Gas and execution fees
intermediate · 3 MIN READ

Layer 2 fee components

Execution and data-related costs can be combined differently by each network.

LET’S PICTURE IT

A shipping company can combine local delivery and long-distance transport charges into one bill.

SEE IT FOR YOURSELF
Calculate and split a manual execution feeStep 1 / 4
Calculate and split a manual execution feeGas used21,000A resource quantityGas used and gas limit are different quantitiesBase10 GweiEffective tip2 GweiTotal rate12 Gwei / gasAssumed total cap: 20 Gwei; no live prices are fetchedWork × rate21,000 × 12252,000 GweiExecution fee0.000252 ETHExact unit conversionThis calculation excludes blob and layer 2 data feesBase component0.00021 ETHBurned by protocolPriority component0.000042 ETHTo fee recipientComponents sum to the supplied 0.000252 ETH example

This example supplies twenty-one thousand gas used. It is a simple teaching input, not a live estimate of a contract call.

Animated local teaching model. No wallet, RPC or live blockchain data. Some labels and hashes are abbreviated for readability.

Identify the network’s formula

A layer 2 can charge for its own execution and for costs related to publishing or settling data on another layer. The exact components, scalars and quoting interfaces differ across implementations.

Compression and batching affect shared costs

A rollup can aggregate transactions and publish data in a shared batch. Per-user fee allocation may therefore involve assumptions beyond the individual action’s local execution gas.

An ETH label does not make formulas identical

Two networks can denominate fees using ETH while calculating them differently. A familiar unit is not evidence that one mainnet-only arithmetic model gives the full layer 2 cost.

Use the manual tool for one component

You can explore execution inputs here while keeping additional components out of the result. For a real quote, consult the specific network’s current fee interface and documentation rather than inventing a universal live estimate.

TURN UNDERSTANDING INTO PRACTICEOpen the Gas calculator →
QUICK CHECK · NO PRESSURE

Does using ETH as the fee currency mean every layer 2 has identical fee accounting?

Your progress stays in this browser.
Keep exploring the original referenceethereum.org ↗

Original explanations by EtherTools. Examples are educational and source-linked; this site is independent of the Ethereum Foundation. Our approach.