Flash Loan Fee Calculator
Price the cost of borrowing uncollateralised capital for a single atomic transaction. Solve Fee = Loan Amount × Fee Rate for any of its three unknowns, then layer on repayment totals, break-even arbitrage spread, and provider-by-provider cost comparisons across Aave, dYdX, Balancer and Uniswap.
The fee is the strategy's break-even spread
Because a flash loan is repaid in the same transaction, the only way it can leave you worse off is if the arbitrage or liquidation you used the capital for did not produce enough gross profit to cover the fee. That makes R — not L — the single most important number for strategy viability. A 5 bps fee means your opportunity needs a gross spread above 0.05% to be worth executing; a 30 bps fee means you need 0.30%. The calculator's break-even panel expresses this directly: any opportunity that returns less than R in percentage terms will lose money no matter how large the loan is.
Size amplifies both profit and risk
The fee scales linearly with L, so a $1M loan at 5 bps costs $500, and a $100M loan at the same rate costs $50,000. This linearity cuts both ways: large loans let you capture proportionally larger arbitrage profits (since the price dislocation you are correcting has a fixed depth), but they also expose you to proportionally larger slippage on the trades that constitute your strategy. This is why the effective ceiling on flash loan size is set not by the protocol's credit limit but by market depth — there is no point borrowing $100M if the venue you are arbitraging can only absorb $10M before the spread disappears.
Most flash loans are actually free
Several major protocols charge no fee at all: dYdX, Balancer, Morpho Blue, Euler and MakerDAO's DAI flash mint are all zero-fee. Aave's 5 bps fee is the most widely-cited number, but it is not universal — and for many strategies the choice of provider is driven entirely by whether the asset you need is available on a free venue. The trade-off is that zero-fee protocols often have smaller liquidity pools or a narrower set of supported assets, so the "free" option may not have enough capital to execute your target size. This calculator lets you price both scenarios side by side.
The fee is the protocol's only compensation
Flash loans are uncollateralised — the borrower posts nothing and can lose nothing if the transaction reverts. The protocol's entire compensation for taking on this exposure is the fee, plus the gas cost of executing the loan-and-repay cycle. That is why zero-fee providers exist: for them, the value of the flash loan is the trading volume and any downstream activity it enables, not the direct fee revenue. For Aave and similar lending markets, the fee is a direct contributor to the protocol's treasury and is shared with the lenders who supply the underlying asset. Understanding who is being paid, and why, explains why the same asset can cost 0 bps on one venue and 30 bps on another.
How to Use This Calculator
The flash loan fee relation links three quantities: the loan amount, the fee rate, and the fee itself. Choose which one you want the tool to solve, then fill in the other two.
1. Choose what to solve for
Pick the fee, the loan amount, or the fee rate. The calculator rearranges F = L × R automatically for whichever variable you select.
2. Enter the loan amount
Use the full notional you intend to borrow, not your own capital. Flash loans are uncollateralised, so the loan amount is limited only by the protocol's available liquidity and the depth of the market you are trading into. Presets run from $10K to $1B.
3. Enter the fee rate
Check the lending protocol's documentation for the current flash loan fee on the asset you need. Presets cover the common values: 0 bps (dYdX, Balancer, Morpho), 5 bps (Aave V3), 9 bps (Aave V2), and 30–100 bps (Uniswap flash swaps at the pool's swap-fee tier).
4. Read the result and verdict
The result card shows the fee plus the total repayment amount, the fee in basis points, and the cost per $1,000 and per $1M borrowed. A colour-coded verdict classifies the cost from free through negligible, low, moderate, high and punitive.
5. Check the atomic lifecycle diagram
The diagram walks through the four-step atomic transaction: borrow → execute strategy → repay with fee → keep the profit. The step labels update live with your numbers, and the verdict strip reflects the overall cost class.
6. Switch to Advanced for depth
Advanced mode adds a fee-vs-rate chart, a sensitivity check on a +1% input change, and companion metrics including the break-even spread, the cost per $1,000, and the implied annualized rate if the same loan were rolled continuously.
What This Tool Offers
Built around the classic flash loan relation F = L × R — the arithmetic that decides whether a DeFi arbitrage is worth executing.
Three-way solving
Solve for the fee, the loan amount, or the fee rate. The calculator rearranges the formula for whichever variable you choose.
Provider-aware presets
Presets cover the real fee schedules from Aave V3, Aave V2, dYdX, Balancer, Morpho and Uniswap flash swaps — including the zero-fee venues that most tools overlook.
Cost-class verdict
Each result is classified from free through negligible, low, moderate, high and punitive based on the fee rate in basis points, with a coloured badge.
Atomic lifecycle schematic
A live diagram that walks through borrow → execute → repay → profit, with every label updating as you type — plus a verdict strip that flips between free and expensive.
Dual comparison charts
Fee vs. loan amount at three rate tiers, plus an advanced fee-vs-rate chart for three loan sizes.
Reference tables & provider grid
A fee-tier converter, a full loan × rate lookup grid, a table of real provider fee schedules, a break-even arbitrage panel, and a variable reference.
Reference Tables & Conversions
A fee-tier converter, an arbitrage break-even panel, a full lookup grid, and the fee schedules of every major flash loan provider.
Fee rate and basis point converter
Arbitrage break-even snapshot
Flash Loan Fee Lookup Grid
Computed from F = L × R. Rows are loan amounts, columns are fee rates. Values are the flash loan fee in USD.
Flash Loan Provider Fee Schedules
Current fee rates across major DeFi lending and AMM protocols. Verify against live documentation before executing, as rates and liquidity availability change.
| Provider | Fee rate | Assets available | Chains | Notes |
|---|---|---|---|---|
| dYdX | 0 bps | Major assets (ETH, WBTC, USDC, DAI, LINK, etc.) | Ethereum, StarkEx | Free flash loans; the standard for zero-fee borrowing |
| Balancer | 0 bps | Any asset in a Balancer pool | Ethereum, Polygon, Arbitrum, more | Free; uses "flash swap" pattern against pool reserves |
| Morpho Blue | 0 bps | Assets with active markets | Ethereum, Base | Free flash loans; newer protocol with growing liquidity |
| Euler V2 | 0 bps | Vault assets | Ethereum | Free; based on EVK vault framework |
| MakerDAO DAI Flash Mint | 0 bps | DAI only | Ethereum | Mints DAI on demand; limited to DAI |
| Aave V3 | 5 bps | All listed reserves | Ethereum, Polygon, Arbitrum, Optimism, Base, more | 0.05% fee; the most widely-used paid flash loan |
| Aave V2 | 9 bps | All listed reserves | Ethereum, Polygon | 0.09% fee; legacy version |
| Uniswap V2 flash swap | 30 bps | Any V2 pair asset | Ethereum, most EVM chains | Charged at the pool's 0.30% swap fee tier |
| Uniswap V3 flash loan | Pool fee tier (5 / 30 / 100 bps) | Any V3 pool asset | Ethereum, most EVM chains | Fee depends on the tier you borrow from |
| PancakeSwap V3 flash | Pool fee tier (1 / 5 / 25 / 100 bps) | Any V3 pool asset | BNB Chain, Ethereum | Cheapest tier is 1 bps |
| SushiSwap Kashi | 0.05% | Supported pairs | Multiple EVM chains | Legacy; liquidity varies |
| Radiant Capital | 0.05% | Major assets | Arbitrum, BNB Chain | Same tier as Aave V3 |
Variable Reference
| Symbol | Meaning | Formula | Units |
|---|---|---|---|
| F | Flash loan fee | L · R | USD |
| L | Loan amount (principal) | F ÷ R | USD |
| R | Fee rate | F ÷ L | % or bps |
| Repay | Total repayment | L + F = L · (1 + R) | USD |
| bps | Basis points | R · 100 | bps |
| BE | Break-even gross spread | R (same value in %) | % |
| Net | Arbitrage net profit | L · (spread − R) | USD |
What Does Fee = Loan Amount × Fee Rate Measure?
A flash loan is an uncollateralised loan that must be borrowed and repaid within a single atomic transaction. If the repayment does not complete — for any reason — the entire transaction reverts as if it had never happened, and the borrower walks away having lost only the gas. Because the protocol carries no credit risk, it charges a simple flat fee on the principal, expressed as a small percentage. This calculator computes that fee: the amount the borrower must return on top of the principal by the end of the same transaction, in order for the transaction to succeed.
The Flash Loan Fee Formula
The defining relationship is:
Rearranged to solve for the other two unknowns:
Fee Rate = Fee ÷ Loan Amount
And the derived quantities that describe the full cost of the loan:
Break-Even Spread = Fee Rate
Net Arbitrage Profit = Loan × (Gross Spread − Fee Rate)
Flash Loan Fee Variables
| Symbol | Meaning | Notes |
|---|---|---|
| F | Flash loan fee | The absolute amount added to the principal at repayment |
| L | Loan amount | Principal borrowed; the notional of the atomic transaction |
| R | Fee rate | Percentage of principal; 5 bps on Aave V3, 0 bps on dYdX and Balancer |
| Repay | Total repayment | Principal plus fee; must be returned in the same transaction |
| BE | Break-even spread | The minimum gross return the strategy must generate; numerically equal to R |
| bps | Basis points | 1 bps = 0.01%; the standard unit for flash loan fees |
How Each Variable Affects the Fee
The loan amount scales the fee linearly. A $1M loan at 5 bps costs $500; a $10M loan at the same rate costs $5,000; a $100M loan costs $50,000. This linearity is what makes flash loans attractive for large arbitrage operations — the fee stays proportional, so the economics of a strategy do not degrade as size increases, provided the underlying opportunity has enough depth to absorb the trade. It also means that for any given strategy, the optimal loan size is set by the venue's liquidity, not by the fee.
The fee rate is the parameter that varies most across providers, and it is where the strategic decisions live. Zero-fee providers like dYdX, Balancer, Morpho Blue and Euler exist alongside paid providers like Aave, and for many strategies the choice is obvious: if the asset you need is available on a zero-fee venue in sufficient size, use it. The catch is that zero-fee venues are often smaller and narrower in asset coverage, so the "free" option may not have enough liquidity for a large loan or may not support the specific asset your strategy requires. Aave's 5 bps fee buys broader asset coverage and deeper liquidity, which is often worth the modest cost.
The break-even spread is the number that turns the fee from an input into a decision rule. Because the fee is expressed as a fraction of the loan, the strategy must generate a gross return at least as large as that fraction to be profitable. A 5 bps fee means the arbitrage opportunity must be at least 0.05% deep — anything less and the trade loses money. A 30 bps fee (Uniswap V2 flash swap) requires a 0.30% opportunity, which is much harder to find in liquid markets. This is why zero-fee flash loans are so popular for tight-spread arbitrage: they turn otherwise unprofitable opportunities into viable ones.
Finally, it is worth being precise about what the fee is not. It is not interest — there is no time component, because the loan does not exist across time; it exists only within a single block. A flash loan that lasts the duration of a 12-second block on Ethereum pays the same fee as one that lasts a fraction of a second within that block. The fee is a flat transaction cost, not a rate per unit of time, which is why the annualized figures in the advanced panel are illustrative rather than representative — they describe what the cost would be if you rolled the same loan every block for a year, which is a useful upper bound but not a realistic scenario for most strategies.
Flash Loan Fee Calculation Examples
F = 1,000,000 × 0.05 ÷ 100 = $500
Total repayment = $1,000,500
F = 100,000,000 × 0 = $0
Total repayment = $100,000,000 — principal only
L = 250 × 100 ÷ 0.05 = $500,000
R = 1,000 × 100 ÷ 2,000,000 = 0.05% = 5 bps
F = 10,000,000 × 0.30 ÷ 100 = $30,000
Break-even spread required = 0.30% — much harder to find than 5 bps
Gross profit = 1,000,000 × 0.15 ÷ 100 = $1,500
Fee = $500
Net profit = $1,000 (before gas)
Gross profit = 1,000,000 × 0.03 ÷ 100 = $300
Fee = $500
Net profit = −$200 — the arbitrage loses money; the transaction should not be executed
Frequently Asked Questions
Because the loan and its repayment happen in a single atomic transaction. The borrower's smart contract calls the lending protocol's flashLoan function, receives the principal, executes whatever strategy it wants (arbitrage, liquidation, collateral swap), and then must transfer back the principal plus the fee before the function returns. If the repayment does not arrive, the entire transaction reverts — including the initial borrow — and every state change made during the transaction is undone. From the protocol's perspective, there is no window of exposure: either the money comes back within the same block, or the loan never happened at all. The only cost to a failed borrower is the gas spent on the reverted transaction, which is small relative to the loan. This is why flash loans can be extended without collateral, credit checks, or any assessment of the borrower's identity.
Different protocols have different business models. For a lending market like Aave, the flash loan fee is direct revenue: it accrues to the protocol treasury and is shared with the lenders who supplied the underlying asset, compensating them for the small operational risk of being part of a flash loan cycle. For a DEX or a protocol whose primary product is not lending — dYdX, Balancer, Morpho Blue, Euler — the flash loan is a value-added feature, not a revenue line. The protocol benefits from the extra transaction volume, from integrating with arbitrage bots that keep its prices efficient, and from being the venue of choice for sophisticated DeFi users. Offering flash loans for free costs them nothing (since the loan is atomic and carries no risk) and earns them goodwill and volume. The result is that the same asset can be borrowed for 0 bps on one venue and 5 bps on another, and the choice between them comes down to liquidity depth and asset coverage rather than cost.
The break-even spread is the minimum gross return your strategy must generate in order to cover the flash loan fee. It is numerically equal to the fee rate, because the fee is charged as a percentage of the loan. If the fee rate is 5 bps, your arbitrage must produce at least 0.05% gross return on the borrowed amount to break even; anything less is a loss. This makes the fee rate a direct gate on strategy viability: opportunities with spreads below 5 bps are only viable on zero-fee venues, and opportunities with spreads above 30 bps are rare enough that most flash loan strategies target the 5–15 bps range where Aave's 5 bps fee still leaves meaningful profit. The calculator's advanced panel shows this break-even explicitly, along with the net profit for any assumed gross spread, so you can quickly evaluate whether a specific opportunity is worth executing.
Technically, a flash loan can be as large as the protocol's available liquidity in the asset you want to borrow. Practically, the limiting factor is almost never the protocol — it is the depth of the market you are trading into. If you borrow $100M to arbitrage a DEX pool with only $20M of liquidity, your own trade will move the price against you, and the arbitrage will produce far less than expected. For most strategies the optimal loan size is the largest amount that can be traded without significantly moving the price on both legs of the trade — typically a few percent of the smaller pool's reserves. Zero-fee providers tend to have less liquidity than Aave, so a very large loan may only be possible on a paid venue, which changes the cost calculus. This calculator lets you price both scenarios side by side so you can see exactly how the trade-off plays out at your intended size.
The transaction reverts. This is the defining safety property of flash loans: because the repayment must complete within the same atomic transaction, any strategy that fails to produce enough to cover the principal plus fee simply does not execute. You cannot end up in a position where you owe money you do not have — the worst outcome is a reverted transaction that costs you the gas. In practice this means flash loan strategies are "riskless" in the sense that a bad trade cannot lose you the borrowed principal. The real risks are subtler: gas costs on a reverted attempt, MEV extraction by a searcher who front-runs your transaction, slippage that eats into the profit margin, and smart-contract risk in the protocol or in your own code. On a well-designed strategy these are small relative to the potential profit, which is why flash loans are such a popular tool for sophisticated DeFi operators.
Use the free provider whenever it works. If the asset you need is available on dYdX, Balancer, Morpho Blue, Euler or MakerDAO in sufficient size, there is no reason to pay 5 bps to Aave. The only reasons to choose Aave are: (1) the asset is not available on a free venue; (2) the free venue does not have enough liquidity for your target loan size; (3) your strategy requires a specific integration pattern that Aave's flashLoan interface supports more cleanly. For most common arbitrage on ETH, USDC, DAI, WBTC and other major assets, a free venue is the default, and Aave's 5 bps is the fallback when the free venues cannot accommodate the trade. The savings are meaningful at scale — on a $10M loan the difference between 0 and 5 bps is $5,000 per execution, which over hundreds of executions per year is a real number.
Because a Uniswap flash swap is not a flash loan in the lending sense — it is a swap that is settled at the end of the transaction instead of at the beginning. When you do a flash swap, you receive the output token first, use it for whatever you want, and then either pay back the input token plus the swap fee or return the output token. The fee you pay is the pool's normal swap fee (0.05%, 0.30% or 1.00% depending on the tier), not a separate flash-loan fee. In practice this makes flash swaps more expensive than true flash loans for most arbitrage, but they have a specific advantage: they let you borrow from a pool's reserves without needing a separate lending protocol, and they can be used atomically in complex swap paths where a standard flash loan would require multiple protocol integrations. For tight-spread arbitrage on liquid pairs, Aave at 5 bps or a free venue at 0 bps is almost always cheaper than Uniswap's 30 bps minimum on V2 or the 5 bps floor on V3's cheapest tier.
No — the fee is only the direct cost charged by the lending protocol. The full economic cost of a flash loan strategy includes several other components. Gas: executing a flash loan transaction on Ethereum mainnet costs anywhere from $10 to $500 depending on network congestion and the complexity of the strategy. Slippage: the difference between the expected price and the price you actually get on the trades that constitute your arbitrage, which can be much larger than the flash loan fee on illiquid venues. MEV: if your transaction is visible in the mempool, searchers may front-run it, capturing some or all of the profit before your transaction lands. Failed-attempt gas: even reverted transactions cost gas, and if you try several strategies that do not pan out, those costs accumulate. On a well-run strategy the total of these costs is usually dominated by gas and slippage, not the flash loan fee itself — but the fee is still the hard floor below which the strategy cannot be profitable, which is why getting it right matters.
Variables
| Symbol | Quantity | Unit |
|---|---|---|
| Fee | Flash loan fee | currency |
| Loan Amount | Amount borrowed via flash loan | currency |
| Fee Rate | Protocol's flash loan fee rate | % |
What it means
Flash loans are uncollateralised loans that must be repaid in the same block. They typically have a small fee (e.g., 0.09%). This formula calculates the fee. Flash loans are used for arbitrage, collateral swaps, and self‑liquidation. Understanding the fee structure is essential for using flash loans effectively. It is a key innovation in DeFi.
Worked example
Flash Loan Fee – Two Detailed Examples
Real‑World| Parameter | Value |
|---|---|
| Loan Amount | $1,000,000 |
| Fee Rate | 0.09% |
| Parameter | Value |
|---|---|
| Loan | $100,000 |
| Rate | 0.05% |
Common mistakes
- Flash loan fee: A small percentage fee charged on the loan amount.
- Loan amount: The principal borrowed.
- Fee rate: Usually a fraction of a percent (e.g., 0.09%).
- Must be repaid: Flash loans must be repaid within the same transaction.
Applications
Flash loan fee calculates the fee charged for a flash loan, typically a small percentage of the loan amount. This is a unique feature of DeFi, enabling uncollateralised borrowing for arbitrage and other strategies. Traders use it to calculate the net profit after fees. Understanding flash loan fees is essential for executing profitable flash loan strategies.
- Calculating the cost of flash loans for arbitrage
- Evaluating the profitability of flash loan strategies
- Comparing flash loan fees across protocols
- Optimising loan amounts to minimise fee impact
- Educational understanding of flash loan mechanics
Related calculators · DeFi & Yield Farming
Recently updated formulas
Suggest an improvement
Found a mistake? Have a better example? Let us know.
You may send up to 3 suggestions per 24 hours.