← Protocols
ERC-6551 — Token Bound Accounts
Standard / EIP·EVM

ERC-6551 — Token Bound Accounts

01Description

ERC standard in Review. Gives every ERC-721 NFT its own deterministic smart-contract account, so an NFT can hold tokens, sign transactions, and own other NFTs. The singleton registry at `0x000000006551c19487814612e58FE06813775758` deploys account proxies via CREATE2 with no NFT-contract changes required.

02Best for
  • 01NFTs that own assets (game characters, vaults, profiles)
  • 02composable on-chain identity
  • 03subscription / membership inventories
  • 04AI agent NFTs that hold operating capital
  • 05wallet-as-an-NFT user accounts
03Install
  • pnpm add erc6551
05Prompt snippet
Use the canonical singleton `ERC6551Registry` at `0x000000006551c19487814612e58FE06813775758` (same address on every supported EVM chain) and the reference account implementation `ERC6551Account` from the `erc6551/reference` repo (or Tokenbound's `AccountV3`). Compute an NFT's account address with `registry.account(implementation, salt, chainId, tokenContract, tokenId)` and deploy it with `registry.createAccount(...)`. The account exposes `token() returns (uint256 chainId, address tokenContract, uint256 tokenId)`, `owner()` (resolves through `IERC721.ownerOf`), and `execute(to, value, data, operation)` gated to the current NFT owner. Front-end SDK: `@tokenbound/sdk` for typed helpers. Always advertise `IERC6551Account` (`0x6faff5f1`) and `IERC6551Executable` (`0x51945447`) via `supportsInterface`.
06Gotchas
  • The account's owner CHANGES whenever the underlying NFT is sold — the new holder inherits everything in the TBA. Audit who controls the NFT before relying on permissions.
  • Selling the parent NFT silently transfers all assets inside the TBA. Front-ends and marketplaces must surface this clearly to avoid accidental rug-on-sale.
  • The registry is a singleton at `0x000000006551c19487814612e58FE06813775758` — do NOT redeploy it; doing so produces a different account address space and breaks composability.
  • The salt parameter lets one NFT have many accounts. Pick a single canonical salt (most ecosystems use `0`) or you'll fragment which account 'is' the NFT's account.
  • Soulbound NFTs (ERC-5192) make their TBAs effectively soulbound too — burning the SBT orphans whatever is inside.
  • Some implementations forget to validate the caller against the current `owner()` on every `execute` — leaving the TBA controllable by stale signers.
07Alternatives