Loan-to-Value Explained in Detail
Loan-to-value, or LTV, controls borrowing power. If collateral is worth $100 and the LTV is 75%, the user can borrow up to $75 before other risk rules apply.
LTV is related to, but not always the same as, liquidation threshold or health factor.
Smart contract example
max borrow = collateral value * LTV
The result depends on oracle prices, token decimals, and risk parameters.
Loan-to-Value in Auditing
LTV is a core lending safety control. If the calculation is wrong or the price input is unsafe, users may borrow more than the protocol can recover.
Auditors check every path that changes collateral, debt, or risk configuration.
Red flags in code
-
LTV is confused with liquidation threshold.
-
Collateral can be enabled with unintended nonzero LTV.
-
Token or oracle decimals are scaled incorrectly.
-
Withdraw, transfer, or borrow paths skip solvency checks.
-
Governance can set unsafe LTV values without validation.
How to test or review it
-
Test just below, exactly at, and just above the borrow limit.
-
Fuzz collateral amounts, debt amounts, prices, and decimals.
-
Test multi-collateral portfolios.
-
Simulate oracle manipulation and stale prices.
-
Confirm collateral changes recheck borrowing capacity.
Keep learning this topic
Collateral Ratio
Collateral ratio is the ratio of collateral value to debt value in a lending, borrowing, or minting system.
Health Factor
A health factor is a lending-risk metric that compares a borrower's adjusted collateral value against their debt.
Liquidation
Liquidation is a protocol action that repays or closes an undercollateralized borrow position and transfers collateral according to the protocol's rules.
Practice this in real audit scenarios
Definitions help, but auditors need reps. SCH turns concepts like Loan-to-Value into exploit labs, code review habits, and report-writing practice.
Start the free trial or see the full smart contract auditing course.