Coins: 14,031
Exchanges: 1,065
Market Cap: $2.447T 1.9%
24h Vol: $74.853B
Gas: 7 GWEI
Go Ad-free
Coins & Tokens
TABLE OF CONTENTS

What is Stacks (STX) And How Does It Scale Bitcoin?

4.7 | by Joel Agbo

What is Stacks?

Stacks is a layer for smart contracts built on Bitcoin, where transactions on Stacks are permanently stored on the Bitcoin blockchain. 


Key Takeaways

  • Stacks is a smart contract blockchain network that extends the Bitcoin blockchain by adopting it as its data settlement layer.

  • Through this approach, it hopes to leverage the security and decentralization level of the Bitcoin blockchain while running an execution layer that offers improved user experience and more utility than P2P transfers.

  • Stacks blockchain runs the POX (Proof of Transfer) consensus mechanism, a tokenomics approach to decentralized consensus.

  • The Stacks token (STX) is the native token of the Stacks network. It plays a principal role in the network’s consensus and economy.


What is Stacks

On a close look at new-generation blockchains, relative to older blockchain networks, one of the observations is that older blockchain networks have greater focus on decentralization and security. They sacrifice speed, scalability, and overall network agility for security and decentralization. Slow transaction speed is in fact healthy for security as miners need time to validate every block. But newer blockchains have great appeal as they are faster and cheaper (to use).

However, more often than not, they sacrifice some measure of security and decentralization to achieve this. This is summed up in the blockchain trilemma, where decentralized networks can provide only two of the three benefits of blockchain: decentralization, security and scalability. Efforts to overcome the blockchain trilemma have led to novel work-throughs for blockchain consensus and transaction validation that maintain a good level of security while simultaneously delivering improved user experience such as Layer 2s and other scaling solutions. Stacks is one of these projects. 

Understanding Stacks

Stacks is a ‘semi-standalone’ layer for smart contracts on the Bitcoin blockchain. It is ‘semi-standalone’ as while the Stacks network runs an autonomous state machine and consensus mechanism, it publishes proof of transactions on the Bitcoin network. 

Stacks extends the Bitcoin network, by developing a more agile execution layer as an option to the slower Bitcoin main network. At the same time, it leverages on the strongest security infrastructure in the blockchain space by depending on the Bitcoin network for the final validation of transactions on its network.

It takes a modular approach to blockchain development by partially segregating the execution layer from the consensus layer. By running a state machine, it allows smart contracts to program its ‘virtual vending machine’. Smart contracts deployed on Stacks are written on Clarity, a programming language developed for the Stacks network. 

Stacks also runs BNS (Bitcoin Naming System), a decentralized naming system that enables users to register desired names on the Bitcoin blockchain. Stacks claim that BNS presents a platform for everyone to create a rigidly owned nominal system, as the holder of the private key to the wallet containing the BNS name retains full control of the name’s state.

 Stacks claim to offer a fertile and secure platform for developers, routine users, and smart contract applications. Now, how does Stacks work?

How Stacks Works

To run smart contracts, validate transactions and achieve an extra layer of security via the Bitcoin blockchain, the Stacks network employs a number of role players that work in synergy. The core of the network consists of

  • A novel programing language

  • A smart contract execution layer

  • An interactive consensus mechanism.

Stacks claim to be different from other Bitcoin scaling solutions by adding an extra utility to the Bitcoin blockchain. Unlike the Lightning network, Stacks claims to not just scale the Bitcoin blockchain but make it even more useful. It achieves this by building a programmable execution layer capable of running asset exchange requests from users and keeping record of the transactions. 

These records of smart contract transactions and native P2P transactions are packaged in blocks and sent to the consensus layer for validation. Consensus on the Stacks networks is according to the Proof of Transfer consensus algorithm.

Proof of Transfer

For starters, consensus mechanisms are ways through which participants of a decentralized network reach an agreement on the integrity of transactions recorded on the network. Stacks run the Proof of Transfer (PoX) consensus mechanism. PoX is a tokenomics approach to blockchain consensus, taking a leaf from Proof of Stake and Proof of Burn. PoX connects miners on the Bitcoin blockchain and stackers/stakers on the Stacks network.

