Skip to main content
GET
/
v2
/
api
curl "https://api.etherscan.io/v2/api?chainid=1&module=proxy&action=eth_estimateGas&data=0x4e71d92d&to=0xf0160428a8552ac9bb7e050d90eeade4ddd52843&value=0xff22&gasPrice=0x51da038cc&gas=0x5f5e0ff&apikey=YourApiKeyToken"
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x66ac"
}

Query Parameters

apikey
string
default:"YourApiKeyToken"
Your Etherscan API key.
chainid
string
default:"1"
Chain ID to query, eg 1 for Ethereum, 8453 for Base from our supported chains.
module
string
default:"proxy"
Set to proxy for this endpoint.
action
string
default:"eth_estimateGas"
Set to eth_estimateGas for this endpoint.
data
string
default:"0x4e71d92d"
Hash of the method signature and encoded parameters.
to
string
default:"0xf0160428a8552ac9bb7e050d90eeade4ddd52843"
The address to interact with.
value
string
default:"0xff22"
Value sent in this transaction, in hex.
gasPrice
string
default:"0x51da038cc"
Gas price in wei.
gas
string
default:"0x5f5e0ff"
Gas limit provided for the transaction, in hex.
curl "https://api.etherscan.io/v2/api?chainid=1&module=proxy&action=eth_estimateGas&data=0x4e71d92d&to=0xf0160428a8552ac9bb7e050d90eeade4ddd52843&value=0xff22&gasPrice=0x51da038cc&gas=0x5f5e0ff&apikey=YourApiKeyToken"
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x66ac"
}
I