2020 has been a phenomenal year for the crypto market. Decentralized Finance or DeFi was one of the biggest trends of the crypto realm. With over 25 billion USD locked in DeFi smart contracts at the time of writing, it has witnessed a growth of more than 3500% since the beginning of 2020. It has emerged as an extensive parallel financial system that provides its users banking, investing and trading services in a decentralized and trustless environment.
In the following article we will learn the rise and evolution of the DeFi ecosystem. This is the first in a series of articles to make DeFi simpler.
What is DeFi?
DeFi is an ecosystem of financial applications built on top of the blockchain. It provides a shift from the traditional financial system, which is managed by central authorities, arbitrators, and intermediaries. Instead of involving the banks, exchanges or brokers to provide the required trust among parties, DeFi heavily relies on cryptography, blockchain and smart contracts.
DeFi applications take a decentralized approach in either storing records or governance of the platform or its functionality. These are built as decentralized applications, dApps, where users can interact with each other in a peer-to-peer network. These dApps use a series of immutable smart contracts deployed on a blockchain to automate their functionality.
Popular DeFi projects provide alternatives to many traditional financial services, which include lending and borrowing of assets, decentralized exchanges, arbitrage trading, margin trading, creation of stable coins, derivatives and liquidity pools. It also facilitates many other innovative use-cases, which were not possible earlier like flash loans, synthetic assets and yield farming.
Because of their composability, Defi protocols are also referred to as “Money Legos”. To extend the functionality, these applications can be easily integrated with each other like legos. People are often mixing and matching various DeFi tools in interesting patterns to create new products and services. For instance, you can deposit ether into MakerDAO, receive the stablecoin dai (DAI) and then lend it on Compound to a trader in order to earn the network’s governance token COMP.
Why on Blockchain?
Any traditional financial service involves multiple parties and regulatory bodies. Users have no choice but to trust these financial institutions for safe handling of their funds. DeFi applications by leveraging blockchain technology provides decentralized governance to the community. With all things crypto, a minimum amount of trust is needed. Smart contracts provide transparency in open-source DeFi protocols.
There is no single point of failure as blockchain is a decentralized architecture. Removal of any 3rd party from the transactions, allows faster processing, efficient and affordable system. DeFi applications do not hold any user data. Users are custodians of their assets and have full control of their personal data.
With DeFi, the investment and trading has become more accessible to any user. All they need is a blockchain address and internet connection to plug in for any service. Most traditional finance systems are biased towards the rich with a purpose to generate more and more profit, so they discourage participation from others. DeFi on the other hand rules out any prerequisites of minimum investment allowing access to everyone.
Blockchain is a pseudo-anonymous system, which does not maintain any link between users’ on-chain and real-life identity. In lieu of the third party regulators to safeguard users interests, most DeFi applications are fueled by collaterals. Borrowers typically need to deposit collateral worth substantially more than the loan amount and maintain this collateral above a certain value threshold to protect the borrower. Failing this, the collateral will usually be sold to reimburse the lender if the collateral falls below a certain threshold, known as a loan-to-value (LTV) ratio.
Due to the open availability of blockchain, DeFi applications provide transparent data discovery facilitating easy analysis and decision-making process for users. Popular tools and dashboards for analysis of defi activities are DeFi Pulse and Codefi Data.
History and Evolution of DeFi
It all started with the Maker protocol in 2014. It is a decentralized organization dedicated to bring stability to the cryptocurrency economy. In 2017, MakerDAO created and launched a token called DAI on the Ethereum blockchain. It is a stable coin pegged to the US dollar by using certain incentives. MakerDAO allows users to lock ETH or any volatile cryptocurrency in collateral and generate DAI. It provides a peer-to-contract lending platform enabling over-collateralized loans. DAI can be freely sent to others, used as payments for goods and services, or held as long term savings. It is designed to offer a value-stable asset that does not suffer from the same volatility as other digital assets.
At times, despite a decrease in the market value of its collateral, DAI has maintained a close peg to $1. In addition to ether (ETH), MakerDAO allows collateral in Basic Attention Token (BAT), USD Coin (USDC), and has recently added support for Chainlink’s LINK, Loopring’s LRC and Compound’s COMP token. With a market cap of over 1.5 billion DAI in circulation, nearly 800 apps and services support DAI, including wallets, DeFi platforms, games and more.
Following the lead of MakerDAO, to provide stability in the crypto market other projects extended the DeFi space. One such protocol, Compound Finance, released in Sept 2018, has grown to be a sector-leading open lending protocol. It is an open marketplace for money that enables users to lend and borrow popular cryptocurrencies like Ether, Dai and Tether. It lets users deposit cryptocurrencies and earn interest, or borrow other crypto assets against them.
Liquidity pools are used in Compound to hold users assets. The smart contracts algorithmically adjusts the interest rates for supplying and borrowing, based on their supply and demand. At the time of writing, Compound has a total value of $3.14 billion locked as collateral in its smart contracts. Ether is the most popular token kept as collateral of over 2.4M ETH.
Another protocol based on Ethereum called dYdX was introduced in 2017. It is a decentralized margin trading platform. It allows crypto traders to lend, borrow and make bets on the future prices of popular cryptocurrencies. Margin trading is essentially borrowing money to make bigger bets. It creates leverage (upto 4X)–the more leverage used, the more the risk of gains or losses.
In dYdX, each asset has its own lending pool managed by smart contracts. Instead of individual borrowers and lenders making and accepting loan offers, everyone interacts in one global lending pool. Withdrawing, borrowing, and lending can happen at any time without needing to wait for matches or sufficient capital using any existing crypto holding as collateral. The demand and supply of each asset determines its interest rates. dYdX aggregates spot and lending liquidity across multiple exchanges. In Aug 2020, it introduced trading of ETH with increased leverage (up to 10x), while using ETH as collateral.
One of the most interesting concepts in DeFi, liquidity pool, was popularized by Uniswap, an ethereum based decentralized exchange. It facilitates exchange of tokens between token holders. Lenders gain commissions by contributing to the liquidity pools. Each time a user borrows funds from any pool, lenders earn interest based on their contribution and liquidity of the pool. It supports exchange of any ERC20 token to ETH; or ETH to any ERC20 token.
Uniswap v2, launched in May 2020, brought a range of upgrades and enhancements to the protocol. It allows any ERC20 to ERC20 token swaps without requiring ETH as an intermediary token. Flash swapping is another interesting feature that lets users borrow tokens from a Uniswap pool, make some arbitrary transaction with any external services, and pay back their originally borrowed funds, all in one transaction. At the time of writing, Uniswap holds a liquidity of about $3.3 billion in its liquidity pools.
Defi Applications on Ethereum and Other Blockchains
Ethereum blockchain deploys majority of the DeFi applications as smart contracts hosted on it. Its fairly robust programming language called Solidity allows for writing advanced smart contracts that can contain all the necessary logic for the defi applications.
According to DeFiPrime, of 216 listed DeFi projects, 204 of them are built on Ethereum. Other platforms include Binance Smart Chain, TRON, NEO and Matic. Most popular DeFi applications of 2020 are Synthetix, Badger.Finance, WBTC, Curve, dYdX, Compound and Aave.
Surely, DeFi has attracted a fair share of audience with its innovative and easy to use apps, but it has also been targeted by scammers listing fake tokens for sale and using names that suggest affiliations with high-profile DeFi apps.
In the next article of this series, we will talk about some other popular DeFi applications. We will also explore in detail the associated risks and attacks in the DeFi space.