EVMTools

ERC-20 Token Info Decoder

Decode ERC-20 token function calls and event logs from raw transaction data.

ERC-20 Function Examples

How to Use This ERC-20 Decoder

This tool decodes raw calldata and event logs from ERC-20 token transactions into human-readable function calls and parameter values. It automatically recognizes all standard ERC-20 functions and events.

  1. Paste the raw data — copy calldata from a token transaction (from Etherscan or your development tools) and paste it into the input field.
  2. Automatic detection — the tool identifies the function selector and matches it against known ERC-20 functions (transfer, approve, transferFrom, etc.).
  3. View decoded parameters — see the recipient address, token amount, spender, allowance, and other parameters in a clear format.
  4. Copy the decoded output for documentation, debugging, or audit reports.

All decoding runs locally in your browser. No transaction data is sent to any server.

Common Use Cases

  • Token transfer verification — Decode transfer calldata to confirm the correct recipient and amount before or after execution.
  • Approval inspection — Verify approve() calldata to check what allowance is being granted to which spender address.
  • DeFi debugging — Decode token interactions within complex DeFi transactions involving swaps, lending, and liquidity provision.
  • Event log analysis — Parse Transfer and Approval event logs to track token movements and permission changes.
  • Security review — Inspect token-related calldata in multi-sig proposals or governance actions before signing.

Related Tools

Frequently Asked Questions

What is the ERC-20 token standard?

ERC-20 is the most widely used token standard on Ethereum and EVM-compatible chains. It defines a set of functions (transfer, approve, transferFrom, balanceOf, allowance, totalSupply) and events (Transfer, Approval) that all compliant tokens must implement. This standard enables interoperability between tokens, wallets, and DeFi protocols.

How do I decode an ERC-20 transfer?

An ERC-20 transfer call has the function selector 0xa9059cbb followed by two ABI-encoded parameters: the recipient address (32 bytes) and the amount (32 bytes as uint256). Paste the full calldata into this tool to see the decoded recipient and token amount in human-readable form.

What is the difference between transfer and transferFrom?

transfer(address,uint256) sends tokens from the caller's balance. transferFrom(address,address,uint256) sends tokens from a specified address to another, requiring the caller to have an allowance via approve(). transferFrom is used by DEXes and DeFi protocols to move tokens on behalf of users.

How do ERC-20 event logs work?

ERC-20 events (Transfer and Approval) are emitted during function execution and stored in transaction logs. Transfer events have three indexed topics: the event signature hash, from address, and to address, plus the amount as non-indexed data. Event logs are not stored in contract storage but are accessible via eth_getLogs.

What are token decimals and why do they matter?

ERC-20 tokens use integer arithmetic with a decimals value (typically 18 for ETH-like tokens, 6 for USDC/USDT, 8 for WBTC). The raw uint256 value in calldata must be divided by 10^decimals to get the human-readable amount. For example, 1000000 in USDC (6 decimals) represents 1.0 USDC.