Research

It’s Time to Stack(s) Bitcoin Up

Dec 9, 2021 ⋅  15 min read

The following report was written by Messari Hub Analyst(s) and commissioned by Stacks Foundation, a member of Messari Hub. For additional information, please see the disclaimers following the article

First impression is the last impression. This concept has proven to be true many times in the music or film industry. It has happened for some singers and actors that their first albums or movies were so successful to make their image permanently intertwined with that album or movie, no matter what they have done in their future works. For some of them this has been a blessing whereas the most polyhedric ones have found their future endeavors to be boxed in. Is Bitcoin likely to face a similar scenario? Initially conceived as a peer-to-peer decentralized cash system and most recently referred to as a “store of value”, it could actually become much more than that. One could argue that the recent adoption as a legal tender in El Salvador makes Bitcoin a means of payment too. What’s really missing is the notion of Bitcoin as an ecosystem. To become one, developers must be able to efficiently build applications on top of it. This calls for smart contract compatibility. And that’s exactly what Stacks is cooking.

How did Stacks start?

The evolution of Stacks began in 2013. The project was created by the founders Muneeb Ali and Ryan Shea. Stacks is the product of Muneeb’s doctoral thesis, which detailed a framework for an internet that could be built around the Bitcoin blockchain. This framework was called Blockstack. The initial research and development has been made possible thanks to the participation in the Y Combinator batch in 2014. Muneeb Ali and Ryan Shea have raised funds in the early stage from Union Square Ventures, Naval Ravikant, SV Angel, Winklevoss Capital and others.

The project raised $47M in a token offering for the Stacks cryptocurrency in 2017, and an additional $23M through the first-ever SEC-qualified US Reg A offering and concurrent Reg S offering in 2019. More than 4,500 Stacks holders participated in these offerings, including USV, Lux, DCG, Winklevoss Capital, Blockchain Capital, Foundation Capital, Hashkey, Fenbushi, and others. In 2020, Blockstacks rebranded to Stacks and launched Stacks 2.0 mainnet in January 2021 with Clarity smart contract compatibility.

Stacks addresses the main difficulties of building on top of Bitcoin

There are two fundamental challenges to building apps and smart contracts on Bitcoin:

  • Scalability: Bitcoin blockchain has a limited capacity for transactions.
  • Secure contracts: to preserve the security of the Bitcoin blockchain, the smart contract scripting language is quite limited.

Stacks has developed a solution for both issues. Instead of deploying smart contracts directly on the Bitcoin chain, Stacks executes them on its own Layer-1 blockchain and uses Bitcoin for settlement only.

How does the Stacks blockchain communicate with the Bitcoin blockchain? A novel consensus mechanism called Proof of Transfer (PoX) allows Stacks miners to write new blocks on its own blockchain through the mining energy consumed by those same miners on the Bitcoin blockchain. No further energy consumption is thus needed.

Achieving speed at a micro level

Speed is of the essence when it comes to decentralized apps. The Bitcoin blockchain is notoriously slower than most of the top chains that support smart contracts. Since each block produced on Stacks must be stored on Bitcoin, one could assume that Stacks’ speed must be smaller or equal to that of Bitcoin. To work around this issue, Stacks has designed a mechanism that allows its blockchain to make good use of the time between two blocks produced on Bitcoin by means of intermediate smaller blocks called microblocks. These blocks can leverage a much faster confirmation speed, and by the time Bitcoin has confirmed a block, the microblocks can settle from Stacks to Bitcoin and provide finality. Microblocks, therefore, provide a speed improvement while utilizing the security of the Bitcoin network.

Smart contracts need Clarity

The Stacks blockchain provides support for smart contracts using the Clarity programming language. Clarity differentiates itself from the most common smart contract languages for two main reasons:

  • Decidable language: Turing-(in)completeness is a property of a machine that is theoretically (un)able to solve any problem if it can be coded out. However, the time required to solve “any” problem is obviously unknown and not necessarily bounded from above. Turing-complete programming languages like Solidity have a wide range of technical possibilities that remain unused most of the time. Indeed, the gas fee consumption model reduces the theoretical spectrum of programming design and induces developers to choose simpler and more parsimonious smart contract structures. However, Turing-complete languages increase the surface area for bugs and make it harder to write hack proof codes. Clarity coding language is decidable (Turing incomplete). This makes it more secure and developers are facilitated in seeing what the code will do before running it.
  • Interpreted code: this property allows non-technical users who can’t audit smart contract code to see in the UI exactly what’s going to happen to their balances before running the smart contract.

