Skip to content

What are private and public keys? ​

An obvious question then is, if anyone can make changes to the public Bitcoin ledger, what's to stop someone changing the records fraudulently, and spending the bitcoin in your "account"?

The answer is a pair of cryptographic keys which are used to make transactions over the network, with every transaction signed by the owner of the money, using a secret digital key that only they hold.

Every computer on the network then checks the transaction's signature, verifying that it came from the right owner, before accepting the transaction. A transaction without a valid signature is simply rejected.

To explain, when you "own" bitcoin, what you really own is a private key. Your signature can only be made with your private key. Whoever holds the key, therefore, controls that bitcoin.

Keys come in pairs. A private key, which is kept secret, and a public key, which can be shared with anyone. You can think of the public key as similar to a bank account number, and the private key as the PIN to that account.

To see how a pair of keys works together to secure transactions, imagine two friends, Jane and Jack. Instead of sending money, Jane wants to send Jack a message that no one else can read. Jane locks, or encrypts, her message using Jack's public key, which he has shared freely. Once locked, the message can only be unlocked (decrypted) with the other key in the pair, Jack's private key, which only he holds. To reply to Jane, Jack does the same in reverse, locking his message with Jane's public key so that only her private key can open it. Anyone who intercepts a message between them would only see scrambled text, because they don't hold the right private key needed to unlock the message. But when it reaches its intended recipient, they can use their private key to unlock the message.

Spending bitcoin uses the same idea the other way round. Unlike Jane's message, Bitcoin transactions are not secret, and every one is visible on the blockchain. What matters is proving who made them. So instead of a public key locking and a private key unlocking, the private key signs and the public key checks. When Jane wants to send bitcoin to Jack, her wallet uses her private key to sign the transaction, producing a digital signature that is unique to her private key.

Every computer on the network can then check the signature using Jane's public key. If it matches, they know the transaction came from Jane's private key, cleverly all without Jane’s private key ever being revealed. They’ve simply confirmed that it did come from her.

This idea of paired keys, one public and one private, is called public key cryptography, and it is where cryptocurrencies get their name.

All the signed transactions are then gathered together into a "block", which the network of ledger-keeping computers then verifies (meaning every signature is valid, and no coin has already been spent in a previous transaction). Each block is then time-stamped and sealed with a cryptographic fingerprint of the block before it. This is a short code generated from that block's contents, which changes completely if even one detail is altered.

Sealing a block is deliberately hard work. Computers known as "miners" compete to solve a puzzle that can only be cracked by trial and error, and the winner adds the block to the chain and is rewarded with newly created bitcoin. This is how new bitcoin comes into existence, and why the process is called "mining". Finding the answer takes a great deal of computing power, and electricity, so no new block comes for free. Yet once found, anyone can check the answer almost instantly. Every valid block therefore carries easily verifiable evidence of computational work. This is why the way Bitcoin's network agrees on each new block, its "consensus mechanism", is known as "proof of work"[1].

In the white paper's words, each timestamp includes the previous one, "forming a chain, with each additional timestamp reinforcing the ones before it"[2], hence the name "blockchain". Once a payment is recorded in a block, any later attempt to spend the same coins is rejected. And to change an old entry, a cheat would have to redo the work for that block and every block since, faster than the rest of the network combined, which is why the records are practically impossible to alter once written[3].

You will not find names on the Bitcoin blockchain, however. Instead, each account is an "address", a string of letters and numbers derived from a public key, which you can share with anyone who wants to pay you. Your private key, on the other hand, must stay private, since it is what allows you to spend the funds at that address.

Most people, though, never see their keys at all. They are held by a cryptocurrency wallet, usually a mobile or desktop app, or sometimes a specialised physical device, which keeps the private key safe and signs transactions.

It is not a perfect system, of course. Lose your private key and, unlike a lost bank password, nobody can recover your money for you. Your private key is needed after all to sign transactions. If it's lost, it can’t. An estimated one in five of all bitcoins are thought to be lost like this for good [4].

Still, taken together, these components make value exchange over the internet possible with neither banks nor trusted ledger-keepers. It means value can be measured, spent, earned, stored or exchanged outside a financial system that, in many countries, is dominated by only a handful of banks facing very little real competition[5]. And which, as the 2007/08 financial crisis showed, have at times operated without effective oversight[6].

Since the Bitcoin white paper was published in 2008, the technology underpinning it has produced thousands of other currencies, all built on broadly the same public and private key cryptography[7]. These are now known as cryptocurrencies. Most of them, however, rely on one further innovation, known as smart contracts.

Footnotes ​

  1. Satoshi Nakamoto, "Bitcoin: A Peer-to-Peer Electronic Cash System", 2008, section 4, "Proof-of-Work", and section 6, "Incentive", https://bitcoin.org/bitcoin.pdf (accessed 12 Nov 2026). The reward for each block is the new coins it creates plus the fees paid by the transactions inside it.

  2. Satoshi Nakamoto, "Bitcoin: A Peer-to-Peer Electronic Cash System", 2008, section 3, "Timestamp Server", https://bitcoin.org/bitcoin.pdf (accessed 12 Nov 2026). The white paper itself never uses the word "blockchain"; it describes each block as "chained" after the one before (section 4).

  3. Nakamoto (as note 1), section 11, "Calculations".

  4. A 2020 estimate by the blockchain analysis firm Chainalysis: about 3.7 million bitcoin, roughly a fifth of all bitcoin mined by then, had not moved in five or more years and were likely lost. Reported in "Lost Bitcoin: 3.7 million Bitcoin are probably gone forever", Decrypt, 2020, https://decrypt.co/37171/lost-bitcoin-3-7-million-bitcoin-are-probably-gone-forever (accessed 12 Nov 2026).

  5. World Bank, Global Financial Development Database, "Bank concentration (%)" (assets of a country's three largest commercial banks as a share of all commercial banking assets), https://databank.worldbank.org/source/global-financial-development (accessed 12 Nov 2026); in the UK, for example, the four largest banks held over 70 per cent of main personal current accounts: Competition and Markets Authority, "Retail banking market investigation: Summary of final report", 9 August 2016, para. 46, https://assets.publishing.service.gov.uk/media/57a8c0fb40f0b608a7000002/summary-of-final-report-retail-banking-investigation.pdf (accessed 12 Nov 2026).

  6. House of Commons Treasury Committee, "The Run on the Rock", HC 56-I, 2008, https://publications.parliament.uk/pa/cm200708/cmselect/cmtreasy/56/5604.htm (accessed 12 Nov 2026).

  7. CoinGecko, global market data, https://api.coingecko.com/api/v3/global (accessed 12 Nov 2026), which counted 22,412 active cryptocurrencies on 12 November 2026.