Hello, curious babies!👋

Last time we talked about Bitcoin's 'digital shopping vouchers'—UTXO (if you haven't seen it, hurry up and catch up!). Today, we're going to delve deeper into how these 'shopping vouchers' flow in our hands, which is: Bitcoin transactions!

Did you think that Bitcoin transactions are just like WeChat transfers, just a click away? In fact, there’s a set of ingenious 'magic' behind it!

Transaction: A grand transfer of 'shopping vouchers'!

Imagine you have a pile of digital shopping vouchers (UTXO), and now you want to transfer 0.2 Bitcoin to Xiaoming. What would you do?

  1. Find your 'digital shopping vouchers': You will find some vouchers in your wallet whose amounts add up to at least 0.2 Bitcoin or more. For example, you might take out a 0.5 Bitcoin voucher.

  2. Sign it to prove 'this is mine': It's like you wrote a note: 'I, [your private key signature], authorize spending this 0.5 Bitcoin shopping voucher, giving 0.2 Bitcoin to Xiaoming, and receiving the remaining 0.3 Bitcoin as change.' This 'signature' is very important! It is completed with your private key (your exclusive seal). With this signature, the entire Bitcoin network knows: you are indeed the legitimate owner of this shopping voucher, and you agree to this transaction.

  3. Loudly broadcast, let the whole world know: you put this signed 'note' (i.e., this transaction information) on the network, loudly telling all Bitcoin nodes (those computers maintaining the big ledger): 'I want to make this transaction!'

  4. Uncle miners come to 'keep accounts': Miners on the network will hear your broadcast, and they will verify this transaction:

    If everything checks out, the miners will package your transaction along with several thousand others during that time into a new 'block.'

    • Is your signature real?

    • Do you really have this 0.5 Bitcoin shopping voucher (UTXO)?

    • Have you spent the same shopping voucher twice? (This is Bitcoin's super anti-counterfeiting mechanism!)

  5. Stamped confirmation, transaction successful! When this new block is successfully added to the blockchain (that big 'ledger'), your transaction gets confirmed.

    Thus, a complete Bitcoin transaction is completed!

    • That 0.5 Bitcoin 'old shopping voucher' has been marked as 'spent' and can no longer be used.

    • Xiaoming received his 0.2 Bitcoin 'new shopping voucher'.

    • You also received a 0.3 Bitcoin 'new change shopping voucher' back to your wallet.

A few core keywords of the transaction:

  • Inputs:

    The 'old shopping vouchers' (UTXO) you used to pay with.

  • Outputs:

    New 'shopping vouchers' generated after the transaction is completed. One part is for the recipient, and the other part is change for yourself.

  • Signature:

    Your private key authorizes the transaction, proving you are the legitimate owner. Without a signature, the transaction cannot occur.

  • Transaction Fee:

    You may pay a small fee to the miners (for instance, receiving slightly less change), incentivizing them to prioritize packaging your transaction. The busier the network, the higher the fee may be.

  • Confirmation:

    The number of times your transaction is packaged by miners into a block and 'confirmed' by subsequent blocks. The more confirmations, the less likely the transaction can be altered, making it safer.

Where is the security in Bitcoin transactions?

You might think, isn't there still a transfer and change? Its uniqueness lies in:

  1. Public and transparent:

    Every transaction is publicly traceable on the blockchain, and you can track the flow of any Bitcoin (but you won’t know who it is).

  2. Immutable:

    Once a transaction is packaged into a block and confirmed, it is nearly impossible to modify or revoke it.

  3. Decentralized verification:

    There are no banks or third-party institutions to approve your transaction; it is verified collectively by thousands of miners and nodes around the world. This guarantees fairness and security.

Now, do you have a clearer understanding of the mysterious Bitcoin transactions? It’s like a sophisticated 'digital shopping voucher' circulation game, with each step strictly verified to ensure that every satoshi of your Bitcoin is safe and reliable!

Do you find it interesting and useful? Give it a like, and share it with your friends! Next time, we'll talk about more interesting knowledge about blockchain!

#BTC