Skip to content

  Spin up a managed Avalanche node cluster in minutes! Learn More.

The Sync Blog

Updates and insights from the Bloq team

« Blog Home

How-to: UTXOs vs Accounts, Plus Handling Bitcoin, Ethereum, and More

As you further explore and interact with blockchain technology, you’ll probably recognize some key distinctions between Bitcoin, Ethereum, and their respective cousins.

There are a number of differences in how we interact with the Bitcoin and Ethereum blockchains, such as different record-keeping mechanisms between the two. Values of Bitcoin and Bitcoin Cash are recorded as unspent transaction outputs (UTXOs), while values of Ethereum and Ethereum Classic are recorded as account balances.

Under the Hood: BTC vs ETH

In essence, a Bitcoin wallet is a collection or pool of different sums of BTC. The wallet is also made up of multiple addresses, so there are a number of endpoints that coins can be sent to in the same wallet. When a Bitcoin transaction takes place, the sent coin is received by the wallet as a UTXO. The UTXO is unique from all others. 

The end user only sees one balance: the sum of all UTXOs in each address that makes up the wallet. When users send some amount of BTC, a UTXO is sent as is, or combined with others, to cover the desired amount to send. 

We can highlight the nature of BTC transactions by querying to the Connect API. Here’s some of the output data from an early Bitcoin transaction, where a miner sent 10 BTC from a 50 BTC block reward to another address:

And here is the output:

The output highlights that the UTXO of 50 BTC was accessed by the address 12cbQLTFMXRnSzktFkuoG3eHoMeFtpTu3S. 10 BTC from the UTXO was sent to 1Q2TWHE3GMdB6BZKafqwxXtWAWgFt5Jvm3, while the excess 40 BTC returned to the original address.

In contrast, Ethereum records ETH (and tokens) as account balances. In this model, there is one address associated with each account. Sending and receiving coins instead takes the form of deposits and withdrawals to-and-from the account. 

Like we did with Bitcoin, we can interact with Bloq Connect to see the makeup of an Ethereum transaction ourselves.

The following command highlights a transaction from an early Ethereum mining operation. (Note that, for Ethereum, you will need to generate a project id and replace my-project-id with your own in the sample below.)

And the output (with only the relevant fields included):

In the case of the Ethereum transaction, the exact amount is withdrawn from the sender to the recipient. The “nonce” represents how many transactions have been sent by this account. Because amounts of ether are not unique from one another (like with BTC and UTXOs), the nonce is a security measure put in place to prevent double spend attacks (by differentiating each transaction).

Bloq and UTXOs / Accounts

Bloq services are operable with BTC/BCH as well as ETH/ETC. As you look through documentation and interact with various toolkits under the Bloq umbrella, you’ll probably recognize that the infrastructure and syntax surrounding Bitcoin and friends differs greatly from Ethereum and friends.

In essence, this is also due to differences between UTXOs and accounts. The API infrastructure built out around Bitcoin and Ethereum differs, so Bloq’s solutions must, as well.

Cash vs Debit

Looking at the differences as a real-world analogy, Bitcoin wallets are akin to physical wallets as Ethereum accounts are to bank accounts. 

Your wallet carries a collection of dollar bills and coins of differing amounts (UTXOs). In order to purchase something, you must withdraw one or multiple bills/coins. When you overpay, you get change back to your wallet in the form of new coins or bills. 

Instead, you can pay with a debit card. You swipe your card into the reader to pay the exact amount of the transaction. When this happens, your bank checks to make sure your account can cover the cost of the transaction. So long as all reads well, they approve the transaction and send the exact amount to the recipient’s account.

UTXO vs Account Trade-Offs

You’ve probably experienced certain situations where using cash instead of a debit card (or vice versa) was preferred or necessary. Similarly, there are situations where activity is more suited to either the UTXO or Account model.

BTC and ETH both represent complex activity. UTXO vs Account dictates where that burden of complexity lies. Bitcoin’s UTXO model is more difficult for the end user. Users are responsible for combining their UTXOs in the most efficient way possible. Transaction fees are reflective of the “size” of the transaction, which corresponds to how many separate UTXOs are input. This isn’t immediately obvious to the user, and it takes some low level understanding to combine the “change” of many small UTXOs into one larger one that can be sent more efficiently.

Improvements to the UI/UX in BTC wallets over the past decade make it easier to manipulate UTXOs and interact with the multiple addresses that makeup a Bitcoin wallet, but it’s still not yet a seamless experience.

In contrast, the UTXO model is simpler for network nodes. UTXO represents a standardized transaction format, which makes the process of verifying and recording transactions a fairly accessible endeavor. Your standard laptop or desktop with a steady internet connection is well equipped to operate as a full BTC node.

Ethereum’s approach is more straightforward for the end user. On Ethereum, one account corresponds to one address. The account acts as your universal hub of activity, where you manage your ETH and tokens (different cards, rewards points, loans in a bank account). There is no transaction “standard” on ETH. Instead, users broadcast smart contracts that assert the activity they’re looking to execute. Users can broadcast contracts to do everything from creating and minting tokens to executing player moves to an NFT game.

This makes things more intensive for the nodes. Although launched six-and-a-half years after Bitcoin, the Ethereum blockchain is over 10 times the size of BTC. Pruning strategies eliminate some of the storage space required, but the primary burden comes from synching the node faster than new Ethereum blocks come in, every 13 seconds, on average. (But, really, we think you should outsource your nodes.) 

Ethereum also requires beefier nodes because they have to parse and validate broadcast smart contracts to make sure they aren’t in violation of rules and limitations put in place by the network and other contracts. For example, if I were to broadcast a contract that moves all LINK from the founders address to my own, the network must vet and reject my contract. The computational requirements associated with contract execution is reflected in highly variable gas prices. A standard transaction of ETH or an ERC-20 token will only cost a few pennies worth of gas,  but users interacting with a DeFi platform or other decentralized application routinely see costs of several dollars worth of gas per transaction.

Which is Best?

Between BTC and ETH, both lack where the other excels — and that’s okay. Bitcoin is “digital gold.” Bitcoin users primarily interact with BTC as a store of value, medium of exchange, or unit of account.  When your main actions are spending and holding, the added complexity of the UTXO model won’t cause much controversy.

Ethereum and Ethereum Classic are positioned as “programmable money.” From your ETH account, you can interact with web3 applications (like gaming dApps, decentralized exchanges, DeFi protocols, etc.), manage tokens, and write smart contracts. A more user-friendly interface is required for the vast majority to perform these types of interactions. 

The distinction between these two models and associated trade-offs highlight a much deeper conversation about strengths and weaknesses of different blockchains. But, for now, it’s enough to better understand the differences between these two approaches that the two major blockchain networks and their closest relatives employ. Knowing this will help make blockchain programming a lot easier, particularly when considering cross-chain applications. 

Join the Bloq newsletter for the latest updates

This field is for validation purposes and should be left unchanged.