Need a quick expert recommendation?
Get a practical recommendation before you spend weeks choosing the wrong blockchain architecture.
Book a Free Strategy CallComplete Comparison
On-Chain Storage: What Belongs There
On-chain storage is appropriate for data that must be: immutable (cannot be altered after recording), publicly verifiable (anyone can confirm the value), trustless (no single party can control it), and integral to smart contract execution (the contract reads this value to determine what to do).
- Token balances and allowances (ERC-20 state)
- NFT ownership records (token ID → owner mapping)
- Governance vote records (who voted how)
- Settlement records (payment confirmed at timestamp)
- Compliance certification hashes (SHA-256 of document, not the document itself)
- Supply enforcement (total minted, max supply)
Off-Chain Storage: What Belongs Elsewhere
Off-chain storage (database, IPFS, Arweave, S3) is appropriate for data that is: large (images, videos, documents), frequently updated (user profile data, application state), private (user PII, HIPAA-protected health data), or not required for smart contract execution.
- NFT artwork (image file → stored on IPFS, hash stored on-chain)
- User profiles and identity data (database, on-chain only the wallet address)
- Order history and analytics (database, on-chain only settlement events)
- Application state (database, on-chain only financial transactions)
- PHI in healthcare applications (encrypted off-chain, hash on-chain for integrity)
The Hash Pattern
The standard architecture for large or sensitive data: store the data off-chain. Hash the data (SHA-256). Store the hash on-chain. This provides: immutable proof that the data existed and has not been changed (on-chain hash), without storing the data itself on-chain (which would be expensive and potentially reveal private information).
Used for: NFT metadata, healthcare records, supply chain documents, legal agreements, financial statements referenced in smart contracts.