ERC-20: The Standard That Powers the Token Economy
If you've ever invested in a crypto presale, held a DeFi governance token, or traded on Uniswap, you've interacted with ERC-20. This standard — a set of rules every Ethereum token must follow — is the foundational infrastructure that makes the entire token ecosystem interoperable and investable. Understanding it is the difference between treating tokens as black boxes and understanding what you actually own.
The ERC-20 Interface: What Every Token Must Implement
| Function | What It Does | Investor Relevance |
|---|---|---|
| totalSupply() | Returns total tokens in existence | Verify supply matches whitepaper |
| balanceOf(address) | Returns token balance for any wallet | Check your own balance |
| transfer(to, amount) | Send tokens to another address | Where transfer taxes are implemented |
| approve(spender, amount) | Grant contract permission to spend your tokens | Required before DEX swaps |
| transferFrom(from, to, amount) | Execute an approved token spend | Used by DEXs after your approval |
| allowance(owner, spender) | Returns remaining approved amount | Monitor and revoke old approvals |
| name() / symbol() / decimals() | Token metadata | Verify token identity |
The Approval Mechanism: Understanding the Risk
The approve/transferFrom pattern creates a permission system that powers DeFi but introduces security considerations:
- You call
approve(uniswap_router, 1000e18)— granting Uniswap permission to move 1,000 tokens - Uniswap calls
transferFrom(your_wallet, pool, 1000e18)— executing the swap - The approval persists after the swap — Uniswap could theoretically move more tokens later
Best practice: revoke approvals after completing transactions using revoke.cash for Ethereum and its L2s.
How to Read an ERC-20 Contract Safely
- Find the contract on Etherscan — verify green checkmark (source published)
- Click 'Read Contract' → call
owner()— who has admin control? - Search source code for:
mint,pause,blacklist,setFee,upgradeTo - For each found function: who can call it? Is there a maximum cap? Is there a timelock?
- Check
totalSupply()divided by 10^decimals — matches whitepaper claim?
ERC-20 on Different EVM Networks
| Network | Standard Name | Gas Token | Explorer |
|---|---|---|---|
| Ethereum Mainnet | ERC-20 | ETH | etherscan.io |
| BNB Smart Chain | BEP-20 | BNB | bscscan.com |
| Base | ERC-20 (same standard) | ETH | basescan.org |
| Arbitrum | ERC-20 (same standard) | ETH | arbiscan.io |
| Polygon | ERC-20 (same standard) | MATIC/POL | polygonscan.com |
Glossary
- ERC-20
- Ethereum Request for Comments #20 — the technical standard defining fungible token rules on Ethereum and EVM-compatible chains.
- Allowance
- The amount of tokens a specific contract is permitted to spend from your wallet, set via the approve() function.
- Fungible
- Interchangeable — one unit is identical to any other unit (1 USDT = 1 USDT, as opposed to NFTs where each is unique).
- OpenZeppelin
- The leading open-source library providing battle-tested ERC-20 and other smart contract implementations.
- Decimals
- The ERC-20 field specifying token divisibility — standard is 18 decimals (1 token = 10^18 smallest units).
Disclaimer
This is educational content about the ERC-20 token standard. Understanding ERC-20 helps with presale research but doesn't guarantee investment quality. Not financial advice.
