# What is a Bitcoin transaction?

A Bitcoin transaction spends existing coins (inputs) and locks new ones to their next owners (outputs). See how it works with a real example.

Canonical page: https://mybitcoinexplorer.com/learn/what-is-a-bitcoin-transaction
Topic: Transactions
Published: 2026-10-29
Updated: 2026-10-30


## Spend old coins, create new ones
A Bitcoin transaction is a small data message that says: "take these existing pieces of bitcoin, and create these new pieces, locked to these new owners".

- The pieces being spent are **[inputs](https://mybitcoinexplorer.com/learn/transaction-inputs)**.
- The new pieces being created are **[outputs](https://mybitcoinexplorer.com/learn/transaction-outputs)**.
- Whatever value goes in but doesn't come out is the **[fee](https://mybitcoinexplorer.com/learn/bitcoin-transaction-fees)**, paid to the miner.

> Diagram: Two coins go in, two new coins come out, and the difference is the fee — 0.5,0.3 → 0.6,0.199

## Like paying with notes
If you pay for a 6-euro coffee with a 10-euro note, you get 4 euros change. Bitcoin works the same way: you can't tear a coin in half. You spend whole coins and send the extra back to yourself as a [change output](https://mybitcoinexplorer.com/learn/change-outputs).

## What's inside
| Part | What it does |
|---|---|
| Inputs | Point to earlier outputs being spent, with proof (a [signature](https://mybitcoinexplorer.com/learn/digital-signatures)) that you may spend them |
| Outputs | Amount in sats plus a lock ([script](https://mybitcoinexplorer.com/learn/bitcoin-script)) saying who can spend it next |
| Version and [locktime](https://mybitcoinexplorer.com/learn/locktime-and-sequence) | Rules about how and when it can be confirmed |

### Worked example: The pizza transaction
On 22 May 2010, the famous [pizza transaction](/tx/a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d?block=00000000152340ca42227603908689183edc47355204e7aca59383b0aaac1fd8) spent **131 inputs** into **one output** of 10,000 BTC, paying a 0.99 BTC fee. Open it to see every input listed.



## Reading a transaction on MyBitcoinExplorer
Open any transaction, for example from the [latest blocks](/blocks), and you'll see:
1. **Inputs on the left:** the earlier outputs being spent, with their amounts.
1. **Outputs on the right:** the new amounts and the addresses they're locked to.
1. **Fee:** the difference between the two totals.
1. **Status:** waiting in the mempool, or the block it confirmed in.

## What a transaction can't do
- It can't spend part of an input: whole outputs are always consumed.
- It can't be edited after broadcast, only replaced. See [Replace-by-fee (RBF)](https://mybitcoinexplorer.com/learn/replace-by-fee-rbf).
- It can't say who the people are: only scripts and amounts are recorded.


## Key takeaways

- A transaction spends existing outputs (inputs) and creates new outputs.
- Inputs minus outputs equals the fee.
- Change goes back to the sender as a new output.

## Common questions

### Does a transaction move coins from one address to another?

Not exactly. It destroys old outputs and creates new ones. Addresses are just a convenient way to describe who can spend the new outputs.

### How big is a typical transaction?

A simple one-input, two-output payment is roughly 140 to 225 virtual bytes, depending on address type.

### How long does a Bitcoin transaction take?

It reaches the network in seconds and usually confirms in the next few blocks, about 10 to 30 minutes, depending on the fee rate you pay.

### Can I send bitcoin without a transaction fee?

Almost all nodes require a small minimum fee to relay a transaction, so in practice a fee is needed.

## Related lessons

- [UTXOs: how Bitcoin balances really work](https://mybitcoinexplorer.com/learn/understanding-utxos)
- [Transaction inputs](https://mybitcoinexplorer.com/learn/transaction-inputs)
- [Transaction outputs](https://mybitcoinexplorer.com/learn/transaction-outputs)
- [Change outputs](https://mybitcoinexplorer.com/learn/change-outputs)
