This tutorial explains the basics of using Freeliquid Borrow — a decentralized lending platform that offers loans in USDFL for liquidity providers (LP).
Freeliquid Borrow has been developed to make liquidity pools work as a security asset that its holders can get funding for. For example, only the USDT-USDC pair on Uniswap has over $24 million in liquidity — an asset with minimal volatility that, however, remains locked. Freeliquid Borrow fixes it and offers loans up to 90% in USD of the initial pool value without a risk of liquidation. Every liquidity provider can use Freeliquid Borrow simply by locking liquidity tokens and generating USDFL in Freeliquid Vaults.
Think of a Vault as a single deposit account that is managed by Freeliquid smart contracts. It is created in Freeliquid Borrow by locking liquidity tokens as collateral. Each Vault contains all the information regarding a particular loan, including the invested amount, the outstanding USDFL debt, and the history of transactions. Even if you close your loan completely, the Vault remains available to you for the future use.
Note that liquidity providers keep their passive income from the fees during their investment — the Freeliquid Protocol simply locks the liquidity tokens of its users, while not taking any profits from them. After the debt (or a part of the debt) is covered, users can withdraw their liquidity tokens and gain access to the liquidity pool, including the fees accrued.
How to open a Vault
The rest of the article will take you step-by-step through the process of creating a Vault, depositing liquidity tokens, and generating USDFL as a loan. For a short video tutorial, please visit the following link.
Go to freeliquid.io and click “Get Started” or directly open the Freeliquid Borrow app. Next, connect a crypto wallet, where your liquidity tokens are stored. You will be redirected to the Freeliquid web interface shown below.
If it is your first Vault on Freeliquid Borrow, click the “Get Started” button again. If you already have one or more Vaults and would like to create another one, click on the plus sign on the toolbar to the left of your screen.
Choosing the collateral type
Next, choose one of the supported collateral types from the list. Since the Freeliquid Protocol is now connected to your wallet, you can see your total balances in USD for each collateral type.
Each Vault consists of only one type of collateral and is completely independent from your other Vaults. As you can see on the screenshot, this tutorial refers to the first days of Freeliquid Borrow, when Stability Fees were initially set to zero. The parameters for each collateral type may change over time, so make sure you always check all the information before opening the Vault.
Setting up the Vault
In the next step, press “Setup” to create a proxy contract address for your future Vaults. Set the gas price and confirm the transaction in your wallet. This has to be done only once for every wallet address that you are planning to connect to Freeliquid. You would not need to perform the setup for any future Vaults on Freeliquid Borrow. Afterwards, set an allowance for the collateral type. Again, your wallet should ask you to confirm the transaction. This, in turn, has to be done only once for each collateral type.
Note that the gas fees for setting up the Vault may be substantial and you will not be able to return them back, even if you decide not to take any loans at Freeliquid Borrow.
Depositing LP tokens and generating USDFL
Now, you have to enter the amount of the collateral that you would like to lock as a security for your loan. The amount is typed in the USD equivalent, since Freeliquid automatically converts this sum to the respective number of liquidity provider (LP) tokens.
Next, decide on how many USDFL you would like to generate (i.e., to borrow). The maximal amount of issued USDFL is restricted by the minimal collateralization ratio for each collateral type, below which your Vault is susceptible to liquidation. Put simply, the more USDFL you borrow, the more risk you take, since your position gets closer to the liquidation threshold.
The liquidation mechanism is turned off for the stablecoin pairs, so it makes sense to generate the maximal amount of USDFL and decide on what to do with them later. If liquidity pools with non-stablecoin pairs are to be supported later at Freeliquid, always make sure your collateralization ratio allows for a substantial collateral price drop without your Vault being liquidated.
Creating the Vault
Up to this point, you have not locked any funds yet (except paying the gas fees for setting up the proxy address and the LP token allowance). You can go back and change the amounts, if needed. Make sure you check all the parameters of your Vault before opening it.
Finally, press “Open Vault” and confirm the transaction in your wallet to create the Vault. After the transaction is done, your Vault is opened and the USDFL are transferred to your personal wallet. You can now deposit USDFL into Freeliquid Save to receive a passive income or simply use funds however you like by exchanging USDFL for any other token on decentralized exchanges.
Managing the Vault
After your Vault has been created, you can access it from the Overview tab.
Users can always add more funding (i.e., liquidity tokens of the same type) to an existing Vault. This would allow them to borrow more USDFL, as well as increase the collateralization ratio and decrease the liquidation price. Similarly, it is always possible to withdraw liquidity tokens, provided the collateralization ratio is large enough. Users should be aware, however, that withdrawing a part of the collateral or generating more USDFL will inevitably increase the liquidation price.
To close the loan simply return your whole outstanding USDFL debt. You will then be able to retrieve all your LP tokens. As mentioned earlier, your Vault remains reserved for your wallet address, even if it is empty. To borrow USDFL again you would not need to go through the whole process one more time. Instead, you can simply deposit the collateral and generate USDFL again.
A note on the Ethereum network fees
As you might have noticed, setting up a Vault on Freeliquid Borrow and interacting with it later requires many transactions via the Ethereum blockchain. Some transactions involve a lot of data and may result in high gas fees. Setting up a Vault and borrowing USDFL can “cost” around $50 of gas fees in total or even more, depending on the current gas price.
Obviously, the Freeliquid Protocol has no influence on the Ethereum network fees. However, we urge our users to carefully estimate all the amounts that they enter while creating the Vault. By issuing the exact needed amount of USDFL and getting your collateralization ratio right, users avoid any further corrections, which would result in unnecessary transactions.
We also suggest to always check the gas price before creating a Vault, for example, through services like Etherscan or Eth Gas Station. Ethereum network fees fluctuate substantially over the course of the day. By picking a moment when the gas price is the lowest, users may easily save up to several times on Ethereum fees.
Generally, if you are ready to wait for 10–15 minutes or more, it should be fine to use the lowest recommended gas price, suggested by the services mentioned above or wallets such as Metamask. Going below this price, however, may result in your transaction getting stuck for hours.