What a Bitcoin Transaction Contains: Inputs, Outputs, and Change

What a Bitcoin Transaction Contains: Inputs, Outputs, and Change

A
A bitcoin transaction contains inputs and outputs: inputs show source, outputs set recipient and amount, and leftover becomes miner fee and change.

A bitcoin transaction contains two core groups of data: inputs and outputs. Inputs say where the coins are coming from; outputs say where they are going. Around those sit a digital signature, a version number and an optional locktime. There is no “balance” field anywhere.

What’s actually inside the transaction

Bitcoin’s ledger is a stack of transactions, not a table of balances. If you open one, you’ll see the same handful of logical pieces over and over.

ElementWhat it does
VersionTells nodes which set of rule changes applies
InputsReferences to older outputs, each unlocked by a signature from the matching private key
OutputsLocking instructions plus an amount; usually a recipient address, but a change address works the same way
LocktimeOptional time or block height before which the transaction cannot be mined
Miner feeNo dedicated field. It’s the difference between total input value and total output value.

Each input points at an unused earlier output. Bitcoin calls that unspent output a UTXO. Instead of checking people’s balances, nodes check whether every input in a transaction points to a valid, unspent output and whether the signature is good. A bitcoin transaction contains inputs and outputs, and every other field exists to help those two parts get verified.

How a transaction gets assembled

Constructing a payment is closer to sorting coins and writing receipts than to logging into an app.

  1. Gather coins. The wallet scans the UTXOs its keys control and picks enough of them to cover the payment and the miner fee. It might use one output or several.
  2. Write destinations. One output goes to the recipient. If the inputs add up to more than the recipient should get, another output sends the surplus back to you. That output is change.
  3. Sign and broadcast. The private key signs the transaction’s key details. Change an address or an amount and the signature breaks. Only then is the transaction sent to the network and eventually selected by a miner.

Why it doesn’t look like a bank transfer

This is the part that trips people up. Bank transfers change balances. Bitcoin consumes old outputs and creates new ones.

Bank account modelBitcoin UTXO model
Account has a balance, and the bank adjusts itLedger has no balance, just unspent outputs
Identity is an account numberOwnership is the ability to spend an output with a private key
One institution verifies and settlesEvery node independently checks; miners put valid transactions in blocks
One debit, one creditOne transaction can have several inputs and several outputs, including change

Keeping the change is not a wallet quirk, it’s structural. You cannot spend half of a UTXO. You spend the whole thing and then write yourself a new output for the leftover.

Only the sender signs

Receiving bitcoin doesn’t require a signature from the recipient. The signature proves that the person who supplied the inputs owns them; it isn’t a form of acknowledging receipt. That will change later when the recipient spends those coins and has to sign the next transaction.

FAQ

Why doesn’t the blockchain show my balance?

Because there is no balance field. A wallet works out its balance by scanning unspent outputs that can be unlocked by its private keys, then adding up their value. Change wallets, same keys, same number.

What is the change output, exactly?

It’s the leftover value from the chosen inputs after the recipient and fee are deducted. It is written as a fresh output in the same transaction and belongs to the sender.

Can one transaction pay several people at once?

Yes. Outputs are a list, so a transaction can create as many outputs as the fee budget allows. That’s how batch payments and split bills often work on-chain.

Can someone change the amount after I broadcast?

No. The transaction carries a signature that locks the key fields, including recipient scripts and amounts. Any modification makes the signature fail, so nodes bounce the altered version.

Open a block explorer and start with the inputs and outputs. Inputs point back to older transaction IDs; outputs show addresses and amounts. All the other fields are noise. Subtract the sum of outputs from the sum of inputs, and the leftover is the miner fee.

This article was originally published by Bit.Fan. For more cryptocurrency news and market insights, visit www.bit.fan.
3000

Disclaimer:

The market information, project data, and third-party content displayed on this platform are for industry information sharing only and do not constitute any form of investment advice or return commitment.

Cryptocurrency trading carries high risks. Users should fully assess their risk tolerance and make independent decisions. All profits, losses, and legal responsibilities are borne by the users themselves.