Bitcoin Ordinals under the hood. How Inscriptions and BRC20 workIntroduction.
One of the most talked about narratives in recent weeks is tokens on the Bitcoin blockchain. It is so popular simply because it has already given 50–100+ X’s to those who dipped into the trend early. $ORDI, $SATS are the most popular examples. Those who mined such tokens for free at low gas e.g. spent 10–12$ per min — now have 7000$ ($TRAC).
While thousands of people continue to fly into this trend, not everyone has figured out what is meant by these tokens, transfers and more terms. So with this article I want to break down and give an understanding of the basic concept and technology, their pros and cons(besides the FOMO from such X’s).
The goal is to explain the essence of ordinals and inscriptions, not to be 100% accurate on the technical side, so feedback and questions are welcome in the comments:)
Basics.
A Satoshi (abbreviated as “sats”) is the smallest unit of bitcoin. Each bitcoin consists of 100 million satoshis. New sats are created when bitcoin blocks are mined. A miner receives new sats as a reward for mining.
Ordinals
What are Ordinals and why are they needed.
A special standard was invented — Ordinals Protocol. Its purpose is to assign each satoshi an ordinal number corresponding to the order in which it was created by miners (1, 2, 3, 4, …). Initially, satoshis have no order in the bitcoin network, so you have to invent one.
Let’s look at an example of why satoshis have no order numbers in our view.
If I receive 1 sat as a reward for a block, and there were 10 sats before I received that reward, my sat is obviously numbered 11.
Similarly, if I receive not 1 but 10 sats as a reward, it is clear that I own 11–20 sats. So far so good. But what happens if I decide to send some bitcoin(i.e. some amount of satoshis) to someone ?
If I own sats #11–20 and send you 1 satoshi, did I send you satoshi #11, #20, #15 or some other? The bitcoin blockchain itself doesn’t know the answer to this question and it doesn’t care which satoshi to send, hence it doesn’t determine the order. Instead, we need a new protocol that will come up with the answer, and that’s the Ordinals standard.
How Ordinals work
The Ordinals protocol solves the transfer issue described above in a fairly simple way.It sets a certain rule that you always send the lowest numbered sats when transferring.For example, if I have sats #11–20 and send you 1 satoshi, then according to the Ordinals protocol, I send you #11.
This way it becomes possible to number every satoshi in the bitcoin network. In addition, we can choose which satoshis we want to transfer. If I want to send you #12, I can transfer 1 satoshi to another wallet and then 1 satoshi to you. The first satoshi will be #11 and the second will be #12.
Of course, this should only work if everyone treats this transfer of sats equally. In theory, any other new protocol could say that satoshis are transferred first to the one with the highest order number (#20 in our example) and this would be equally correct, but incompatible with the Ordinals standard. Roughly speaking, the rule of firsts works here, and the rule of consensus is that everyone has agreed to keep this order.
There is an important technological thing to note here: creating “your own rules” in this way is not necessarily a bad thing for the network, as there is no fundamental truth in the bitcoin network about the ordering of its smallest unit.
If you don’t believe me or don’t understand, I don’t have time to try to change your mind, sorry.
Satoshi Nakamoto
How to use Ordinals
As we’ve already established above, you always transfer your lowest numbered satoshis first. But to really determine the ordinal number of satoshis, you need to apply this rule to every bitcoin transaction, imagine the amount of work that needs to be done, considering that bitcoin was launched as early as 2009.
In practice, we need a service that indexes the bitcoin blockchain, performs the necessary calculations and tracks the movement of these satoshis. Such a service is called an “indexer”.
The well-known Etherscan can with a stretch be called an indexer for the Ethereum network, only without ordering the ETH coin itself, as it tracks the balances of ETH and other ERC-20 tokens.
Basic indexers exist for Ordinals, and there will be more convenient new ones if this narrative develops.
And there’s the all-too-familiar uselessness of the NFT pfp, which is now only stored actually on the blockchain, not the website.
What are Inscriptions?
At their core, they are simply items that you can use to “store” any data on the bitcoin network. They are based on the idea of using the blockchain as a data store.
It is a very old idea — in fact it is as old as the very first Bitcoin block, into which Satoshi embedded his famous message pointing to the true world crisis of 2008:
The Times 03/Jan/2009 Chancellor on brink of second bailout for banks.
Why might we need to store different data on a blockchain? The answer lies in the immutability of the data — if we need to keep something “forever”, make it censorship-resistant, prove the validity of a point in time (timestamps), etc. This has been known for many years.
This has been known for years.
Two things are new:
1- Taproot bitcoin update that made it possible to profitably add much more data than was possible before: photos, gifs, audio, video, etc.
2. The Ordinals standard, which inherently provides the foundation for the bitcoin network to be able to assign ownership of some data(so that the code guarantees your ownership of that data) .
How do Inscriptions work?
We can embed data in any transaction we send in bitcoin. If you embed a picture in a random transaction, it will be available to anyone for the lifetime of bitcoin, but literally no one will own it.
Inscriptions solved this problem by embedding data into satoshis (remember, this is 1/100mnth of a bitcoin, the smallest unit in the bitcoin network) . Once this is done, it can be said that the owner of that satoshi (ownership of satoshi was dealt with above in the first part about Ordinals) is the owner of the data.
However, neither in bitcoin nor in the Ordinals protocol there is no concept of “embedding” anything in a satoshi. This is why Inscriptions requires a new protocol.
Inscriptions created a model for “inscribing”(inscribe — therefore inscribe; the process of inscribing is inscribe) data into satoshi. This data is defined within a transaction in a special way:
1. To find the inscribed data in a satoshi, you have to look through all transactions that have ever involved a particular satoshi. This is not possible with bitcoin, but it is possible with bitcoin + Ordinals. this is why Inscriptions cannot exist and depend on the Ordinals standard.
2. Once we have found a transaction that has embedded data in a certain format(e.g. simple JSON), we realize that it is data “written” in satoshi.
I would use here a simplified but very clear analogy to understand: you work in a t-shirt factory and each t-shirt has its own article(serial number) . You, standing behind the assembly line, draw something on some of these t-shirts with a marker. By doing so you inscribe your data on them, you can always tell from the articles and fingerprints that they belong to you:)
The actual writing of the data into the satoshi itself uses the same approach: we send the satoshi to ourselves by embedding the data in a transaction. Since this satoshi is identifiable (it is numbered), we can trace its history back to the transaction in which the data was embedded in it, thus allowing us to determine that this satoshi contains such and such data.
What is important to realize here is that the data is not actually inscribed in the satoshi. Only those who recognize the Ordinals protocol and Inscriptions itself can claim that this is the case. In fact, the data is actually in the bitcoin blockchain, just literally “somewhere”, with no attachment to the satoshi. This is a technical fact that even opponents of Ordinals and Inscriptions recognize.
The same debate issue as Ordinal repeats itself here. We have yet another protocol that cannot be explained by some previous technical basis. Again, there is an opportunity for competing but equally valid protocols. For example, which data record in a satoshi would be original: the one that was the very first, or the one that was the most recent? It is generally accepted that the original is the first inscribe. This is also true for BRC20 tokens, I’ll show you an example below.
-Summarizing on Inscriptions, if everyone follows the same protocol, and there are public indexers that correctly track all data and transactions, then all participants can agree on who owns what content without additional consensus or trust mechanisms.
BRC20 tokens
That final piece that money is made on.
What is BRC-20?
BRC20 makes it possible for tokens to appear on the bitcoin blockchain other than BTC itself.
The name BRC-20 is a reference to ERC-20, the standard for interchangeable tokens in Ethereum. ERC-20 stores the balance of each token directly on the onchain (on the network), simply updating that balance of it each time that token is transferred. Transferring such an ERC-20 standard to bitcoin would mean the same thing.
However, the basic idea behind Inscriptions is that they are immutable. We can’t have one inscription with a balance of 100 X tokens that we own and then just update that inscription when we buy more tokens (as happens in Ethereum) .
What BRC-20 inherently does is it allows users to simulate a balance update using multiple inscriptions.
It does this by recording each transaction affecting the balance and calculating the final result offchain(not on the bitcoin network itself) . Since the history of changes affecting the balance will never change(they are already in the blockchain) , they can be represented using inscriptions. The following will become clear with specific examples.
1. To create a token in a simplified version of BRC-20, I would make an inscribe with roughly the following content:
{
"protocol": "brc-20",
"operation": "deploy",
"symbol": "ABM_Token",
"maxSupply": "21000000",
"perOrdinalMintLimit": "1000"
}
To the average person, it’s just a JSON file, plain text that can mean anything.
But for the BRC-20 standard, it means that we have created a new token called “ABM_Token” with a maximum sapple of 21 million. The operation line means literally what we are doing, in this case creating a token(deploy). The last line means that we can ABM_Token 1000 tokens at a time.
2. A mint can look like this:
{
"protocol": "brc-20",
"operation": "mint",
"symbol": "ABM_Token",
"amount": "1000"
}
We just mined ourselves 1000 ABM_Token tokens, and now the blockchain is recording that data, which also means we own it.
Let’s recall for a moment what we mentioned above in the Inscriptions part about BRC-20 tokens, and the importance of the order of inscribd for them. Here in our example, a total of 21mn tokens can be mined. But if due to the high popularity of a token (which is happening on 12/16/23) many people are miniting at the same time, and there are more tokens than available tokens, then those who are the first to take them for themselves will be considered the original owners. And those who make inscrabs later will get the same JSONs on their wallet, with the same inscriptions, but they won’t mean anything. You can make infinitely many such inscriptions until you run out of money for commission, but no BRC-20 token indexers will show you that you own at least one token, because you mined after the total sapplay of 21mn was dealt by others.
3. To send these tokens to someone else, including selling them on some marketplace, we inscribe the transfer and the desired amount in this way:
{
"protocol": "brc-20",
"operation": "transfer",
"symbol": "ABM_Token",
"amount": "500"
}
4- And now we transfer the embedded satoshis to another address, for example to a friend.
Now we have 500 #ABM_Token tokens and a friend has 500. The question is where these balances exist and where they are displayed, otherwise how do we realize that we have “something”.
Just like with Inscriptions, we need a special indexer to find all these BRC-20 inscribed inscriptions and calculate the balances itself. Balances are stored in bitcoin in the sense that they can be calculated from transactions, directly using the bitcoin network. But, as mentioned above, to do this, everyone must interpret these transactions in the same way (order of inscriptions, value of the tokens themselves, etc.)
Conclusion + Lifehacks + next 100x gems on DYOR
At this point, I don’t think anyone has a clear understanding of where this trend, which has gained wild momentum, is going to go. Out of 100% of the entire ecosystem, 95% are trivial memcoins, hyped by the Chinese community and fueled by speculation alone. Ixes are nonetheless obvious, only the recent $BONK HYIP can compete with this narrative.
As on any HYIP, the trend has moved to other networks, which adds absurdity to the narrative, inscriptions on Arbitrum, BNB, Avalanche, even on Tron the capitalization of inscript boxes is several million dollars. For networks, this is a definite burden and unprofitable to use, such commissions have not been seen in bitcoin for a long time. But none of the operators of mining pools are interested in stopping the trend, because they earn almost more on commissions than on the reward per block.
But it’s important to note that in the huge pile of useless memcoins, there are products with fundamental groundwork. And they are at least worth paying attention to if you plan to stay in this narrative for a long time. Not a financial advice, do your own research: $TRAC ecosystem could be the basis of new data (=Chainlink for Ethereum), $GHSY has a working understandable cross bridge product, $TRVS is trying into secure vaults. Even emerging questionable offshoots — experiments like CYBORD can continue to fuel this hype, because pumpamentals are often much stronger than fundamentals.
In the end, it is always easier and clearer to evaluate the next trends by understanding what’s under the hood. Dive into crypto wisely!
Basic services + tools:
- GeniiData. A convenient indexer and service for tracking your positions
- Unisat. The most popular wallet for BTC+Ordinals. There is also a marketplace with large volumes
- Ordinals Wallet. Wallet + marketplace
- Magic Eden. Top1 marketplace, more for NFT.
- OKLink. Inscriptions Explorer by OKX. Lifehack: in the Inscriptions List section it is convenient to track mint dynamics on tokens that are mined by less than 50%
- BRC-20.io. Explorer for BRC-20 tokens, also has useful features
- BRC-20 Alerts. Telegram channel with notifications about active BRC-20 minte (more than 50% of sapplay).
- Ordi Chat. Chat with not bad calls and opinions.
- -MagicEden. A multichain marketplace where the bulk of the volume is image trading.
- Ordinals рынок на бирже OKX. Most often used for brc 20 trading. Volumes on OKX are growing at a steady pace, which indicates the popularity of ordinals among the Asian sector of the crypto community.
- Xverse. Separate address for BTC, for ordinals and for STX. You need to be careful when sending this or that asset. Shows the balance in dollars. It is convenient to watch the history.
Platforms for creating your own ordinals.
- Gamma with image compression function.
- OrdinalsBot. Image Compression. It is possible to mine on rare satoshas. Minus — high commissions.
General useful information can be found on various services.
- Dune. General information on the state of the market for ordinals.
- Best in Slot. Gives aggregated information on all ordinals and brc-20.
- Mempool Space to understand the current fees and speed of transaction confirmation.
- GeniiData more detailed information on ordinals. Here you can track the success of your mint.
You can find the original article as well as a lot of other interesting information here.