eth_feeHistory
Returns a collection of historical gas information.
Parameters
BLOCKCOUNT
- Number of blocks in the requested range. Between 1 and 1024 blocks can be requested in a single query. Less than requested may be returned if not all blocks are available. REQUIREDNEWESTBLOCK
- Highest number block of the requested range. REQUIREDREWARDPERCENTILES
- (optional) A monotonically increasing list of percentile values to sample from each block's effective priority fees per gas in ascending order, weighted by gas used. REQUIRED
Returns
Object
OLDESTBLOCK
- Lowest number block of the returned range.BASEFEEPERGAS
- An array of block base fees per gas. This includes the next block after the newest of the returned range, because this value can be derived from the newest block. Zeroes are returned for pre-EIP-1559 blocks.GASUSEDRATIO
- An array of block gas used ratios. These are calculated as the ratio ofgasUsed
andgasLimit
.REWARD
- (Optional) An array of effective priority fees per gas data points from a single block. All zeroes are returned if the block is empty.
Example
Request
Response
Last updated