39

If I understand it right, a stale block is a block for which an earlier confirmation has been found and was accepted by majority of people. This block is considered invalid and is later never used.

But what is a orphaned block. How is it created? How is it verified that it is orphaned and what is done to the orphaned block?

1
  • Whether or not it has been accepted by a majority is irrelevant to the definition. May 1, 2020 at 10:22

4 Answers 4

29

Stale blocks:

At any second, a block may be "solved." This means that everyone else in the world working on that block must stop, and restart their work. Continuing to work after that point is known as working on a "stale block" because it is old data, and old transactions.

My understanding is the term stale is much more commonly applied to shares when mining in a pool, so you're more likely to hear about stale shares than stale blocks. In this case, the pool probably wouldn't even bother checking whether the share actually solved a block or not.

Orphaned blocks:

Detached or Orphaned blocks are valid blocks which are not part of the main chain. They can occur naturally when two miners produce blocks at similar times or they can be caused by an attacker (with enough hashing power) attempting to reverse transactions.

My own understanding is that orphaned blocks are initially accepted by the majority of the network, but are later rejected when proof of a longer blockchain is received that doesn't include that particular block.

This means that a user could see a transaction as having one confirmation and then, if a longer blockchain was received that didn't include the transaction, it could change back to 0 confirmations.

1
  • As Pieter wrote in his answer, what you are calling an "orphan block" is an extinct block that may contain "orphaned transactions". Actual orphan blocks are blocks that were received by a node before the node received the parent block.
    – Murch
    May 1, 2020 at 0:58
53

There are several definitions with overlapping meanings.

The first is perhaps best called extinct blocks. These are blocks that were produced by building on a block that is no longer the active tip of the chain. Some nodes may have considered it to be the best block at some point, but they switched to another chain which does not contain the relevant block anymore. They are valid, verified, and their ancestry up to the genesis block is fully known - they're just not currently 'active'. They are sometimes called stale blocks (typically in the context of mining software realizing it built on old data) or orphan blocks. The latter name originates from the fact that payouts from extinct blocks are denoted as "orphaned" in the reference client (referring to the fact that their coinbase transactions are now orphaned).

However, there also exist real orphan blocks, with orphan in its original meaning of "having no parent". These are blocks received by a node that does not have its entire ancestry (yet) and thus cannot be validated. Nodes keep such blocks in memory, while asking their peers to fill in the gap of their history. The client does not show these, so when people talk about orphan blocks, they are most likely referring to extinct blocks. Note that since Bitcoin Core v0.10, there are no such orphan blocks anymore, due to a significant change in the download mechanism.

Terminology is confusing here :)

4
  • 1
    Nice explanation Pieter, could you please elaborate on details of current download mechanism that Bitcoin Core uses? I wonder how it solves orphan block problem.
    – eugenekr
    Mar 19, 2018 at 16:46
  • 7
    @eugenkr The headers are downloaded and validated first, before the client even requests block data. As a result, it will never receive blocks whose parents it doesn't know about. Mar 19, 2018 at 17:11
  • Got to this thread from Twitter. My suggestion is "lonesome block".
    – Phuoc Do
    Aug 29, 2019 at 18:52
  • So, to confirm, this chart at blockchain.com is showing what you prefer to call extinct blocks.
    – davidbak
    Sep 24, 2021 at 0:20
5

Orphans are not in the chain (as seen by the processing node) because their parents are missing, stales are not in the chain because they have no children in the chain.

Source: the glossary at bitcoin.org:

stale blocks are: "Blocks which were successfully mined but which aren’t included on the current best block chain, likely because some other block at the same height had its chain extended first."

and orphan blocks are: "Blocks whose parent block has not been processed by the local node, so they can’t be fully validated yet."

2
  • 1
    "Orphans are not in the chain because they have no parents in the chain" this statement is wrong. orphaned blocks have "parent"-blocks which are part of the blockchain
    – anion
    Apr 2, 2018 at 17:13
  • According to en.bitcoin.it/wiki/Vocabulary#Orphan_Block: "An orphan block is a block which has no known parent in the currently-longest block chain. Not to be confused with a Stale Block (which has a known parent, but is no longer part of the longest chain)."
    – Ed Posnak
    Dec 27, 2018 at 17:14
-1

Both answers are quite good and explain well about the concept of orphaned block (or more precise name according to Pieter Wuilie: extinct blocks). I just want to give a specific view for the future readers who could also want to take a look at the real orphan blocks in Bitcoin chain, just like me:)

In blockchain.info website, there are some detailed record for those orphaned blocks, if you click the block height, even the block header info of those orphaned blocks are there for you, for example an orphaned block 503949 mined by SlushPool.

It also has a statistics view of orphaned blocks, I download its csv history and can calculate Bitcoin orphaned block rate is about 0.31% (from 2014/3/18 to 2017/6/14). The statistic excel file is here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.