<p>The maximum is 100 bytes and is checked and defined here: <a href="https://github.com/bitcoin/bitcoin/blob/master/src/consensus/tx_verify.cpp#L195" rel="noreferrer">https://github.com/bitcoin/bitcoin/blob/master/src/consensus/tx_verify.cpp#L195</a></p>

CC BY-SA 4.0
2023-12-07T22:14:03.583Z
The check was moved a few years ago, this link to v26 should be stable: https://github.com/bitcoin/bitcoin/blob/v26.0/src/consensus/tx_check.cpp#L46-L49
Sjors Provoost
CC BY-SA 4.0
2023-12-07T22:50:44.710Z
Fwiw the check has been present since v0.1.0 (see "coinbase script size" in main.h)
Sjors Provoost
CC BY-SA 4.0
2018-11-09T23:25:57.270Z
2018-11-09T23:25:57.270Z
Ava Chow
<p>Since the <code>scriptSig</code> of the coinbase transaction of a block can contain arbitrary data, what is the maximum number of bytes it can contain? I've seen various mentions of a limit around 100 bytes, but can't find that defined anywhere.</p>

<bitcoin-core><coinbase-transaction><input-script>
What is the maximum number of bytes the coinbase scriptSig (coinbaseaux) can hold?
JBaczuk
# What is the maximum number of bytes the coinbase scriptSig (coinbaseaux) can hold?

(Asked by: username_0 on 2018-11-09)

Since the `scriptSig` of the coinbase transaction of a block can contain arbitrary data, what is the maximum number of bytes it can contain? I've seen various mentions of a limit around 100 bytes, but can't find that defined anywhere.

**Tags:** bitcoin-core, coinbase-transaction, input-script


---

## 1 answers

### Answer by username_1 on 2018-11-09. Score: 5 | Accepted answer

The maximum is 100 bytes and is checked and defined here: <https://github.com/bitcoin/bitcoin/blob/master/src/consensus/tx_verify.cpp#L195>

> **Comments:**
> **username_2**: The check was moved a few years ago, this link to v26 should be stable: https://github.com/bitcoin/bitcoin/blob/v26.0/src/consensus/tx_check.cpp#L46-L49  
> **username_2**: Fwiw the check has been present since v0.1.0 (see "coinbase script size" in main.h)  

---

