Flash Loans · interactive mechanism simulation

Borrower requests a loan → pool disburses it with no collateral → borrower's callback uses it (arb / liquidation) on a DEX → funds return and repayment is checked before the transaction ends. If principal + fee isn't repaid, the atomicity gate reverts the entire transaction as if it never happened.
Borrower contract calls flashLoan() Flash loan pool fee reserve: 0.00 ETH DEX / target protocol arb, liquidation, or oracle read margin: 0.30% Atomicity gate principal + fee returned? External protocol governance / thin oracle drained: 0.00 ETH
Loans executed
0
Volume borrowed
0 ETH
Pool fee reserve
0.00 ETH
Reverted attempts
0
Drained by attack
0.00 ETH
Parameters — edit me
250 ETH
0.09%
0.30%
1.0/s
Controls

Illustrative simulation. Defaults mirror the researched flash-loan mechanism (Aave V1's ~0.09% fee, atomic borrow-use-repay-or-revert in one transaction), but loan sizes, arbitrage margins, and timing are randomized for visualization — not live onchain data. The "governance attack" button models the Beanstalk pattern (April 2022): the flash loan itself repays successfully and the transaction never reverts — the external protocol's own governance or oracle is what breaks. Drag the sliders to explore how margin vs. fee determines success or revert. Part of The Onchain Experiment Atlas.