<p><a href="http://www.righto.com/2014/02/bitcoin-mining-hard-way-algorithms.html" rel="nofollow">Richard Kiss covered this extremely well in his blog.</a></p>

<p>There's several ways to go about embedding data in the Blockchain:</p>

<ol>
<li>OP_RETURN method embeds data to a single output and the script following the OP_CODE is hex encoded ASCII text</li>
<li>Use pubkeyScript fields to have ASCII (in hex) which can be concatenated across all the outputs (the addresses as hash160 are unspendable)</li>
<li>Coinbase field can hold hex data, such as the Genesis Block</li>
<li><a href="http://blockchain.info" rel="nofollow">BCI</a> metadata notes which are not actually included in the Blockchain, but are visible on BCI</li>
</ol>

<p>The first method is most common and accepted, allowing for 40 bytes of text.</p>

CC BY-SA 3.0
2015-01-25T04:32:06.400Z
2015-01-25T04:32:06.400Z
Wizard Of Ozzie
<p>Someone recently suggested that scripts could get embedded inside the blockchain and executed independently by designated machines. What exactly can get stored inside the blockchain, and what are the limits? For instance, if someone uses Bitcoin to purchase electronics from an online site, could the review get embedded inside the transaction and be available for all to view (as opposed to controlled by the seller site)?</p>

<blockchain>
How do text, scripts, and other information get embedded inside the blockchain?
Crashalot
# How do text, scripts, and other information get embedded inside the blockchain?

(Asked by: username_0 on 2015-01-20)

Someone recently suggested that scripts could get embedded inside the blockchain and executed independently by designated machines. What exactly can get stored inside the blockchain, and what are the limits? For instance, if someone uses Bitcoin to purchase electronics from an online site, could the review get embedded inside the transaction and be available for all to view (as opposed to controlled by the seller site)?

**Tags:** blockchain


---

## 1 answers

### Answer by username_1 on 2015-01-25. Score: 1

[Richard Kiss covered this extremely well in his blog.](http://www.righto.com/2014/02/bitcoin-mining-hard-way-algorithms.html)

There's several ways to go about embedding data in the Blockchain:

1. OP\_RETURN method embeds data to a single output and the script following the OP\_CODE is hex encoded ASCII text
2. Use pubkeyScript fields to have ASCII (in hex) which can be concatenated across all the outputs (the addresses as hash160 are unspendable)
3. Coinbase field can hold hex data, such as the Genesis Block
4. [BCI](http://blockchain.info) metadata notes which are not actually included in the Blockchain, but are visible on BCI

The first method is most common and accepted, allowing for 40 bytes of text.


---

