Loopring is a layer-2 technology that allows for faster and cheaper transactions on Ethereum. It supports the Loopring Decentralised Exchange (DEX) and the native LRC token. This guide will teach you how to move funds onto Loopring, use the DEX as well as earn money by providing liquidity.
Disclaimer: This information should not be interpreted as an endorsement of cryptocurrency or any specific
provider, service or offering. It is not a recommendation to trade.
What is Loopring?
The number of investors utilising decentralised finance (DeFi) protocols has exponentially increased over the last few years. Many DeFi protocols are built on the Ethereum blockchain and utilise the Ethereum network for transactions.
While promoting the decentralisation of traditional financial services, the increasing number of users has led to problems of congestion on the Ethereum network, which has resulted in higher transaction (gas) fees. To tackle this scaling problem, layer-2 (L2) solutions were developed.
A layer-2 solution is a secondary blockchain that lies on top of the underlying blockchain and completes the majority of the work. The L2 processes the transactions of the protocol before posting them to the Ethereum blockchain. This provides the same level of security as the Ethereum blockchain and means the network can handle a much larger volume of transactions, often referred to as throughput.
Loopring is a layer-2 scaling provider. Established in 2017, it allows for the production of highly scalable decentralised exchanges (DEXs), centralised exchanges (CEXs) and payment applications without a trade-off in security. The Loopring protocol achieves this by using zkRollup technology. Throughput on a Loopring application can reach 1,000x that of Ethereum, with transactions that are 1/100th the cost.
Any exchange can integrate with the Loopring network and take advantage of the scaling capabilities and potentially increased liquidity. This includes exchanges that are already established.
From the development of the Loopring protocol, the Loopring Exchange was born.
What is the Loopring Exchange?
The Loopring Exchange is a decentralised exchange (DEX) that utilises the Ethereum blockchain. However, unlike other DEXs, the Loopring Exchange is built on the layer-2 Loopring zkRollup protocol.
The exchange was born out of the layer-2 scaling solution and was the first DEX to be launched on the system in February 2020. Allowing users to trade via an automated market maker (AMM) and order book trading system, the layer-2 exchange provides extremely low gas fees and increased speed without a trade-off in security. Thanks to the application of zkRollup protocols, users can enjoy low fees while maintaining custody of their digital assets at all times.
Loopring's order book exchange utilises an innovative order ring system. An order ring occurs when multiple orders from different token pairings are linked together (ring-matched). Ring matching allows all desired exchange rates to be matched or even bettered. The system aims to greatly improve liquidity in comparison to only matching orders from the same token pairing. Ring matching is completed by relayers.
Relayers, sometimes referred to as "ring miners", match orders in the background of the system, maintain the trade history and broadcast new orders. Relayers are rewarded for their efforts with the native LRC token.
While focusing primarily on exchanges, the Loopring Exchange also doubles as a payment application, allowing users to cheaply and securely transfer ERC-20 tokens or ETH to any Ethereum address via the layer-2 network.
Zero-Knowledge (zk) Rollups
Zero-Knowledge Rollups, or zkRollups, are integral to the Loopring protocol and are the foundation of the layer-2 scaling solution. zkRollups bundle multiple transactions together and store them in an off-chain database. Each zkRollup can be thought of as a block on the Loopring protocol.
zkRollups efficiency comes from an ability to demonstrate transactions without revealing what the transactions exactly were. This is completed using validity proofs that attest to what happened off-chain (off the Ethereum blockchain). The Ethereum blockchain verifies the proofs and allows the transactions to occur. As much work as possible is completed off-chain with only verification completed on-chain.
zkRollups allow for the same non-custodial transfer of assets, meaning users remain in control of their private keys but can complete transactions much faster compared with the Ethereum blockchain. 4,000 transactions can be added to a single rollup or "block", which is then processed as a single transaction on Ethereum.
Merkle trees allow decentralised blockchains to share data and verify it, a process required by layer-2 scaling solution like Loopring.
On Loopring, Merkle trees are a snapshot of a user's account, token balance and transaction history. This is stored on-chain (on the Ethereum blockchain). Loopring Merkle trees allow transactions completed off-chain (on the Loopring network) to be verified on-chain. Data within Merkle trees are organised in a power-efficient manner, meaning less processing power is required for verification on Ethereum.
The use of Merkle trees means that if the Loopring Exchange disappears, or goes rogue, a user can still gain access to deposited funds. The last Merkle tree snapshot can be used in conjunction with the Ethereum blockchain as proof to recover funds if anything on the DEX goes wrong.
How to trade on Loopring
Before trading on the Loopring Exchange, you must onboard the layer-2 network. Onboarding to layer-2 requires a web 3.0 digital wallet such as MetaMask. MetaMask is an online Ethereum digital wallet that acts as a bridge between your cryptocurrency assets and decentralised applications and comes in the form of a browser extension.
Onboarding to layer-2
Although gas fees are almost non-existent on layer-2 systems, depositing digital assets from outside a layer-2 network does require a gas fee. However, the gas fees are standard and comparable to a simple token transfer on an exchange like Uniswap. Once this initial gas fee for your deposit is paid, your digital assets will then be within the gas-free layer-2 network until you wish to withdraw.
- Activate layer-2. Once your wallet is connected, you will be prompted to "Deposit to Active Layer-2".
- Asset. Select a cryptocurrency to deposit and enter the amount.
- Confirm. Check the transaction details and confirm the deposit in your web 3.0 digital wallet to execute.
- Multiple confirmations. There will be a further set of confirmations that are required before completion and access to the Loopring Exchange is granted.
- Unlock. An "Unlock" button should appear on the next screen. Click "Unlock" to provide a signature from your digital wallet. The Unlock button can be thought of as a "Log On" function for your layer-2 account and will be required every time you access it. No gas fees are required at this stage, it is just a digital signature required for access.
Once you have funds deposited into your Loopring layer-2 wallet, you are ready to begin exchanging.
The digital assets you deposit in the layer-2 network are mapped to the Loopring Merkle tree. This means that the assets can be recovered if anything were to happen to the Loopring Exchange.
How to exchange on Loopring using an AMM
The Loopring Exchange supports both AMMs and order book exchanges. Here we'll go through the steps of swapping cryptocurrencies via the AMM.
- Swap. Click on the "Swap" tab at the top of the website.
- Choose. Select a pool that you wish to trade in. The liquidity pool represents two cryptocurrency assets that traders can use to trade with.
- Enter amount. Enter the amount you would like to exchange. The AMM will display the current exchange rate for the token pair, including the minimum amount you will receive from the swap.
- Adjust parameters. Evaluate the parameters of the exchange such as slippage tolerance.
- Swap. Click "Swap" and the transaction will be executed instantly and with no gas fee.
Once the exchange is completed, the balance will be updated in your layer-2 wallet. Exchange history can be evaluated in the "Orders" tab.
Trading on Loopring using the order book
The Loopring Exchange also provides users with the option of trading via a traditional order book, similar to a centralised exchange.
- Trade. On the "Trade" tab, search for a pair you wish to trade with. Select buy or sell and enter the price at which you wish to make the trade. Subsequently, enter the amount you would like to trade.
- Confirm. Check and confirm the details and click either "Buy now" or "Sell now" depending on the transaction.
- Open order. Open orders will be shown in the open orders tab. Open orders can be cancelled by clicking "Cancel".
The advantage of the order book exchange is that a user can place limit orders. Limit orders are created when a user defines a price that they wish to buy or sell at. The order remains open on the order book until another trader comes along to complete it.
The order book exchange offers market makers a 0.02% rebate. Makers are those that leave open orders on the exchange which provides liquidity. When that order is filled by another trader, the maker receives 0.02% of the traded amount – effectively a negative fee for trading.
How to provide liquidity on Loopring
The Loopring Exchange AMM utilises liquidity pools to offer smart contract exchange of cryptocurrencies. Liquidity can be provided to the liquidity pools, which are subsequently used by traders.
For risking assets, liquidity providers earn 0.20% from all trades completed via the AMM, with the awarded amount being proportional to the user's share of the liquidity pool. The accrued fees are added to the liquidity pool and then claimed when an investor withdraws funds.
To become a liquidity provider, a user needs to deposit equal amounts of both assets in the liquidity pool.
- Pool. On the Loopring Exchange, click the "Pool" tab.
- Choose. Select which liquidity pool you would like to provide liquidity for.
- Enter amount. Click "Add", and on the next page for one of the cryptocurrencies, enter the amount that you want to deposit. The other asset amount will be automatically filled so that the two are equal to one another.
- Add liquidity. Click "Add" and the transaction will be completed.
In return for the liquidity deposited, a user will receive liquidity provider tokens minted by the Loopring Exchange. This represents the user's share of the liquidity pool.
When depositing liquidity into a liquidity pool, there is always a risk of impermanent loss.
Cryptocurrencies must be deposited in equal proportion to a liquidity pool. However, large movements in price can result in an imbalance of tokens. Arbitrage traders take advantage of this imbalance, trading with the pool until the pool is rebalanced and in line with new asset prices. After rebalancing, a liquidity provider may have lost or gained cryptocurrency tokens.
When withdrawing funds, a liquidity provider may leave with a slightly different ratio of tokens compared with the equal proportion they entered with. At the current market value, those assets may not be worth as much in comparison with assets that had stayed in a digital wallet or exchange.
Impermanent loss is only realised when an investor withdraws funds from a liquidity pool.
What is a liquidity provider token?
Liquidity provider tokens represent a user's share of a liquidity pool and are received once liquidity has been provided. They allow users to remain in complete control of their digital assets and help to create multiple levels of liquidity in the DeFi ecosystem.
For depositing cryptocurrency with a liquidity pool in Loopring, you will receive liquidity provider tokens in your layer-2 wallet. LP tokens can be viewed on the "Pool" page and in your "Balance".
If a user deposited equal proportions of ETH and DAI in the ETH-DAI liquidity pool, they would receive LP-ETH-DAI tokens in their layer-2 wallet.
For certain liquidity pools on the Loopring Exchange, users can stake their liquidity provider tokens to receive further rewards. The AMM liquidity mining initiative was launched at the start of 2021 to encourage users to move from the layer-1 Ethereum network to layer-2. Liquidity mining opportunities change every 14 days and can be found on the "AMM Info" tab and filtering by "Rewards".
How to withdraw tokens from a pool
To withdraw funds from a liquidity pool on the Loopring Exchange, follow these steps:
- Head over to the Loopring Exchange.
- Pool. Click on the "Pool" tab at the top of the website. Look for the "My Pools" tab, which highlights which liquidity pools you have cryptocurrencies in.
- Remove. Click "remove" next to the chosen liquidity pool.
- Enter amount. Enter the amount that you wish to withdraw from the pool.
- Reclaim. Once happy with the amount, click "Reclaim". Your liquidity provider tokens will then be removed from your layer-2 wallet and replaced with your original cryptocurrency assets plus accrued transaction fees.
Note. Removing liquidity from a liquidity pool does incur a small transaction. Although the operation is completed on layer-2, a small layer-1 transaction is required.
Risk of providing liquidity on Loopring
- Impermanent loss. As mentioned above, an impermanent loss can occur if price changes of the deposited assets cause an imbalance in the liquidity pool. This imbalance can result in a change in the ratio of deposited assets through arbitrage trading. Upon withdrawal, the assets may be worth less than if they had stayed on an exchange leading to an impermanent loss.
- Smart contracts. Although innovative and hugely efficient in the DeFi sector, smart contracts can develop bugs. Bugs can lead to unexpected effects on the system, which may lead to loss of funds.
What does the LRC token do?
LRC is the native ERC-20 token to the Loopring protocol and was launched in August 2017 as part of an initial coin offering. The token has primarily stayed the same for 3 years and was used to reward relayers that operated the system. However, in 2021, the LRC token utility will be advancing to fall alongside the evolving Loopring platform.
LRC token holders will be rewarded if they use their assets for the good of the Loopring system, which includes liquidity providers, relayers (operators of the system) and those offering governance. The protocol fee, which is 5-20% of all layer-2 transaction fees, is collected and distributed by the relayers to all LRC token holders that benefit the system.
Starting from Q2 2021, users can provide LRC to an insurance fund that is kept on the layer-1 Ethereum network. Although highly secure, Loopring acknowledges that bugs in smart contracts can occur and therefore will be implementing an insurance fund. 10% of all protocol fees will go to liquidity providers of the insurance fund.
In Q3 2021, Loopring aims to launch a decentralised autonomous organisation (DAO) for the governance of the Loopring protocol. Holders of the LRC token will be able to vote and govern developments of the system such as the distribution of protocol fees, the protocol fee percentage and what triggers the use of the insurance fund. Decision-makers will receive 10% of all protocol fees.
The LRC token remains crucial in the Loopring reputation system. To create a DEX on the Loopring protocol, DEX owners must stake 250,000 LRC. The staked LRC provides security for users and can be burned by the Loopring protocol if there is any malicious activity by a DEX. This is referred to as "slashing". A benefit for DEXs is that by staking LRC, DEXs can reduce the fees associated with using the protocol.
The LRC token is ultimately deflationary due to the burning processes associated with the deterrence of malicious activity. Some tokens are also burned through transactional processes.
Where to buy LRC
Pros and cons of Loopring
- Non-custodial. Users always remain in control of their digital assets.
- Security. Merkel proofs allow a user to gain access to layer-2 assets even if the layer-2 protocol fails. zkRollups allow Ethereum-style security on exchanges.
- Increased speed and lower fees. Off-chain execution of exchanges means that transaction times are significantly reduced and gas fees on the layer-2 network are next to nothing.
- Reputation system. DEXs are encouraged to behave correctly towards users through fear of losing staked LRC tokens.
- Slow development. Although beginning the Loopring protocol in 2017, the Loopring Exchange was only launched in 2020 and only then as a beta version.
- Ease of access. Funds must be stored and used from the layer-2 digital wallet.
Disclaimer: Cryptocurrencies are speculative, complex and involve significant risks – they are highly
volatile and sensitive to secondary activity. Performance is unpredictable and past performance is no guarantee of
future performance. Consider your own circumstances, and obtain your own advice, before relying on this information.
You should also verify the nature of any product or service (including its legal status and relevant regulatory
requirements) and consult the relevant Regulators' websites before making any decision. Finder, or the author, may
have holdings in the cryptocurrencies discussed.