Health Factor
The health factor is a critical metric within the Aave Protocol that measures the safety of a borrow position. It is calculated as:
Health Factor = (Total Collateral Value * Weighted Average Liquidation Threshold) / Total Borrow Value
This metric indicates the stability of a borrow position, with a health factor below 1 signaling the risk of liquidation. The liquidation threshold, set by Aave Governance for each collateral asset, determines the maximum percentage of value that can be borrowed against it. For example, if you supply $10,000 in ETH with an 80% liquidation threshold and borrow $6,000 in GHO, your health factor would be 1.333.
Managing Health Factor
Maintaining a health factor above 1 is crucial to avoid liquidation. Regular monitoring of this metric is essential, as it fluctuates with the value of both collateral and borrowed assets. To improve your health factor, you can either supply more collateral or repay part of your borrow position. The health factor is sensitive to market changes—if your collateral's value increases, so does your health factor; conversely, if it decreases, your health factor drops, heightening the risk of liquidation.
There is no universally "safe" health factor, as this depends on the volatility and correlation of your assets. Generally, lower health factors may be acceptable for correlated assets, such as stablecoins or assets closely tied to ETH.
Tools for Managing Health Factor (Use at your own risk):
- Simulate health factor changes: DeFi Simulator
- Auto-repay borrow position: DeFi Saver
Liquidation Process
A liquidation in the Aave Protocol occurs when a borrower's health factor falls below 1, indicating that their collateral no longer sufficiently covers the borrowed amount. This situation can happen when the value of the collateral decreases or the borrowed amount increases, pushing the position past the liquidation threshold.
During a liquidation, up to 50% of the borrower's debt is repaid by the liquidator, with an equivalent value, plus a liquidation fee, taken from the borrower's collateral. Liquidations are permissionless, meaning any network participant can initiate the process when a borrow position is eligible for liquidation.
Liquidations within Aave are highly competitive, requiring a deep understanding of the protocol and technical proficiency. Liquidators must actively monitor borrow positions, quickly react to changes in oracle prices, collateral balances, and protocol parameters, and submit transactions with high priority in the attempt to be first to execute the liquidation.
Due to the competitive nature, successful liquidations often necessitate custom-coded bots or scripts that automate monitoring and execution. Developers interested in building liquidation bots or learning more about the process can find guidance and resources in the Aave Developer Documentation.