How bitcoin transactions work — step-by-step diagram from UTXO signing to blockchain confirmation

How bitcoin transactions work: a complete technical guide

How bitcoin transactions work: When you send bitcoin, you are not moving a file or a coin — you are broadcasting a cryptographically signed message to a global network of computers, instructing them to update a shared ledger. A bitcoin transaction works by consuming unspent outputs associated with your address, creating new outputs locked to the recipient’s address, attaching a fee that miners collect, and propagating the message across thousands of nodes until a miner packages it into a block on the blockchain. No bank, no intermediary, no central authority — only mathematics, economics, and distributed consensus.

What is a bitcoin transaction, exactly?

A bitcoin transaction is a data structure — a precisely formatted message — that transfers ownership of a quantity of bitcoin from one address to another. It contains three core components: one or more inputs identifying bitcoin the sender already controls, one or more outputs specifying where the bitcoin should go, and digital signatures proving that the sender has the right to move those funds.

No account balance is updated the way a bank updates your balance when you make a payment. Instead, the Bitcoin protocol tracks individual chunks of bitcoin called UTXOs: Unspent Transaction Outputs. Your “balance” is simply the total value of all UTXOs that your private keys can unlock.

Why transactions aren’t simple transfers

Most people expect a payment system to work like a bank account: subtract from one balance, add to another. Bitcoin does not work this way. Each unit of bitcoin exists as a discrete UTXO — a specific output from a previous transaction — and every transaction must reference specific UTXOs as its inputs.

This design was a deliberate choice by Bitcoin’s creator, Satoshi Nakamoto, outlined in the 2008 Bitcoin whitepaper. The UTXO model gives the network a clean, auditable way to prevent double-spending without trusting any central record-keeper.

How the UTXO model structures every transaction

The UTXO (Unspent Transaction Output) model is the accounting framework underlying every bitcoin transaction. Understanding it removes the mystery from how bitcoin moves.

What a UTXO is

A UTXO is a spendable portion of bitcoin produced by a previous transaction that has not yet been used as an input in any confirmed transaction. Think of UTXOs as discrete sealed envelopes of value — each one locked to a specific address and worth a fixed amount. Your wallet shows you a total balance, but under the surface it holds a collection of these envelopes, not a single number.

Every UTXO traces its origin back to a coinbase transaction: the special transaction miners create when they win a block and collect their reward. All bitcoin in existence started this way, and every transaction since has simply passed these outputs forward in a chain.

Inputs and outputs: how value moves

A transaction consumes one or more existing UTXOs as its inputs and creates new UTXOs as its outputs. The mechanics follow a strict rule:

  • Inputs reference specific existing UTXOs and include a digital signature proving ownership
  • Outputs specify a new value and a locking condition — typically a recipient’s bitcoin address
  • The fee is implicit: the difference between the total value of all inputs and all outputs. There is no separate fee field — whatever is not assigned to an output is collected by the miner

This means you cannot spend part of a UTXO. If you hold a UTXO worth 1 BTC and want to pay someone 0.3 BTC, the entire 1 BTC input must be consumed. The transaction creates two outputs: one worth 0.3 BTC locked to the recipient’s address, and one worth the remainder (minus the fee) locked back to an address your wallet controls. This second output is called change — a concept borrowed directly from physical cash.

A concrete example: Alice sends 0.4 BTC to Bob

Suppose Alice’s wallet holds a single UTXO worth 1 BTC. She wants to send Bob 0.4 BTC.

Her wallet constructs a transaction with:

  • Input: the full 1 BTC UTXO (which must be consumed entirely)
  • Output 1: 0.4 BTC locked to Bob’s address
  • Output 2: 0.595 BTC locked to Alice’s change address
  • Implicit fee: 0.005 BTC (the difference, paid to the miner)

After confirmation, Alice’s 1 BTC UTXO no longer exists. In its place are two new UTXOs: one Bob controls, one Alice controls as change.

