← All lessons

Learn · season 04 · episode 11

Aave: lending, borrowing and liquidation

Suppliers put tokens into a pool. Borrowers take tokens out and owe them back with interest. Collateral gives the protocol something to recover if a loan becomes undercollateralised.

A beginner lesson using Aave V3 mechanics. All numbers are fictional browser simulations. No wallet, live rates or real funds.

01 · follow the balances

The pool connects suppliers and borrowers

Aave is a lending protocol implemented in smart contracts. Each supported token has a reserve: supplied tokens are available for borrowing. A supplier earns interest through a supply claim; a borrower supplies eligible collateral and takes on debt.

Here, WETH means wrapped ETH. We hold USDC at $1. The supplier lends USDC; the borrower supplies WETH as collateral. These are two reserves, not a token swap. The borrower still has exposure to WETH’s price.

Illustrative · manual steps

Follow the tokens

Supplier

Wallet: $10,000.00 USDC

Supply claim: $0.00 USDC

USDC reserve

Available: $0.00

Loan outstanding: $0.00

Borrower

Wallet: $0.00 USDC + 2 WETH

Debt: $0.00 USDC

Separate WETH reserve · Borrower’s enabled collateral: 0 WETH. Collateral supports the debt; it is not the USDC being lent.

1 / 5 · Before supplying

A supplier holds 10,000 USDC. A separate borrower holds 2 WETH. The USDC reserve is empty.

This short sequence omits elapsed time and interest. Real debt accrues interest in the borrowed token. Withdrawal also needs available liquidity and sufficient remaining collateral if debt is outstanding.

Source: Aave V3 liquidity pool: supply, withdraw, borrow and repay.

After borrowing USDC against WETH, what does the borrower owe?

02 · two different limits

Borrowing capacity is not the liquidation boundary

Loan-to-value (LTV) limits new borrowing relative to collateral value. With $4,000 collateral and a fictional 70% LTV, the limit is $2,800. Liquidation threshold is a separate risk parameter: at 80%, the health-factor boundary is $3,200 of debt.

Health factor (HF) compares collateral adjusted by that threshold with total debt. For one collateral asset: HF = collateral value × liquidation threshold ÷ debt. With $4,000 collateral and $2,000 debt, HF is 1.6. A position becomes eligible for liquidation below 1.

Try reducing WETH to $1,000, then reduce the debt. A price fall reduces collateral value without reducing how many USDC are owed. Interest accrual also increases debt over time; the debt slider can represent that change. Nothing advances automatically.

Stress an existing loan

Illustrative · computed here

Fixed collateral: 2 WETH. Fictional LTV: 70%; liquidation threshold: 80%. Debt is USDC at $1. These controls describe a possible existing position, not permission to open a loan above LTV.

500 to 3500
0 to 4000
Filled bar: debt / collateral = 50.0%. First marker: 70% LTV. Second: 80% liquidation threshold.
Collateral value · 2 × price
$4,000.00
Borrow limit · collateral × 70%
$2,800.00
Liquidation boundary · collateral × 80%
$3,200.00 of debt
Health factor · boundary / debt
1.600

Within the example borrowing limit. HF above 1 is not a guarantee against future liquidation.

Keeping this debt unchanged, HF reaches 1 at $1,250.00 per WETH. Below that price the position is eligible for liquidation.

Additional borrowing capacity from LTV alone: $800.00. Actual borrowing also depends on liquidity, caps and other market rules.

In a liquidation, a liquidator repays debt and receives collateral plus a liquidation bonus. This lesson marks eligibility only; it does not simulate execution or assume a fixed percentage is always liquidated. With multiple collateral assets, health factor uses their value-weighted liquidation thresholds.

Sources: Aave reserve parameters and health factor and liquidations.

Collateral is $4,000 and debt is $3,000. With 70% LTV and 80% liquidation threshold, which is true?

03 · the price of borrowing

Variable rates respond to pool usage

Utilisation measures how much of a reserve is borrowed. Higher utilisation leaves fewer tokens available. A rate curve can increase borrowing cost more sharply above a target, encouraging repayment or more supply. This reserve-wide measure is separate from one borrower’s health factor.

When available liquidity gets scarce

Illustrative · computed here

A separate USDC reserve has 10,000 supplied. Move utilisation: the percentage currently borrowed. This toy curve has a 2% base borrow APR, rises to 6% at 80% utilisation, then rises more steeply to 66% at 100%.

0 to 100
Horizontal: utilisation, 0–100%. Vertical: annual rate, 0–70%. Solid line: borrow APR. Dashed line: supply APR. Vertical marker: 80% kink. The dots follow your input.
Borrowed from the reserve
$5,000.00
Available to withdraw or borrow
$5,000.00
Variable borrow APR
4.50%
Estimated supply APR
2.02%

Supply APR ≈ borrow APR × utilisation × 90%. Only borrowed funds pay interest; this example allocates 10% of borrower interest to the protocol reserve factor. At 0% utilisation, supply interest is zero even though the quoted borrow rate is 2%.

APR is an annualised rate before compounding, not a promised annual return. This snapshot omits incentives, fees, losses and changing rates. Real parameters vary by asset, market and protocol version.

Sources: interest-rate strategy and reserve factor and variable borrowing rates.

Why is supply APR lower than borrow APR in this example?

What this model leaves out

Real markets have changing prices, interest, liquidity and governance settings. Asset caps, collateral modes, oracle behaviour and liquidation rules add constraints. Smart-contract failures, token depegs and bad debt can affect suppliers too. This model teaches the relationships; it does not estimate a return or choose a borrowing level for you.