Skip to content

Coinbase Transaction

The coinbase transaction is a special, unique transaction that appears as the first transaction in every Bitcoin block. It creates new bitcoins (the block subsidy) and collects all transaction fees from the block, paying the total to the miner or pool that found the block.

Unlike regular Bitcoin transactions that spend existing coins, the coinbase transaction has no real input. Its input field contains arbitrary data (up to 100 bytes) rather than a reference to previous unspent outputs. This is where the block subsidy originates — the coinbase transaction is literally where new bitcoins come into existence.

Think of it as a mint printing fresh currency. Regular transactions are people passing existing bills between each other. The coinbase transaction is the mint itself, creating new bills and handing them to the miner as payment for securing the network.

The coinbase transaction serves several important functions in the mining process:

  • Block subsidy creation: It mints the new bitcoins according to the current halving schedule
  • Fee collection: It collects the difference between inputs and outputs of all other transactions in the block
  • ExtraNonce space: The arbitrary data field in its input provides space for the extranonce, expanding the miner’s search space
  • Identification: Pools often embed their name or identifier in the coinbase data (this is how block explorers identify which pool mined a block)

When a pool constructs a new block template, it builds the coinbase transaction to pay the block reward to the pool’s address. The coinbase input data might contain: the block height (required by BIP34), the pool’s extranonce fields, and a tag like “/MyPool/” for identification. Block explorers display this data, which is how you can look at any block and see which pool mined it.