What is On-Chain?

1 min read Updated

On-chain refers to data and transactions that are recorded directly on the blockchain — fully transparent, immutable, and verifiable by any network participant.

WHY IT MATTERS

On-chain means it's on the blockchain. Transactions, smart contract state, token balances, NFT ownership — all on-chain. Anyone can verify this data by running a node or querying a block explorer.

The tradeoff: on-chain storage is expensive (storing 1 byte costs gas) and permanent. This is why applications use on-chain storage selectively — putting critical state (balances, ownership) on-chain while keeping large data (images, documents) off-chain.

On-chain data is the ground truth. If there's a dispute between what an app shows and what's on-chain, the blockchain is correct.

FREQUENTLY ASKED QUESTIONS

What data should be on-chain?
Financial state (balances, ownership), critical logic (smart contract rules), and anything requiring trustless verification. Large files, metadata, and UI state belong off-chain.
Is on-chain data private?
Public blockchains are transparent — all on-chain data is visible. Privacy requires encryption, zero-knowledge proofs, or keeping sensitive data off-chain.
How expensive is on-chain storage?
On Ethereum L1, storing 32 bytes costs ~20,000 gas. At 30 gwei, that's ~$2. On L2s, it's orders of magnitude cheaper. This cost drives the on-chain/off-chain design decision.

FURTHER READING

Enforce policies on every tool call

Intercept is the open-source MCP proxy that enforces YAML policies on AI agent tool calls. No code changes needed.

npx -y @policylayer/intercept
github.com/policylayer/intercept →
// GET IN TOUCH

Have a question or want to learn more? Send us a message.

Message sent.

We'll get back to you soon.