Proof of Transfer

Source: Stacks

Stackers stake their STX tokens on the Stacks network while miners on the Bitcoin blockchain ‘lobby’ stackers to earn the rights to parse a block and sign off on them. The selected miner is incentivized for contributing to the network’s security through rewards in STX. A miner’s chances of being selected to validate a block on Stacks is relative to the amount of bitcoin they have committed to the network. 

Participants in Stacks validation

Source: Stacks

Stackers on the other hand earn BTC rewards as an incentive for strengthening the Stacks network by locking their tokens. BTC earned by a stacker is relative to the amount of STX they locked on the network. PoX takes a leaf from the Proof of Burn (PoB) and Proof of Stake (PoS) consensus mechanism. It adopts the token commitment practice in PoB; the only difference is that the committed tokens aren’t destroyed but distributed to stakers on the other network (Stacks).

The consensus system sends the proof of validity for these transactions to the Bitcoin blockchain for final validation. The idea is that, by publishing transaction proofs, to the Bitcoin blockchain, an attacker can only deliver a successful attack on the Stacks network by first, defeating the Bitcoin security architecture.

Stacks Microblock Architecture

Stacks publishes a record of transactions on its network for a given period of time to the Bitcoin blockchain at once. Like rollups on the Ethereum blockchain, this single transaction contains multiple transactions on Stacks and is validated at once, saving cost and time. This record, validated at once and simultaneously with normal Bitcoin blocks is known as an Anchor block. Anchor blocks being validated alongside Bitcoin blocks means that transactions from Stacks get validated on the Bitcoin network only as fast as the Bitcoin blockchain permits. New transactions on the Stacks network will have to wait until another Bitcoin block is ready for validation. Considering the Bitcoin blockchain’s block time of 10 minutes, this could be a long wait.

To avoid this limiting effect, Stacks introduced Microblocks, Microblocks are validated independently of the Bitcoin blockchain but still sent for final validation when a new Bitcoin block is ready for validation. Stacks claims that this allows the network to scale without decoupling from the Bitcoin security structure.

Clarity Programing Language

Clarity is the language of the Stacks network. Stack claims that Clarity is secure by design, as it takes a syntax-level approach to smart contract handling so as to allow developers to worry less about extra security infrastructures for their applications. Stacks claims that the Clarity programming language is resistant to popular reentrance attacks that allows an attacker to send repeated requests to a smart contract and obtain the same result each time as seen in the infamous Ethereum DAO hack.

Stacks also claims to shed a layer of complexity for its smart contract by translating them ‘as is’ instead of compiling them into byte code. By this, it also avoids compilation bugs. In contrast to Solidity, Stacks claim that Clarity is ‘decided’; developers will know at a glance how the smart contract will function on deployment.

STX Tokenomics

STX is the native token of the Stacks network. As the project reports, STX allows Stacks to develop and manage its own economy and also incentivize its security infrastructure. STX fuels the consensus system by being used to attract Bitcoin miners to validate blocks on the network, STX holders also play a key role in the consensus and security by locking their tokens to the network, a role that qualifies them for Bitcoin rewards. STX also runs the network’s tax system, and is used as fees for transactions.

STX’s tokenomics is intertwined with Bitcoin, just like its consensus and security. Bitcoin miners are more likely to commit to the network when the STX token stays up in price. However, this could also be influenced by a number of other factors.

According to data from CoinGecko, almost 1.4 billion STX tokens are currently in circulation. Total supply isn’t capped, however, about 1.8 billion STX tokens are expected to be in circulation by 2050. Like the parent Bitcoin blockchain, Stacks also runs a halving program that reduces miners' reward by half its previous value. Stacks halves every 4 years. STX currently trades on Binance, Coinbase, Kucoin, and a number of other centralized exchanges. See active STX trading pairs.

Applications Built on Stacks

