> ## Documentation Index
> Fetch the complete documentation index at: https://docs.theblockchainlibrary.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Lending

> Lending in DeFi refers to the practice of depositing cryptocurrency assets into a protocol so that others can borrow them, in exchange for earning interest. These decentralized lending protocols operate through smart contracts that automatically manage supply, demand, interest ra

# Lending

Lending in DeFi refers to the practice of depositing cryptocurrency assets into a protocol so that others can borrow them, in exchange for earning interest. These decentralized lending protocols operate through smart contracts that automatically manage supply, demand, interest rates, and loan security. By providing liquidity to these pools, users become lenders and can earn a yield on their idle capital, which is paid by borrowers who use the funds.

## Definition

Lending in DeFi refers to the practice of depositing cryptocurrency assets into a protocol so that others can borrow them, in exchange for earning interest. These decentralized lending protocols operate through smart contracts that automatically manage supply, demand, interest rates, and loan security. By providing liquidity to these pools, users become lenders and can earn a yield on their idle capital, which is paid by borrowers who use the funds.

## Simple explanation

Lending is like putting your money in a savings account, but better. You give your crypto to a protocol, and it automatically lends it out to people who need it. In return, you earn interest that is paid directly to your wallet.

## Why it matters

DeFi lending allows for a permissionless, global interest rate market. It provides a way for investors to earn passive income without relying on centralized banks or legacy financial institutions.

## How it works

Liquidity providers deposit assets into a smart contract vault. The protocol aggregates these deposits and lends them to borrowers based on established collateral rules. Interest rates are determined by algorithmic supply and demand, with the protocol distributing a share of the fees back to the lenders.

## Real-world example

Compound and Aave, where users earn yield by supplying stablecoins or volatile assets to the platform.

## Advantages

* Passive income generation
* Permissionless financial participation
* Transparent interest rates

## Limitations

* Smart contract exploit risk
* Market volatility impacts yield
* Potential for liquidity crunches

## Common misconceptions

* Many think lending is risk-free earning.
* People assume there is a middleman deciding who gets the loan.

## Related knowledge

* [Borrowing](https://docs.theblockchainlibrary.com/generated/v2/glossary/borrowing) — term
* [Collateral](https://docs.theblockchainlibrary.com/generated/v2/glossary/collateral) — term
* [DeFi](https://docs.theblockchainlibrary.com/categories/defi) — term
* [Liquidity](https://docs.theblockchainlibrary.com/generated/v2/glossary/liquidity) — term
* [Smart Contract](https://docs.theblockchainlibrary.com/generated/v2/glossary/smart-contract) — term
* [Yield Farming](https://docs.theblockchainlibrary.com/generated/v2/glossary/yield-farming) — term

***

**Canonical knowledge ID:** `glossary:lending`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.