Skip to content

eth_call ​

served · same as reth

Runs a call against the state of a block and returns the output. Nothing changes on the chain.

When to use ​

Use it to read a contract view function, for example balanceOf or totalSupply, or to test a transaction before you send it.

Example ​

bash
curl -s -X POST -H 'Content-Type: application/json' \
  --data '{"jsonrpc": "2.0", "id": 1, "method": "eth_call", "params": [{"to": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48", "data": "0x18160ddd"}, "0x18facad"]}' \
  http://127.0.0.1:8547
json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "eth_call",
  "params": [
    {
      "to": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
      "data": "0x18160ddd"
    },
    "0x18facad"
  ]
}

Response ​

Live mainnet, block 26193069, 2026-10-14. Checked against reth 2.7: equal.

json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x00000000000000000000000000000000000000000000000000ab38d270bbc858"
}

Full response

Parameters ​

NameTypeRequiredMeaning
callobject, see Transaction call objectyesThe call to run. All fields are optional.
blockblock number in hex, or a tag, see Block parameternoThe block whose state the call uses. The head or one of the 128 blocks before it. Default: latest.
stateOverridesobject, see State overridenoChanges to balances, nonces, code or storage before the call.
blockOverridesobject, see Block overridenoChanges to the block fields that the call sees, for example the number or the time.

The main fields of call. The Transaction call object page has all of them.

FieldTypeMeaning
fromaddressThe sender. Default: the zero address.
toaddressThe contract or account to call. Leave it out to deploy the code in input.
gashex numberThe gas limit. Default: the gas cap of the node (--rpc-gascap, 50 000 000). A larger value gets the gas cap.
valuehex number, weiThe ether to send with the call. Default: 0.
inputhex dataThe call data: the function selector and the arguments. data is also accepted. If both are present and not equal, the call gives -32602, as in reth. eth_simulateV1 then uses input.

Returns ​

The return data of the call as hex data. For a view function, decode it with the ABI of the function.

Notes and limits ​

  • The gas cap is --rpc-gascap, 50 000 000 by default. A call without gas and without a gas price runs with the gas cap.
  • A call with a gas price and without gas gets the gas that the sender can pay for. The gas limit of the block is the upper limit. The gas cap does not apply.
  • The gas price of an EIP-1559 call is the lower of maxFeePerGas and the base fee plus the tip. Without maxFeePerGas, the gas price is the base fee plus the tip. So a call with only maxPriorityFeePerGas has a gas price, also when the tip is 0.
  • A call pays no gas fee, as in reth. The gas price sets only the gas that the sender can pay for and the value of GASPRICE.
  • A call without a gas price sees a base fee of zero.
  • At pending, the call runs on the state of latest, as in reth. It sees the number, time, base fee and blob fee of the next block and a random PREVRANDAO. It does not see the transactions of the pending block.
  • For a revert, the error has code 3 and the revert data in data. The message has the reason when the contract gives an Error(string) or a Panic.

Errors ​

CodeMessageWhen
3execution reverted: <reason>The call reverted. data has the revert data.
-32003out of gas: gas required exceeds: NThe call ran out of gas.
-32003insufficient funds for gas * price + value: have X want YThe value is above the balance. The call has a gas price and no gas.
-32000max fee per gas less than block base feemaxFeePerGas is below the base fee. When maxFeePerGas and the tip are both 0, this error does not occur.
-32003max priority fee per gas higher than max fee per gasmaxPriorityFeePerGas is above maxFeePerGas.
-32602both gasPrice and (maxFeePerGas or maxPriorityFeePerGas) specifiedThe call has gasPrice and also an EIP-1559 or blob fee field.
-32003blob transaction missing blob hashesThe call has maxFeePerBlobGas but no blob hashes, or blobVersionedHashes is empty.
-32602Invalid paramsA fee value is larger than 128 bits. data gives the value and its column.
-32602Invalid paramsA parameter is missing or does not parse. data has the text of reth, with the position.
-32001block not found: 0x...The block is above the head or the hash is unknown.
4444pruned history unavailable: requested N, earliest available MThe block is more than 128 blocks below the head.

Compared with reth ​

Cinder applies the gas cap, the overrides and the base fee rule as reth does. The error codes and texts are those of reth.

The live example above gives the same answer on Cinder and on reth 2.7.

Speed against reth ​

ERC-20 balanceOf1.3x faster
Cinder0.33 ms
reth0.42 ms
Uniswap V3 quote1.01x faster
Cinder0.62 ms
reth0.62 ms
Median, reth 2.7, 2026-10-17. Shorter is better.

eth_estimateGas, eth_callMany, eth_simulateV1, debug_traceCall.

Schema (OpenRPC) ​

The official specification: eth_call in ethereum/execution-apis.

