Sending a Blockchain Transaction

Imagine a town where every time someone trades a rare book, the trade must be recorded in a giant ledger that everyone in town can see and has a copy of. Each day, all trades are written into a new page of the ledger. Once a page is filled, it is sealed with a unique lock that links it to the previous page, so no one can change any trade without breaking the lock on every page after it.

Before a trade is officially recorded, a group of trusted librarians check that the trade is real and that the books actually exist. Once verified, the trade becomes part of the permanent, unchangeable record.

This is essentially how a blockchain works. Every transaction, whether it involves transferring money, digital assets, or other valuable information, is grouped into a block, cryptographically linked to the previous one, and verified by a decentralized network of computers, known as nodes. Once added, each transaction is permanent, transparent, and tamper-proof, creating a secure, distributed ledger that anyone in the network can trust.

Step 1: Initiation and Creation

The process starts with a wallet, either software like MetaMask or hardware like Ledger. The wallet constructs the transaction by defining inputs (funds you control), outputs (recipient addresses and amounts), transaction fees, and optional data such as smart contract instructions in Ethereum. The wallet calculates the totals to ensure inputs cover outputs plus fees, returning any leftover funds as change. The raw transaction is then serialized into a format the blockchain network can process, typically a hexadecimal string of bytes.

Step 2: Signing

To confirm ownership, the wallet uses the sender’s private key to generate a digital signature using cryptographic algorithms like ECDSA in Bitcoin. This signature locks the transaction data, preventing tampering. Public keys derived from private keys allow nodes to verify the transaction without revealing sensitive information. Once signed, the transaction is immutable unless re-signed with the correct private key.

Step 3: Broadcasting

The signed transaction is then broadcast to the network. It connects to one or more nodes, which relay it using peer-to-peer protocols to other nodes. Each node forwards the transaction to its peers, rapidly spreading it across the network. While propagation is usually fast, some transactions may require rebroadcasting if they fail to propagate to all nodes.

Step 4: Validation and Mempool Entry

Nodes validate transactions by checking the signature, confirming that inputs haven’t been spent elsewhere, verifying sufficient balance, and ensuring proper transaction format. Valid transactions enter the node’s memory pool (mempool), a temporary queue sorted by transaction fees. Transactions offering higher fees are prioritized for inclusion in the next block, while low-fee transactions may experience delays or be evicted during network congestion.

Step 5: Block Inclusion (Mining or Staking)

Miners in proof-of-work (PoW) systems or validators in proof-of-stake (PoS) systems select transactions from the mempool to include in a new block. In PoW blockchains like Bitcoin, miners solve cryptographic puzzles, hashing the block header repeatedly to meet a difficulty target. This process consumes significant computational power and secures the network. In PoS networks like Ethereum, validators are selected based on staked coins and propose blocks without the energy-intensive hashing process.

Step 6: Block Propagation and Chain Extension

Once a block is created, it is broadcast to the network. Nodes verify its validity, checking the included transactions, proof-of-work or stake, and consistency with the existing blockchain. If accepted, the block is appended to each node’s copy of the blockchain, extending the ledger. At this point, the transaction is considered confirmed, though final settlement depends on subsequent blocks. Forks may occur temporarily if competing blocks are found.

Step 7: Confirmations and Final Settlement

A transaction gains finality as new blocks are added on top. In Bitcoin, six confirmations (about one hour) are standard before a transaction is considered irreversible. In Ethereum’s PoS system, finality is achieved faster through validator attestations and slashing mechanisms for misbehavior. Once sufficiently confirmed, the transaction cannot be reversed, and its outputs can be used in future transactions.

Jefferson Wachira is a writer at Africa Digest News, specializing in banking and finance trends, and their impact on African economies.