Behavioural Senior Level

You are designing a new smart contract system. How do you decide which logic goes on-chain versus off-chain? Walk me through your architectural decisions.

Quick Tip

Frame it as a trust question: "Only put logic on-chain when users need to verify it without trusting anyone. Everything else goes off-chain to reduce cost and increase flexibility."

What good answers include

On-chain: asset ownership, critical business rules that require trustlessness, token transfers, governance votes. Off-chain: complex computation, data storage, user interfaces, metadata, and anything that does not need consensus. Hybrid patterns: IPFS for data with on-chain hashes, oracles for external data, off-chain signing with on-chain verification (EIP-712), and Layer 2 for scalability. Strong candidates discuss gas cost budgets, user experience trade-offs, and the trust spectrum.

What interviewers are looking for

Senior architecture question. Candidates who put everything on-chain create expensive, slow systems. Those who put too little on-chain undermine the value proposition of blockchain. Look for thoughtful trade-off reasoning.

← All Solidity questions