DeFi Yield / APY Calculator
DeFi Yield / APY Calculator
APR→APY at any compounding frequency + gas-cost impact on net yield.
DeFi Yield / APY Calculator
Turn the rate a protocol quotes into what the deposit grows to over your hold, at the compounding that really happens. Gas is taken off the earnings, and the tool tells you how long the yield needs to pay it back. Add a price move to see the impermanent loss on a 50/50 liquidity pool.
An APY already includes its compounding, so the frequency you pick does not change the growth. It is used only to show the APR behind that APY.
Enter a price change above to see what it costs a 50/50 liquidity position against simply holding the two tokens.
The same APR at every compounding frequency
| Yield added | APY |
|---|
Assumes the rate stays where it is for the whole hold and the deposit keeps its USD value. Real DeFi rates move with supply and demand, and rewards are often paid in a token whose price can fall. Smart-contract failure, a stablecoin losing its peg and impermanent loss are not in the main projection.
How to Use the APY Calculator
Check which rate the protocol quotes
Look for the label beside the number. An APR leaves the compounding out; an APY already has it in. The same 8% means more as an APR compounded daily than as an APY, so pick the label the protocol uses, not the one you expect.
Pick the compounding that actually happens
A lending market or auto-compounding vault adds yield to your balance on its own. If you have to claim rewards and deposit them again, choose how often you will really do that. If rewards are paid out and left in your wallet, choose "Never": the deposit then earns simple interest.
Add up every gas fee
Entry, each claim or compound, and exit. Gas varies by network and by the hour, so take the figures from your wallet's own estimate rather than an average. The two break-even tiles show how many days of yield the gas costs and the deposit below which gas takes more than the yield over your hold.
For a liquidity pool, add a price move
Enter how far one token might move against the other. The tool applies Uniswap's impermanent-loss formula for a 50/50 pool and shows whether the yield would still leave you ahead of simply holding the two tokens.
DeFi Yields — Math, Risk, and the Reality Behind the Numbers
APR vs APY — A Common Confusion
APR is the nominal yearly rate; APY is what that rate grows a deposit by in a year once each credit starts earning too. At 10% APR compounded daily, APY = (1 + 0.10/365)^365 − 1 = 10.52%. At 100% APR compounded daily it is 171%. The gap grows with the rate and with how often yield is added. If the yield is paid out and never re-invested, there is no compounding at all and the APR is what you earn.
The same percentage shown two ways can mislead. "12% APR" compounded daily is a 12.75% APY, and compounded continuously it rounds to the same 12.75%: past daily, more frequent compounding adds almost nothing. For very high rates the gap is huge. A 1,000% APR compounded daily multiplies a deposit about 19,250 times in a year (continuously, e^10, about 22,000 times) — a figure that shows why such rates cannot last: they are paid in newly issued reward tokens, or they fall as soon as more money arrives.
Where DeFi Yields Come From
Yield has to be paid by someone. In a lending market it is interest from borrowers, passed to depositors less the protocol's cut, and it rises and falls with demand to borrow. In a liquidity pool it is a share of the trading fees the pool collects, which moves with trading volume. Many protocols add reward tokens on top to attract deposits; that part is worth only what the token sells for, and it shrinks as emissions fall or the token's price drops.
None of those rates is fixed. That is why this page quotes no protocol's current yield, and why the projection should be read as "if today's rate held for my whole hold". Check the rate on the protocol's own page on the day you deposit.
Impermanent Loss and Other Hidden Costs
A liquidity position in a 50/50 pool loses value against simply holding the two tokens whenever their prices move apart. Uniswap's documentation gives the size of that loss as 2√r ÷ (1 + r) − 1, where r is how far the price ratio has moved, and tabulates it: a 2× move costs 5.7%, a 3× move 13.4% and a 5× move 25.5%. It is the same for a move up or down (a halving is r = 0.5, the same 5.7%), and it disappears only if the prices return to where they started. Pools of two stablecoins move little against each other, so their loss stays small while both hold their peg. The formula is for Uniswap v2-style constant-product pools; concentrated-liquidity, weighted and stable-swap pools follow different curves. A yield display that shows reward APR alone leaves this out.
A 10% APR compounded daily is a 10.52% APY, and a 2× price split costs a pool 5.7%
APR leaves compounding out; APY puts it in. With yield added more than once a year, APY is higher; added once a year, they are equal.
At 10% APR compounded daily, APY = 10.52%. Continuous compounding adds only another 0.0015 points (e^0.10 − 1 = 10.517%).
An APY already contains its compounding. Over any period its growth is (1 + APY)^years, whatever frequency you pick.
Impermanent loss on a 50/50 constant-product pool: 2× price move 5.7%, 3× 13.4%, 5× 25.5% (Uniswap v2 documentation).
In the US, income from digital assets is taxable (IRS), and staking rewards are income when you gain control of them (Rev. Rul. 2023-14).
Frequently Asked Questions
- APR is the nominal annual rate; APY includes compounding. APY = (1 + APR/n)^n − 1, where n is how many times a year yield is added (e^APR − 1 when it is added continuously). At 10% APR compounded daily, APY = 10.52%. Protocols differ in which one they display, so read the label beside the number before you enter it.
- Because an APY already includes it: it is the growth over a year after compounding. Over any hold the deposit grows by (1 + APY)^years. The frequency is used only to show the APR that would produce that APY. The one exception is "Never": an APY paid out and not re-invested earns its one-year amount each year, without compounding.
- Only if the rate holds for the whole hold and the deposit keeps its USD value. DeFi rates change with demand to borrow, trading volume and reward emissions; rewards paid in a protocol token are worth what that token sells for when you sell it. The projection also leaves out smart-contract failure and a stablecoin losing its peg, either of which can cost more than a year of yield.
- When the two tokens in a 50/50 pool move apart in price, the position ends up worth less than holding the two tokens would have been. Uniswap's documentation gives the loss as 2√r ÷ (1 + r) − 1 for a price ratio r: 5.7% for a 2× move, 25.5% for 5×, and, from the same formula, 42.5% for 10×. It is "impermanent" because it disappears if the prices return to where they started. Enter a price move in the tool to see it beside your yield.
- When the gas is more than the yield over your hold. The tool shows both sides of that: "Days to earn back gas" is how long this deposit needs at this rate to cover the gas, and "Deposit where gas = yield" is the size below which the hold loses money. On the defaults — USD 10,000 at 8% APR daily and USD 50 of gas — gas is paid back in about 23 days, and a deposit under about USD 600 would lose money over a year. Every claim or compound you add costs gas again.
- In the US the IRS says income from digital assets is taxable and asks about digital-asset rewards on every federal return. For staking, Rev. Rul. 2023-14 says rewards are gross income at their fair market value when you gain dominion and control of them; a later sale is a separate gain or loss from that value. Other kinds of DeFi income, and other countries, have their own rules; this tool does not compute tax, so check with your tax authority (IRAS in Singapore) or an adviser.
Method & sources
How it computes
APY = (1 + APR/n)^n − 1, or e^APR − 1 when continuous. An APY already contains its compounding, so it grows as (1 + APY)^years at any frequency; yield that is not re-invested earns simple interest. Earnings after gas = deposit × growth − deposit − gas; break-even days and deposit invert the same growth. Impermanent loss = 2√r ÷ (1 + r) − 1 for a 50/50 constant-product pool (Uniswap v2). Computed in your browser.
What this tool implements
- APR to APY as (1 + r/n)^n − 1, or e^r − 1 when continuous — the same expressions as the site's shared effective-annual-rate and APY-to-APR conversions, which the test suite checks against at every frequency.
- An APY is the growth over a year after compounding, so a hold of t years grows by (1 + APY)^t whatever frequency is chosen; the frequency is used only to show the APR behind it. Fractional periods accrue at the same rate.
- Impermanent loss uses the formula and table in Uniswap's v2 documentation (2x 5.7%, 3x 13.4%, 5x 25.5%), which apply to 50/50 constant-product pools only; the page says concentrated-liquidity, weighted and stable-swap pools follow other curves.
- The projection assumes a constant rate and a deposit that keeps its USD value, and says so beside the result. The page quotes no protocol's current rate and no "typical" yield or gas figure.
- Corrected 2026-11-05: APY + continuous read the APY as an APR (8% → 8.33%); "1,000% APR daily-compounded is e^10 = 22,026×" (daily is about 19,254×; e^10 is continuous); "APY > APR for any rate > 0%" (equal at annual compounding); a pull-quote and fact giving a 15–30% loss probability and a 3–4× risk-free rule, and unsourced stablecoin yield, gas, aggregator-fee and TVL thresholds; unverified claims about which protocols display APR or APY; a non-US tax list.
Sources
- Uniswap Labs. Uniswap v2 documentation, "Understanding Returns" — impermanent_loss = 2 * sqrt(price_ratio) / (1+price_ratio) - 1, and its table of losses by price change: https://docs.uniswap.org/contracts/v2/concepts/advanced-topics/un…
- Internal Revenue Service. Digital assets — income from digital assets is taxable, and the digital-asset question on federal returns: https://www.irs.gov/filing/digital-assets
- Internal Revenue Service. Revenue Ruling 2023-14 (2023) — staking rewards are gross income when the taxpayer gains dominion and control: https://www.irs.gov/pub/irs-drop/rr-23-14.pdf
What can make this go out of date
- None at runtime: the reader enters the rate, its label, the compounding, the hold and the gas. Nothing typed leaves the page.