Parameter Transaction: object
json
{
  "additionalProperties": false,
  "properties": {
    "accessList": {
      "description": "EIP-2930 access list",
      "items": {
        "additionalProperties": false,
        "properties": {
          "address": {
            "pattern": "^0x[0-9a-fA-F]{40}$",
            "title": "hex encoded address",
            "type": "string"
          },
          "storageKeys": {
            "items": {
              "pattern": "^0x[0-9a-f]{64}$",
              "title": "32 byte hex value",
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "address",
          "storageKeys"
        ],
        "title": "Access list entry",
        "type": "object"
      },
      "title": "accessList",
      "type": "array"
    },
    "authorizationList": {
      "description": "EIP-7702 authorization list",
      "items": {
        "properties": {
          "address": {
            "pattern": "^0x[0-9a-fA-F]{40}$",
            "title": "hex encoded address",
            "type": "string"
          },
          "chainId": {
            "description": "Chain ID on which this transaction is valid",
            "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
            "title": "chainId",
            "type": "string"
          },
          "nonce": {
            "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
            "title": "nonce",
            "type": "string"
          },
          "r": {
            "pattern": "^0x(0|[1-9a-f][0-9a-f]{0,63})$",
            "title": "r",
            "type": "string"
          },
          "s": {
            "pattern": "^0x(0|[1-9a-f][0-9a-f]{0,63})$",
            "title": "s",
            "type": "string"
          },
          "yParity": {
            "description": "The parity (0 for even, 1 for odd) of the y-value of the secp256k1 signature",
            "pattern": "^0x([0-9a-fA-F]?){1,2}$",
            "title": "yParity",
            "type": "string"
          }
        },
        "required": [
          "chainId",
          "nonce",
          "address",
          "yParity",
          "r",
          "s"
        ],
        "type": "object"
      },
      "title": "authorizationList",
      "type": "array"
    },
    "blobVersionedHashes": {
      "description": "List of versioned blob hashes associated with the transaction's EIP-4844 data blobs.",
      "items": {
        "pattern": "^0x[0-9a-f]{64}$",
        "title": "32 byte hex value",
        "type": "string"
      },
      "title": "blobVersionedHashes",
      "type": "array"
    },
    "blobs": {
      "description": "Raw blob data.",
      "items": {
        "pattern": "^0x[0-9a-f]*$",
        "title": "hex encoded bytes",
        "type": "string"
      },
      "title": "blobs",
      "type": "array"
    },
    "chainId": {
      "description": "Chain ID that this transaction is valid on.",
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "chainId",
      "type": "string"
    },
    "from": {
      "pattern": "^0x[0-9a-fA-F]{40}$",
      "title": "from address",
      "type": "string"
    },
    "gas": {
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "gas limit",
      "type": "string"
    },
    "gasPrice": {
      "description": "The gas price willing to be paid by the sender in wei",
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "gas price",
      "type": "string"
    },
    "input": {
      "pattern": "^0x[0-9a-f]*$",
      "title": "input data",
      "type": "string"
    },
    "maxFeePerBlobGas": {
      "description": "The maximum total fee per gas the sender is willing to pay for blob gas in wei",
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "max fee per blob gas",
      "type": "string"
    },
    "maxFeePerGas": {
      "description": "The maximum total fee per gas the sender is willing to pay (includes the network / base fee and miner / priority fee) in wei",
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "max fee per gas",
      "type": "string"
    },
    "maxPriorityFeePerGas": {
      "description": "Maximum fee per gas the sender is willing to pay to miners in wei",
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "max priority fee per gas",
      "type": "string"
    },
    "nonce": {
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "nonce",
      "type": "string"
    },
    "to": {
      "oneOf": [
        {
          "title": "Contract Creation (null)",
          "type": "null"
        },
        {
          "pattern": "^0x[0-9a-fA-F]{40}$",
          "title": "Address",
          "type": "string"
        }
      ],
      "title": "to address"
    },
    "type": {
      "pattern": "^0x([0-9a-fA-F]?){1,2}$",
      "title": "type",
      "type": "string"
    },
    "value": {
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "value",
      "type": "string"
    }
  },
  "title": "Transaction object generic to all types",
  "type": "object"
}
Parameter Block: Block number or Block tag or Block hash
json
{
  "anyOf": [
    {
      "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
      "title": "Block number",
      "type": "string"
    },
    {
      "description": "`earliest`: The lowest numbered block the client has available; `finalized`: The most recent crypto-economically secure block, cannot be re-orged outside of manual intervention driven by community coordination; `safe`: The most recent block that is safe from re-orgs under honest majority and certain synchronicity assumptions; `latest`: The most recent block in the canonical chain observed by the client, this block may be re-orged out of the canonical chain even under healthy/normal conditions; `pending`: A sample next block built by the client on top of `latest` and containing the set of transactions usually taken from local mempool. Before the merge transition is finalized, any call querying for `finalized` or `safe` block MUST be responded to with `-39001: Unknown block` error",
      "enum": [
        "earliest",
        "finalized",
        "safe",
        "latest",
        "pending"
      ],
      "title": "Block tag",
      "type": "string"
    },
    {
      "pattern": "^0x[0-9a-f]{64}$",
      "title": "Block hash",
      "type": "string"
    }
  ],
  "title": "Block number, tag, or block hash"
}
Result: string
json
{
  "pattern": "^0x[0-9a-f]*$",
  "title": "hex encoded bytes",
  "type": "string"
}