eth_feeHistory

Returns transaction base fee per gas and effective priority fee per gas for the requested block range.

Path parameters

apiKeystringRequired

Request

This endpoint expects an object.
blockCountstringRequiredformat: "^0x([1-9a-f]+[0-9a-f]*|0)$"
The number of blocks in the requested range. Must be greater than zero. Clients may return fewer blocks if not all blocks are available.
newestBlockstring or enumRequired
The highest block number of the requested range, or 'latest' for the most recent block.
rewardPercentileslist of doublesOptional

An optional array of percentile values (between 0 and 100) in ascending order.

Response

Fee history for the returned block range. This can be a subsection of the requested range if not all blocks are available.
oldestBlockstring or nullformat: "^0x([1-9a-f]+[0-9a-f]*|0)$"
baseFeePerGaslist of strings or null
gasUsedRatiolist of doubles or null
rewardlist of lists of strings or null

A two-dimensional array of effective priority fees per gas.

baseFeePerBlobGaslist of strings or null
blobGasUsedRatiolist of doubles or null