Learn

|

Mining

What is a blockchain?

A decentralized database for security, transparency, and integrity

A blockchain is a database – a way to store and organize information. Blockchains are used for secure, transparent, and tamper-proof record keeping, such as for financial transactions like Bitcoin.

Blockchains are a new kind of database.

They work by organizing information as a sequence of grouped updates, called “blocks”. In Bitcoin, the updates are transactions being sent peer-to-peer. Each block contains a reference to the preceding block, forming an unbroken “chain of blocks” that go all the way back to the blockchain’s beginning.

It’s kinda like an accountant’s ledger book, where each page in the book contains a list of transactions and includes a special note, referencing the previous page’s transactions.

Traditional databases, like the ones used by banks for financial transactions, are centralized, which means the access and control of information is managed by a central authority (the bank). It’s kinda like a master copy of the ledger book, where only the owner of the book can control it and make changes.

Blockchains, on the other hand, use a decentralized model. They work within a network of independent peers, each participating in the operation of the database by following standardized rules for how and when to update the information. It’s like everyone having their own copy of the ledger book and all agreeing on the same rules for how and when to make changes to their own copy.

This lack of a central authority means blockchains offer a way to manage information, while preventing corruption, obstruction, or manipulation of the database by any individual or group.

Bitcoin is by far the largest, most secure, and robust blockchain.

How does a blockchain work?

Blockchains are based on rules.

A blockchain’s software contains the rules that govern its operations. For Bitcoin’s blockchain, the rules define things like the supply of bitcoin, the formatting of transactions, and the timing and size of blocks. You can read more about Bitcoin’s rules here.

Computers can download and run the software, thereby becoming a “node” in the blockchain's network and enforcing its rules. By running the software, nodes can check for themselves whether the information within the blockchain follows the rules, while also participating in the process for adding new blocks.

So how are new blocks added if nobody is in charge?

The solution is a process called mining. Here’s the basics of how mining works with Bitcoin:

  1. Broadcasting: A new proposed transaction is broadcast to the network of nodes, containing an amount to send, a destination, and the required signature to authorize the transaction.
  2. Checking: Each node checks the validity of the transaction to ensure it follows the rules, such as valid amounts, signatures, and formatting.
  3. Mining: Computers (called “miners”) perform computational work called “hashing,” in a competitive “lottery-style” competition to win the right to add the next block to the blockchain.
  4. Grouping: The miner who finds a winning hash gets to assemble a group of proposed transactions into a block and broadcast it to the network, which includes a reward of newly issued bitcoin payable to themselves. The winning hash acts as mathematical “proof of work” that the miner expended computational power (aka hashpower), to “mine the block”.
  5. Appending: All nodes check that the new block’s data is valid and that the hash was legitimately won, before adding that block to their own copy of the blockchain.
  6. Repeating: The new block serves as an input for the next round of the lottery and the process repeats.

If there’s ever conflicting versions of the blockchain, the version with the most computational work applied is correct.

Every 2 weeks the lottery’s difficulty automatically adjusts (aka the “difficulty adjustment”), to ensure that the lottery is won every 10 minutes, thereby ensuring consistent block intervals and predictable supply issuance of bitcoin.

Why are blockchains useful?

With a blockchain, any miner or node can disconnect and reconnect to the network, and easily verify what has taken place in their absence. This means that the blockchain doesn’t exist in any single location or computer, but rather equally across all copies of the blockchain.

It’s a database that exists everywhere, yet nowhere in particular.

Blockchains offer significant advantages over traditional databases, making them ideal for certain applications, such as peer-to-peer electronic cash.

  • No central authority: There is no individual or group capable of manipulation or unilateral changes to the rules, or blocking or reversing transactions.
  • Transparency: Each node can verify the validity of every transaction to ensure that everyone is following the rules, which are publicly available for all to see.
  • Immutability: Once a transaction is added on the blockchain (aka “confirmed”), reversing it requires an amount of computational work that surpasses all other competing versions of the blockchain that contain the transaction, making it virtually impossible to alter transactions after multiple blocks have passed.
  • Democratization: Anyone can participate as a node or a miner, verifying transactions and enforcing the rules that they support.
  • Internal incentives: Blockchains can sustain themselves based solely on their own incentives. Miners get rewarded for their work, nodes get their desired transactions confirmed, and everyone follows the rules because the value of rewards and transactions is based on rule-following.

Decentralization is paramount

In centralized systems, such as financial databases, trust is required to ensure the central authority doesn’t manipulate transactions or unilaterally change the rules to arbitrarily create money or block access to funds.

A blockchain with only a few nodes or miners requires trust that they won’t collude, be coerced, or act on mis-aligned incentives. Given the financial value of blockchain transactions, there is always the risk that if someone can manipulate the blockchain for financial gain, they will.

Centralization of a blockchain can take many forms:

  • A small total number of nodes or miners
  • A concentration of network hashpower in a few miners or groups of miners
  • Miners or nodes operating in a single country, subject to that country’s laws
  • A leadership team that can influence or dictate rule changes

Bitcoin’s software and entire transaction history are small enough to be downloaded and verified on a typical laptop, making it accessible for countless people to run a node. Mining is a globally competitive industry, with many independent operators worldwide and who aim to avoid excessive consolidation to protect the blockchain’s integrity. Ensuring Bitcoin’s continued decentralization is a shared interest for everyone in the community.

Other blockchains often lack sufficient decentralization. If they rely on leadership teams or a small number of nodes or miners to verify transactions, they are vulnerable to failures, corrupt incentives, or attacks. Centralized blockchains are simply databases that require trust in a central authority or group, risking manipulation, obstruction, or changes made for their own benefit.

Lightning

What is the Lightning Network?

The global bitcoin payments network that’s instant, private, and low-to-no cost

Business

What is the Strike widget?

Add a “Buy bitcoin” button to your app

Bitcoin

What is the bitcoin supply schedule?

The pre-programmed pace from zero to 21 million

Markets

What is the Bitcoin halving?

The automatic reduction in Bitcoin’s supply-issuance rate

Lightning

What is a Lightning invoice?

Bitcoin payment requests within the Lightning Network

Lightning

Using Bitcoin to send money abroad

Bitcoin's Lightning Network makes global money transfers faster and cheaper

© 2024 NMLS ID 1902919 (Zap Solutions, Inc.)

Get off zero.

Strike

BitcoinAll in on bitcoinPaymentsSend GloballyBusinessAPI

Platform