ElementValueGoes to
Input (Alice’s UTXO)1.000 BTCConsumed
Output 1 (payment)0.400 BTCBob
Output 2 (change)0.595 BTCAlice
Implicit fee0.005 BTCMiner

This table reflects every bitcoin transaction at its core. The values will differ; the structure will not.

How bitcoin transactions are signed and verified

Before a transaction can be broadcast, the sender must prove ownership. This is where cryptography does the work that a bank password does in traditional finance — and does it in a fundamentally stronger way.

Public keys, private keys, and addresses

Bitcoin uses a system called public-key cryptography. Each user generates a key pair:

  • A private key: a randomly generated 256-bit number that must be kept secret. Anyone who possesses it can spend the associated bitcoin.
  • A public key: derived from the private key through elliptic curve mathematics. Sharing it is safe — it cannot be reverse-engineered back to the private key.
  • A bitcoin address: derived from the public key through two cryptographic hash functions (SHA-256 and RIPEMD-160). An address is what you give to someone who wants to send you bitcoin.

The relationship is one-way: you can go from private key → public key → address, but not backwards. This asymmetry is the security foundation of Bitcoin.

How a digital signature proves ownership

When Alice spends a UTXO, her wallet produces a digital signature by applying her private key to the transaction data. This signature has two properties that are crucial:

  1. Proof of authorization: only the holder of the private key can produce a valid signature for that specific transaction
  2. Non-reusability: the signature is mathematically bound to this exact transaction — it cannot be copied and used to authorize a different transaction

Nodes on the network verify the signature using Alice’s public key, without ever seeing her private key. If the signature is valid, the UTXO is unlocked. If anything in the transaction data changes — even a single character — the signature becomes invalid.

What locking and unlocking scripts do

At the protocol level, every UTXO is protected by a locking script (scriptPubKey) that specifies conditions for spending it. The most common condition is “provide a valid signature for this public key.” When spending, the sender provides an unlocking script (scriptSig or witness data) that satisfies those conditions.

This scripting system is what makes Bitcoin programmable beyond simple payments. Multi-signature arrangements, for example, require signatures from two or more private keys before a UTXO can be spent.

How a transaction travels from wallet to blockchain

Signing is only the beginning. After construction and signing, a transaction follows a specific path before it becomes a permanent part of the ledger.

Step 1: Broadcasting to the network

The wallet broadcasts the signed transaction to one or more Bitcoin nodes — computers running the Bitcoin software. Each node checks the transaction against a set of rules:

  • All referenced input UTXOs exist and are unspent
  • The digital signatures are valid
  • The total output value does not exceed total input value
  • The transaction meets minimum size and formatting requirements

If the transaction passes these checks, the node adds it to its mempool — the memory pool — and forwards it to connected peers. Within seconds, the transaction typically propagates across most of the global network.

Step 2: Waiting in the mempool

The mempool is a temporary holding area maintained by every full node independently. Transactions sit there, unconfirmed, until a miner selects them for inclusion in a block.

Miners are economically motivated to maximize their fee revenue per block. They rank mempool transactions by fee rate, measured in satoshis per virtual byte (sat/vbyte). A satoshi is the smallest unit of bitcoin — one hundred-millionth of a BTC. A virtual byte measures the data footprint of the transaction in the block.

This creates a fee market: when the mempool fills with many competing transactions, senders must pay higher fee rates to secure prompt confirmation. When demand is low, even minimal fee rates are sufficient. The fee rate required for next-block confirmation fluctuates continuously with network activity.

Step 3: Miners assemble a block

Bitcoin miners are computers running the proof-of-work consensus mechanism. Their job is to bundle pending transactions from the mempool into a block and find a valid proof-of-work — a specific hash value that meets the network’s current difficulty target.

