What Is a Public Key?
A public key is a shareable cryptographic key derived from a private key and used to verify digital signatures. On most blockchains, wallet addresses are generated from the public key.
On this page 6
A public key is a shareable cryptographic key that is mathematically derived from a private key and used to verify digital signatures. The private key signs a transaction; the public key lets anyone confirm that the signature really came from the matching private key. That pairing is what allows cryptocurrencies to prove ownership without a bank in the middle.
How does public-key cryptography work?
Public-key (asymmetric) cryptography uses two linked keys: one kept secret, one safe to share. Bitcoin and Ethereum derive the public key from the private key using an elliptic curve called secp256k1. The calculation only works in one direction. Going from private to public key takes a fraction of a second, but recovering the private key from the public key is not feasible with today’s computers.
When you send a transaction, you broadcast a signature, not your private key. Nodes check the signature against the public key and accept the transaction only if it matches. Anyone can verify, but only the key holder can sign.
Is a public key the same as a wallet address?
Usually not. On most networks the wallet address is a hashed, shortened form of the public key:
- On Ethereum, the address is the last 20 bytes of the Keccak-256 hash of the public key, written with a “0x” prefix.
- On Bitcoin, classic addresses come from a hash of the public key, while some address types represent several keys or a spending condition.
So when you want to receive funds, share the address shown in your wallet’s “Receive” screen. The long public key string you might see in developer tools is not a substitute for it.
Is it safe to share a public key?
A public key cannot be used to spend your funds, so sharing it is safe from that point of view. Privacy is a different matter. An extended public key, or xpub, can generate every address in a wallet. Give an xpub to a portfolio tracker and it cannot move your coins, but it can see your balance and much of your transaction history.
Sharing one address exposes only that address’s activity, while sharing an xpub exposes the whole wallet. Check what a “watch-only” connection actually exports before you set one up.
Could quantum computers break public keys?
In theory, a sufficiently powerful quantum computer could break elliptic curve cryptography and derive a private key from a public key. No such machine exists today, and researchers are working on quantum-resistant signature schemes. Addresses whose public key has never appeared on-chain offer an extra layer of protection against that future risk.
Frequently asked questions
Can someone find my private key from my public key?
No, not with any computer that exists today. The security of the whole system rests on that one-way relationship.
Where can I see my public key?
Most wallets don’t show it directly. On Bitcoin, the public key appears in the data of transactions you have spent from, viewable in a block explorer, and advanced wallets expose the xpub in their settings.