What is UTXO

The full name of the UTXO model is Unspent Transaction Output model. It is one of the main accounting models for shared ledgers (blockchains), used to record, store, and execute transactions. The UTXO model is often mentioned together with Bitcoin (BTC). However, in fact, many other blockchain networks also apply UTXO as their accounting model, such as NEO, Litecoin, Zcash, Cardano (extended UTXO model), and others.

How the UTXO Model Works

The name of the UTXO model actually contains its basic concept, which is that this model uses the unspent portions of cryptocurrency in transactions as a way of accounting.

In the UTXO model, there are no “accounts” or “balances.” UTXOs are the units used to help execute transactions. A UTXO refers to the amount of cryptocurrency remaining after a transaction (i.e., unspent cryptocurrency). In other words, in the UTXO model, the balance that a user can transfer is the amount of unspent funds from their previous transactions.

In the UTXO model, each transaction consists of inputs and outputs represented as UTXOs. Inputs consume existing UTXOs, while outputs create new UTXOs. After the transaction is completed, any unused outputs are recorded as inputs in the database and can be used for future transactions.

Example of the UTXO Model

Wallet A has 5 Bitcoins (UTXO_0). Wallet B is empty. Now, A wants to send 3.15 BTC to B’s wallet. A’s 5 BTC will be recorded as an input and then consumed (which can be viewed as destroyed). At the same time, 3.15 BTC and 1.85 BTC (UTXO_1 and UTXO_2) will be created as transaction outputs. UTXO_2 will go to A’s wallet, and UTXO_1 will go to B’s wallet. After the transaction, A’s wallet will have an unspent balance of 1.85 BTC. B’s wallet will have an unspent balance of 3.15 BTC.

Note: In real blockchain transactions, transaction fees are deducted. For example, the balance of UTXO_2 after deducting the transaction fee will be slightly less than 1.85 BTC.

Features of the UTXO Model

The UTXO model is applied as the main accounting model for blockchains because it allows tracing the origin of transactions and verification.

From the above example, we can see that the origin of each asset can be traced back to its creation. This is because each transaction output must have a corresponding input. In the Bitcoin system, each Bitcoin can be traced back to the block in which it was mined. In the UTXO model, once an erroneous transaction occurs, the system can precisely locate its source.

The UTXO model can also be viewed as a verification system. It only allows transactions to be executed when the inputs are Unspent Inputs. The system verifies the status of the inputs before executing the transaction. If the inputs are unused, the transaction proceeds. This can prevent malicious behaviors (such as double spending). $PNUT **$TUT $XAUT

BTC-1,67%
NEO-3,05%
LTC-0,88%
ZEC-0,47%
View Original
This page may contain third-party content, which is provided for information purposes only (not representations/warranties) and should not be considered as an endorsement of its views by Gate, nor as financial or professional advice. See Disclaimer for details.
  • Reward
  • Comment
  • Repost
  • Share
Comment
0/400
No comments
  • Pin

Trade Crypto Anywhere Anytime
qrCode
Scan to download Gate App
Community
  • 简体中文
  • English
  • Tiếng Việt
  • 繁體中文
  • Español
  • Русский
  • Français (Afrique)
  • Português (Portugal)
  • Bahasa Indonesia
  • 日本語
  • بالعربية
  • Українська
  • Português (Brasil)