Learn how crypto lending works step by step: smart contracts, collateral, interest rates, oracles, and liquidation mechanics fully explained.
Arkadii Kaminskyi
Head of Operations at Sats Terminal
Head of Operations at Sats Terminal with 5 years of experience in crypto. Specializes in DeFi, yield farming, and borrowing — has reviewed 50+ crypto products.

The crypto lending market surpassed $30 billion in total value locked by early 2025, yet most people still cannot clearly explain how crypto lending works at a mechanical level. If you have ever wondered what actually happens between the moment someone deposits collateral and the moment a loan appears in their wallet, this article is for you. We are going to disassemble every gear in the machine: smart contracts, liquidity pools, oracles, interest rate curves, liquidation engines, and the differences between centralized and decentralized approaches. By the end, you will understand the full lifecycle of a crypto loan from first principles.
If you are brand new to the concept, you may want to start with our companion piece on what crypto lending is and why it matters before diving into the mechanics below.
At its core, crypto lending mirrors the logic of any secured loan: a borrower pledges an asset as collateral and receives funds in return, paying interest over time. The critical difference is who holds the collateral, how the terms are enforced, and where the capital comes from.
In a traditional bank loan, a single institution evaluates your creditworthiness, custodies any collateral, and decides when to call in the loan. In crypto lending, those responsibilities are distributed across code, liquidity providers, and price oracles. There is no credit check, no loan officer, and often no human involvement at all once the protocol parameters are set.
The high-level flow looks like this:
That is the skeleton. Now let us put flesh on the bones.
Lending protocols need liquidity before anyone can borrow. In DeFi, this liquidity comes from liquidity pools, which are on-chain smart contracts that hold deposited funds. Anyone with a compatible wallet can deposit assets such as USDC, USDT, ETH, or wBTC into these pools.
When you deposit into a pool on Aave, Compound, or a similar protocol, you receive a receipt token (aUSDC, cUSDC, etc.) that represents your share of the pool plus accrued interest. These receipt tokens are themselves ERC-20 tokens, meaning they are composable: you can transfer them, use them as collateral elsewhere, or simply hold them and watch your balance grow as borrowers pay interest.
In CeFi (centralized finance), the process is simpler on the surface. You transfer funds to a platform like Ledn, Nexo, or a brokerage, and the platform manages the pooling and lending behind the scenes. You earn a stated APY, but you do not hold a transparent receipt token; you trust the platform to manage the funds responsibly.
Not all deposited capital is lent out at any given time. The utilization rate measures the percentage of a pool's total deposits that are currently borrowed. If a USDC pool holds $100 million and $70 million is lent out, utilization is 70%. This number is critical because it directly governs interest rates, which we will cover in detail later.
Borrowing in crypto is almost always overcollateralized. Unlike an unsecured personal loan from a bank, you must lock up collateral worth more than the amount you want to borrow. This is because there is no credit score or legal recourse to recover funds if you default; the collateral is the only guarantee.
Suppose you hold 1 BTC and want to borrow USDC against it. On a DeFi protocol, you would send that BTC (or its wrapped equivalent, wBTC) to the protocol's smart contract. On a CeFi platform, you would transfer it to the platform's custody solution. In both cases, you retain ownership of the BTC, but it is locked and inaccessible until you repay the loan or until a liquidation event occurs.
The amount you can borrow is determined by the loan-to-value (LTV) ratio. If BTC is worth $90,000 and the protocol allows a maximum LTV of 75%, you can borrow up to $67,500 in stablecoins. Most experienced borrowers stay well below the maximum LTV to avoid liquidation risk. For a deeper look at the role collateral plays, see our article on crypto collateral lending.
In DeFi, loan disbursement is instant. The moment your collateral transaction is confirmed on-chain, you can withdraw the borrowed stablecoins to your wallet. There is no approval queue, no waiting period, no paperwork. The smart contract verifies that your collateral meets the LTV requirement and releases the funds atomically within the same transaction block.
In CeFi, disbursement times vary. Some platforms transfer stablecoins to your account within minutes; others may take one to two business days, especially for larger amounts or first-time borrowers that trigger compliance reviews.
Understanding how crypto lending works at a protocol level requires understanding smart contracts and liquidity pools.
A smart contract is a self-executing program deployed on a blockchain. Once deployed, its logic cannot be changed (unless the contract is upgradeable via a proxy pattern, which introduces its own trust assumptions). In lending, the smart contract enforces every rule: how much you can borrow, what interest rate you pay, when liquidation occurs, and how repayments are processed.
Think of it as an automated loan officer that follows its instructions perfectly, 24 hours a day, 7 days a week, without discretion or bias. The contract does exactly what its code says, which is both its greatest strength (predictability) and its greatest weakness (bugs in the code can be catastrophic).
A liquidity pool is simply a smart contract that holds token balances. When lenders deposit, the pool's balance increases. When borrowers draw loans, the pool's balance decreases. Interest payments flow back into the pool, growing the total value for lenders.
Major lending protocols maintain separate pools for each asset. Aave v3, for example, has distinct pools for USDC, USDT, DAI, WETH, wBTC, and dozens of other tokens. Each pool has its own interest rate model, its own utilization rate, and its own risk parameters. The protocol's governance (typically token holders) sets these parameters through on-chain votes.
This isolation means that a problem in one pool (say, a sudden liquidity drain in the USDT pool) does not necessarily affect borrowers in the USDC pool. It is a design choice that balances efficiency with risk compartmentalization.
Interest rates are arguably the most important variable in any lending market. In crypto lending, rates are determined very differently depending on whether you are using a DeFi protocol or a CeFi platform. For a comprehensive breakdown of current rate environments, check out our guide to crypto lending rates in 2025.
Most DeFi lending protocols use an algorithmic interest rate model tied to utilization. The basic idea: as more of a pool's capital is borrowed, the interest rate increases to incentivize new deposits and discourage additional borrowing. When utilization drops, rates fall to encourage borrowing.
A typical rate curve has two segments:
This mechanism is elegant because it requires no human intervention. Supply and demand for capital are balanced purely through price (the interest rate). The slope of each segment and the location of the kink point are governance-controlled parameters.
Fixed-rate lending in DeFi is less common but growing. Protocols like Notional Finance and Term Finance allow borrowers to lock in a rate for a set period. Under the hood, these protocols use fixed-maturity lending pools or zero-coupon bond mechanics. The trade-off is that fixed-rate loans are typically less liquid and may require borrowers to commit to specific maturity dates.
Centralized platforms set rates through internal pricing models that factor in their cost of capital, competitive positioning, regulatory overhead, and risk appetite. Rates may change weekly or monthly. Some platforms offer promotional rates to attract deposits. The lack of transparency is a frequent criticism: unlike a DeFi protocol where the rate curve is public and auditable, a CeFi platform can change rates at its discretion.
Oracles are the bridge between blockchain smart contracts and real-world data. In crypto lending, oracles serve one indispensable function: they tell the smart contract the current market price of every collateral asset and borrowed asset.
A lending protocol must know the dollar value of your collateral at all times to enforce LTV ratios and trigger liquidations. But blockchains are deterministic, isolated systems. They cannot natively query Coinbase, Binance, or any external API. Oracles solve this by aggregating price data from multiple sources and posting it on-chain in a tamper-resistant manner.
Chainlink, the dominant oracle provider in DeFi, operates a decentralized network of node operators. Each node independently fetches price data from premium data aggregators (covering exchanges worldwide), and the Chainlink protocol aggregates these individual reports into a single on-chain price feed. The result is a price that is resistant to manipulation by any single exchange or data source.
Other oracle solutions include Pyth Network (which specializes in low-latency price feeds pulled directly from market makers and exchanges), RedStone (which uses a pull-based model for gas efficiency), and Uniswap v3 TWAP oracles (which derive prices from on-chain trading activity).
Oracle failure is one of the most serious risks in DeFi lending. If an oracle reports an incorrect price, whether due to a bug, manipulation, or network congestion, the lending protocol may liquidate healthy positions or fail to liquidate underwater ones. This has happened historically: in 2023, a Chainlink oracle delay during extreme volatility caused brief mispricing on several protocols. Modern protocols mitigate this with circuit breakers, price deviation checks, and multi-oracle fallback systems.
Liquidation is the enforcement mechanism that keeps crypto lending solvent. Understanding it is essential to understanding how crypto lending works safely for all participants.
Every lending protocol defines a liquidation threshold for each collateral type. If you borrow USDC against BTC with a maximum LTV of 82.5% (a common Aave v3 parameter), your position becomes eligible for liquidation when the value of your collateral drops enough that your actual LTV reaches that threshold.
Example: You deposit 1 BTC at $90,000 and borrow $60,000 USDC (66.7% LTV). If BTC drops to approximately $72,700, your LTV reaches 82.5% and your position can be liquidated.
In DeFi, liquidation is performed by liquidators, which are independent agents (bots or MEV searchers) that monitor the blockchain for undercollateralized positions. When they find one, they repay a portion of the borrower's debt (typically up to 50% per transaction) and receive the equivalent value in collateral plus a liquidation bonus (usually 5-10%). This bonus is the profit incentive that motivates liquidators to keep the system healthy.
The liquidation bonus comes from the borrower's collateral. So if you are liquidated, you do not lose your entire collateral, but you do lose the bonus amount on top of the debt that was repaid. After partial liquidation, your remaining position has a healthier LTV, and you may continue borrowing if you choose.
CeFi platforms typically handle liquidation internally. They issue margin calls first: notifications warning you that your LTV is approaching the danger zone. You are usually given a window (often 24-72 hours) to add collateral or repay part of the loan. If you fail to act, the platform sells your collateral at market price. Some platforms offer more borrower-friendly terms than others, so comparing approaches is important. For a thorough understanding of collateral-backed Bitcoin loans and how liquidation varies across platforms, our guide on Bitcoin-backed loans is a useful reference.
Repayment is the final step in the lending lifecycle. It is straightforward in concept but has meaningful differences in execution between DeFi and CeFi.
On a DeFi protocol, you repay by sending the borrowed asset (plus accrued interest) back to the smart contract. Interest accrues continuously, block by block, so the exact amount owed increases with every passing second. Most protocol interfaces show a live-updating balance so you can see your total obligation in real time.
Once you repay in full, the smart contract releases your collateral immediately. There is no settlement delay, no confirmation email, no business-day restrictions. You can repay at 3 AM on a Sunday and have your collateral back within seconds.
Partial repayments are also supported. You can repay a portion of your loan at any time to reduce your outstanding balance and improve your LTV, lowering your liquidation risk without closing the position entirely.
CeFi repayment processes vary by platform. Some allow on-demand repayment via their app or website. Others have structured schedules, particularly for fixed-term loans. Early repayment penalties are uncommon in crypto lending but do exist on some platforms, so it is worth checking the terms.
The borrowed stablecoins or fiat currency are returned to the platform, and your collateral is released. Release times depend on the platform's operational processes and can range from instant to several business days.
We have touched on DeFi and CeFi differences throughout this article, but it is worth consolidating them because the mechanical differences are substantial. For a full side-by-side comparison, see our dedicated article on CeFi vs DeFi crypto lending.
Aggregator platforms like Borrow by Sats Terminal help bridge the gap by letting you compare rates and terms across multiple DeFi and CeFi lenders from a single interface, so you can see the mechanical differences in real time before committing to a loan.
Beyond basic borrowing, the programmable nature of DeFi enables advanced strategies that have no analog in traditional finance.
A flash loan allows you to borrow any amount from a lending pool without any collateral, as long as you repay the full amount within the same blockchain transaction. If the repayment fails, the entire transaction reverts as if it never happened. Flash loans are used for arbitrage, liquidations, collateral swaps, and debt refinancing. They are one of the most novel financial primitives enabled by blockchain technology.
Some users deposit collateral, borrow against it, deposit the borrowed funds as additional collateral, and borrow again. This recursive loop amplifies their exposure to the collateral asset. For example, looping ETH deposits can effectively create leveraged long exposure to ETH's price. The risk, of course, is that leverage amplifies losses just as much as gains, and a price drop can trigger cascading liquidations across the looped positions.
As multi-chain DeFi matures, protocols are beginning to offer cross-chain lending, where you deposit collateral on one blockchain and borrow on another. Aave's GHO stablecoin and cross-chain governance, along with protocols like Radiant Capital, are pushing in this direction. The mechanics rely on cross-chain messaging bridges and synchronized oracle feeds, adding complexity but also opening new capital efficiency possibilities.
Let us walk through a concrete example to tie everything together.
This example illustrates every component we have discussed: liquidity pools funded by lenders, smart contract custody, algorithmic interest rates, oracle price feeds, and instant repayment settlement.
Common Questions
Crypto lending replaces credit checks with overcollateralization. Because you must deposit collateral worth more than your loan, the protocol has a built-in guarantee. If you fail to repay, the protocol liquidates your collateral to recover the lender's funds. Your identity, credit history, and income are irrelevant because the math of the collateral ratio protects the system.