cryptocurrency calculators

Crypto Loan Liquidation Calculator

Determine the health factor of your crypto-backed loan and how close you are to automatic liquidation. Essential for DeFi borrowers managing collateral risk across protocols like Aave or Compound.

About this calculator

A crypto loan's health factor (HF) measures how safely your collateral covers your outstanding debt including accrued interest. The formula is: HF = (collateralValue × liquidationThreshold / 100) / (loanAmount × (1 + interestRate / 100 × timePeriod / 365)). When HF falls below 1.0, your position becomes eligible for liquidation by the protocol. The numerator represents the maximum debt your collateral can support before the protocol steps in; the denominator is your total debt — principal plus interest accrued over the loan period. A higher liquidation threshold (set by the protocol per asset) means the collateral is considered safer. Monitoring HF regularly is critical because collateral value fluctuates with crypto prices, and a rapid price drop can push HF below 1.0 in hours.

How to use

Example: You deposit $15,000 of ETH as collateral, borrow $8,000 USDC, the liquidation threshold is 80%, the annual interest rate is 5%, and the loan has been active for 90 days. Step 1 — numerator: $15,000 × 80 / 100 = $12,000. Step 2 — accrued debt: $8,000 × (1 + 0.05 × 90 / 365) = $8,000 × 1.01233 = $8,098.63. Step 3 — HF: $12,000 / $8,098.63 = 1.48. Your health factor is 1.48 — safely above 1.0, meaning you have a comfortable buffer before liquidation risk.

Frequently asked questions

What health factor should I maintain to avoid liquidation on a crypto loan?

Most DeFi protocols liquidate positions when the health factor drops to exactly 1.0. To protect yourself from sudden price swings, experienced borrowers aim to keep their HF above 1.5, and ideally above 2.0 for volatile collateral like altcoins. A buffer of at least 50% gives you time to add collateral or repay part of the loan if the market moves against you. Some protocols send alerts when HF approaches critical levels, so enabling notifications is strongly advised.

How does rising interest rate affect my liquidation risk over time?

Interest continuously increases the denominator of the health factor formula, gradually eroding your safety buffer even if collateral prices stay flat. For example, a 10% annual rate on a $10,000 loan adds roughly $27 in debt every month. Over a year this accumulates to $1,000 of extra debt, which can meaningfully reduce your HF. Borrowers on long-term positions should periodically repay interest or add collateral to prevent slow-burn liquidation risk.

What happens to my collateral when a crypto loan gets liquidated?

When your health factor drops below 1.0, liquidators — bots or users — repay part of your debt in exchange for your collateral at a discount, called the liquidation bonus (typically 5–15%). This means you lose more collateral than the debt value repaid, resulting in an immediate financial loss beyond simply closing the position. Any remaining collateral after the liquidation penalty is returned to you. To avoid this outcome, set price alerts and maintain a healthy buffer above the liquidation threshold at all times.