Hey, crypto OG! We've started to write more guides and decided to tell you about loans and deposits on dYdX. You should read the article and leave feedback. We make more such articles - you like these articles, ok? We think the formula is clear, but what about dYdX? Let's go!
dYdX is a decentralised trading platform that currently supports three functions:
In this article, we will explain how to make a deposit and borrow.
dYdX is a decentralised app, so all your assets are managed and stored on the blockchain using smart contracts; there are no intermediaries or third parties.
Lending on dYdX can be a relatively passive and low-risk way of making a profit. By depositing an asset in your dYdX account, you will immediately earn an interest in the profit without having to perform any action.
Interest on your deposited asset is paid by other users who borrow your assets. The dYdX platform ensures that any borrower always has enough collateral to repay the amount borrowed. If the collateral falls below a certain collateral threshold, its collateral is automatically sold until it fully covers the amount the borrower has borrowed. With dYdX loans, you have the option to withdraw your funds at any time. There is no lock-in period.
To become a lender in dYdX, you will need three components:
- A wallet (for example, metamask)
- ETH to pay for transactions
- Assets to put in collateral (ETH, DAI, USDC)
ETH is the native Ethereum blockchain token. DAI, USDC are stablecoins designed to maintain a stable price of around $1.
On dYdX, each asset has its interest rate, and these interest rates are dynamic. This means that as supply and demand for each asset change, so does the interest rate.
Buy tokens (ETH (to pay commissions) and USDC or DAI) on DEX, e.g. 1inch.
Go to dYdX and connect your wallet. (Blue button at the top right of the screen "Connect wallet").
Make a deposit. Click on the "Deposit" button on the bottom left of the screen.
When you finish the deposit process, you will soon see your dYdX balance update automatically. Boom! You automatically receive interest on your deposit! Remember that you can always deposit or withdraw at any time.
This part will look at how to borrow assets on dYdX and dive into two critical concepts that are integral to how dYdX works: shared loan pools and loan collateral.
On dYdX, both lenders and borrowers interact with single loan pools. There is a single pool for each supported asset managed by smart contracts. When you deposit an asset on dYdX, your asset goes into the appropriate pool where borrowers can borrow your asset. This model allows borrowers and lenders on dYdX to deposit and withdraw assets at any time.
As borrowers and lenders interact with the lending pools, the supply and demand for each asset change, which affects the utilisation rate (Collateral / Loan) of each asset. Interest rates on dYdX are floating and are based on these utilisation rates. You will notice that there are two rates for each asset on dYdX: the rate lenders receive for providing their assets (the 'supply rate') and the rate that borrowers pay for borrowing an asset (the 'borrow rate'). The borrowing rate will always be higher than the collateral rate. The interest received on the collateral will always be lower than the borrowing rate.
Collateralization is a concept you will come across frequently with dYdX. Your collateralisation ratio determines how much you can borrow and when your position will be liquidated.
As an example, let's assume:
We have: ETH = $100 and USDC = $1.
Suppose the user has deposited the following assets as collateral on dYdX: 2.5 ETH.
The user has also borrowed: 200 USDC.
For this user, we can calculate the collateral ratio as follows:
Collateral: 2.5 ETH * $100 = $250
Loan: 200 USDC * $1 = $200
So the security factor for this user is 250 / 200 = 1.25 or 125%.
On dYdX you can borrow assets until your collateral ratio reaches 1.25 or 125%. Once you get this ratio, dYdX will not allow you to borrow any more assets until you have accumulated collateral or paid off some of your debts.
Suppose a critical situation: the price of ETH has fallen to $90.
The user's collateral ratio is now as follows:
Collateral: 2.5 ETH * $90 = $225.
Loan: 200 USDC * $1 = $200
225 / 200 = 1.125 or 112.5%.
On dYdX, when the account falls below the "liquidation threshold", all existing loans in that account are considered too risky. The account will be "liquidated" to protect creditors: the collateral will be sold until all negative balances equal 0. On dYdX, the liquidation threshold is 1.15 or 115%, and in this case, the user's account has a collateral ratio of 112.5%, just below the liquidation threshold. This account will be liquidated, and the user will have to pay a 5% liquidation fee eventually containing these balances after liquidation:
Understanding collateral and how it affects your account is an integral part of risk management when borrowing and opening positions on dYdX.
Click on the "Borrow" button at the top of the site
Under 'Outstanding Borrows', you will see a list of all your current loans; any negative balance is considered a loan.
Under "Outstanding Borrows", you will notice an "Expiry" column. Direct borrowing on dYdX has no expiry date, so you are free to borrow the asset and return it at any time as long as your collateral remains above the liquidation threshold. However, if your balance becomes negative, this is no longer considered direct borrowing but trading. We will look at expiry and cross trading later. At this point, expiry should not be a problem if you are not trading.
Step 2 Borrow an asset
Click on the asset you want to borrow under "Borrow Assets" to borrow an asset. Be sure to pay attention to the two essential parameters for borrowing: Interest Rate (Interest Rate)/(APR) and Account Collateralisation.
"Account Collateralisation" represents the collateral ratio. Remember that dYdX will not allow you to borrow below a collateral ratio of 125%, and accounts with a ratio below 115% will be liquidated.
Always consider the price movement of the asset in the collateral and the asset you borrowed.
Above the section Account Collateralization, you will see the field labelled Deposit. This field allows you to deposit money into your dYdX balance at the same time as you make the loan and increase your margin so you can take out a bigger loan. In addition, if you enter a loan amount below 125%, the Deposit field will show the amount you need to complete your loan and keep your collateral level above 125%.
Then click on the "Borrow" button and confirm the transaction. You will see that your new loan is displayed under "Outstanding loans". You will also see the borrowed asset in your wallet and a corresponding negative balance under "Account balances", reflecting the amount borrowed on dYdX.