Stacks is a smart contract network, projects across different sectors are deploying decentralized solutions on the Stacks network. Some of these applications include:

Alex

Alex

Alex offers a number of services on the Stacks network. It offers decentralized financial facilities including a decentralized asset swap platform, a money market, yield farming opportunities, and Launchpad. Alex claims that its Launchpad offers new projects an opportunity to start off on a high, leveraging fundraiser and liquidity facilities on the platform. Alex’s lending protocol also offers decentralized loans and an opportunity to earn passive income by lending assets to borrowers.

ALEX is the official token of the project and is used to incentivize liquidity providers through staking rewards. Liquidity providers commit their assets to Alex pools and in turn, earn ALEX for this service. Assets in the pools are collectively managed in the Alex vault. Alex claims that this collective asset management system allows it to offer even more services like flash loans. Alex also runs a bridge that allows asset transfer between the Stacks network and the Ethereum blockchain.

According to Defilama, about $18 million worth of assets are locked on the platform. Alex is the leading project on the Stacks network by TVL.

Arkadiko

Arkadiko

Arkadiko claims to offer self-paying loans and a collateralized stable coin on the Stacks network. Users on the platform can commit their STX tokens to mint USDA, the dollar-pegged stablecoin issued by the platform. Arkadiko is able to reward users for borrowing through its self-paying loan design, which is achieved by staking the Stacks tokens used as collateral. The stake tokens earn Bitcoin rewards as specified by the Proof of Transfer consensus mechanism. The bitcoin generated by the staked assets is used to gradually pay off the loan. According to the project, the principal goal of Arkadiko is to establish the USDA stablecoin and develop DeFi systems on the Stacks network.

DIKO is the native token of the Arkadiko project and is used to fuel the economy and governance as well. Liquidity providers on the network earn passive income on Diko. Arkadiko is run by the Arkadiko DAO using the DIKO tokens. DIKO holders are members of the DAO and vote on improvement proposals. Data from DefiLlama at the time of writing claims that over $5.4 million worth of assets are locked on the platform.

Stackswap

Stackswap

Stackswap is a multipurpose decentralized finance platform on the Stacks network. It offers decentralized asset swaps in addition to yield farming, staking, and other passive income opportunities. Users lock their tokens to the pools and benefit from the farming event. 

StackSwap also runs a launchpad which it claims to be designed to foster young projects on the network. StackSwap also claims to offer utility to NFT enthusiasts on the Stacks network through the StackSwap NFT marketplace and collection management facility. Through StackSwap’s cross-chain bridge, users can move assets between Bitcoin and the Stacks network. STSW is the project’s native token and is used as an incentive on the staking and yield farming portals.

Defilama, at the time of writing, reports $190,000 in locked assets on the platform. 

Sigle

Sigle

Sigle is a decentralized writing platform on the Stacks network. It claims to hand over full ownership of intellectual properties as writers on the network retain full ownership of their publications. Sigle claims to make publishing easier through an easy-to-understand publishing dashboard. It leverages NFTs and offers projects and individual creators an opportunity to build their communities.

Stacks Nakamoto release

In a December 2022 publication, Stacks announced the pending Nakamoto release. This upgrade, according to the project, was named after the secretive Bitcoin creator as it reflects Satoshi’s vision of a decentralized network that can connect with external decentralized networks in a secure and effective way. Stacks claims that the Nakamoto release will bring significant changes to the network and the Bitcoin blockchain as well. The Nakamoto release is an attempt at creating a layer on the Bitcoin blockchain that is self-functioning and in serene inter-operation with the parent Bitcoin blockchain. Part of the Nakamoto release includes updates to the Clarity language and optimizations to the Stacks network

The goal of the Nakamoto release is to enable the Stacks network to ‘write’ to the Bitcoin blockchain. This, according to the project, opens doors for a number of possibilities including the exchange of assets. Stacks has announced the sBTC (Stacks BTC) as the pioneer of this development.

sBTC

