Written by Pablo Gómez
Founder & CEO at Metlabs · Reviewed on October 11, 2026
ERC20Votes inherits from OpenZeppelin's abstract `Votes` module, which implements ERC-5805. Each account's voting units equal its ERC-20 balance, but that balance does not count as votes until the account delegates, to itself or another, with `delegate` or `delegateBySig`. On every transfer or delegation change a voting-power checkpoint is written, later queried with `getVotes` and `getPastVotes`. By default the clock uses block number and, per ERC-6372, can use timestamps. It is not an EIP with its own number, but an OpenZeppelin contract extension conforming to those standards.
It is the standard building block of DAOs. It enables secure snapshot-based on-chain voting, which stops anyone buying votes and reselling them in the same block, and delegated governance without giving up custody. It is the direct materialization of ERC-5805 on a fungible token.
The best-known governance tokens are built on this pattern: Uniswap's UNI, Compound's COMP (the original design that inspired the extension), ENS, Gitcoin and AAVE. It pairs with OpenZeppelin's `Governor` contract for the propose, vote, queue and execute flow, often alongside a `TimelockController`. In recent OpenZeppelin versions, `ERC20Votes` was unified around `uint256`, replacing the older variant capped at `uint96` for compatibility with Compound's Governor.
Also known as
- ERC20Votes





