> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dune.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Rollup Economics

> Curated rollup profitability datasets for Ethereum L2s on Dune

Dune's rollup economics tables track the financial performance of Ethereum L2 rollups by comparing their revenue (gas fees earned from users on L2) against their costs (fees paid to post data and proofs on Ethereum L1).

<Info>
  **Maintained by:** Dune · **Refresh:** \~1 hour · **Coverage:** 10 rollups (revenue), 25 rollups (L1 costs)
</Info>

<Card title="Get This Data" icon="database" href="https://dune.com/enterprise?dataset=rollup-economics">
  Access rollup economics data via API, Datashare, or the Dune App.
</Card>

## Available Tables

<CardGroup cols={2}>
  <Card title="rollup_economics_ethereum.l2_revenue" icon="database" href="/data-catalog/curated/rollup-economics/l2_revenue">
    Daily gas fee revenue earned by each rollup on L2
  </Card>

  <Card title="rollup_economics_ethereum.l1_fees" icon="database" href="/data-catalog/curated/rollup-economics/l1_fees">
    Daily fees paid by each rollup to post data/proofs on Ethereum L1
  </Card>
</CardGroup>

## When to Use These Tables

* Analyze rollup profitability (L2 revenue minus L1 costs)
* Compare L1 posting costs across rollups
* Track the impact of EIP-4844 blobs on rollup costs
* Benchmark rollup revenue and growth over time

## Coverage

**L2 Revenue (10 rollups):** Scroll, Mantle, Zora, Linea, Arbitrum, zkSync Era, OP Mainnet, Base, Polygon zkEVM, Blast

**L1 Fees (25 rollups):** Orderly Network, Starknet, Mode, Starkware, Base, Boba, Polygon zkEVM, Blast, Hypr Network, Scroll, Lyra, Public Goods Network, Zora, Mantle, Linea, IMX, zkSync Lite, Loopring, Metis, Aevo, Arbitrum, Manta Pacific, zkSync Era, OP Mainnet, Fraxtal

<Tip>
  L1 fees covers more rollups because tracking posting costs only requires monitoring known addresses on Ethereum, while L2 revenue requires Dune to have indexed each L2 chain directly.
</Tip>

<Info>
  **Need a rollup that's not listed?** We can add new rollup coverage. [Contact our enterprise team →](https://dune.com/enterprise)
</Info>

## Query Performance

Both tables are incremental with daily granularity. Filter on `day` and optionally `name`.

```sql theme={null}
-- ✅ Good: time-bounded
SELECT * FROM rollup_economics_ethereum.l2_revenue
WHERE day >= DATE '2025-01-01'
  AND name = 'base'
```

## Methodology

These tables are maintained by Dune ([source code](https://github.com/duneanalytics/spellbook)).

**L2 Revenue** aggregates total gas fees from `gas.fees` for each rollup's chain, grouped by day.

**L1 Fees** monitors known rollup batch-posting and proof-verification addresses on Ethereum, decomposing costs into: calldata gas costs, proof verification costs (ZK rollups), and EIP-4844 blob gas costs (post-Dencun).

## Example Queries

**Rollup profitability (revenue minus costs):**

```sql theme={null}
SELECT
  r.name,
  r.day,
  r.l2_rev_usd,
  f.l1_fee_usd,
  r.l2_rev_usd - f.l1_fee_usd AS profit_usd
FROM rollup_economics_ethereum.l2_revenue r
JOIN rollup_economics_ethereum.l1_fees f
  ON r.name = f.name AND r.day = f.day
WHERE r.day >= DATE '2025-01-01'
ORDER BY r.day DESC, profit_usd DESC
```

**L1 cost breakdown: calldata vs blobs vs verification:**

```sql theme={null}
SELECT
  name,
  SUM(data_fee_usd) AS calldata_costs,
  SUM(blob_fee_usd) AS blob_costs,
  SUM(verification_fee_usd) AS verification_costs,
  SUM(l1_fee_usd) AS total_l1_costs
FROM rollup_economics_ethereum.l1_fees
WHERE day >= DATE '2025-01-01'
GROUP BY 1
ORDER BY 5 DESC
```

## Related Tables

* `gas.fees` — Transaction-level gas data used to compute L2 revenue

<CardGroup cols={2}>
  <Card title="Enterprise Data Solutions" icon="building" href="https://dune.com/enterprise">
    Need custom rollup analytics or additional L2 coverage? Talk to our enterprise team.
  </Card>

  <Card title="Build Custom Models" icon="code" href="/api-reference/connectors/overview">
    Build private rollup profitability dashboards with the dbt Connector.
  </Card>
</CardGroup>