Proof of Transfer (PoX) & Stacking

The traditional Proof-of-Work mechanism on the Bitcoin blockchain basically works like this: miners spend electricity to guess the hash of the preceding block and the first one able to do this receives bitcoin as rewards for its effort.

All Stacks transactions settle on Bitcoin. This enables Stacks transactions to benefit from Bitcoin’s security. Because of the need for the Stack blockchain to broadcast its block headers to the Bitcoin blockchain, implementing a Proof-of-Work algorithm on Stacks would have implied an additional energy consumption.

Stacks has chosen a more energy-friendly mechanism that employs bitcoin as “digital energy” to be spent by Stacks miners in place of electricity. This mechanism is called Proof-of-Transfer (PoX) and it allows any Proof-of-Work chain, such as Bitcoin, to be leveraged and extended.

This consensus mechanism involves two parties: miners and stackers.

  • Miners: with PoX, miners are not converting electricity and computing power to earn block rewards and transaction fees. Instead, they transfer Bitcoin, a proof-of-work currency, to holders of Stacks Token. This enables holders of Stacks Token to earn Bitcoin from consensus. This process is called Stacking. Leader election happens on Bitcoin and new blocks are written on the Stacks blockchain. Their cost function is represented by the amount of bitcoin they commit to transfer on the Bitcoin blockchain. The miner in charge of mining the next block (also called “leader”) is elected on the Stacks blockchain using a Verifiable Random Function and the chance of being elected increases with the amount of bitcoin transferred by the miner relative to other miners. The elected miner earns coinbase rewards in the form of STX tokens on top of transaction fees. In order to avoid incentive misalignment in mining on the Stacks blockchain rather than the Bitcoin blockchain, the coinbase rewards per block decrease over time according to the Bitcoin halving schedule.
  • Stackers: they temporarily lock their STX to support the network’s security and consensus. As a reward, stackers earn BTCs that miners transfer as a part of the PoX. Depending on the amount of STX held, they can choose whether to stack independently or to join a stacking pool. STX holders (or pools) that control some threshold number of STX would be able to issue a signed message that locks their STX tokens for some period of time, specifies a Bitcoin address to receive funds, and signals (votes) on a Stacks chain version/fork as the current one. This information would be useful to (honest) miners on the network. Stackers provide a Bitcoin address to receive bitcoin rewards sent by miners.

To sum it up, in PoX miners are not converting electricity into computing power to earn block rewards. They are instead leveraging the already mined bitcoin to transfer them to stackers. This approach harnesses Bitcoin Proof-of-Work without further environmental impact.

What’s the point for miners to be rewarded in STX and for stackers to be rewarded in BTC? Stackers earning BTC could rely on a more established and stable cryptocurrency than STX. This should contribute to boost initial adoption among the community and reduce the reliance on the native STX cryptocurrency. On the other hand, miners could achieve more diversification by earning a cryptocurrency other than BTC but whose success and adoption is intrinsically dependent on Bitcoin. Through the use of a native cryptocurrency, miners can join the Stacks blockchain in a permissionless fashion. Miners and stackers contribute to STX market dynamics in a complementary way: stackers provide buying pressure because of the incentive to lock STX to earn BTC rewards. Miners can therefore invest in the mining activity knowing that STX tokens they receive as rewards will be well supported by the market.

What differentiates PoX from Proof-of-Stake (PoS)? The first difference is that miners and stackers are not the same entity whereas in PoS they can coincide. Moreover, miners actually spend tokens to participate in the miner election whereas validators in PoS help achieve consensus through bonding their capital in the form of native tokens. Contrary to a PoS blockchain, the Stacks blockchain can fork because it is not affected by the “weak subjectivity” problem. Weak subjectivity means that no miner/validator is able to identify the “correct” chain without trusting other nodes. The ability to fork allows a blockchain to survive critical failures that could severely impact the functioning of a PoS chain. Finally, actors participating in the consensus (i.e. stackers) earn rewards in a different token (BTC) than the one locked in the blockchain (STX).

Currently there are more than 436 million STX (more than $1.1 billions) locked in stacking, more than 30% of the STX circulating supply. The average stacking APR is in the 8-10% range.

