beginner10 min

What Is DeFi? Decentralized Finance Explained

DeFi recreates banking services — trading, lending, earning yield — using smart contracts. No bank, no KYC, open to anyone with a wallet.

What Is DeFi? Decentralized Finance Explained

DeFi replaces banks with smart contracts — same services, no intermediaries, open to anyone.

TL;DR

  • DeFi = Decentralized Finance: banking services run by smart contracts, no middlemen
  • DEXs (like Uniswap) use liquidity pools and AMMs to enable trading without an order book
  • Lending protocols (like Aave) let you borrow against your crypto without selling it
  • Stablecoins (USDC, DAI) are the cash layer of DeFi — value pegged to the dollar
  • Main risks: smart contract bugs, impermanent loss, liquidation, composability risk

What Is DeFi?

DeFi = Decentralized Finance.

The idea: replicate every banking service using smart contracts. No intermediary, no permission required, open to anyone in the world with a wallet.

A traditional bank:

  • Takes your deposits, lends them to others, keeps the margin
  • Charges fees on everything
  • Decides who gets access to its services

DeFi does the same thing, but the rules are public smart contracts, the margins go to users, and anyone with a wallet can participate — no KYC, no borders.

KYC (Know Your Customer): the identity verification process required on centralized platforms — ID, selfie, proof of address. Mandatory on Binance or Coinbase. On a DEX, you connect your wallet and you're in. DeFi is permissionless — the smart contract doesn't know who you are, it just executes the rules.


DEXs — Trading Without an Intermediary

A CEX (Centralized Exchange) like Binance uses an order book — a list of buy and sell orders matched by the platform between human counterparties.

A DEX (Decentralized Exchange) like Uniswap uses no order book. Instead, an AMM (Automated Market Maker) — a smart contract holding a liquidity pool.

A liquidity pool is a smart contract containing a pair of tokens — for example ETH and USDC. When you want to buy ETH, you buy it directly from the pool. The price adjusts automatically via a mathematical formula based on the available reserves. The more ETH you buy, the less remains in the pool, and the higher its price. No human needed.

A swap is the exchange of one token for another on a DEX.

Liquidity Providers (LPs)

LPs deposit tokens into a pool. In return, they earn a share of the trading fees generated by each swap — typically 0.3% on Uniswap.

Note: trading fees are not gas fees. Gas fees are paid to the network for every transaction — they are separate.

Impermanent Loss

When you're an LP and the price of the tokens diverges, you recover a different ratio than what you deposited. Here's why:

When ETH rises in price, traders buy ETH from your pool at a discount compared to the market. They add USDC and take out ETH. The pool mechanically loses ETH and accumulates USDC. Your share follows.

Example:

  • You deposit: 1 ETH + 2,000 USDC (ETH = $2,000)
  • ETH rises to $4,000
  • You recover: 0.7 ETH + 2,800 USDC

In dollar value, you're up — but if you had simply held: 1 × $4,000 = $4,000 vs 0.7 × $4,000 + $2,800 = $5,600. You're $400 worse off compared to just holding.

Impermanent loss is a relative loss versus not doing anything. Not an absolute loss.


Lending — Aave and Others

Aave is the leading decentralized lending protocol. Others include Morpho, Compound, and Spark.

How It Works

You have 1 ETH worth $2,000. You need cash but don't want to sell because you expect the price to rise.

You go to Aave and deposit your ETH:

  1. Aave locks your ETH and gives you aETH — a receipt token proving your deposit
  2. You can borrow up to ~80% of your collateral value (LTV = Loan-to-Value)
  3. You choose to borrow 1,000 USDC (50% to keep a safety margin)

Your wallet after: aETH + 1,000 USDC

The aETH is just a receipt — like a coat check ticket. Your ETH is locked there, you hold the claim. When you want it back: return the aETH → Aave releases your ETH + interest.

You deploy the borrowed USDC. ETH rises to $4,000. You repay the 1,000 USDC + interest, return the aETH → Aave gives back your ETH. You captured the upside without selling.

This is leverage — same mechanics as a mortgage, but instant, without a bank, with crypto as collateral.

APY (Annual Percentage Yield): the annualized return rate. Example: deposit 10,000 USDC at 5% APY → 10,500 USDC after one year.

Liquidation

If ETH drops too far and your collateral approaches the value of your debt, Aave automatically sells your ETH to repay itself. It's mechanical and instant. This is the primary risk of lending.

The closer you borrow to the maximum LTV (80%), the less margin you have. Borrowing at 50% gives you a much larger safety buffer before liquidation.


Stablecoins — DeFi's Cash Layer

A stablecoin is a token whose value is pegged to a stable asset — usually the dollar. 1 USDC = $1.

You have ETH, the market is uncertain. You swap part of it into USDC. That portion stops fluctuating. With those USDC, you can deposit on Aave to earn yield (~5% APY), use them as collateral, or wait for an opportunity to buy back at a lower price.

Without stablecoins, every time you want to "go safe," you'd need to fully exit crypto to a bank account. Stablecoins let you stay in the ecosystem while removing volatility exposure.

Three Types

🏦 Dollar-backed (centralized) — USDC, USDT One real dollar in a bank account for each token. Simple and reliable, but centralized — the issuer can freeze your address.

🔐 Crypto-collateralized (decentralized) — DAI No central issuer. Maintained via ETH/USDC collateral locked in smart contracts. More robust.

⚡ Algorithmic — UST (Terra) No real collateral. UST collapsed in 72 hours in 2022 — $40 billion wiped out. Avoid entirely.


DeFi-Specific Risks

🐛 Smart Contract Bugs

The code can have vulnerabilities. Billions have been stolen through exploits, even on audited protocols. Example: Euler Finance (2023) → $197M drained.

💸 Impermanent Loss

Covered above — a risk specific to liquidity providers.

📉 Liquidation

If your collateral value drops below the liquidation threshold, your position is automatically closed.

🔗 Composability Risk

When you deposit USDC on Aave, you receive aUSDC. You can deposit those aUSDC into a second protocol, which interacts with a third. Each added layer increases risk. If Aave has a bug, every protocol depending on your aUSDC is affected.

TVL (Total Value Locked): the total assets deposited in a protocol. The primary indicator of size and credibility. Older protocols with high TVL are generally safer — but nothing is risk-free in DeFi.