sBTC is a bitcoin-pegged asset on the Stacks network. You are probably familiar with Wrapped BTC (wBTC) on Ethereum and other smart contract blockchain networks; but sBTC is quite different, at least in the underlying technology. sBTC allows the Stacks network to write to the Bitcoin network, thus creating a pathway for decentralized communication and even stronger security. Through this pathway, Bitcoin can be ported to a system with a (relatively) increased utility.

Stacks defines a decentralized ‘peg-in’ and ‘peg-out’ system to allow Bitcoin and SBTC holders to transfer Bitcoin (value) between both networks. To peg-in, BTC holders on the Bitcoin blockchain commit their BTC to the Stacks smart contract deployed on the Bitcoin network. Once BTC is committed to the contract, an equal amount of sBTC is minted on the Stacks network. The holder provides a Stacks network wallet address where the minted sBTC will be sent.

The committed BTC is held in the contract until a peg-out request is submitted by an sBTC holder. To peg-out, an sBTC holder commits their asset to the contract on the Stacks network and provides a Bitcoin wallet address to which the BTC will be sent. An exact amount of BTC is redeemed on the Bitcoin network.

A key difference between sBTC and wBTC is that the latter is operated by custodial entities while Stacks claim that the procedure described earlier is fully self-functioning and guarded by the security infrastructure on both systems.

Stacks also defines a regulatory design for the sBTC-BTC pegging. According to this, the sBTC has two modes; the Normal mode and the Recovery mode. We already discussed the normal mode where the peg-in and peg-out process continues without friction. Assets on both networks are balanced and minting and redemption swiftly go through. However, if this balance is disturbed, the system enters Recovery mode and attempts to restore the balance. This is where the Proof of Transfer consensus mechanism comes in.

In recovery mode, assets on either end aren’t balanced, the system tries to regain this balance by channeling the Bitcoin committed to the network (by miners to stackers) to settle peg-outs. This continues until the network regains its balance. Stacks claim that this approach will keep the sBTC system running.

According to the project, sBTC is set to add economic flair to the Stacks network. By introducing swift BTC cross-transfer, Stacks delves into a multi-billion dollar asset class. sBTC can be used on decentralized money markets to run lending protocols through Bitcoin collaterals and loans. Other DeFi systems like decentralized exchanges and yield farming platforms could also benefit from the liquidity sBTC could bring to the network. Stacks also suggest other use cases like a DAO run by sBTC holders and of course, decentralized payment structures powered by sBTC. 

Final Thoughts

Bitcoin is arguably the most decentralized and secure blockchain network. With millions of miners guarding the network, it is a role model for other blockchain networks in areas of security. Stacks take a route similar to that of L2 networks on the Ethereum blockchain. A few differences exist, however, but the goal and the basic approach are related.

On the micro level, Stacks shines the light on an interesting way to not only interact with the Bitcoin network but to utilize it. After all, when the mining rewards end, Bitcoin will need to survive on transaction fees alone. This approach could be adopted in parts or whole by independent projects and projects on its ecosystem, respectively. We have discussed the latter and how they are leveraging Stack to develop decentralized applications. For the former, the PoX consensus mechanism could work in an even larger scenario, especially if it lives up to its claim of being an energy-efficient and effective resource-distribution approach to blockchain consensus.

The Stacks ecosystem will likely grow as more projects attempt to benefit from everything it promises to offer and stay in (indirectly) congruence with the oldest and most decentralized blockchain network. Having said this, note that this article is only for educational purposes and not financial advice.

CoinGecko's Content Editorial Guidelines
CoinGecko’s content aims to demystify the crypto industry. While certain posts you see may be sponsored, we strive to uphold the highest standards of editorial quality and integrity, and do not publish any content that has not been vetted by our editors.
Learn more
Tell us how much you like this article!
Vote count: 36
Joel Agbo
Joel Agbo

Joel is deeply interested in the technologies behind cryptocurrencies and blockchain networks. In his over 7 years of involvement in the space, he helps startups build a stronger internet presence through written content. Follow the author on Twitter @agboifesinachi

