Skip to main content

Overview

Base uses resource metering to measure how much computation each transaction requires during block building. Three resources are tracked:
  • Gas — total gas consumed by the transaction
  • Execution time — wall-clock time spent executing the transaction in the EVM
  • Data availability (DA) — compressed transaction size posted to L1
Each resource has a limited budget per block (or per flashblock). The block builder always includes transactions in priority fee order, but when demand for a resource exceeds capacity, lower-paying transactions are skipped for inclusion until capacity allows. Resource metering affects you in two ways:
  1. Transactions that consume excessive resources may be skipped for inclusion. If your transaction uses a disproportionate amount of execution time or DA relative to its gas usage, it may be skipped even if its gas-based priority fee would normally be sufficient.
  2. You can query the recommended priority fee for your transaction. The base_meteredPriorityFeePerGas RPC method simulates your transaction and returns the priority fee needed to get included based on recent block congestion across all three resources.
The base_meteredPriorityFeePerGas RPC method simulates a bundle of transactions and returns a recommended priority fee based on recent block congestion. It evaluates all three resource types independently and returns the highest fee across them.

Request

Send a JSON-RPC request with a single bundle object:
Example request
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "base_meteredPriorityFeePerGas",
  "params": [
    {
      "txs": ["0x02f86c..."],
      "blockNumber": "0x0"
    }
  ]
}

Bundle parameters

FieldTypeRequiredDescription
txsBytes[]YesRLP-encoded signed transactions (EIP-2718 envelopes)
blockNumberquantityYesTarget block number (hex). Use 0x0 for the current block.
flashblockNumberMinquantityNoEarliest flashblock index for inclusion
flashblockNumberMaxquantityNoLatest flashblock index for inclusion
minTimestampquantityNoEarliest block timestamp for inclusion
maxTimestampquantityNoLatest block timestamp for inclusion
revertingTxHashesTxHash[]NoTransaction hashes allowed to revert without failing the bundle
replacementUuidstringNoUUID for replacing a previously submitted bundle
droppingTxHashesTxHash[]NoTransaction hashes to drop from the pool

Response

The response includes the priority fee recommendation alongside full bundle simulation results.

Top-level fields

FieldTypeDescription
priorityFeequantityRecommended priority fee per gas (hex). This is the maximum across all resource types.
blocksSampledintegerNumber of recent blocks used for the estimate. 0 means no historical data was available.
resourceEstimatesResourceEstimate[]Per-resource fee breakdown
totalGasUsedintegerTotal gas consumed by all transactions
totalExecutionTimeUsintegerTotal EVM execution time in microseconds
stateRootTimeUsintegerTime to compute the state root in microseconds
stateBlockNumberintegerBlock number used for simulation state
stateFlashblockIndexintegerFlashblock index used for simulation state (omitted if not applicable)
resultsTransactionResult[]Per-transaction simulation results
bundleGasPricequantityEffective gas price of the bundle
bundleHashhashHash of the bundle
coinbaseDiffquantityTotal change in sequencer balance
ethSentToCoinbasequantityETH explicitly sent to the sequencer
gasFeesquantityTotal gas fees paid by the bundle

Resource estimates

Each entry in resourceEstimates describes the fee threshold for a single resource type.
FieldTypeDescription
resourcestringResource name: "gasUsed", "executionTime", or "dataAvailability"
thresholdPriorityFeequantityMinimum fee to displace enough lower-paying transactions to free capacity for the bundle
recommendedPriorityFeequantityFee with a safety margin above the threshold
cumulativeUsagequantityTotal resource usage of transactions that would remain included alongside the bundle
thresholdTxCountintegerNumber of higher-paying transactions that would be included alongside the bundle
totalTransactionsintegerTotal transactions considered in the estimate

Transaction results

Each entry in results describes the simulation outcome for one transaction.
FieldTypeDescription
txHashhashTransaction hash
fromAddressaddressSender address
toAddressaddressRecipient address (null for contract creation)
gasUsedintegerGas consumed
gasPricequantityEffective gas price
gasFeesquantityGas fees paid
coinbaseDiffquantityChange in sequencer balance from this transaction
ethSentToCoinbasequantityETH explicitly sent to the sequencer
valuequantityETH value transferred
executionTimeUsintegerExecution time in microseconds

