Skip to main content
Returns historical gas information for a range of blocks, including base fees and the distribution of priority fees. Useful for building fee estimation strategies.

Parameters

blockCount
string | number
required
Number of blocks to return. Can be a decimal or hexadecimal integer. Maximum is typically 1024.
newestBlock
string
required
The highest block to include, as a block number in hex or a block tag ("latest", "pending", etc.).
rewardPercentiles
array
required
Array of percentile values (0–100) to sample from each block’s priority fees. Example: [25, 50, 75] returns the 25th, 50th, and 75th percentile priority fees.

Returns

result
object

Example

{
  "jsonrpc": "2.0",
  "method": "eth_feeHistory",
  "params": ["0xa", "latest", [25, 50, 75]],
  "id": 1
}