EIP Standards Reference

Key Ethereum Improvement Proposals for developers


Appendix B: EIP Standards Reference

Ethereum Improvement Proposals (EIPs) define standards for the Ethereum ecosystem. This appendix covers the most important EIPs for smart contract developers.

Token Standards

ERC-20: Fungible Tokens

The standard interface for fungible tokens.

interface IERC20 {
    function totalSupply() external view returns (uint256);
    function balanceOf(address account) external view returns (uint256);
    function transfer(address to, uint256 amount) external returns (bool);
    function allowance(address owner, address spender) external view returns (uint256);
    function approve(address spender, uint256 amount) external returns (bool);
    function transferFrom(address from, address to, uint256 amount) external returns (bool);
 
    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

ERC-721: Non-Fungible Tokens

The standard interface for NFTs.

interface IERC721 {
    function balanceOf(address owner) external view returns (uint256);
    function ownerOf(uint256 tokenId) external view returns (address);
    function safeTransferFrom(address from, address to, uint256 tokenId) external;
    function transferFrom(address from, address to, uint256 tokenId) external;
    function approve(address to, uint256 tokenId) external;
    function setApprovalForAll(address operator, bool approved) external;
    function getApproved(uint256 tokenId) external view returns (address);
    function isApprovedForAll(address owner, address operator) external view returns (bool);
 
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
}

ERC-1155: Multi-Token Standard

Manages multiple token types in a single contract.

interface IERC1155 {
    function balanceOf(address account, uint256 id) external view returns (uint256);
    function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids) external view returns (uint256[] memory);
    function setApprovalForAll(address operator, bool approved) external;
    function isApprovedForAll(address account, address operator) external view returns (bool);
    function safeTransferFrom(address from, address to, uint256 id, uint256 amount, bytes calldata data) external;
    function safeBatchTransferFrom(address from, address to, uint256[] calldata ids, uint256[] calldata amounts, bytes calldata data) external;
}

Security & Access Control

ERC-165: Interface Detection

Standard for publishing and detecting supported interfaces.

interface IERC165 {
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

ERC-173: Contract Ownership

Standard for contract ownership.

interface IERC173 {
    function owner() external view returns (address);
    function transferOwnership(address newOwner) external;
    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
}

Transaction Standards

EIP-2612: Permit (Gasless Approvals)

Allows approvals via signature instead of transaction.

interface IERC20Permit {
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v, bytes32 r, bytes32 s
    ) external;
 
    function nonces(address owner) external view returns (uint256);
    function DOMAIN_SEPARATOR() external view returns (bytes32);
}

EIP-712: Typed Structured Data Signing

Standard for signing typed data off-chain.

// Domain separator
bytes32 DOMAIN_SEPARATOR = keccak256(abi.encode(
    keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"),
    keccak256(bytes(name)),
    keccak256(bytes(version)),
    chainId,
    address(this)
));

EIP-1559: Fee Market Change

Base fee burning and priority tips (Ethereum only, not ETC).

Account Abstraction

ERC-4337: Account Abstraction

Enables smart contract wallets without protocol changes.

Key components:

  • UserOperation: Signed operation for the account
  • Bundler: Submits UserOperations
  • EntryPoint: Central contract that executes operations
  • Paymaster: Sponsors gas for users

Contract Standards

EIP-1967: Proxy Storage Slots

Standard storage slots for proxy implementations.

// Implementation slot
bytes32 IMPLEMENTATION_SLOT = bytes32(uint256(keccak256("eip1967.proxy.implementation")) - 1);
 
// Admin slot
bytes32 ADMIN_SLOT = bytes32(uint256(keccak256("eip1967.proxy.admin")) - 1);

ERC-1820: Pseudo-introspection Registry

Universal registry for interface detection.

EIP-2535: Diamond Standard

Multi-facet proxy pattern for modular contracts.

Network Standards

EIP-155: Replay Attack Protection

Chain ID in transaction signatures.

ChainChain ID
Ethereum Mainnet1
Ethereum Classic61
Sepolia Testnet11155111
Mordor Testnet63

EIP-1193: Provider API

Standard JavaScript API for Ethereum providers.

// Request accounts
const accounts = await window.ethereum.request({
    method: 'eth_requestAccounts'
});
 
// Send transaction
const txHash = await window.ethereum.request({
    method: 'eth_sendTransaction',
    params: [{ from, to, value, data }]
});

Metadata Standards

ERC-721 Metadata Extension

interface IERC721Metadata {
    function name() external view returns (string memory);
    function symbol() external view returns (string memory);
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

ERC-1155 URI Standard

interface IERC1155MetadataURI {
    function uri(uint256 id) external view returns (string memory);
}

Finding EIPs

When implementing EIPs, use battle-tested libraries like OpenZeppelin rather than writing from scratch.