Constructor Argument Encoder for Verification
Free to download on every platform. Comes pre-installed on BotFone, BotPad and BotFlip — with extra free apps included.
About this app
WHAT IT DOES
This tool connects to your EVM wallet and encodes constructor arguments for smart contract verification, enabling you to generate the correct constructor argument data needed for block explorer verification. It reads deployed contract bytecode and creation transaction data to extract original constructor parameters when available. The tool supports encoding arguments from JSON arrays or comma-separated values, decoding constructor arguments from encoded data, and extracting creation data directly from the chain.
HOW TO USE
Connect your Web3 wallet using the Connect button. Enter the contract ABI (JSON array) in the Contract ABI field—this must include the constructor definition. Enter constructor arguments in the Constructor Arguments field as a JSON array or comma-separated values. Click "Encode Arguments" to generate the ABI-encoded constructor data. Click "Extract from Chain" to fetch the creation transaction data from a deployed contract address. Click "Decode Arguments" to decode encoded constructor data back into readable arguments using the provided ABI. Results appear in the Results card with the encoded data and decoded arguments.
TECHNICAL MECHANISM: ABI-BASED CONSTRUCTOR ARGUMENT ENCODING AND DECODING
The tool uses ethers.js's Interface class to encode and decode constructor arguments according to the Ethereum ABI specification. Given a contract ABI containing a constructor definition, the tool extracts the constructor's input types and uses ethers.utils.Interface.encodeConstructor() to encode the provided arguments into the format expected by block explorers (Etherscan, Polygonscan, etc.). The encoded output is a hex string that can be pasted directly into the "Constructor Arguments" field during contract verification. For decoding, the tool uses ethers.utils.Interface.decodeConstructor() to parse encoded data back into readable arguments. On-chain extraction uses provider.getCode() and provider.getTransaction() to retrieve deployment data.
WHAT IT CANNOT SEE
This tool cannot decode constructor arguments without knowing the contract ABI—the ABI is required to interpret the encoded data. It cannot verify that decoded arguments are correct without external source code validation—the tool performs encoding/decoding but does not verify correctness against source code. It cannot handle contracts that use complex or custom encoding patterns—the tool follows the standard ABI specification. It relies on ABI parsing and may fail for non-standard constructor parameter types—custom types may not be supported. It cannot reconstruct constructor arguments that are not present in on-chain data—if arguments are not stored or retrievable, the tool cannot recover them.
PLEASE NOTE
This is a read-only tool for encoding and decoding—it never signs transactions. All data is processed in-memory and never persists. The tool supports EVM chains only—Ethereum, Polygon, BSC, Arbitrum, Optimism, Avalanche, Base, and Fantom. The encoded data is essential for block explorer verification—ensure the ABI matches the deployed contract exactly. The example ABI shown is a template—replace it with your contract's actual ABI.