Hard & Soft Fork
BLOCKCHAIN
• A blockchain is a collection of data blocks linked together by safe
cryptographic keys to build a chain of blocks stretching all the way
back to the first one.
• Blockchains, for example, are decentralized open-source systems with
no centralized power. As a result, the option to update the system
involves the agreement of all users in the network.
• A fork is considered a unique method of updating or improving a
blockchain. Based on their function, forks are classified into two
categories: soft and hard forks.
• Therefore, it leads the blockchain visualization as a straight road
formed up of interconnected blocks.
• Since the blocks are linked by an agreement that all of the blocks
accept, each optimization to the system necessitates a modification in
consensus across the blocks. However, since the blocks are linked
through a practically unalterable set of protocols, the chances of
reaching such a consensus are nearly impossible.
• Therefore, rather than recreating each block, forks are frequently
used to make modifications to a blockchain.
• A fork is an event on the blockchain platform in which the initial
programming is copied, and the relevant modifications are made to it.
• Moreover, two blockchain platforms can’t coexist; therefore, the new
blockchain separates into two branches, generating a fork-like
deflection from the primary blockchain.
A fork in blockchain maybe defined by:
• Diversion of potential path of a blockchain.
• A change in protocol.
• A condition when two or more blocks attain the same height.
• Forks are of different kinds, they can either be temporary or permanent.
Permanent forks exist forever in the network while temporary forks are short-
lived and are created under certain situations and conditions.
Blockchain Forks
There are three major reasons why blockchain forks occur:
• Adding new functionalities
• Fixing security issues
• Reversing transactions
Fork Formation
• Blockchains, however, feature different subsets of participants ranging
from miners to full node users and developers. So, who gets the final
say on what changes should be implemented on the network?
• Because each subset contributes differently to the network, some
participants have more voting power than others.
• According to blockchain experts, since there is no centralized entity
running the blockchain, it is up to the platform’s members to decide
on a path ahead and make modifications that enhance overall
system functionality and efficiency.
• Forks may be initiated by developers or members of a crypto community
who grow dissatisfied with functionalities offered by existing blockchain
implementations. They may also emerge as a way to crowdsource funding
for new technology projects or cryptocurrency offerings.
• For example, miners, who secure the network by dedicating
computational resources for block validation, tend to determine the
security and popularity of the fork versions.
• Because miners provide the computational recourses necessary to run the
network, any fork version that attains the miners’ approval tends to
succeed.
FORKS IN BLOCKCHAIN
• In simple terms, Forks in blockchain means copying the code and
modifying it to create a new software or product.
• In open-source projects Forks are very common and used widely.
• So, cryptocurrencies like Ethereum and Bitcoin are decentralized and
open software so that anyone can contribute.
• As they are open-sources they rely on their communities to make the
software more secure and reliable. Also open source with the help of
fork can make user interface more interactive and look good, helping in
gaining more users worldwide. In open source the code is visible to
everyone, anyone can modify, edit, access there is no copyright claims
for such actions.
• For example: Tor browser is an open source software, Linux one of the
most widely use Operating system is an open source system, in similar
way Bitcoin and Ethereum protocol are also open sourced.
CODEBASE FORK
• In codebase blockchain fork you can copy the entire code of a particular
software.
• Let us take BITCOIN as an example, so suppose you copied the whole blockchain
code and modified it according to your need, say that you decreased the block
creation time, made some crucial changes and created a faster software than
BITCOIN and publish / launch it has a new whole software named against you,
by completing the whole white paper work process.
• So in these way a new BLOCKCHAIN will be created from an empty blank
ledger. It’s a fact that many of these ALT COINS which are now running on the
blockchain are been made in these way only by using the codebase fork i.e. they
have made little up and down changes in the code of BITCOIN and created their
whole new ALT COIN.
LIVE BLOCKCHAIN FORK
• Live Blockchain fork means a running blockchain is been divided
further into two parts or two ways. So in live blockchain at a specific
page the software is same and from that specific point the chain is
divided into two parts. So in context to this fork the Live Blockchain
Fork can occur because of two reasons : accidental or temporary
forks and intentional forks
ACCIDENTAL FORK / TEMPORARY
FORK
• When multiple miners mine a new block at nearly the same time, the entire network may
not agree on the choice of the new block.
• Some can accept the block mined by one party, leading to a different chain of blocks from
that point onward while others can agree on the other alternatives (of blocks) available.
• Such a situation arises because it takes some finite time for the information to propagate in
the entire blockchain network and hence conflicted opinions can exist regarding the
chronological order of events.
• In this fork, two or more blocks have the same block height. Temporary forks resolve
themselves eventually when one of the chain dies out (gets orphaned) because majority of
the full nodes choose the other chain to add new blocks to and sync with.
• Example (TEMPORARY FORK / ACCIDENTAL FORK): Temporary forks happen more often
than not and a usual event that triggers this fork is mining of a block by more than one
party at nearly the same time.
INTENTIONAL FORK
• In intentional fork the rules of the blockchain are been changed,
knowing the code of the software and by modifying it intentionally.
• This gives rise to two types of forks which can occur based on the
backwards-compatibility of the blockchain protocol and the time
instant at which a new block is mined. So Intentional fork can be of
two types:
• Hard Fork
• Soft Fork
Hard Fork
• A hard fork is when nodes of the newest version of a blockchain no longer
accept the older version(s) of the blockchain; which creates a permanent
divergence from the previous version of the blockchain. Here the previously valid
blocks are made invalid or vice-versa.
• Adding a new rule to the code essentially creates a fork in the blockchain: one
path follows the new, upgraded blockchain, and the other path continues along
the old path.
• Hard fork causes permanent divergence of newer nodes from the previous
version of the blockchain protocol. After a time, even those old chains realize that
their version is outdated and upgrade itself to the latest version.
• Example: Rise of Bitcoin cash
• A Hard Fork, on the other hand, is a non-backwards-compatible
alteration of the blockchain protocol, where the old version of the
software is unable to validate new blocks mined based on the new
rules. Hard forks often lead to the creation of a new currency, with an
equivalent amount of the original currency being distributed to full
nodes who choose to upgrade their software. The decision to join a
particular chain rests with the full node, and upgrading the software
is necessary to make transactions valid on the new chain.
Examples of a Hard Fork
• One of the biggest examples of hard fork in the history of
cryptocurrency is separation of Bitcoin Cash from Bitcoin. It occurred
in august 2017. The split arose due to a fundamental disagreement
between the miners.
Ethereum Shapella
• The Ethereum Shapella hard fork went live in April 2023 as part of the
Shanghai Upgrade. One of its functions is to finally allow validators to
unstake ETH from the Beacon Chain.
Reasons for a Hard Fork
• There are a number of reasons why developers may implement a hard
fork, such as correcting important security risks found in older
versions of the software, to add new functionality, or to reverse
transactions—such as when the Ethereum blockchain created a hard
fork to reverse the hack on the
Decentralized Autonomous Organization (DAO).
Soft Fork
• A soft fork in blockchain is defined as a change in the software protocol. Here only
previously valid transaction blocks are made invalid. The process is also called a
backwards-compatible software update, as the old nodes will identify the new blocks
as valid blocks.
• A Soft Fork is a backwards-compatible alteration of the blockchain protocol, where new
rules are added without conflicting with the old rules. This means that the old version of
the software is still able to validate new blocks mined based on the new rules.
• Unlike hard fork, not all miners need to agree to implement the rules, but even an
agreement among the majority of miners will work. Sometimes, even a new transaction
entry is also coined as a soft fork.
• A soft fork can also happen during the time of temporary divergence in blockchain. Or
when miners violate a new consensus rule that their nodes don’t know. Unlike hard forks,
soft forks don’t require nodes for the maintenance of consensus.
Example of a Soft Fork
Bitcoin SegWit
• Segregated Witness, commonly known as SegWit, is a soft fork
upgrade to the Bitcoin protocol that was activated in August 2017. It
increased the transaction capacity of the Bitcoin network by allowing
more transactions to be included in each block.
• One of the popular examples of soft fork is the introduction of SegWit
(Segregated Witness- refers to a change in the transaction format of
Bitcoin). History is proof the miners’ community has always debated
on the best way to increase bitcoin transaction speed. Generally, it
takes around ten minutes to mine a bitcoin transaction in a block.
Miners always want to increase the number of transactions in a block.
Difference between Hard Fork and Soft Fork
Hard fork is a contradiction to soft fork in their process and properties. The list
of differences between hard fork and soft fork is given below:
1. Hard fork is a backwards-incompatible process, while soft fork is a
backward-compatible process.
2. Hard fork is reversible in nature, while soft fork is irreversible.
3. Hard fork creates two blockchains, while soft fork at the end combines the
split into one.
4. Hard fork can valid previously entered invalid transactions and vice-versa.
While soft fork only can invalidate previously entered valid transactions.
5. Hard fork requires all miners to validate new rules, while soft fork can
work well with the majority of miners.
1. Hard fork is more secure and private when compared to the soft
fork.
2. Hard fork changes the entire rules of a blockchain. While a soft fork
is used to add new functions and properties to a blockchain.
3. Hard fork alters the characteristics of a blockchain, while soft fork
modifies the characteristics of a blockchain.
4. Due to the reversible process, a soft fork is safer than a hard fork.
5. Hard fork doesn’t require a soft fork for reversible process, while
soft fork requires a hard fork for reversible process.
Reasons for fork
Forking in blockchain happens for some reasons:
• Upgrades: To improve or enhance the network.
• Disagreement: When there are conflicts in the community. To resolve
a disagreement within the community about the crypto currency’s
direction.
• Bug fixes: To fix critical issues.
• Creation of new cryptocurrencies.
• Security: protecting the networks from threats.
• To add functionality
Reasons for the occurrence of a blockchain
fork:
• Add new functionality: The Blockchain code is upgraded regularly.
Since most public blockchains are open source, it is developed by
people from around the world. The improvements, issues are created,
resolved and new versions are released when the time is suitable.
• Fix security issues: Blockchain (and cryptocurrency on top of it) is a
relatively new technology as compared to the traditional currency
(notes, coins, cheque), research is still underway to fully understand it.
So, versions are bumped and updates are released to fix the security
issues that arise in the way.
• Reverse transactions: The community can actually void all the
transaction of a specific period if they are found to be breached and
malicious.
Potential Benefits of a
Blockchain Fork:
• Collective Innovation: When there’s a disagreement about the
direction of a blockchain, a fork can allow a team of developers to
explore new ideas and solutions that may eventually benefit the
entire crypto community.
• Competition and Liquidity: A new blockchain and coin increase
competition within the field. It may generate new investments and
eventually liquidity in the crypto market.
• Improvement and Value: Every successful technical improvement and
upgrade helps evolve a blockchain’s functionality, possibly leading to
increased adoption of its technology and the value of its coin.