Finding a valid hash requires enormous computational effort: mining hardware makes trillions of calculations per second, testing different values until one produces a hash below the target. The difficulty adjusts automatically every 2,016 blocks (roughly every two weeks) to maintain an average block interval of approximately 10 minutes, regardless of how much computing power is added or removed from the network.

The miner who finds a valid proof-of-work broadcasts the completed block to the network. It includes the selected transactions, a reference to the previous block’s hash, the proof-of-work itself, and a coinbase transaction crediting the miner with the block reward plus all collected transaction fees.

Step 4: Confirmation and finality

Once a block is accepted by the network, every transaction inside it receives its first confirmation. Each new block added on top of that block adds another confirmation. The cumulative proof-of-work protecting a transaction grows with every confirmation.

Industry practice treats transactions as progressively more final with each confirmation:

ConfirmationsApproximate timeTypical use case
0 (unconfirmed)InstantSmall, trusted payments only
1~10 minutesLow-value transfers
3~30 minutesModerate-value transfers
6~60 minutesLarge transfers, most exchanges

Six confirmations has been the traditional standard for treating a payment as irreversible. To reverse a confirmed transaction, an attacker would need to outpace the entire honest network’s accumulated proof-of-work — a feat that becomes exponentially harder with each additional confirmation.

Transaction fees: how they work and why they vary

Transaction fees in Bitcoin are not set by any authority. They emerge from a market between senders who want their transactions confirmed quickly and miners who want to maximize revenue.

How fees are calculated

The fee is the difference between total inputs and total outputs. But what matters to a miner is the fee rate: how many satoshis the sender pays per virtual byte of block space consumed.

A simple transaction sending bitcoin from one input to two outputs (payment + change) occupies roughly 140–250 virtual bytes. A transaction consolidating many small UTXOs as inputs occupies more space. Fee rate × transaction size = total fee paid.

Because each Bitcoin block is limited to approximately 4 million weight units (roughly equivalent to 1–4 MB of transaction data), block space is a constrained resource. When transaction demand exceeds what fits in one block, fee rates rise until enough senders are priced out and the backlog clears.

What happens to a low-fee transaction

A transaction with a fee rate below the current competitive threshold will sit in the mempool, waiting. This is not lost money — it is simply unconfirmed. If the mempool remains congested long enough, some nodes will eventually drop the transaction (after roughly two weeks, by default). When dropped, the bitcoin returns to the sender’s wallet automatically — no funds are lost.

Wallets that support Replace-By-Fee (RBF) allow senders to rebroadcast the same transaction with a higher fee, replacing the original in the mempool and improving its priority.

Common misconceptions about bitcoin transactions

Several persistent misunderstandings circulate about how Bitcoin transactions work. Addressing them directly helps build an accurate mental model.

Misconception 1: Bitcoin transactions are anonymous

Every transaction is permanently recorded on a public blockchain, visible to anyone. Addresses are pseudonymous — they do not contain names — but transaction histories are traceable. Sophisticated blockchain analysis can often link addresses to real-world identities, particularly when addresses interact with exchanges that collect identity information. Bitcoin is better described as pseudonymous, not anonymous.

Misconception 2: A pending transaction can be cancelled

Once a transaction is broadcast and seen by the network, it cannot be “cancelled” in the traditional sense. If the wallet supports RBF before any miner confirms it, the sender can replace it with a different transaction. If the transaction is dropped from the mempool due to a very low fee, the sender can rebroadcast with a higher fee. But once a transaction is included in a confirmed block, it is irreversible.

Misconception 3: Higher transaction value means higher fees

Bitcoin fees are determined by transaction size in data terms, not by the value transferred. Sending 1,000 BTC costs no more in fees than sending 0.001 BTC, assuming identical transaction structures. Fees scale with how many inputs a transaction uses and how large the data payload is — not the amount being moved.

Misconception 4: You need to send the exact amount

The UTXO model handles this automatically. Wallets select appropriate UTXOs to cover the payment, construct a change output for the remainder, and include a fee. Users simply enter a recipient address and an amount; the wallet handles the arithmetic.

