Skip to content

Inputs & Outputs

What Are Inputs & Outputs?

What Are Inputs & Outputs?

Every bitcoin transaction is made up of inputs & outputs. Inputs are bitcoin being sent and outputs are bitcoin being received.

Until bitcoin is sent from an address, it remains at that address as a specific kind of output known as an unspent transaction output (UTXO).

Inputs

Inputs are bitcoin that are being sent in a transaction. When a transaction is created, the sender must select which UTXOs to use to create the transaction. These UTXOs will be the bitcoin that gets sent to the receiving address or addresses.

Inputs are UTXOs that are in the process of being spent to generate the transaction outputs.

Outputs

Outputs are the bitcoin being received in a transaction. When a transaction is created, outputs are new UTXOS that are being generated by the transaction inputs. Every address in every bitcoin transaction, including coinbase transactions, receives an output.

Whenever an address has a bitcoin balance, what that address actually has is a specific type of output known as an unspent transaction output.

Unspent Transaction Outputs (UTXO)

Unspent Transaction Output (UTXO) is a term that refers to a particular “piece” or fraction of a bitcoin that has not been spent yet. A single UTXO can hold any amount of bitcoin such as a fraction of a bitcoin or multiple bitcoin. UTXOs can be combined or split into multiple UTXOs to generate payments of any size. When this happens, the input UTXOs are destroyed to generate the output UTXOs.

In a standard bitcoin transaction, each input is a UTXO being destroyed and each output is a new UTXO being generated.

Input & Output Combinations

To better understand how inputs and outputs work, here are all of the different combinations that exist.

Newly Generated Coins. 1 Output.

The first transaction in every block of bitcoin is a special kind of transaction called a Coinbase transaction. These types of transactions are how new bitcoin is generated so the input of these transactions will always be different than a standard bitcoin transaction.

Note: It’s important to not confuse a Coinbase transaction with the San Francisco-based exchange named Coinbase.

Here is a coinbase transaction with newly generated bitcoin as the input and 1 output.

Since coinbase transactions are a unique type of transaction, the input is not generated from any pre-existing UTXOs. The input is brand new coins so this transaction destroyed 0 UTXOs and generated 1 UTXO.

1 Input. 1 Output.

A transaction with 1 input and 1 output means that all of the bitcoin at the sending address is transferred to the receiving address and there is no change.

This transaction has 1 input and 1 output, which means that 1 UTXO was destroyed to create 1 new UTXO.

1 Input and 1 Output

Notice how with only 1 input and 1 output, the entire balance was transferred from the sending address to the receiving address minus the miner fee.

1 Input. 2 Outputs.

A transaction with 1 input and 2 outputs is when the amount of bitcoin from 1 sending address is greater than what is being sent to the receiving address. To deal with the difference, the remainder is sent to a second address owned by the sender commonly known as a change address.

This transaction has 1 input and 2 outputs, which means that 1 UTXO was destroyed to create 2 new UTXOs.

1 Input and 2 Outputs

1 Input. Multiple Outputs.

Multiple Outputs, also known as batched outputs, are used to send bitcoin to multiple receiving addresses in a single transaction.

Batched output transactions are helping bitcoin to scale by maximizing the use of limited block space and lowering the cost of sending bitcoin to multiple addresses.

This transaction has 1 input and 14 outputs, which means that 1 UTXO was destroyed to create 14 new UTXOs.

1 Input To Multiple Outputs

Notice how the sending address begins with “bc1q” and only one of the receiving addresses begins with “bc1q”? It’s likely that both of these addresses belong to the sender. After paying 13 different addresses, the remainder of the input was then sent to an address owned by the sender. Again, this is the sender’s change address.

Multiple Inputs. 1 Output.

Single Output transactions only have a single output but can use 1 or more inputs. Multiple Inputs are used to send bitcoin when you need to combine the balance of multiple sending addresses into 1 receiving address.

This transaction has 5 inputs and 1 output, which means that 5 UTXOs were destroyed to create 1 new UTXO.

Multiple Outputs To 1 Output

Notice how there is only one single address that received bitcoin? This could be a sender consolidating bitcoin from 5 addresses into 1 single address or even making a payment to someone.

Multiple Inputs. Multiple Outputs.

Some transactions have both multiple inputs and multiple outputs. These types of transactions are often used to consolidate smaller address balances to make payments to multiple addresses.

This transaction has 16 inputs and 4 outputs, which means that 16 UTXOs were destroyed to create 4 new UTXOs.

Multiple Inputs and Multiple Outputs

If you ever make a withdrawal from a bitcoin exchange, it will likely be part of a transaction with multiple inputs and multiple outputs.

Fully understanding how inputs, outputs, and UTXOs all work takes time so don’t get too worried about all of the technical details of how these work if you’re new to bitcoin. What’s important to understand is that when you spend bitcoin, you are combining and splitting unique “pieces” of bitcoin in order to send bitcoin from one address to another.