Blockchain explained
Series
Blockchain explained
Lesson
05 of 06
Edition
November 2026
References
5

Digital signatures: who may spend

Abstract

A private key signs and the matching public key verifies. A signature proves that the holder of the key approved exactly that message, without revealing the key.

Key points

  1. A key pair is a private key, kept secret, and a public key, which anyone may see.
  2. Only the private key can produce a signature that the public key accepts.
  3. The signature covers the exact message: change one character and verification fails.
  4. In a blockchain a transaction is valid only if it carries a signature from the key that controls the coins.

LimitsWhere this toy model differs from the real system: Limits

Two keys that belong together

Public-key cryptography uses pairs of keys created together. The private key stays with its owner; the public key can be published. Anything signed with the private key can be checked by anyone who has the public key. The public key cannot be used to sign, and the private key cannot be worked out from it.

Figure 1Try it: Sign and verify

This widget needs JavaScript. The text of the lesson explains the same idea without it.

Sign the message, then change the received copy by one character: verification fails. Switch to someone else’s public key: it fails too. A valid signature ties this exact message to this exact key.

What signatures do in a blockchain

A blockchain has no accounts protected by passwords. Coins are locked to a public key; in Bitcoin, usually to an address derived from the hash of a public key. To spend them, a transaction must carry a signature made with the matching private key, and every node checks that signature before accepting the transaction. So nobody can spend coins locked to someone else’s key, not even a miner with enormous computing power.

Signatures decide who may spend; proof of work decides the order of the transactions. And whoever holds the private key controls the coins: if the key is lost, nobody can sign for them again, and if it is stolen, the thief can.

Limits

Sources

Primary sources this lesson is based on.