Aave explained
Tags: defi, crypto, aave
Published: 2022-12-11 14:53:22

Index
1. What is Aave
2. Traditional Bank money market vs Aave crypto market
3. Collaterals in Aave
4. Aave market, interest rates and supported chains
5. Risks involved
6. Step by step tutorial to Lend, Borrow and Repay money on Aave

## <u>**What is Aave**</u>
Aave is a decentralized finance (DeFi) platform that allows users to borrow and lend cryptocurrencies. It is built on the Ethereum blockchain and uses a protocol called "smart contracts" to facilitate lending and borrowing.

## <u>**Traditional Bank money market vs Aave crypto market**</u>

1) <u>Traditional Banks money market</u>
- Lender has cash or cash based assets which he lends to the bank, then the bank uses their reserves to lend the cash to borrowers.
- Borrower needs to pay high interests on their loans and also provide something as a collateral, for example their house. If for any reason the borrower fails to pay their loans, bank can take the house to suffice for the money they lent.
- Also another thing to notice is that lender get very less interest on their deposited assets in the bank.
- It is a centralized form of market

2) <u>Aave money market</u>
- Aave is decentralized, free, open for all and every asset is crypto based.
- Lenders can put their crypto based tokens in the equidity pool and can earn a transparent interest rate depending upon the demand and supply of the crypto they put in the market.
- While borrowers have to put crypto based collateral in the market to borrow the crypto based assets from aave.
- The borrowed money is always less than the collateral depending upon the given limit. for example you can borrow 80% of the ETH you put in aave as collateral, so if you put $10,000 worth of ETH, you can only borrow $8000 worth of value.
- The lender have no direct contact with borrower and their identity remain anonymous to each other, everything happens through a smart contract and automated process.

## <u>**Collaterals in Aave**</u>

![collatoral](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fst2r40lbrzp6nynk44t.png)

- **Over collateralization**: As you can see here, every token has its own LTV(Loat to value) percentage, this determines how much loan you can borrow respective to your deposited value cryptocurrency. This is called Over collateralization. It is done so that Lenders never loses their money.
- There are many strategies people use to leverage this technique and gain profits.

## **<u>Aave market and interest rates</u>**

![aave market](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9ifu7xvdu3avoqgdd48p.png)

- Here you can see Ethereum market, number of assets that are available, interest provided by each assets, total supply, total borrowed etc.
- This is a open market and interest rates are calculated based upon the supply and demand by the protocol.
- High utilization rates means very competitive interests.
- You can know more about the liquidity and returns of the token by opening it on the platform

![Dai](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dbhe9rb27iz5cvg30897.png)

- Aave is a multichain protocol and supports many chains that are compatible with EVM network.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hxq6omxsjvbca01ujgh9.png)

## <u>**Risks involved**</u>
1. <u>Smart contract risk</u>: Each markets/protocol depends on a smart contract which dictates supply and demand of the assets. If there is a vulnerability within the contract, hackers might be able to exploit it, which puts the assets at risk.
2. <u>Blockchain risk</u>: Smaller chains might be prone to get hacked, so choosing your chain wisely is the thing to prioritize.
3. <u>Liquidation risk</u>: If you borrow a lot of money and value of your assets falls, then you could be liquidated. 
4. <u>Asset risk</u>: Each assets have their own risks of loosing their value.
 
## **<u>Step by step tutorial to Lend and borrow money on Aave</u>**
1) Go to aave website and launch the app, you will land here [Aave app](https://app.aave.com/). Connect your wallet(I'm using Metamask here) with your desired chain. I have connected to Polygon market here.

2) Here you will see your available assets, choose an asset and click on supply button.
![available assets](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jwr1fx6cf94zd58vr8cw.png)
3) Select the value of token you want to deposit and then click on 'supply'. Confirm the Metamask transaction.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dicxhoynondgk1t8094a.png)

4) All done, you should be able to see your Net worth now. (which you can make $10B by chrome dev tools and give yourself momentarily happiness until the next browser refresh XD )

![Assets](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x3ur2l8nk1rpuyof3f5n.png)

5) To borrow assets, You can see 'Assets to borrow' on same screen down below. Select your desired token and click on borrow button.

![Borrow](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nvkzfh94ozzs4iim1kmt.png)

6) You should see this screen. From here you can select Variable or stable interest.

> Variable interest can increase and decrease depending upon the reserve in pool, while the stable interest will remain same.
Also you should consider checking your health factor.

> Your health factor and loan to value determine the assurance of your collateral. To avoid liquidations you can supply more collateral or repay borrow positions.

Click on 'Borrow', confirm metamask transaction and soon the amount will be credited into your metamask.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/limegtal3barg0gtrqk7.png)

7) You should now be able to see your borrows on the same page.

![Borrow](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/t7t8tdka0wa3uhzbcund.png)

8) When you're ready to repay the asset, click on repay. You can chose the amount to repay also the source you want to repay from i.e. Wallet or collateral. Then approve and Repay through metamask transaction. Now all your debts are gone. Good job!

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yj239ug1til2803j0fdn.png)

---
Wrapping up... there are many more topics left to cover in aave such as Flash loans (You have to pay as soon as you take the load i.e. within transaction time, it could be as small as 13 seconds) which could be covered in separate article.
Thanks for your time.
Cheers.