eth_contract_address
Compute a contract's CREATE or CREATE2 deployment address from deployer, nonce, salt, or init code without deploying.
Instructions
Compute a contract's CREATE or CREATE2 deployment address.
scheme=create -> needs nonce; address = keccak256(rlp([deployer, nonce]))[12:]
scheme=create2 -> needs salt and init_code;
address = keccak256(0xff ++ deployer ++ salt ++
keccak256(init_code))[12:]
Returns {address}, EIP-55 checksummed. Computes only — nothing is deployed.
Example: eth_contract_address("create", "0x6ac7ea33f8831ea9dcc53393aaa88b25a785dbf0", nonce=0) -> address="0xcd234A471b72ba2F1Ccf0A70FCABA648a5eeCD8d".
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| salt | No | A 32-byte hex salt chosen by the deployer (required for scheme=create2). | |
| nonce | No | The deployer's transaction nonce for this deploy (required for scheme=create; int, decimal string, or 0x-hex). A contract deployer's nonce starts at 1, an EOA's at 0. | |
| scheme | Yes | 'create' derives from the deployer and its `nonce`; 'create2' (EIP-1014) derives from the deployer, a `salt`, and the `init_code`, so the address is known before deployment. | |
| deployer | Yes | The deploying account's 20-byte hex address (0x optional, any casing) — an EOA for a top-level deploy, or the factory contract. | |
| init_code | No | The full contract creation bytecode as hex — constructor code plus its ABI-encoded arguments, NOT the deployed runtime code (required for scheme=create2). |