Glossary
Oct 2, 2026

What Is a Flash Loan? Uses, Risks and Attacks

A flash loan is an uncollateralised loan borrowed and repaid in one transaction. Learn how flash loans work, their legitimate uses and flash loan attacks.

What Is a Flash Loan? Uses, Risks and Attacks

A flash loan is an uncollateralised crypto loan that must be borrowed and repaid within a single blockchain transaction, or the whole transaction is reversed. Because repayment is enforced by code within one atomic step, the lender takes almost no credit risk, and anyone can borrow very large sums for a few seconds for a small fee.

Flash loan definition

Ordinary DeFi loans are overcollateralised: you lock up more value than you borrow. A flash loan needs no collateral at all. The trick is atomicity. A blockchain transaction either completes entirely or fails entirely, so a lending contract can hand over funds, let the borrower run any logic, and then check that the funds plus a fee have come back. If they have not, the transaction reverts as if the loan never happened.

Flash loans are offered by lending protocols and some DEXs. Aave's documentation states that its V3 flash loan fee was initialised at 0.05% and can be changed by governance (Aave docs, checked October 2026).

On Move-based chains such as Sui, flash loans typically use a "hot potato" pattern: the loan returns a receipt object that cannot be stored or dropped, so the transaction can only complete by passing it back to the repay function.

How a flash loan works

  1. Borrow. Your contract or transaction requests, say, 1,000,000 USDC from a protocol that offers flash loans.
  2. Use. Within the same transaction, you do whatever the strategy requires: swap across DEXs, repay a debt, swap collateral, or liquidate a position.
  3. Repay. Still in the same transaction, you return the principal plus the fee.
  4. Verify. The lender checks its balance. If repayment is short by even one unit, the entire transaction reverts, including every step in between. You lose only the network fee.

This composability, chaining several protocols together in one transaction, is what makes flash loans possible; our guide to DeFi composability and money legos explains the wider idea.

Flash loan example

A hypothetical arbitrage. Say USDC buys ETH at 3,000 on DEX A, and ETH sells for 3,015 on DEX B.

  • Flash-borrow 300,000 USDC at a 0.05% fee: fee = 150 USDC.
  • Buy about 100 ETH on DEX A (ignoring price impact for simplicity).
  • Sell 100 ETH on DEX B for about 301,500 USDC.
  • Repay 300,150 USDC. Profit: about 1,350 USDC, before swap fees, price impact and gas.

If price impact or a competing bot made the sale return only 300,100 USDC, the repayment check would fail and the whole transaction would revert. The borrower loses the gas fee but never owes anything.

Why flash loans matter

  • Useful tools. Flash loans let users refinance a loan, swap collateral or close a leveraged position without first finding the capital to do it. They also make arbitrage and liquidations open to anyone, not just well-funded traders.
  • Attack amplifiers. A flash loan attack is not a bug in flash loans themselves; it uses borrowed size to exploit a weakness elsewhere, such as an oracle that reads a manipulable pool price or a flaw in accounting. In March 2023, Euler Finance lost about $197 million in an exploit that began with a 30 million DAI flash loan from Aave; most funds were later returned (Chainalysis, checked October 2026).
  • A due-diligence lens. Ask whether a protocol would stay safe against an attacker with unlimited capital for one transaction. Robust oracles, audits and limits all help; see our checklist on how to check a DeFi protocol is safe.
  • Not a normal loan. Flash loans cannot fund anything that lasts beyond one transaction. For borrowing over days or months, collateralised or peer-to-peer lending is the relevant model.
  • Price oracle — the price feeds flash loan attacks most often target.
  • MEV — ordering profit that searchers often capture using flash loans.
  • Utilization rate — how much of a lending pool is borrowed, which limits flash loan size.
  • Rug pull — a different kind of DeFi loss, caused by insiders rather than attackers.
  • Leverage — flash loans are often used to open or unwind leveraged positions.

Learn more on the JewelSwap blog

Frequently asked questions

What is a flash loan attack?

A flash loan attack uses a large uncollateralised flash loan to exploit a weakness in another protocol, such as a manipulable price oracle or an accounting flaw, then repays the loan in the same transaction and keeps the profit.

Can anyone take a flash loan?

Technically yes, because no collateral or credit check is required. In practice you need to write or use a smart contract or programmable transaction that borrows, executes the strategy and repays in one atomic step.

Flash loan vs regular crypto loan: what is the difference?

A regular crypto loan is backed by collateral and lasts as long as you keep it open. A flash loan needs no collateral but must be repaid within the same transaction, so it can only be used for actions that complete instantly.

JewelSwap Crypto Glossary · educational, not financial advice. Updated 2 October 2026. Browse the full glossary.

About the author.

Co-Founder at JewelSwap & CMO at iDenfy. Viktor brings his successful track record of superb development & project management.