<blockquote>
  <p>My understanding is that OP_RETURN was first introduced in v0.9.0 </p>
</blockquote>

<p>No, it was just changed to be standard in 0.9.0. If a transaction is nonstandard, miners running Bitcoin Core with default settings will not mine the transaction. </p>

<p>OP_RETURN has been around since the beginning, in 0.1.0. This was the fragment that implemented OP_RETURN in 0.1.0:</p>

<pre><code>        case OP_RETURN:
        {
            pc = pend;
        }
        break;
</code></pre>

<p>Back then, OP_RETURN didn't necessarily cause a script to fail. You could also use it in the scriptSig of a transaction, meaning that you could steal anyone's Bitcoins by pushing a non-zero value and calling OP_RETURN. Ah, those were the days.</p>

CC BY-SA 3.0
2016-12-29T19:53:55.163Z
Nice. How did you get hold of 0.1.0? Bitcoin github only goes back to 0.1.5? https://github.com/bitcoin/bitcoin/releases?after=v0.2.7
cloudnthings
CC BY-SA 3.0
2016-12-29T20:08:20.180Z
It also sounds like there was no specific size for OP_RETURN defined back in those days?
cloudnthings
CC BY-SA 3.0
2016-12-29T21:35:38.937Z
@cloudnthings http://bitcoin.stackexchange.com/questions/21964/where-can-i-access-the-original-satoshi-written-bitcoin-code
Nick ODell
CC BY-SA 3.0
2016-12-29T21:44:10.810Z
@cloudnthings Well, there's a max block size of 32 MB, so there's definitely a 32 MB limit.
Nick ODell
CC BY-SA 3.0
2016-12-31T00:48:51.547Z
Hmm, isn't the max block size 1Mb in Core and 2Mb in classic? Where did 32 Mb come from?
cloudnthings
CC BY-SA 3.0
2016-12-31T00:59:46.460Z
@cloudnthings It's 1MB *now*, but back then it was 32 MB.
Nick ODell
CC BY-SA 3.0
2016-12-29T00:21:02.913Z
2016-12-29T01:09:22.583Z
2016-12-29T01:09:22.583Z
Nick ODell
<p>My understanding is that OP_RETURN was first introduced in v0.9.0 (<a href="https://bitcoin.org/en/release/v0.9.0" rel="nofollow noreferrer">https://bitcoin.org/en/release/v0.9.0</a>).</p>

<p>This link (<a href="https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2014-November/006917.html" rel="nofollow noreferrer">https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2014-November/006917.html</a>) mentions "initially supposed to be 80 bytes, but got reduced to 40".</p>

<p>This link (<a href="https://github.com/bitcoin/bitcoin/pull/5286" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/pull/5286</a>) says: "The maximum size for OP_RETURN outputs used to be 80 bytes, then got changed to 40 bytes to be on the safe side". </p>

<p>Pull request <a href="https://github.com/bitcoin/bitcoin/pull/3737" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/pull/3737</a> talks about reducing it to 40 bytes. Was it ever in the code at 80 bytes prior? </p>

<op-return>
What was the very initial value of OP_RETURN?
cloudnthings
# What was the very initial value of OP_RETURN?

(Asked by: username_0 on 2016-12-28)

My understanding is that OP\_RETURN was first introduced in v0.9.0 (<https://bitcoin.org/en/release/v0.9.0>).

This link (<https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2014-November/006917.html>) mentions "initially supposed to be 80 bytes, but got reduced to 40".

This link (<https://github.com/bitcoin/bitcoin/pull/5286>) says: "The maximum size for OP\_RETURN outputs used to be 80 bytes, then got changed to 40 bytes to be on the safe side".

Pull request <https://github.com/bitcoin/bitcoin/pull/3737> talks about reducing it to 40 bytes. Was it ever in the code at 80 bytes prior?

**Tags:** op-return


---

## 1 answers

### Answer by username_1 on 2016-12-29. Score: 4 | Accepted answer

> My understanding is that OP\_RETURN was first introduced in v0.9.0

No, it was just changed to be standard in 0.9.0. If a transaction is nonstandard, miners running Bitcoin Core with default settings will not mine the transaction.

OP\_RETURN has been around since the beginning, in 0.1.0. This was the fragment that implemented OP\_RETURN in 0.1.0:

```
        case OP_RETURN:
        {
            pc = pend;
        }
        break;

```

Back then, OP\_RETURN didn't necessarily cause a script to fail. You could also use it in the scriptSig of a transaction, meaning that you could steal anyone's Bitcoins by pushing a non-zero value and calling OP\_RETURN. Ah, those were the days.

> **Comments:**
> **username_0**: Nice. How did you get hold of 0.1.0? Bitcoin github only goes back to 0.1.5? https://github.com/bitcoin/bitcoin/releases?after=v0.2.7  
> **username_0**: It also sounds like there was no specific size for OP_RETURN defined back in those days?  
> **username_1**: @username_0 http://bitcoin.stackexchange.com/questions/21964/where-can-i-access-the-original-satoshi-written-bitcoin-code  
> **username_1**: @username_0 Well, there's a max block size of 32 MB, so there's definitely a 32 MB limit.  
> **username_0**: Hmm, isn't the max block size 1Mb in Core and 2Mb in classic? Where did 32 Mb come from?  
> **username_1**: @username_0 It's 1MB *now*, but back then it was 32 MB.  

---

