Solidity & Smart Contract Developer Interview Questions (2026)
Technical sources checked October 20–21; incident figures are dated reports
A contract can have the right modifier, a familiar library and a respectable stack of audits, yet trust the wrong thing. A vault trusts that a balance change came from rewards. A price feed trusts a forwarder. A signer trusts the transaction shown on a screen. The interesting interview question begins when someone asks who controls that assumption.
That is the thread through this guide: explain what the code relies on, show how the assumption can fail, then describe a test or design change that would expose it. Syntax matters because it lets you be precise. Reciting vulnerability names is less useful than following control through one external call.
The questions cover the EVM, gas, security, DeFi, account abstraction, L2s and testing, followed by prompts for four kinds of role. J, M and S suggest junior, mid-level and senior depth; they are study labels, not a hiring rubric. Ten reported incidents supply follow-ups. You don't need to memorize their dollar amounts. You do need to understand why the money could move.
What changed for Solidity interviews in 2025–2026
Compiler and chain versions belong in the answer. Code that is safe under one set of assumptions may behave differently on an older deployment or an L2. These changes give you useful follow-up questions; they aren't evidence that every interviewer will ask them.
| Change | Version or date | Question to practice |
|---|---|---|
EIP-7702, type 0x04, in Pectra | Announced mainnet activation: May 7, 2025 | What does an EOA with delegated code do to your caller assumptions? |
| ERC-4337 is Final | Status checked October 21, 2026 | What do bundlers, paymasters and EntryPoint validate? How does 7702 fit? |
| Fusaka | Announced mainnet activation: December 3, 2025 | P-256 (EIP-7951), CLZ (EIP-7939), transaction gas cap (EIP-7825): which target chain supports the feature you need? |
| Solidity 0.8.31–0.8.37 | Dec 2025–Sep 2026; 0.8.37 released Sep 10 | Check osaka targeting, the erc7201 builtin added in 0.8.35, and warnings before changing compiler versions |
| Transient state variables | Solidity 0.8.28, October 2024 | When must a transaction-scoped lock be cleared so a second call can work? |
Sources: the Ethereum Foundation's Pectra announcement and Fusaka announcement, ERC-4337 and the Solidity release index. Check a deployment's actual compiler and chain configuration before applying this table to it.
How smart contract interviews are structured
A frontend developer and an auditor can both be asked about signatures, but need to follow different parts of the system. Use the role to set your preparation priorities. These are possible exercises; confirm your own format with the recruiter.
| Round | Smart contract engineer | DeFi protocol engineer | Auditor / security researcher | Web3 frontend |
|---|---|---|---|---|
| Screen | Solidity and EVM fundamentals | Fundamentals + DeFi vocabulary | Vulnerability classes, past findings | React/TypeScript + wallet basics |
| Technical | Write or fix a contract live | Design a pool, vault or lending market | Review unfamiliar code and explain findings | Build a wallet flow (connect, sign, send) |
| Take-home ("web3 task") | Small protocol with Foundry tests | Mechanism with invariant tests | Audit a small codebase, write findings | dApp against a testnet contract |
1. EVM and Solidity fundamentals
Start with what changes and what persists. A problem that looks like exotic DeFi mathematics can begin with an ordinary mistake about a copy, a call or a storage slot.
Q (J): What is the difference between storage, memory and calldata? storage is persistent state and the most expensive to touch. memory is a temporary buffer for one call. calldata is the read-only call input; prefer it for read-only external array arguments to avoid a copy. Classic bug: assigning a storage struct to a memory local makes a copy, so changes to it are never saved. A storage local is a reference.
Q (J): Explain public, external, internal and private. public functions support internal and external calls; public state variables get generated getters. An external function uses an external call, including an explicit self-call such as this.f(), rather than a direct internal call f(). That self-call changes call context, including msg.sender, and costs gas. internal is accessible in the contract and derived contracts; private only in the declaring contract. Neither hides on-chain data. A private variable is a language access rule, not a secret.
Q (J): require, revert, assert and custom errors: when do you use each? Use require or if (...) revert for validation, and assert only for invariants that should never fail (it raises Panic(0x01)). Custom errors are cheaper than revert strings because only a 4-byte selector plus arguments is encoded. Since 0.8.26 (via-IR) and 0.8.27 (legacy pipeline) you can write require(ok, MyError()). Know the panic codes 0x11 (overflow), 0x12 (division by zero) and 0x32 (index out of bounds).
Q (J): What are events for, and what does indexed do? Events write logs that off-chain code (indexers, frontends) can read cheaply. Contracts cannot read them. A non-anonymous event can have up to three indexed parameters. Indexed parameters become topics, so you can filter by them. Indexed reference types such as string are stored as their hash, so the original value can't be recovered from the topic.
Q (J): What's the difference between receive and fallback? With empty calldata, receive() runs if present; otherwise the call goes to fallback(). Nonempty calldata with no matching function selector goes to fallback() whether or not a receiver exists. Accepting ETH requires the selected function to be payable. Ordinary transfers can revert while ETH can still arrive through a path such as a SELFDESTRUCT beneficiary transfer. Consequently, address(this).balance alone doesn't establish the sum of customer deposits or liabilities. It can measure ETH assets in a solvency check, but the obligations need their own accounting.
Q (M): Compare call, delegatecall and staticcall. call runs the target's code in the target's context. delegatecall runs the target's code in the caller's storage, with the caller's msg.sender and msg.value. That is how proxies and libraries work, and also why a delegatecall to an untrusted address is a full takeover (see Bybit below). staticcall reverts if the callee tries to modify state. Low-level calls return false instead of reverting, so you must check the return value.
Q (M): Is overflow still a concern after Solidity 0.8? Checked arithmetic normally reverts on overflow or underflow in 0.8 and later. unchecked arithmetic can wrap, explicit narrowing casts can truncate, and older deployed contracts retain their original compilation semantics. A modern compiler on your laptop does nothing for those deployments. BlockSec's Truebit analysis identifies Solidity 0.6.10 and an overflowing purchase-price calculation in the January 2026 incident.
Q (M): What is transient storage? EIP-1153 adds TSTORE and TLOAD: state that disappears at transaction end. Solidity 0.8.28 supports transient value-type state variables such as bool transient locked;. A transient reentrancy guard can save gas compared with a persistent storage lock. But transaction-scoped doesn't mean call-scoped. If a successful function leaves the lock set, a second legitimate call in the same batch can fail. Release it when the protected operation finishes; transaction-end cleanup is too late for that second call.
Q (S): Is require(msg.sender == tx.origin) a valid "caller is an EOA" check in 2026? No. It was always a weak pattern, and EIP-7702 breaks the assumption behind it: an EOA can now carry delegated code, and the EIP itself notes that the msg.sender == tx.origin assumption no longer means "top-level frame only". extcodesize == 0 is unreliable too: it is 0 for a contract still running its constructor and non-zero for an EOA with delegated code. Design so that contract callers are safe, rather than trying to exclude them.
2. Gas optimization
Gas is a resource budget, so start with measurement. Saving an instruction while adding another storage access is an elaborate way to lose.
Q (J): Why is storage expensive, and roughly how expensive? Since EIP-2929, the first (cold) read of a slot costs 2,100 gas and later (warm) reads cost 100. A zero-to-nonzero storage write has a base cost around 20,000 gas; actual charges depend on access warmth and slot state. These EVM gas figures do not predict fiat cost or an L2 total fee. Look first for avoidable storage access and writes.
Q (M): How does variable packing work? The EVM uses 32-byte slots. Consecutive state variables or struct fields that fit together share one slot. Order matters:
struct Packed { uint128 a; uint64 b; uint64 c; } // 1 slot
struct Unpacked { uint128 a; uint256 b; uint64 c; } // 3 slotsPacking helps when the fields are read or written together. Reordering an existing proxy layout is a different matter: saving a slot can corrupt its data. If one field is written often and the others rarely, packing can cost more, because every write has to read-modify-write the shared slot.
Q (M): Name five practical optimizations. Cache storage reads in loops, use calldata for read-only arguments, use custom errors, use immutable/constant for configuration, and avoid unbounded loops over storage. Since 0.8.22, the compiler can remove overflow checks for eligible simple loop increments. Check your compiler and generated result before adding manual unchecked blocks. An unbounded storage loop is also a liveness risk: eventually no caller may be able to afford it.
Q (S): When should you NOT optimize gas? When it hurts readability in security-critical code or adds assembly that reviewers can't check easily. Senior answer: "I measure with forge test --gas-report, optimize hot paths only, and keep assembly isolated and fuzzed." Know the hard limits: the 24,576-byte contract size limit (EIP-170) and, since Fusaka, a per-transaction gas cap of about 16.78 million (EIP-7825).
3. Security: follow the control and the value
A modifier answers one question about one entry point. Follow the operation through callbacks, other contracts and privileged actors until the state is consistent again.
Q (J): What is reentrancy and how do you prevent it? An external call hands control to another contract, which calls back into you before your state is updated.
// Vulnerable: balance is zeroed after the external call
function withdrawAll() external {
uint256 amount = balances[msg.sender];
(bool ok, ) = msg.sender.call{value: amount}("");
if (!ok) revert TransferFailed();
balances[msg.sender] = 0;
}This exact example remains vulnerable with Solidity 0.8 checked arithmetic: writing zero after the call doesn't underflow as nested calls unwind. Move the accounting effect before payment and consider a guard across functions that share the affected state. A different example using balances[msg.sender] -= amount after the call may revert on underflow; that doesn't make this example safe or turn 0.8 into a reentrancy defense.
Then extend the reasoning. Can another function spend the same balance? Can another contract observe an inconsistent price through a view and act on it? Cross-function, cross-contract and read-only reentrancy are ways unfinished state becomes someone else's input.
Q (J): What access control mistakes do you look for first? List privileged operations, then trace who can reach them: missing admin checks, an unprotected initialize(), an implementation left initializable, a role that grants itself more authority, or one key able to mint or upgrade without a bound. Lock implementations where the proxy pattern calls for it. A deliberately all-powerful admin can satisfy every access check and still violate the trust model users thought they had.
Q (M): How does oracle or price manipulation work? An attacker moves an input, takes an action priced from it, then unwinds the manipulation. A flash loan can supply temporary capital. Inspect source independence, liquidity, update rules, staleness and deviation bounds. A TWAP raises the cost of some attacks; its window and market depth still need a threat model. On supported L2s, sequencer status and a recovery grace period can matter before liquidations resume. Naming a feed provider starts the answer; it doesn't establish that the price is safe to use.
Q (M): How do you prevent signature replay? Bind the signature to its operation: a domain including chain and verifying contract, all relevant parameters, a nonce and any deadline. Consume the nonce before an external interaction can reuse it. EIP-712 makes typed data explicit; it doesn't invent nonce handling for you. Use a vetted signature library, reject invalid recovery, and support the appropriate verification path for contract-wallet signers. Ask whether a signature for one amount, recipient or action could authorize another.
Q (M): What are the classic proxy and upgradeability pitfalls?
- Storage collisions when a new implementation reorders variables. Use ERC-1967 slots for proxy data and ERC-7201 namespaced storage for app state (Solidity 0.8.35 added an
erc7201builtin that computes the slot). - Uninitialized implementations and unprotected initializers.
- Selector clashes between proxy and implementation.
- UUPS: an unprotected
_authorizeUpgrade, or an implementation without the upgrade function, which bricks upgrades. delegatecallto arbitrary targets from a privileged context.
On chains implementing EIP-6780, SELFDESTRUCT generally transfers ETH without deleting code; deletion is limited to a contract created in the same transaction. Check fork rules before applying older destructive-upgrade assumptions to a deployment.
Q (M): What is front-running and MEV, and how do you design against it? Searchers and builders see pending transactions and can order theirs around yours, as in a sandwich attack on a swap. Defenses: slippage limits (amountOutMin) and deadlines, commit-reveal, batch auctions, private order flow, and no on-chain "randomness" from block data.
Q (M): What is the ERC-4626 inflation (donation) attack? In a simple empty vault, an attacker obtains a tiny share position and donates assets directly. The inflated assets-per-share rate can make the next user's deposit round down to few or zero shares. OpenZeppelin explains virtual assets/shares and a decimals offset as a defense in its implementation. Seeding a vault or rejecting zero-share results addresses parts of the problem, but neither phrase proves safety across donation sizes and repeated operations. Test the actual conversions and minimum accepted output.
Q (S): Why does rounding direction matter? Specify it per operation and per conversion. In ERC-4626, shares returned for a deposit round down, while assets required for a requested share mint round up. Rounding must preserve the intended economic guarantees across sequences of actions too. Tiny absolute errors become large relative errors near empty balances, and a batch can make them repeatable. "Round in the protocol's favor" is a reminder to investigate, not a full specification of pool mathematics.
Q (S): Which ERC-20 behaviors break naive integrations? Some tokens omit a return value; others levy transfer fees, rebase balances, block recipients, invoke hooks or use unexpected decimals. SafeERC20 helps handle token call and return-value conventions. It doesn't make a fee-on-transfer deposit credit the correct amount or settle a rebasing token's accounting policy. Define supported behavior, measure actual received amounts where needed, and consider callbacks in the control-flow review.
4. DeFi questions
Here arithmetic expresses a financial promise. State the promise before the formula, then ask what happens when prices move or someone declines to follow the pleasant path through your diagram.
Q (J): How does a constant-product AMM work? The pool keeps x * y = k for two reserves. A trade adds to one side and takes from the other so that k stays constant (it grows slightly from fees). Price is the ratio of reserves, and larger trades move it more: that is price impact. Concentrated liquidity (Uniswap v3-style) lets LPs provide liquidity within a price range for higher capital efficiency, at the cost of more active management.
Q (M): Explain a lending market's health factor and liquidations. Each collateral asset has a liquidation threshold. A position's health factor is roughly (collateral value × threshold) / debt value. Below 1, anyone can repay part of the debt (bounded by a close factor) and receive collateral at a discount (the liquidation bonus). Follow-ups: bad debt when prices fall faster than liquidators act, oracle latency, and interest-rate curves.
Q (M): What is a flash loan, and is it a vulnerability? An uncollateralized loan repaid in the same transaction, or everything reverts. It isn't a vulnerability: it lets someone with no capital exploit a capital-dependent bug. Name the real root cause (manipulable oracle, broken accounting), not "flash loan".
Q (S): How would you design an oracle for a new lending market? An aggregated feed with staleness and deviation checks, a circuit breaker, supply caps, sanity bounds on donation-sensitive rates (ERC-4626 share prices), and the sequencer check on L2s.
Q (S): How do you secure a mint function for a stablecoin or synthetic asset? Separate permission to request a mint from permission to issue an unbounded amount. Depending on the collateral model, enforce: per-epoch caps, collateral-ratio checks, and a multisig or timelock for privileged roles. Assume the signing key will be compromised one day, and limit what it can do when that happens.
5. Account abstraction: ERC-4337 and EIP-7702
These proposals solve related problems at different layers. Keep account control, operation processing and payment separate when explaining how they fit.
Q (M): What are the parts of ERC-4337? Users sign UserOperations for a separate mempool. Bundlers simulate them and submit batches to the shared EntryPoint, which runs validation (the account's validateUserOp) and then execution. Paymasters sponsor gas or take ERC-20 payment; aggregators verify many signatures at once. Validation rules restrict opcodes and storage access so bundlers can't be griefed. ERC-4337 now lists EIP-7702 as a requirement, and EntryPoint v0.8 supports 7702 authorizations natively.
Q (M): What does EIP-7702 do? It adds transaction type 0x04 with an authorization_list. Each authorization (chain_id, address, nonce plus a signature) makes the EOA's code a delegation indicator (0xef0100 || address). Calls to the EOA then run the delegate's code in the EOA's own storage. The EOA keeps its private key, and delegating to the zero address resets it to a plain EOA. Use cases: batching, gas sponsorship, session keys, all from an existing address.
Q (S): What are the security risks of EIP-7702?
- Malicious delegation: delegate code executes in the account context and can expose its assets. A friendly wallet prompt does not constrain the code the user authorizes.
- Storage collisions when switching delegates. The EIP recommends ERC-7201 namespaced storage.
- Initialization front-running: no initcode runs on delegation, so setup calls must be authenticated, for example by a signature from the EOA's key.
- An authorization with
chain_id = 0has cross-chain scope on chains supporting the mechanism. - Broken assumptions in other contracts:
tx.originchecks, "EOAs have no code", and the idea that a call to an EOA can't re-enter.
Q (S): ERC-4337 vs EIP-7702: which do you pick? They complement each other. 7702 gives an existing EOA smart-account code; 4337 provides the infrastructure (bundlers, paymasters, EntryPoint) that both 7702 accounts and native smart accounts use. Since Fusaka, the P-256 precompile (EIP-7951) makes passkey signatures cheaper to verify.
6. L2 questions
Q (J): Optimistic vs ZK rollups? Optimistic designs rely on a challenge process for disputed execution; canonical withdrawals can wait through a challenge window. ZK designs use validity proofs for execution correctness. Proof production, submission, L1 finality and bridge implementation still affect withdrawal time: a validity proof does not make every withdrawal instant. Rollups using EIP-4844 blobs can lower data-posting costs. Distinguish the mechanism from a particular chain configuration.
Q (M): What changes when you deploy the same contract to an L2?
- Sequencer downtime: prices can go stale while users can't act. Check Chainlink's L2 sequencer uptime feed and apply a grace period before liquidating.
block.number: on Arbitrum it returns a value close to the L1 block number. UseArbSys(100).arbBlockNumber()for the L2 block, or use timestamps.- Cross-chain messages: some L1-to-L2 routes, including Arbitrum paths, alias L1 contract senders. Other routes authenticate differently. Check the exact messenger, origin and replay rules; do not apply one aliasing rule to every L2.
- EVM version and precompiles differ per chain. Check before you rely on the latest opcodes.
Q (S): How should a protocol think about bridge risk? Map the full authorization path: verifier independence, configuration and upgrade powers, message replay checks, off-chain infrastructure and value limits. Ask what one compromised component can release and how quickly the route can be paused. The reported KelpDAO incident below is a prompt to examine those dependencies; its disputed configuration responsibility is separate from the design exercise.
7. Testing and tooling
A test is an executable statement about a model. Before admiring how many calls a fuzzer made, check whether the model permits the failure you care about.
Q (J): Unit tests vs fuzz tests vs invariant tests? Unit tests check specific cases. Fuzz tests run one function with many random inputs. Invariant tests (stateful fuzzing) run random sequences of calls across functions and check properties that must always hold, such as "the total supply equals the sum of balances" or "the vault holds at least what it owes".
Q (M): How do you write a useful invariant test in Foundry? A handler bounds actions, funds actors and tracks ghost state used for comparison. Here is a scaffold, not a complete runnable test. It assumes a separate Vault with payable deposit(), withdraw(uint256) and a public balances getter, plus Foundry's Test imports and invariant-test setup.
// Assumes a separate Vault with this interface:
// deposit(), withdraw(uint256), public mapping balances
contract Handler is Test {
Vault public vault;
uint256 public ghostDeposits;
constructor(Vault _vault) { vault = _vault; }
function deposit(uint256 amount) external {
amount = bound(amount, 1, 100 ether);
vm.deal(address(this), amount);
vault.deposit{value: amount}();
ghostDeposits += amount;
}
function withdraw(uint256 amount) external {
amount = bound(amount, 0, vault.balances(address(this)));
vault.withdraw(amount);
ghostDeposits -= amount;
}
receive() external payable {}
}
contract VaultInvariants is Test {
Vault vault;
Handler handler;
function setUp() public {
vault = new Vault();
handler = new Handler(vault);
targetContract(address(handler));
}
function invariant_solvency() public view {
assertEq(address(vault).balance, handler.ghostDeposits());
}
}The equality assertion fits a deliberately restricted model: the handler is the only participant, deposits and withdrawals move the recorded amounts, and no donation, forced ETH or yield changes the balance. Its name invariant_solvency doesn't make equality a universal definition of solvency. For a vault accepting other inflows, reason about assets ≥ liabilities and track those liabilities correctly. For a strategy vault, valuation and withdrawal availability add further conditions.
Tune runs, depth and fail_on_revert to the property. If nearly every call reverts, many executions can explore very little behavior. When expected reverts are allowed, check that the important successful actions still occur.
Q (M): What other tools do you use? Static analyzers such as Slither and Aderyn flag suspicious code; Echidna, Medusa and Foundry explore fuzzed behavior; Halmos explores Foundry-style tests symbolically. Hardhat supports TypeScript and Solidity testing workflows. Choose supported project versions rather than memorizing a preview feature's release number. Fork tests reveal integration behavior mocks may omit, but represent a particular chain state. No tool repairs a wrong specification, secures a signer's workstation or proves that privileged roles have acceptable power.
Real exploits as interview questions
Choose a few incidents and reconstruct the transaction or trust boundary. Explaining one failure all the way through is more persuasive than reciting ten names followed by ten amounts.
The figures below are reported incident estimates, not comparable final net losses. Reports can count funds taken, value issued or affected deployments differently; use the dates and scope in the table when comparing them.
| Incident | Date | Reported amount and scope | Mechanism to study |
|---|---|---|---|
| Penpie | Sep 3, 2024 | ~$27M taken | Reentrancy + permissionless market input |
| UwU Lend | Jun 10, 2024 | ~$19.4M in the first incident | Manipulated oracle inputs from pool states |
| Bybit | Feb 21, 2025 | ~$1.5B taken | Signing-interface compromise + malicious delegatecall |
| KiloEx | Apr 14, 2025 | ~$7.5M across deployments | Authorization failure on a price-setting path |
| Resupply | Jun 26, 2025 | ~$9.6M reported | Donation-sensitive rate + zero rounding |
| GMX V1 | Jul 9, 2025 | ~$42M initially taken; most returned for a bounty | Reentrancy into inconsistent short accounting |
| Balancer V2 | Nov 3, 2025 | $120M+ across Balancer and forks in OpenZeppelin's analysis | Direction-insensitive rounding in repeated swaps |
| Truebit | Jan 8, 2026 | ~$26M reported | Overflow in purchase pricing compiled before 0.8 |
| Resolv | Mar 22, 2026 | ~$25M extracted after ~80M unbacked USR issued | Compromised minting key with unbounded authority |
| KelpDAO rsETH | Apr 18, 2026 | ~116,500 rsETH, valued at ~$290M in reports | Bridge-verifier compromise; configuration responsibility disputed |
Penpie: "Rewards are computed from a balance difference. What can go wrong?" The reported harvest path measured balances around a call to a supplied market. An attacker-controlled market could re-enter and deposit during that call, so the difference included deposits rather than only rewards. Work through market admission, callback control and accounting together. A guard or allowlist deserves a follow-up: which entry points and counterparties does it cover? Establish the origin of a balance change, not merely its existence.
UwU Lend: "Your oracle takes a median of many sources. Is that safe?" Sources that move together aren't independent observations. In the reported attack, manipulable Curve pool states affected oracle pricing and borrowing or liquidation behavior. Draw the data dependencies before counting feeds. Then ask how much capital and time an attacker needs to move enough inputs, and what action the lending protocol permits at the resulting price.
Bybit: "Three signers approved it. How did the assets leave?" The reported attack compromised the signing interface so that a routine-looking operation concealed a malicious delegatecall. That call changed the Safe's implementation pointer and enabled asset transfers. Follow what signers saw, what they signed and what execution did. Independent transaction decoding and guards can reduce specific risks; a multisig approval doesn't prove that its payload matched everyone's intent. The signing environment belongs in the trust model alongside the contract.
KiloEx: "Prices are only set through a trusted forwarder. Where's the bug?" Halborn's analysis traces the restricted price-setting path back to a public forwarder with inadequate authorization. The attacker could submit data to set a low price, open a position, then raise the price and close it. Review the full call path and what a signature binds. An access check can be locally correct while the identity it trusts was accepted incorrectly upstream.
Resupply: "The oracle reported the exchange rate correctly. Why was that a problem?" Reports describe a donation into a nearly empty collateral vault inflating its share rate. A calculation of 1e36 / price rounded to zero, undermining the collateral check. Follow the units and the rate's downstream use, including zero and extreme values. Minimum liquidity, rate bounds and zero checks must preserve the whole lending invariant; "seed the vault" doesn't finish the analysis.
GMX V1: "Functions have guards. Can the system still be re-entered?" Halborn describes a refund callback reaching a circular path through short accounting, AUM and GLP valuation before the state was consistent. GLP could be redeemed at an inflated value. Its report traces the bug to an unaudited earlier fix and says funds were returned minus a $5M bounty. Draw the shared state across contracts: guard coverage belongs to the complete operation, not to a count of nonReentrant modifiers.
Balancer V2: "How can rounding a few wei down become an expensive bug?" OpenZeppelin's analysis shows scaling that rounded down regardless of swap direction. At tiny pool balances, relative error affected exact-output pricing; repeated operations through batchSwap amplified the opportunity. Explain each conversion's required direction, test extreme liquidity states and check a sequence's economic result. A small absolute error doesn't imply a small extractable error.
Truebit: "Why would a 2026 exploit involve integer overflow?" BlockSec's decompiled-bytecode analysis identifies Solidity 0.6.10 and an overflow in the TRU purchase-price computation. A large intermediate value wrapped to a small payment, while redemption used a different pricing path. The attacker could buy cheaply and redeem against reserves. Review deployed bytecode, compiler semantics and both paths; calendar year is a poor arithmetic defense.
Resolv: "Why didn't a history of audits limit what one stolen key could mint?" Sentora's analysis reports roughly 80M unbacked USR issued through a compromised key, with about $25M extracted. It describes signature verification without on-chain mint caps or collateral-ratio enforcement. Compute the authority granted by the design, then ask what still constrains it when the signer fails.
KelpDAO: "Which part of a bridge do you audit first?" Reports describe a forged message accepted through compromised verifier infrastructure on a route using one verifier. LayerZero and Kelp disputed responsibility for that configuration. Keep disputed attribution separate from the design exercise: inspect independent verification, configuration powers, rate limits, pause paths and infrastructure dependencies. A diagram with two protocol logos can still have one operational point of failure.
Smart contract auditor interview questions
Auditor interviews ("web3 security interview questions") focus on method more than trivia.
- "Walk me through how you audit a new codebase." Docs and tests first, then trust boundaries and privileged roles, invariants, every external call and value flow, function by function, and finally fuzzing the invariants.
- "Rate this finding's severity." Explain reachable impact, prerequisites, privileges and the program's rubric. Distinguish an arbitrary caller from a trusted admin, while checking whether admin trust itself is the disputed assumption.
- "Write a proof of concept." Expect to write a Foundry test that demonstrates the exploit on a fork or a local deployment.
- "Tell me about a finding you're proud of, and one you missed." Have a real contest or bounty report ready.
- Live review: practice a bounded exercise, for example 45–90 minutes on a small contract. State unresolved questions instead of filling them with confident guesses. The employer sets the actual duration, code size and format.
DeFi protocol engineer interview questions
- "Design a lending market for a new collateral asset." Cover the oracle, liquidation threshold, close factor, caps and the bad-debt path.
- "Design an ERC-4626 vault with a strategy." Cover inflation protection, rounding direction, withdrawal queues and how losses are reported.
- "What invariants would you fuzz for an AMM?" Start from the mechanism. For a basic fee-bearing constant-product pool, reason about the reserve product across swaps; do not transplant that property unchanged to concentrated liquidity, donations or liquidity withdrawals. Check user claims and solvency across sequences.
- "How would you respond to a live exploit?" Pause, assess the scope, coordinate with security partners, communicate, write the post-mortem.
- "What's the MEV impact of your design?" Liquidations, oracle updates and rebalances are all MEV opportunities. Say who captures them.
Web3 frontend interview questions
- "How does a dApp find the user's wallet?" Through an EIP-1193 provider. With several extensions installed, use EIP-6963 discovery (the
eip6963:announceProviderandeip6963:requestProviderevents) instead of relying onwindow.ethereum. - "How do you batch approve + swap into one confirmation?" EIP-5792 provides
wallet_getCapabilities,wallet_sendCallsandwallet_getCallsStatus. Check wallet capabilities on the selected chain and request the atomicity the operation needs. A smart account or a method name alone does not guarantee support for atomic execution. - "Walk me through a transaction's lifecycle in the UI." Simulate, estimate, sign, broadcast, pending, confirmed or replaced or dropped, and reorg handling. Show the decoded error from a custom-error revert.
- "How do you make signing safe for users?" Use EIP-712 typed data, show human-readable intent, never request unlimited approvals by default, and warn on 7702 authorization requests. The Bybit incident makes the signing interface part of this discussion. Libraries such as viem and wagmi provide plumbing; they do not decide what authority the user should trust.
Blockchain developer and web3 developer interviews
Broader "blockchain developer interview questions" add basics: proof of stake and finality, Merkle proofs, signatures, account model vs UTXO, and EIP-1559 fees (base fee plus priority fee). Multichain teams may ask how Solana's account model differs from Ethereum's.
How to prepare: a six-week plan
This is a sample sequence, not an entrance requirement. Choose exercises for your role and available hours. Finishing an entire challenge collection is less useful than being able to explain why your solution works.
| Week | Focus | Concrete output |
|---|---|---|
| 1 | Fundamentals and the EVM | Explain sections 1–2 aloud; verify uncertain answers in the Solidity docs; build a small storage/call example |
| 2 | Security classics | Solve selected Ethernaut levels; write down the failed assumption and a regression test for each |
| 3 | DeFi attacks | Choose Damn Vulnerable DeFi v4 challenges relevant to your target protocol; reconstruct the value flow |
| 4 | Testing | Add unit, fuzz and stateful invariant tests to a small contract; inspect static-analysis findings |
| 5 | Findings | Read public reports on Solodit and past contest reports; optionally join a suitably scoped, currently available contest |
| 6 | Rehearsal | Explain three incidents from assumption to result; do a timed review; prepare examples from your own engineering work |
Sherlock, Cantina and CodeHawks are places to check for contests; CodeHawks' First Flights can offer a smaller exercise. Availability and rules change, so inspect the current program before committing time. Historical Code4rena reports can still be study material regardless of the platform's current status. For bounty work, including Immunefi programs, read scope and testing rules. A well-explained finding is useful evidence; getting paid isn't a prerequisite for having something worthwhile to discuss.
For experience questions, choose a bug, a severity disagreement or a design tradeoff that you are allowed to describe. Separate what you personally changed from the team's result. OfferVibe's My Experience can extract draft facts and interview notes from material you supply, with source references to check as you prepare. Use project notes you have permission to process. Text used for AI processing is sent to OpenAI; local storage uses OS encryption when available and can fall back to plaintext when it isn't. Explore OfferVibe →
FAQ
What are the most common Solidity interview questions?
A useful starting set is storage/memory/calldata, visibility, external calls, reentrancy, errors, gas, proxies and one exploit you can explain in detail. For more advanced roles, add the relevant DeFi mechanism, account abstraction and invariant testing. The job description and round format should set your priorities; this guide doesn't measure question frequency.
Are "top 100 Solidity interview questions" lists on GitHub enough?
They can reveal vocabulary gaps. Check their compiler and chain assumptions, then go beyond a definition: write a counterexample, trace an external call or test a boundary condition. A list you can recite may still leave you stuck when the interviewer changes one line.
What does a blockchain developer do?
They build smart contracts, the backends and indexers that read chain data, and the frontends users sign transactions with. Protocol engineers work on the node software itself.
Is blockchain developer a good career? Are blockchain developers in demand?
Decide using the work and openings you can actually assess: protocol design, security research, infrastructure or frontend development. Demand depends on location, funding and specialization; this guide has no hiring-market measurement. A shipped project, clear write-up or public finding demonstrates skills more concretely than a claim about the whole market.
How does web3 work?
Wallets manage keys and authorize actions. Nodes validate transactions and agree on state according to the chain protocol; contracts execute application rules. Many applications also depend on ordinary servers, interfaces and data providers. Include those dependencies when explaining what the user trusts.
What is the difference between a smart contract and a blockchain?
The blockchain is the shared ledger and the network that agrees on it. A smart contract is a program deployed on it, with its own code and storage.
Can a smart contract be changed after deployment?
Deployed runtime code generally is not edited in place. A proxy can retain its address and state while an authorized upgrade changes the implementation it delegates to. That makes upgrade authority part of the trust model. Inspect the actual deployment and fork rules before calling it immutable.
What is a "web3 task" in an interview?
A take-home: a small contract with Foundry tests, a short audit, or a dApp screen against a testnet contract. Tests and a clear README matter as much as the code.