A vault wraps assets and issues shares. Share price = pro-rata claim on the pool.
A smart contract that holds one asset (e.g. USDC) and mints ERC-20 share tokens to depositors — like a mutual fund on-chain.
Deposit asset → get shares. Redeem shares → get asset back at current price.
When the vault earns yield, totalAssets goes up but shares stay the same → each share is worth more. No separate payout is issued.
Alice calls deposit(10,000 USDC) on an ERC-4626 vault at NAV = $1.00/share.
deposit()
transfer
deposit(assets)
Send USDC → get shares
mint(shares)
Specify shares → pay USDC
withdraw(assets)
Ask for USDC → burn shares
redeem(shares)
Burn shares → get USDC
previewDeposit / convertToShares read the exchange rate before acting.