The blockchain is a public ledger which contains every single transaction that has ever occurred on the Bitcoin network.
The blockchain is like a shared database on which the entire Bitcoin network relies. All confirmed transactions are included in the blockchain. This way, Bitcoin wallets can calculate their spendable balance and new transactions can be verified to be spending bitcoins that are actually owned by the spender.
Every node of the network stores a copy of the blockchain. Whenever a new block is added to the blockchain, every connected node receives a notification, which in turn gets stored in its database. The integrity and the chronological order of the block chain are enforced with cryptography.
Blockchain data is distributed across a network of computers. A blockchain is typically managed by a peer-to-peer network collectively adhering to a protocol for validating new blocks. Once recorded, the data in any given block cannot be altered retroactively without the alteration of all subsequent blocks, which requires collusion of the network majority.
To be able to add new transactions to the blockchain, a node must show proof of work which solves a cryptographic puzzle. The block is then added to the blockchain and the miner is rewarded with transaction fees and newly created bitcoin.
What makes blockchain secure?
The blockchain is an open, distributed ledger that can record transactions between two parties efficiently and in a verifiable and permanent way. The blockchain ledger is not stored in any single location, meaning the records it keeps are truly public and easily verifiable. No centralized version of this information exists for a hacker to corrupt. Hosted by millions of computers simultaneously, its data is accessible to anyone on the internet.