Example response

Example response
{
  "priorityFee": "0x5f5e100",
  "blocksSampled": 12,
  "resourceEstimates": [
    {
      "resource": "gasUsed",
      "thresholdPriorityFee": "0x3b9aca00",
      "recommendedPriorityFee": "0x5f5e100",
      "cumulativeUsage": "0x1e8480",
      "thresholdTxCount": 5,
      "totalTransactions": 10
    },
    {
      "resource": "executionTime",
      "thresholdPriorityFee": "0x2540be400",
      "recommendedPriorityFee": "0x2540be400",
      "cumulativeUsage": "0xf4240",
      "thresholdTxCount": 8,
      "totalTransactions": 10
    },
    {
      "resource": "dataAvailability",
      "thresholdPriorityFee": "0x1",
      "recommendedPriorityFee": "0x1",
      "cumulativeUsage": "0x2710",
      "thresholdTxCount": 10,
      "totalTransactions": 10
    }
  ],
  "bundleGasPrice": "0x3b9aca00",
  "bundleHash": "0xabc123...",
  "coinbaseDiff": "0x4a817c800",
  "ethSentToCoinbase": "0x0",
  "gasFees": "0x4a817c800",
  "results": [
    {
      "txHash": "0xdef456...",
      "fromAddress": "0x1111111111111111111111111111111111111111",
      "toAddress": "0x2222222222222222222222222222222222222222",
      "gasUsed": 21000,
      "gasPrice": "0x3b9aca00",
      "gasFees": "0x4a817c800",
      "coinbaseDiff": "0x4a817c800",
      "ethSentToCoinbase": "0x0",
      "value": "0x0",
      "executionTimeUs": 150
    }
  ],
  "stateBlockNumber": 12345,
  "stateFlashblockIndex": 3,
  "totalGasUsed": 21000,
  "totalExecutionTimeUs": 150,
  "stateRootTimeUs": 80
}

Interpreting the response

The priorityFee field is the recommended value for your transaction’s maxPriorityFeePerGas. It reflects the highest recommended fee across all three resource types, so setting your priority fee to at least this value gives your transaction the best chance of inclusion. To understand which resource is driving the fee, inspect the resourceEstimates array. The resource with the highest recommendedPriorityFee is the binding constraint on your bundle’s inclusion.
ScenariopriorityFeeblocksSampledWhat it means
Normal congestion> 0> 0Set your maxPriorityFeePerGas to at least this value.
UncongestedLow value> 0Blocks have spare capacity. The returned fee is a floor value.
No historical data0x00The metering system does not have enough data yet. The bundle simulation results are still valid.

How the estimate works

The estimation runs in three stages:
1

Simulate the bundle

Your bundle is executed against the latest pending state (including any in-progress flashblocks). This produces the bundle’s resource consumption: gas used, execution time, and DA bytes.
2

Estimate per block

For each recent block (default: 12 blocks), the estimator evaluates each flashblock:
  • Transactions are sorted by priority fee, highest first.
  • For each resource, the algorithm walks down the sorted list, accumulating resource usage.
  • It stops when adding the next transaction would leave less remaining capacity than your bundle needs.
  • The last included transaction’s fee becomes the threshold — the minimum fee your bundle would need to displace it.
  • If all transactions fit with room to spare, the resource is uncongested and a default floor fee is returned.
Execution time is a use-it-or-lose-it resource. Unused time in one flashblock does not carry over to the next. For this resource, transactions are aggregated across all flashblocks before running the estimation.
3

Aggregate across blocks

For each resource, the median recommended fee across all sampled blocks is computed. The final priorityFee is the maximum across all three resources.

Errors

ErrorCause
Priority fee estimation not configuredThe node does not have resource metering enabled.
bundle ... demand (...) exceeds capacity limit (...)Your bundle’s resource consumption exceeds the block’s capacity for that resource. The bundle cannot fit in a single block.
Failed to parse bundleOne or more transactions in txs could not be decoded as valid RLP-encoded EIP-2718 envelopes.
Bundle metering failedThe simulation failed (for example, insufficient balance or invalid nonce).