⏳ TokenVesting cliff · linear · from scratch
—
vested 0% connect wallet

Time-release your tokens.

Funded schedules vest with a cliff, then linearly. Beneficiaries claim what's vested — owners can revoke the unvested remainder at any time.

start— cliff— end— total— claimed— status—
releasable now — of your vesting schedule contract ↗
your schedule
start cliff end
vested cliff point

connect your wallet to see your schedule

Activity

loading…

Loading…

How this dApp works

A plain-language guide to the TokenVesting dApp — what each button does, and the on-chain flow behind it. Configured for Sepolia testnet.

1 · How to use

  1. Connect your wallet with Connect Wallet (top-right). The dApp opens on the Sepolia testnet (chain 11155111) — switch MetaMask to Sepolia and grab test ETH from a faucet if needed.
  2. Your vesting ring, the start / cliff / end / total / claimed chips and the schedule bar load from your schedule; the “releasable now” card shows what you can withdraw today.
  3. Press Claim vested tokens whenever the releasable amount is above zero — the Activity strip below logs every claim (↻ refreshes it).
  4. Owners see the owner tools card: enter beneficiary, amount (VEST), cliff days and vesting days, then press Create schedule — the dApp approves the token spend for you.
  5. To stop a grant, enter the beneficiary and press Revoke: the unvested remainder returns to you, the beneficiary keeps what already vested.
  6. ⚙ Settings switches network or TokenVesting address (Mainnet / Sepolia / local Anvil); if no contract is configured yet, the setup banner accepts an address via Use this contract.

2 · The process — what happens on-chain

  1. MockToken implements the minimal IERC20 interface and is the VEST token; the owner approves TokenVesting to spend the grant from their wallet.
  2. TokenVesting.createSchedule() — owner-only (Ownable): pulls the full grant in with transferFrom and stores start, cliff and end, so claims are always backed by real tokens.
  3. TokenVesting.vestedAmount() does the math: 0% before the cliff, then linear — total × (now − cliff) / (end − cliff) — reaching 100% at the end.
  4. TokenVesting.claim() — the beneficiary withdraws vested-minus-claimed; ReentrancyGuard protects the payout against re-entrancy.
  5. TokenVesting.revokeSchedule() — the owner freezes accrual at the revocation timestamp, gets the unvested tokens back, and the beneficiary keeps exactly what vested.

3 · Flow graph

1 Approve & fund VEST MockToken (VEST) 2 Create schedule TokenVesting 3 Cliff, then linear TokenVesting 4 Claim vested tokens TokenVesting 5 Revoke (optional) TokenVesting Sepolia testnet · funded at creation · claims always backed

Left to right: fund a schedule → cliff, then linear unlock → claim. Revoke is an owner-only exit that stops future vesting.