How does Stacks compare with peers?

The projects that could be considered closest to Stacks are Liquid Network, Lightning Network and RSK. However, Stacks represents a unicum, and it differentiates itself from each of these three projects in the following features:

  • The history of Stacks blocks is stored on Bitcoin. This makes the Stacks blockchain different from a sidechain like Liquid Network by conferring Stacks a higher level of security. A malicious attacker creating a private fork on Stacks would expose itself before Stacks blocks are finalized on the Bitcoin blockchain. Honest miners could then act to stop the attack.
  • The STX token is not pegged to BTC. Contrary to Liquid Network, the value generated on the Stacks blockchain acts as a safety backstop and with no need to provide incentives in keeping the peg between Bitcoin and the sidechain token.
  • Stacks transactions are independent of Bitcoin transactions. Since Stacks is not a Layer-2 solution like the Lightning Network, its utility goes beyond the pure scalability improvement on Bitcoin
  • Stacks miners are independent of Bitcoin miners. This makes Stacks different from merged-mined chains like RSK where the security of the network relies on a subset of Bitcoin miners that, under certain circumstances, could turn out to be a single entity with critical implications in terms of decentralization.

STX tokenomics

As for most of the Layer-1 blockchain native coins, Stacks cryptocurrency (STX) is designed to pay for transaction fees and smart contract execution. This makes the long-term value of Stacks dependent on the growth of the Stacks ecosystem and the related demand for Clarity smart contracts because:

  • Miners can see the blocks mined increasing in value because of the higher transaction fee component and this provides incentives for them to acquire STX to participate in consensus.
  • STX stackers will be able to benefit from the growth in the Stacks ecosystem since their rewards in bitcoin depend not only on the coinbase reward but also on the network usage.

The Stacks cryptocurrency has 1.32 billion STX in the genesis block. The distribution has been rolled out through an initial coin offering in 2017 where Stacks raised approximately $ 47 million and investors purchased STX at $ 0.12. In 2019, two SEC-regulated coin offerings occurred: the Reg S offering raised $ 7.6 million with a STX price of $ 0.25 whereas the Reg A+ offering raised $ 15.5 million with a STX price of $ 0.3.

The Stacks’ economic policy was updated in October 2020 with the switch from an adapting burn-and-mint mechanism to a decreasing issuance model that should result in a future supply of approximately 1,818 million by 2050. The decreasing issuance is achieved through the three halvings already illustrated in the previous paragraph.

What’s going on Stacks?

The Stacks ecosystem is experiencing a solid organic growth mainly driven by the following sectors:

  • CityCoins - CityCoins has created an innovative protocol that allows communities to contribute to their cities’ financial resources by forwarding STX in exchange for rewards. Contributors can provide their STX through the Stacks protocol. 30% of forwarded STX tokens are collected by cities in a custodial wallet. The remaining 70% is effectively stacked to provide CityCoin Stackers with STX rewards. Miami has been the first city to join the project and make the headlines even before the city Mayor Francis Suarez declared that its paycheck will be denominated in BTC. The Miami wallet has reached more than $20 million in Total Value Locked which is about 20% of the total annual tax income collected by the Miami city. New York has joined the program as well and, according to the favorable public perception, many more will follow their lead.
  • DeFi - The first DeFi platform that went live on the Stacks blockchain was Arkadiko. This project aims at issuing a stablecoin called USDA through self-repaying loans. Arkadiko has already reached $60 million in total value locked. Another very promising project is called Alex, a DeFi protocol that allows users to launch and trade their own token, lend and borrow without risk of being liquidated and participate in yield farming. Alex has recently raised $ 5.8 million in a funding round led by White Star Capital.
  • NFTs - The Stacks ecosystem hosts some very popular collections:
  • Punks: they are everywhere and the Stacks ecosystem makes no exception. StacksPunks, the Stacks counterparts of the top Ethereum avatar project CryptoPunks, have been recently introduced on the Stacks blockchain and generated more than $1.5 million worth of trading volume.
  • Megaponts: the most famous collection in Stacks had reached $ 2.2 million in NFT sales. Megapont will release it interactive minting that will go live in December
  • BitcoinBirds: the second most popular collection has reached $ 1 million in NFT sales
  • Satoshibles: the world's first cross-chain NFT bridge connecting Ethereum and Bitcoin. This is an NFT avatar collection originally launched on Ethereum. As the name suggests, no community in the crypto space could appreciate the art creations inspired by the pseudonymous creator of Bitcoin more than the Bitcoin community itself. Satoshibles

