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

# eth_feeHistory

> Call eth_feeHistory on Goldsky Edge RPC to return historical base fees, gas usage ratios, and priority-fee reward percentiles across a range of EVM blocks.

## Parameters

**blockCount** `string` *required*

Number of blocks to return (hex, max 1024)

**newestBlock** `string` *required*

Newest block (hex), or `latest`, `pending`

**rewardPercentiles** `array`

Array of percentiles for priority fee sampling

## Returns

**feeHistory** `object`

Fee history object

**properties**

**oldestBlock** `string`

Oldest block in range (hex)

**baseFeePerGas** `array`

Array of base fees per gas

**gasUsedRatio** `array`

Array of gas used ratios

**reward** `array`

Array of priority fee percentiles

## Example

```bash cURL theme={"dark"}
curl -X POST "https://edge.goldsky.com/standard/evm/1?key=demo" \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc": "2.0", "method": "eth_feeHistory", "params": [4, "latest", [25, 75]], "id": 1}'
```

```javascript JavaScript theme={"dark"}
const response = await fetch('https://edge.goldsky.com/standard/evm/1?key=demo', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
  "jsonrpc": "2.0",
  "method": "eth_feeHistory",
  "params": [
    4,
    "latest",
    [
      25,
      75
    ]
  ],
  "id": 1
})
});
const { result } = await response.json();
console.log(result);
```

```python Python theme={"dark"}
import requests

response = requests.post(
    'https://edge.goldsky.com/standard/evm/1?key=demo',
    json={
  "jsonrpc": "2.0",
  "method": "eth_feeHistory",
  "params": [
    4,
    "latest",
    [
      25,
      75
    ]
  ],
  "id": 1
}
)
print(response.json()['result'])
```


## Related topics

- [eth_blobBaseFee](https://docs.goldsky.com/edge-rpc/evm/methods/eth_blobBaseFee.md)
- [eth_maxPriorityFeePerGas](https://docs.goldsky.com/edge-rpc/evm/methods/eth_maxPriorityFeePerGas.md)
- [Get started with Feeds](https://docs.goldsky.com/feeds/quickstart.md)
- [Feeds: ready-made onchain datasets](https://docs.goldsky.com/feeds.md)
- [Transfers](https://docs.goldsky.com/feeds/api/transfers.md)
