Skip to content

getGasPrice

Returns the current price of gas (in wei).

Usage

import { publicClient } from './client'
 
const gasPrice = await publicClient.getGasPrice() 

Returns

bigint

The gas price (in wei).

JSON-RPC Method

eth_gasPrice