Furthermore, STX stackers have been given the option to earn NFTs as stacking rewards. This has been made possible by a project called Boomboxes whose total value locked now exceeds $1 million.

What’s ahead for Stacks?

The Stacks blockchain is undertaking a major upgrade, namely Stacks 2.1. The 2.1 upgrade will not be automatic. When ready, it will only activate with the consent of the network. There are a few backwards-incompatible features the upgrade should ship in 2.1 that will contribute to improve the overall functioning of the Stacks blockchain such as:

  • Stacking improvements: these features will make stacking more efficient in terms of timing (no reward cycles missed due to cooldown period) and capital employed (users can freely increase their STX from one cycle to another and receive back the STX not used to earn rewards).
  • Clarity improvements: these features will allow programmers to leverage on an increased range of built-ins, a better parsing and conversion primitives. Furthermore, developers could use the PoX rewards information to build stacking derivatives on top of Stacks.
  • In-band blockchain upgrades: these features will allow miners and STX holders to vote on “stop dates” when it comes to implement backward-incompatible upgrades (like the current 2.1 one) and vote to extend the PoX mechanism sunset date.
  • Reliability improvements: these features will contribute to adjust the runtime cost to make more room for smart contracts that use iterations, to manage Bitcoin flash blocks in a better fashion, to improve the sortition weights for miners and to make multisig signing and verification independent of the order in which they arrive.

Furthermore, the Stacks team is currently working to enhance the interoperability with different blockchains through the following bridges:

Stacks Bridge - cross-chain transfer service that allows owners of ETH or STX based NFTs to move their NFTs between blockchains.

Banana Bridge - this bridge would allow Megakongs transferability from Ethereum to Stacks and vice versa. Bitcoin NFTs could then access metaverse projects very soon.

Orbit Chain - the Orbit Chain, which has recently partnered with Gala Games to expand into the gaming industry, is currently bridging Stacks. In the past year, more than $ 10 billion worth of assets have been bridged across the likes of Ethereum, BSC, Polygon, Klaytn, ICON, and Ripple.

Conclusion

Bringing smart contracts to Bitcoin is an incredibly ambitious plan because of the technical reasons mentioned so far. A fair question could be whether it’s really worth the effort when there are so many other blockchains available for DeFi, NFTs and other applications. Bitcoin, however, can count on the largest community, one of the most secure and decentralized blockchains and a worldwide adoption that no other coin currently even comes close to. Since the cryptocurrency market is gaining wider adoption, decentralization and network robustness become paramount for large and systemically important institutions to build upon. Bitcoin is that network. It’s only logical for Nakamoto's creature to take on the challenge of smart contract compatibility. At the dawn of the multi-chain era, the most famous blockchain in the world seemed way behind competitors in terms of product offerings. Stacks has built a theoretically sound and operationally flexible infrastructure to fill this gap and take Bitcoin to the next level.

Let us know what you loved about the report, what may be missing, or share any other feedback by filling out this short form. All responses are subject to our Privacy Policy and Terms of Service.

This report was commissioned by Stacks Foundation. All content was produced independently by the author(s) and does not necessarily reflect the opinions of Messari, Inc. or the organization that requested the report. The commissioning organization does not influence editorial decision or content. Author(s) may hold cryptocurrencies named in this report. This report is meant for informational purposes only. It is not meant to serve as investment advice. You should conduct your own research, and consult an independent financial, tax, or legal advisor before making any investment decisions. Past performance of any asset is not indicative of future results. Please see our Terms of Service for more information.

No part of this report may be (a) copied, photocopied, duplicated in any form by any means or (b) redistributed without the prior written consent of Messari®.

Upgrade to Messari Pro

Gain an edge over the market with professional grade tools, data and research.

Already a member? Sign in

Upgrade to Messari Pro

Gain an edge over the market with professional grade tools, data and research.

Already a member? Sign in

Mentioned in this report

Read more

Research Reports

Read more

Based on your watchlists

Create a new watchlist
Read more

Research Reports

Read more

Based on your watchlists

Create a new watchlist

About the author

Mentioned in this report