Bitcoin vs. Ethereum: two different transaction models

Bitcoin and Ethereum are both blockchain-based networks, but they manage transactions through fundamentally different accounting approaches.

FeatureBitcoin (UTXO model)Ethereum (Account model)
Accounting unitUnspent Transaction OutputsAccount balances
AnalogyPhysical cashBank ledger
PrivacyBetter (each transaction uses new outputs)Weaker (balance visible on one address)
ParallelismMultiple UTXOs can be spent simultaneouslyNonce-based, sequential per account
Smart contractsLimited scriptingFull programmability via EVM
Fee denominationSatoshis per virtual byteGas units × gas price

The UTXO model provides stronger privacy-by-design and makes it easier to verify the state of the blockchain efficiently. Ethereum’s account model makes it easier to build complex smart contracts that track state across many interactions.

FAQs

What is a bitcoin transaction ID (TXID)? A TXID is a unique 64-character hexadecimal string generated by hashing the transaction data with SHA-256, applied twice. It serves as a permanent identifier for every transaction on the blockchain. Entering a TXID into a block explorer lets anyone view the transaction’s status, inputs, outputs, and confirmation count.

Can a bitcoin transaction be reversed? Once included in a confirmed block, a bitcoin transaction is effectively irreversible. Reversing it would require an attacker to redo the proof-of-work of that block and every subsequent block faster than the honest network continues extending the chain. After six confirmations, this is considered computationally infeasible for any realistic attacker.

How long does a bitcoin transaction take to confirm? The first confirmation arrives roughly 10 minutes after a transaction is included in a mined block, since that is Bitcoin’s target block interval. In practice, time varies: a high fee rate during low congestion can yield a confirmation in under five minutes, while a low fee rate during peak demand can mean hours or longer. Most exchanges and services require three to six confirmations before crediting funds.

What happens if I send bitcoin to the wrong address? Bitcoin transactions are irreversible. If funds are sent to an incorrect address that is owned by someone else, recovery depends entirely on the goodwill of that address’s owner. If the address is invalid or unspent (a “burn” address), the bitcoin becomes permanently unspendable. Always verify recipient addresses carefully before broadcasting.

Why do some transactions have many inputs? A wallet accumulates UTXOs over time from multiple received payments. When spending, the wallet may need to combine several small UTXOs to cover the payment amount. Each additional input adds data to the transaction, increasing its virtual size and therefore its fee at the same fee rate. This is why wallets sometimes consolidate UTXOs during low-fee periods.

What is RBF (Replace-By-Fee)? Replace-By-Fee is an opt-in feature that allows a sender to rebroadcast an unconfirmed transaction with a higher fee, signaling to miners that the new version should replace the old one in the mempool. It is useful for accelerating a stuck transaction when the original fee rate was insufficient for current network demand. Not all wallets support RBF.

What is a block explorer? A block explorer is a publicly accessible web application that allows anyone to search the Bitcoin blockchain by transaction ID, address, or block number. Block explorers display transaction inputs, outputs, fees, confirmation status, and the full chain of spending history for any UTXO — making the ledger transparent to any observer.

Disclaimer

This article is written for educational and research purposes only. It does not constitute financial advice, investment advice, or a recommendation to buy, sell, or hold any cryptocurrency. Cryptocurrency transactions are irreversible and carry technical and financial risks. Readers should conduct their own research and consult qualified professionals before engaging with any digital asset.

Understanding how bitcoin transactions work — from the UTXO model through cryptographic signing, mempool queuing, proof-of-work mining, and block confirmation — reveals a system built on mathematical guarantees rather than institutional trust. Value moves only when valid signatures authorize it, fees compete openly for block space, and each confirmation adds computational proof that makes reversal progressively harder. That architecture, not the price, is what distinguishes Bitcoin as a payment protocol.

Our healing articles are waiting with exactly the words your heart needs in our featured library.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *