DeFi

From Kyber to Uniswap via Bancor, when everything works onchain

Kyber, Uniswap and Bancor are three DeFi protocols on Ethereum which allow exchanging tokens onchain.

These are decentralized exchanges (DEX) that allow users to trade tokens with each other without having to use an intermediary, and without having to hand over their funds to a third-party custodian.

On defipulse.com, among the three DEXs, the one with the most locked funds is Uniswap, which is currently fifth in the overall ranking of all DeFi instruments with over 44 million dollars, while Bancor is ninth with just over 9 million dollars.

Bancor started operating in August 2017, although it didn’t really take off until September of the same year. Whereas Uniswap debuted in November 2018 and Kyber in February 2018. While Uniswap and Kyber have shown a slow but steady growth in locked assets, Bancor’s history has been more eventful, since it originated with an ICO in June 2017, during the ICO hype, reaching an all-time high of almost $60 million in locked assets in January 2018. But that happened in the middle of a speculative bubble, when ETH reached its historical high of over $1,400, compared to the current $200.

Since then, the value of locked assets on Bancor has dropped a lot, reaching a low in mid-December 2019, below $4 million.

Uniswap

Uniswap

Uniswap is an on-chain protocol on Ethereum that allows the decentralized exchange of tokens using liquidity pools instead of classic orders. With this protocol, anyone can quickly exchange ETH with any ERC20 token, but also earn commissions by providing liquidity.

Uniswap also allows anyone to create a market, i.e. a liquidity pool, by providing an equal value of ETH and any ERC20 token. Whoever creates these markets can set the exchange rate, which then varies according to the “constant product market maker” mechanism.

When trades reduce the liquidity of one of the two tokens of the pair relative to that of the other, the price changes in order to restore balance. This also generates opportunities for arbitrage between the different pairs, thereby encouraging trades. The main interface of Uniswap allows trading tokens, creating markets or managing a liquidity pool. It is also possible to view token balances, current exchange rates and shares within the liquidity pool. The protocol does not have its own native token, however, each trading pair is represented by a specific freely transferable ERC20 token.

A fee of 0.3% is charged on each transaction, which is collected by the liquidity providers in proportion to their share. At the same time, if large price fluctuations occur, these providers suffer a so-called “impermanent loss”, which is reduced when prices return to the levels at the time the liquidity was provided. With sufficient trading volumes, commissions can compensate for this loss. Being a decentralized platform, liquidity providers have full control over their funds and can, therefore, add or withdraw funds at any time.

Bancor

Bancor

Bancor is a protocol similar to Uniswap and was born more than a year before the latter.

Even Bancor is based on the Ethereum blockchain and is a non-custodial exchange that uses liquidity pools, without the order book. This allows users to bypass the need for an intermediary, i.e. a centralized third-party that collects, stores and manages orders.

Bancor’s protocol uses an algorithmic market-making mechanism that uses “Smart Tokens”, thanks to which liquidity and prices are guaranteed, maintaining a fixed ratio in relation to linked tokens (for example ETH) and adjusting its offer. It also has its own native tokenthe Bancor Network Token (BNT), which acts as a hub for Smart Tokens, thus connecting all other tokens within the Bancor network.

These Smart Tokens are ERC20 tokens featuring built-in logic that allows users to buy and sell them directly through smart contracts, at prices that adjust to match changes in the supply/demand ratio. They have a relatively complex built-in liquidity mechanism that ensures that they are convertible with other tokens.

This way the tokens function as fully automated and decentralized market makers. As of September 2018, the protocol also supports other blockchains, offering its services on EOS and POA Network.

Kyber

Kyber

Kyber is somewhat similar, with its Network being an on-chain liquidity protocol that allows token owners to contribute with the so-called reserves to the network’s liquidity. The particularity lies precisely in the use of the reserves, which are multiple smart contracts controlled by those who implement them. One of these reserves is that of Kyber Network.

Kyber doesn’t use the order book either, and when users decide to exchange tokens, the protocol automatically provides them with the best price for the token they are acquiring among all the reserves in the network. This protocol can be integrated into dApps, while vendors and wallets can also use Kyber Network to allow users and customers to exchange, pay, or receive tokens in a single transaction.

The interface of the protocol is KyberSwap, which uses the MetaMask wallet, and thanks to a collaboration with Coindirect also allows the purchase of ETH paying in fiat currency. ETH tokens are fundamental for using the platform.

KyberSwap allows the exchange of ETH with more than 70 other ERC-20 tokens, including DAI, USDC, TUSD, USDT, WBTC, MKR and others. A special feature of KyberSwap includes the non-custodial limit orders, which allow placing an order at a certain price, and waiting for it to be executed when that price is reached.

Kyber has a native token called KNC which reserve managers are required to use to pay fees. Although these DEXs operate primarily, or exclusively, with ERC-20 tokens, the fact that there are ERC-20 tokens like WBTC also allows them to operate with cryptocurrencies that do not operate on Ethereum.

Moreover, just as Bancor is doing, it is possible to imagine that cross-chain solutions will be introduced over time that will also allow decentralized trading using cryptocurrencies from other blockchains.

Website | Blog | Telegram | Twitter