How Does DeFi on Bitcoin Work?

An introduction to Rootstock smart contracts

DeFi, shorthand for “Decentralized Finance”, has been one of the last years’ most significant trends. What Bitcoin does to money transactions, DeFi promises to bring to lending, borrowing and trading: a system that works without the need to trust any middlemen. All intermediaries such as banks or exchanges, which make the traditional financial system so vulnerable to fraud and corruption, are replaced by the cold hard math of open source software. A crucial role in this financial revolution play so-called smart contracts, a concept that has been developed by the computer scientist, lawyer and cryptographer Nick Szabo in the early 1990s.

This concept was first turned into reality by Vitalik Buterin and his Ethereum team in 2015. Today, Ethereum dominates the DeFi market. More than 90% of all DeFi transactions have taken place on the Ethereum blockchain. Other blockchains such as Tron, Solana or EOS hardly matter. But will Ethereum continue to rule the DeFi space? I don’t think so. A sleeping DeFi giant is about to wake up: Bitcoin. Many people are unaware of the fact that everything that can be done with Ethereum is also possible with Bitcoin.

It is true that Bitcoin has been conceived by Satoshi Nakamoto as digital cash with very limited programmability. But there is a clever solution which allows smart contracts to work on the Bitcoin blockchain just as well as on Ethereum. It is called Rootstock, sometimes abbreviated RSK.

Rootstock a sidechain that is connected to the Bitcoin blockchain by a so-called Two-Way Peg. On this sidechain, smart contracts can be executed in pretty much the same way as on Ethereum. Rootstock even uses the same programming language and Virtual Machine as Ethereum, which means that the code of a smart contract developed for Ethereum can easily be reused.

Rootstock has its own native currency called Smart Bitcoin, which is pegged in a ratio of 1:1 to the original bitcoin. In order to use smart contracts based on the Bitcoin blockchain. All one has to do is to change Bitcoin into Smart Bitcoins. This is without a risk, as the original coins are locked. When you want to get them back, you can easily convert the smart bitcoins back into the original ones. You will not miss out on a Bitcoin bull run, as the Smart Bitcoin follows excatly the same growth pattern as Bitcoin.

This connection between bitcoin and smart bitcoin is based on a process called Merged Mining. A miner can generate Smart Bitcoins at the same time he generates Bitcoins. For this, Rootstock has formed partnerships with some of the biggest bitcoin mining pools. By „piggybacking“ on the most powerful computing network the world has ever seen, Rootstock’s smart contracts are much less prone to attacks than the ones on any other blockchain. 

Another huge advantage of Merged Mining: The miner already makes his money through the block rewards and transaction fees of Bitcoin. He uses the same infrastructure to produce Smart Bitcoins, so his costs for this extra effort are marginal. This means that transaction fees, also known as „gas prices“, can be much lower on Rootstock than on Ethereum. Due to the DeFi boom, gas prices in the Ethereum network have skyrocketed in the last months. The low transaction costs may therefore be a key advantage of Bitcoin-based DeFi.

Nick Szabo and ego Gutiérrez Zaldívar, painted by Max Cryptohead

The idea for Rootstock was born when Diego Gutiérrez Zaldívar, its co-founder and CEO, met Nick Szabo in Palo Alto in December 2014. At that time, Diego was the president of both the Argentinian and the Latin American Bitcoin Foundation, NGOs with the goal to educate people about Bitcoin.

“I was introduced to Nick by a common friend, and he was very interested in the development of Bitcoin in Latin America“, recalls Diego. “I told him that financial inclusion was a big issue there, because so many people do not even have a bank account. For financial inclusion to happen, Bitcoin needed to be expanded to include smart contracts.”

Ethereum was under development then, but Diego and Nick both agreed that Bitcoin-based smart contracts would be a much better solution. Diego suggested contacting Sergio Lerner, a former Bitcoin core developer, who had developed a concept for a programmable cryptocoin. They sent him an email right away. That conversation led to the creation of Rootstock, with Sergio Lerner as CTO, Diego Gutiérrez as CEO, and Nick Szabo as an advisor.

“Rootstock is an evolution of two platforms, QixCoin and Ethereum. QixCoin was a turing-complete cryptocurrency created back in 2013 by some of the Rootstock founders”, explains Sergio. “QixCoin introduced the concept of pay-per-execution, currently known as transaction ‘gas.’ However, Rootstock inherits several key concepts from Ethereum, such as its account format, virtual machine and web3 interface.”

Rootstock was first announced at the Latin American Bitcoin Conference in Mexico City in December 2015. Its mainnet was launched in January 2018. However, developing this kind of software and building up the necessary infrastructure for it are quite ambitious and time-consuming endeavors. Since then, quite a few projects have been realized on Rootstock, but it is still in its infancy.

The Honey Badger in a space suit, Sovryn’s mascot

One of them is Money-on-Chain, a stablecoin and trading platform. This platform also provides the BitPro token, an interesting way to generate a passive income for Bitcoin owners. Another promising project is Sovryn, which provides permissionless leveraged and spot trading. In the near future we can expect a wave of new Rootstock-based projects to be launched. 

While Ethereum undoubtedly has a first-mover advantage, many factors indicate that a Bitcoin-based DeFi system will finally prevail. First and foremost: the money is in Bitcoin. Its market capitalization is more than five times higher than the one of Ethereum. More and more institutional investors and big companies use Bitcoin as a store of value. I assume that Bitcoin hodlers hesitate to convert their precious “digital gold” into Ether, only to profit from some suspicious yield farming project. A solution that allows them to make their Bitcoins work for them without an exchange rate risk will surely be welcomed by many conservative Bitcoin owners.

Furthermore, the Ethereum team made several decisions that raised doubts about the truly decentralized nature of this project. In 2016, a hacker abused a badly coded smart contract of an Ethereum based investment fund to steal a lot of money. Therefore the core team led by Vitalik Buterin decided to hardfork the Ethereum blockchain to restore the funds. However, this has violated the basic principles of a blockchain, which by definition should be immutable and censorship-resistant.

While decisions about Bitcoin are meticulously checked over and over again by the core development team and fiercely debated in the community, one can easily get the impression that Ethereum‘s fate lies in the hand of a small group of people around Vitalik Buterin. Currently, Ethereum is about to change its consensus mechanism from Proof-of-Work to Proof-of-Stake. This might solve some of the scalability problems Ethereum currently has, but it might as well end up in a disaster.

According to Saifedean Ammous, author of the book The Bitcoin Standard, the decentralized structure of Bitcoin makes it stand out from all competing crypto projects. Saifedean identifies two uncatchable advantages of Bitcoin: The lack of a central leader – Satoshi Nakamoto stepped back from the project in late 2010 – and the fact that no other crypto project will ever have the luxury to work unnoticed by the general public for years.

“Bitcoin’s massive pool of users and asset value is the biggest network effect in crypto”, says Sovryn‘s co-founder and CEO Edan Yago. “There is simply no reason to build Bitcoin DeFi on Ethereum. Bitcoin’s layer 2 provides all the tools to do this in a bitcoin-native environment.”

By Aaron Koenig