~/defi/lending $ cat flash-loans-zaymy-na-sekundu.md
Flash loans: a million-dollar loan with no collateral for one transaction
A flash loan is a loan without collateral with one condition: repay within the same transaction. Fail to repay - the whole transaction reverts as if it never happened. This is only possible on a blockchain, where a transaction is atomic.
Mechanics
A constructor transaction: [borrow a million] → [do anything with it] → [repay the million + a fee]. If the final step does not add up, the EVM rolls back everything: the protocol risked nothing, which is why no collateral is needed. The fee is hundredths of a percent.
Peaceful uses
- Arbitrage: leveling prices between DEXes without holding capital - the flash loan democratized arbitrage.
- Refinancing: moving debt from protocol to protocol in one transaction without your own money for repayment.
- Liquidations: bots repay other people's debts with borrowed money and return the loan out of the bonus.
The dark side
The flash loan is an attack amplifier: any exploit that requires capital (oracle manipulation through a thin pool, skewing a governance vote, attacking an AMM curve) became available without capital. "Flash loan attack" in a headline means: the hole was in the protocol, the loan merely provided the lever. The instrument itself is neutral - it simply made capital free for 12 seconds, and protocol security is obliged to account for that.