The key difference
A private key is a secret random number that signs transactions; a public key is computed from it and can be shared so anyone can check a signature. The private key gives you the public key, never the other way round. Think of a personal seal (private key) and the published impression of that seal (public key).
What each key is
Bitcoin uses ECDSA on the secp256k1 curve. A private key is a 256-bit number; the public key is a point on the curve derived from it. Uncompressed public keys are 65 bytes (0x04 plus X and Y), compressed ones 33 bytes (0x02 or 0x03 plus X), the default in Bitcoin Core. An address is a hash of the public key plus a version byte and checksum, not the key itself.
How signing works
When spending a P2PKH output you reveal the full public key and an ECDSA signature made with the private key. Nodes check the key hashes to the address and that the signature verifies. Unused addresses keep the public key hidden until the first spend, one reason not to reuse addresses.
Side by side
Visibility: private is secret, public can be shared. Role: private signs, public verifies. Origin: private is random, public is derived. Reversibility: one way only. Size: 32 bytes versus 33 or 65 bytes. If leaked: a private key hands over the funds; a public key does not.
Sources
Prepared with AI assistance. This guide explains protocol behavior for educational use.
This content is for learning and risk education only and does not constitute investment advice.
Editorial policy (Chinese)