Bitcoin is the most popular and valuable cryptocurrency globally, while Ethereum has the most applications based on the sheer number of DApps and tokens built on top of its blockchain.
So, what’s the difference in the mechanisms behind both?
At the core of any cryptocurrency is the model of transactions, and these two, generally built for different purposes, have unique transaction models.
Interestingly, each model is linked to existing financial models, making it easier for anyone to comprehend the complex computing powering these blockchain technologies.
Bitcoin’s UTXO Model
UTXO (Unspent Transaction Output) is a model where “unspent” bitcoins sent to a user (transacted) are kept in a fully synchronized node.
Each transaction spends the output from a prior transaction on the bitcoin blockchain and generates a new output that can be spent in future transactions. If a transaction’s output is not spent, it is called an “unspent token.”
Essentially, an owner does not directly own the tokens but owns the output of a specific number of tokens that can then be signed over as input to a new owner, who then controls the new outputs.
On the blockchain, they appear like a collection of bitcoin amounts at different addresses, and any owner must have the requisite address, digital signature, and digital key necessary to prove ownership over the new output.
Based on this explanation, a Bitcoin wallet’s simple job is to figure out which addresses a user has the keys to and give them permission to make transactions.
Three primary rules apply in the UTXO model.
- Every transaction must prove that the sum of its inputs is greater than the sum of its outputs.
- Every referenced input must be valid and unspent.
- The transaction must have a signature matching the owner of the input for every input.
UTXO In layman’s language
The UTXO system is like a digital recreation of the cash economy, which involves actual notes or coins and wallets. Let’s put this into perspective using two subjects, Fatuma and Odhiambo.
|Bitcoin Transaction||Cash Transaction|
|Fatuma has 10 BTC; the system recognizes that there is 10 BTC signed to her, and they have not been spent. Meanwhile, Odhiambo has 5 BTC, recognized and unspent.||Fatuma has Ksh 1000 note in her wallet. Odhiambo has Ksh 500 note in his wallet.|
|Fatuma sends 2 BTC to Odhiambo: Fatuma’s wallet opens a UTXO using the entire 10 BTC as the input to the transaction. This transaction sends 2 BTC to Odhiambo and returns 8 BTC to Fatuma in the form of a new UTXO to a newly-created address.||Fatuma gives Odhiambo the Ksh 1000 note. Odhiambo takes Ksh 200 and returns Ksh 800 to Fatuma.|
|Odhiambo’s wallet now keeps track of 2 UTXOs; the original 5 BTC and the new 2 BTC sent by Fatuma. His balance now reads 7 BTC.||Odhiambo’s wallet now has two notes; the original Ksh 500 note and the newly acquired Ksh 200 note, which brings the total balance to Ksh 700|
That’s just a simple illustration of how the UTXO model functions. Take note that you don’t own the coins in the bitcoin blockchain; instead, you own the transaction details that assign coins to you.
Ethereum’s Account Balance Model
Ethereum differs from bitcoin fundamentally in that it is primarily an open-source blockchain platform for decentralized applications, whereas bitcoin is primarily a cryptocurrency. Ethereum was built to perform more functions than just enable the transfer of value through the internet.
Consequently, certain concepts applied by the developers of its predecessor (bitcoin) were discarded and replaced by more applicable ones. For a start, the account balance model of transactions replaced the UTXO model.
This simpler and space-saving model is critical to enabling the Ethereum ecosystem, which uses smart contracts to perform complex transactions. Other advantages of the model include familiarity and fungibility (equal value between assets).
Ethereum’s Account Balance model stores information about the entire balance associated with a user’s account and keeps track of the balance of each as a global state. Every account in Ethereum has its own balance, storage, and code space for calling other accounts or addresses.
For a transaction to happen, the user must show that they own the account and that there is enough money in the account to pay for the transaction and the transaction fee. Once these conditions are met, the sending account is debited and the receiving account is credited.
Additionally, suppose the receiving account has a code. In that case, it runs and makes changes to the internal storage or sends more messages to other accounts, which results in more debit and credit transactions.
Account balance model in layman’s language
This model is based on the banking system, which uses accounts with money in the form of numbers. Transactions are made based on who owns the account (by entering bank pins or passwords) and whether there is enough money in the account to make the transaction.
Again let’s use our two subjects once again
|Ethereum Transaction||Bank Transaction|
|Odhiambo has 100 ETH in his Ethereum wallet, while Fatuma has 20 ETH in hers. The system recognizes that both Odhiambo and Fatuma own their respective accounts.||Odhiambo has Ksh 50,000 in his bank account, while Fatuma has Ksh 20,000 in hers.|
|Odhiambo sends Fatuma 30 ETH; The system first confirms that Odhiambo owns the account used to request the transfer, then checks whether it contains more Ethers than 30 ETH plus the transaction fee. If both conditions are true, it debits 30 ETH plus the transaction fee from Odhiambo’s account and credits Fatuma’s account with 30 ETH.||Odhiambo requests the bank to send Ksh 10,000. The bank first asks Odhiambo to input his bank pin to initiate the transaction. If the pin is correct, the bank checks if the account has enough money to enable the transaction. If it does, it debits Ksh 10,000 + Ksh 80 (transaction fee) and credits Fatuma’s account with Ksh 10,000|
|Odhiambo’s account now reads a balance between 69 ETH and 70 ETH (due to the transaction cost), while Fatuma’s account reads 50 ETH.||Odhiambo’s account now reads Ksh 39,920 while Fatuma’s account reads Ksh 30,000|
As illustrated, Ethereum’s account balance is just a reflection of the banking system. But smart contracts and other features enabled by the Ethereum blockchain make it possible to do more than just debit and credit accounts.
Even though they use different ideas, both models track account balances in a consensus system, which is the same goal.
Advantages of UTXO
- It is possible to process multiple transactions outputs at the same time hence enabling parallel transactions and providing a scalable infrastructure
- High level of privacy since users acquire new addresses for each transaction
Advantages of Account Balance Model
- Each transaction needs to make only one reference and one signature to produce an output, less space is consumed
- Ease and simplicity in coding
- Since there exists no blockchain-level concept of the source of a specific set of coins, blacklisting coins used for illicit purposes is impractical. Hence each coin is as valuable as the next; fungibility.
On the other hand, each model has its shortcomings.
The UTXO model has certain restrictions that make it hard to build applications on the blockchain and is incompatible with smart contracts.
Meanwhile, the account balance model faces scalability issues and is exposed to double spending unless an incremental nonce counteracts such attacks.