Related Articles


Explore Polkadot's Ecosystem
Discover trending dApps, wallets, DeFi & more

What is Zeebu?
Learn more about the Web3 neobank


coingecko
Continue in app
Track prices in real-time
Open App
Select Currency
Suggested Currencies
USD
US Dollar
IDR
Indonesian Rupiah
TWD
New Taiwan Dollar
EUR
Euro
KRW
South Korean Won
JPY
Japanese Yen
RUB
Russian Ruble
CNY
Chinese Yuan
Fiat Currencies
AED
United Arab Emirates Dirham
ARS
Argentine Peso
AUD
Australian Dollar
BDT
Bangladeshi Taka
BHD
Bahraini Dinar
BMD
Bermudian Dollar
BRL
Brazil Real
CAD
Canadian Dollar
CHF
Swiss Franc
CLP
Chilean Peso
CZK
Czech Koruna
DKK
Danish Krone
GBP
British Pound Sterling
GEL
Georgian Lari
HKD
Hong Kong Dollar
HUF
Hungarian Forint
ILS
Israeli New Shekel
INR
Indian Rupee
KWD
Kuwaiti Dinar
LKR
Sri Lankan Rupee
MMK
Burmese Kyat
MXN
Mexican Peso
MYR
Malaysian Ringgit
NGN
Nigerian Naira
NOK
Norwegian Krone
NZD
New Zealand Dollar
PHP
Philippine Peso
PKR
Pakistani Rupee
PLN
Polish Zloty
SAR
Saudi Riyal
SEK
Swedish Krona
SGD
Singapore Dollar
THB
Thai Baht
TRY
Turkish Lira
UAH
Ukrainian hryvnia
VEF
Venezuelan bolívar fuerte
VND
Vietnamese đồng
ZAR
South African Rand
XDR
IMF Special Drawing Rights
Cryptocurrencies
BTC
Bitcoin
ETH
Ether
LTC
Litecoin
BCH
Bitcoin Cash
BNB
Binance Coin
EOS
EOS
XRP
XRP
XLM
Lumens
LINK
Chainlink
DOT
Polkadot
YFI
Yearn.finance
Bitcoin Units
BITS
Bits
SATS
Satoshi
Commodities
XAG
Silver - Troy Ounce
XAU
Gold - Troy Ounce
Select Language
Popular Languages
EN
English
RU
Русский
DE
Deutsch
PL
język polski
ES
Español
VI
Tiếng việt
FR
Français
PT
Português
All Languages
AR
العربية
BG
български
CS
čeština
DA
dansk
EL
Ελληνικά
FI
suomen kieli
HE
עִבְרִית
HI
हिंदी
HR
hrvatski
HU
Magyar nyelv
ID
Bahasa Indonesia
IT
Italiano
JA
日本語
KO
한국어
LT
lietuvių kalba
NL
Nederlands
NO
norsk
RO
Limba română
SK
slovenský jazyk
SL
slovenski jezik
SV
Svenska
TH
ภาษาไทย
TR
Türkçe
UK
украї́нська мо́ва
ZH
简体中文
ZH-TW
繁體中文
Login to track your favorite coin easily 🚀
By continuing, you agree to CoinGecko Terms of Service and acknowledge you’ve read our Privacy Policy
or
Forgot your password?
Didn't receive confirmation instructions?
Resend confirmation instructions
IT'S FREE! Track your favorite coin easily with CoinGecko 🚀
By continuing, you agree to CoinGecko Terms of Service and acknowledge you’ve read our Privacy Policy
or
Password must contain at least 8 characters including 1 uppercase letter, 1 lowercase letter, 1 number, and 1 special character
Didn't receive confirmation instructions?
Resend confirmation instructions
Forgot your password?
You will receive an email with instructions on how to reset your password in a few minutes.
Resend confirmation instructions
You will receive an email with instructions for how to confirm your email address in a few minutes.
Get the CoinGecko app.
Scan this QR code to download the app now App QR Code Or check it out in the app stores