DeFi risk guide
DeFi Liquidation Calculator: Calculate Health Factor, LTV and Liquidation Price
Use this DeFi liquidation calculator to estimate the health of a borrowing position, model your liquidation price and see how changes in collateral value can affect loan-to-value and safety margin.
DeFi liquidation calculator
Enter a simplified position below. The calculator estimates collateral value, LTV, health factor, liquidation price and the current price buffer. Actual protocol calculations may differ because of interest accrual, multiple assets, asset-specific parameters, price-oracle methodology, fees and liquidation mechanics.
Calculate a simplified DeFi borrowing position
This model assumes one collateral asset and a stable-value debt.
What is liquidation in DeFi?
Liquidation is a risk-control mechanism used in many decentralized lending markets. When the value of a borrower’s collateral falls too far relative to the value of their debt, the protocol can allow a third party to repay some or all of that debt in exchange for collateral. The purpose is to keep the lending market solvent and reduce the chance that liquidity providers are left with unbacked debt.
It is important to separate liquidation from a traditional late payment. In many DeFi systems, liquidation does not require a lender to manually approve an action or wait for an overdue invoice. It is driven by smart-contract rules, price data and account-level risk parameters. If a position crosses the relevant boundary, it may become eligible for liquidation.
For borrowers, liquidation is one of the most consequential risks of using volatile assets as collateral. A borrower can be correct about an asset over a long time horizon yet still lose collateral during a short, sharp drawdown if the position has too little buffer.
Short answer: liquidation can happen when risk-adjusted collateral is no longer sufficient to support outstanding debt under a protocol’s rules. The exact timing and outcome depend on the specific market, its oracle data and its liquidation design.
What is health factor in DeFi?
Health factor is a numerical measure of the safety of a DeFi borrowing position. It typically compares a portfolio’s risk-adjusted collateral value with the total borrowed value. While interfaces and formulas vary by protocol, the underlying idea is consistent: more collateral relative to debt produces a stronger health factor, while falling collateral or rising debt weakens it.
In a simple position with one collateral asset, a $30,000 collateral value, an 80% liquidation threshold and $12,000 of debt, the estimated health factor is 2.00:
In many DeFi lending models, a health factor above 1 means the position is above the liquidation boundary. At 1, risk-adjusted collateral approximately equals debt. Below 1, the position may be eligible for liquidation. This is a general model, not a substitute for the exact rules of a particular protocol.
How health factor changes
- Collateral prices fall, reducing the collateral numerator.
- Interest accrues or fees are added, increasing debt in the denominator.
- The price of a volatile borrowed asset rises, increasing the debt value.
- Collateral composition changes in a multi-asset position.
- A protocol changes market risk parameters through its governance or risk process.
| Health factor | General interpretation | What to consider |
|---|---|---|
| Above 2.00 | Larger modeled buffer | Still monitor collateral volatility, debt growth and market rules. |
| 1.50–2.00 | Moderate buffer | Stress-test likely drawdowns and keep an adjustment plan. |
| 1.10–1.50 | Limited buffer | Small price moves or accrued debt may materially affect risk. |
| Near 1.00 | At or near the boundary | Review the position urgently; liquidation eligibility may be close. |
| Below 1.00 | Potentially liquidatable | The protocol may permit liquidation under its relevant conditions. |
How LTV relates to liquidation threshold
Loan-to-value, or LTV, shows debt as a percentage of collateral value. It is simple to calculate and useful for comparing how aggressively a position is borrowed. Health factor incorporates the liquidation threshold and is often more directly connected to the protocol’s liquidation logic.
If your collateral is worth $30,000 and you borrowed $12,000, your LTV is 40%. If the collateral falls to $20,000 while debt is unchanged, LTV rises to 60%. The position’s health factor simultaneously falls from 2.00 to approximately 1.33 when using an 80% threshold.
Maximum LTV is not the liquidation threshold
A lending market can set a maximum LTV, sometimes called a borrow factor, and a separate liquidation threshold. The maximum LTV limits how much a user can initially borrow. The liquidation threshold is used to determine when a position can become liquidatable. A protocol may set the latter higher than the former, creating some separation between the opening limit and the liquidation boundary.
| Term | Purpose | Example |
|---|---|---|
| Collateral value | Current market value of supplied assets | 10 ETH × $3,000 = $30,000 |
| Maximum LTV | Initial borrowing ceiling | 75% maximum LTV |
| Current LTV | Debt relative to current collateral value | $12,000 ÷ $30,000 = 40% |
| Liquidation threshold | Risk parameter used in liquidation calculations | 80% |
| Health factor | Risk-adjusted collateral divided by debt | 2.00 |
How to calculate liquidation price in DeFi
For a single collateral asset and a stable-value debt, you can estimate the collateral price at the liquidation boundary with a simple formula. This approximation is useful for planning and comparing loan sizes, but real DeFi positions can be more complex.
Using 10 ETH as collateral, $12,000 of debt and an 80% threshold:
At $1,500 per ETH, the collateral is worth $15,000. After applying the 80% threshold, the risk-adjusted value is $12,000, equal to the debt. As debt grows through interest, the estimated liquidation price rises; as a borrower repays debt or supplies more collateral, it falls.
Why the displayed price can differ from your estimate
- Interest often accrues continuously or at frequent intervals.
- The collateral and borrowed assets can both be volatile.
- Multi-collateral accounts use weighted thresholds rather than one threshold.
- Price feeds can differ from a specific exchange’s spot price.
- Some protocols use special modes or isolated-market restrictions.
- Liquidation can be partial, and the debt/collateral balance can change during the process.
DeFi liquidation examples
The following examples use a simplified ETH-collateral, stablecoin-debt position. They do not include interest, fees or protocol-specific liquidation incentives, but they show how a fall in collateral price changes LTV and health factor.
Example 1: A 40% starting LTV position
Assume 10 ETH at $3,000 each, $30,000 collateral value, $12,000 debt and an 80% liquidation threshold. The starting LTV is 40%, the health factor is 2.00 and the estimated liquidation price is $1,500.
| ETH price | Collateral value | LTV | Health factor | Position status |
|---|---|---|---|---|
| $3,000 | $30,000 | 40% | 2.00 | Starting position |
| $2,700 | $27,000 | 44.44% | 1.80 | More risk, still above boundary |
| $2,400 | $24,000 | 50% | 1.60 | Buffer reduced |
| $2,100 | $21,000 | 57.14% | 1.40 | Risk increasing |
| $1,800 | $18,000 | 66.67% | 1.20 | Limited buffer |
| $1,500 | $15,000 | 80% | 1.00 | Estimated boundary |
Example 2: Same collateral, larger debt
Now keep the same $30,000 ETH collateral but borrow $18,000. Starting LTV becomes 60%, health factor becomes 1.33 and the estimated liquidation price rises to $2,250. A 25% decline from $3,000 to $2,250 now reaches the boundary.
This is the core leverage trade-off. More borrowing provides more liquidity, but it reduces the distance a volatile asset can fall before risk controls may activate.
Example 3: Interest reduces the buffer
In the first example, if $600 in interest and fees accrue, total debt rises from $12,000 to $12,600. With all other inputs unchanged, the estimated liquidation price rises from $1,500 to $1,575. The borrower needs no price decline for the position to become less healthy; debt growth alone does it.
How to reduce DeFi liquidation risk
No risk-management step guarantees safety, but borrowers can reduce the chance of being caught with an unhealthy position by creating a conservative plan before opening the loan.
- Use less than the maximum available borrowing capacity. The borrow limit is not a safety target; start with a buffer appropriate for the collateral’s volatility.
- Stress-test severe price moves. Model a 20%, 30%, 40% and larger decline rather than only a small correction.
- Monitor total debt, not only principal. Accrued interest and fees reduce health factor over time.
- Keep assets available for repayment. A partial repayment can improve LTV and health factor without requiring additional collateral.
- Know your collateral options. Before markets move, verify which assets can be added and how quickly funds can reach the correct chain and wallet.
- Set alerts and review the protocol directly. Alerts are useful but can fail or arrive late. During high volatility, inspect the live position and current protocol parameters.
- Understand the liquidation terms. Review close factor, liquidation bonus, fees and the protocol’s approach to partial versus full liquidation.
Operational risk matters: a plan to add collateral is only useful if the funds are liquid, supported by the protocol and accessible before the price reaches the liquidation boundary. Bridging delays, network congestion and wallet issues can turn a theoretical buffer into an unusable one.
DeFi liquidation risks and calculator limitations
A liquidation calculator is a decision-support tool, not a guarantee. It simplifies a dynamic risk system into a few inputs. Borrowers should understand its limitations and the broader risks of crypto-backed borrowing.
- Price volatility: crypto markets can gap or move faster than a borrower can react.
- Oracle risk: lending protocols rely on price feeds, which can have update rules, market coverage assumptions and failure modes.
- Smart-contract risk: lending contracts, dependencies and integrations can contain vulnerabilities or operational risks.
- Rate risk: variable borrowing costs can increase during high utilization or market stress.
- Stablecoin risk: a dollar-pegged debt asset can deviate from its intended value.
- Liquidity and execution risk: collateral liquidation can happen in poor market conditions, and borrowers may face slippage or delayed transactions.
- Governance risk: protocol parameters can be updated through governance, subject to the platform’s specific process.
- Multi-asset complexity: portfolios with several supplied and borrowed assets can be difficult to model with a single price calculation.
Risk data and capital-efficient DeFi lending
Collateral, LTV and liquidation thresholds are foundational risk controls in DeFi. They are transparent and programmable, but they also mean that users commonly need to supply more value than they borrow. That trade-off protects lending markets while limiting capital efficiency.
Risk data can add more context to a lending decision. On-chain credit, repayment behavior, fraud signals and reputation data can potentially help a protocol distinguish between different risk profiles rather than treating every wallet as identical. Such inputs do not eliminate the need for collateral, monitoring or robust liquidation design. They can support more granular eligibility rules, borrowing terms and risk management.
RociFi has explored on-chain credit scoring as a component of capital-efficient lending. Learn more through RociFi’s on-chain scoring resources.
Frequently asked questions
What health factor gets liquidated in DeFi?
In many DeFi lending systems, a health factor below 1 indicates that a position can be eligible for liquidation. The exact formula, thresholds and liquidation process depend on the protocol and market configuration, so check the relevant documentation and live interface.
How do I calculate my DeFi liquidation price?
For a simplified single-collateral position with stable-value debt, divide total debt by collateral amount multiplied by the liquidation threshold. Actual liquidation price can differ because of accrued interest, fees, multiple assets, price-oracle methodology and protocol-specific rules.
Can I avoid liquidation by adding collateral?
Adding eligible collateral can improve the collateral-to-debt ratio and health factor, provided the transaction completes before liquidation occurs. Repaying part of the debt can also reduce risk. Neither option is guaranteed to be available or timely during fast market moves.
Does paying back debt improve health factor?
Yes. Reducing total borrowed value typically raises health factor, assuming collateral and liquidation parameters remain unchanged. It also lowers current LTV.
What is the difference between LTV and liquidation threshold?
LTV describes debt relative to collateral value. A liquidation threshold is a protocol risk parameter used to determine when risk-adjusted collateral no longer supports the debt. Maximum LTV, current LTV and liquidation threshold are separate concepts.
Why did my health factor change if crypto prices barely moved?
Your debt may have accrued interest, the borrowed asset may have changed in value, other collateral or debt assets in your portfolio may have moved, or the protocol may use price-oracle values that differ from one exchange’s displayed spot price.
Is a higher health factor always better?
A higher health factor generally means a larger safety buffer under the protocol’s formula. However, it can also reflect that you borrowed less relative to collateral. The appropriate level depends on asset volatility, your risk tolerance, market conditions and ability to manage the position.
Can stablecoins be liquidated?
Yes. A position that uses stablecoins as collateral or debt can still face liquidation depending on the entire collateral/debt portfolio, the assets’ risk parameters and possible price deviations. Stablecoins can also depeg.
Is this calculator connected to a live DeFi protocol?
No. This is an educational calculator. It does not access wallet data, live prices, protocol parameters or transaction state, and it does not provide a liquidation guarantee or borrowing quote.