Skip to content

Public keys, private keys and addresses: what's the difference in crypto?

How crypto wallets use a private key, a public key and an address, which one you can share, how signatures prove ownership and why a lost key is final.

Figures checked against 6 official and primary sources on . See the sources · How we check

Key points

  • Your private key signs transactions and must stay secret. Your public key is derived from it and lets others verify your signature. Your address is a shorter code derived from the public key.
  • You can share an address freely. ethereum.org puts it simply: you never really hold crypto, you hold private keys; the funds are on the blockchain.
  • NIST warns that if a private key is lost, the assets are lost, and if it's stolen, the thief has full access. A stolen-crypto headline almost always means stolen keys, not a broken blockchain.
  • Your seed phrase can regenerate your private keys, so it deserves the same protection.
In this guide
  1. Public-key cryptography in one minute
  2. The three pieces
  3. How a signature proves it’s you
  4. From private key to address
  5. “You hold keys, not coins”
  6. Why losing a private key is final
  7. Where the seed phrase fits
  8. Smart contracts have addresses too
  9. Practical rules

Every crypto wallet, from a phone app to a hardware device, is built on three related pieces of information: a private key, a public key and an address. Knowing which is which tells you what you can safely share, what you must never share, and why “losing your keys” is so final.

This guide explains each one in plain language, using NIST’s blockchain overview and the Ethereum and Bitcoin documentation.

Public-key cryptography in one minute

Blockchains use asymmetric-key cryptography, also called public-key cryptography. NIST explains that it uses a pair of keys, a public key and a private key, that are mathematically related:

  • The public key can be made public without reducing security.
  • The private key must remain secret.
  • Even though the two are related, the private key can’t efficiently be worked out from the public key.

That one-way relationship is what makes the system work. It lets strangers who don’t trust each other verify transactions, while the transactions themselves stay public.

The three pieces

Private key Public key Address
What it is A secret number Derived from the private key A shorter code derived from the public key
What it does Signs transactions Verifies signatures Where people send you crypto
Share it? Never Can be public Yes, it’s meant to be shared

NIST sums up the roles:

  • Private keys are used to digitally sign transactions.
  • Public keys are used to derive addresses.
  • Public keys are used to verify signatures made with private keys.

How a signature proves it’s you

When you send crypto, your wallet creates a transaction and signs it with your private key. Anyone can check the signature with your public key, which proves the transaction was authorized by whoever holds the private key, without revealing the key itself.

ethereum.org gives an example: without this, an attacker could broadcast a message saying “send 5 ETH from Alice’s account to Eve’s account”, and nobody could tell it didn’t come from Alice. With signatures, only Alice’s private key can produce a valid one. NIST adds that a common signing algorithm used in blockchains is the Elliptic Curve Digital Signature Algorithm (ECDSA).

How big is a private key?

The Bitcoin developer documentation explains that a bitcoin private key is simply a 256-bit number, which can be almost any value from 1 up to a limit set by the secp256k1 standard, covering nearly the entire range of 2^256 possible values. NIST puts 2^256 at roughly 10^77. That’s why nobody can find your key by guessing: the number of possibilities is astronomically large, as long as the key was generated randomly.

From private key to address

On Ethereum, ethereum.org describes the steps:

  1. Your wallet generates a random private key: 64 hexadecimal characters.
  2. The public key is generated from the private key using ECDSA.
  3. The address is the last 20 bytes of the Keccak-256 hash of the public key, with 0x added in front, giving a 42-character address.

NIST explains the general idea for any blockchain: take the public key, apply a cryptographic hash function, and convert the result to text, sometimes adding a version number and a checksum. Each blockchain does it differently, which is why bitcoin and Ethereum addresses look different. Addresses are shorter than public keys and not secret, and they’re often shown as a QR code to make them easier to use on phones.

“You hold keys, not coins”

ethereum.org makes a point that changes how you think about wallets: you never really hold cryptocurrency, you hold private keys. The funds are recorded on the blockchain. Your wallet is software, or a device, that stores your keys and uses them to sign.

NIST describes wallets the same way: software that stores private keys, public keys and addresses, and may show your total balance.

This is also why “not your keys, not your coins” is a common phrase. If an exchange holds the keys, you rely on the exchange. See hot vs cold wallets and what happens if an exchange goes bust.

Why losing a private key is final

NIST is direct about the stakes:

  • Lost key: any digital asset associated with that key is lost, because it’s computationally infeasible to regenerate the same private key.
  • Stolen key: the attacker has full access to all the assets that key controls.
  • No undo: once a thief uses a stolen key to move funds, the transaction generally can’t be reversed.

NIST adds a useful perspective on the news: when you read that crypto was “stolen from” somewhere, it almost certainly means private keys were found and used to sign a transaction, not that the blockchain itself was compromised.

Where the seed phrase fits

Most wallets today don’t show you the private key directly. They give you a seed phrase, a list of words that is a human-readable backup from which the wallet generates your private keys. That’s why anyone with your seed phrase can take everything in the wallet. See seed phrase security.

One seed, many keys

Two widely used standards explain how this works:

  • BIP 39 turns random data into a phrase of 12, 15, 18, 21 or 24 words, with a built-in checksum that lets a wallet warn you about an invalid phrase. The phrase is then turned into a seed.
  • BIP 32 describes hierarchical deterministic (HD) wallets, which derive a whole tree of key pairs from that single seed. That’s how one backup can restore every address your wallet has ever used.

BIP 39 also allows an optional passphrase on top of the words. It explains that every passphrase produces a valid wallet, and only the correct one opens yours. So a mistyped passphrase doesn’t give an error: it opens a different, empty wallet. If you use one, record it as carefully as the words themselves.

Extended public keys

HD wallets can share an extended public key (often called an “xpub”), for example so that a shop’s server can generate new receiving addresses without holding any private keys. BIP 32 warns that these need more care than ordinary public keys:

  • An extended public key lets anyone reconstruct the descendant public keys, so it reveals your addresses and their history: leaking public keys can mean a loss of privacy.
  • An extended public key combined with certain private keys derived from it is equivalent to knowing the parent private key, and with it every key below. Wallets use “hardened” keys at higher levels to limit that risk.

Smart contracts have addresses too

Not every address belongs to a person. NIST notes that on Ethereum, a deployed smart contract gets its own contract address. ethereum.org adds that contract accounts don’t have private keys: they’re controlled by their code. See what is a smart contract?

Practical rules

  1. Share addresses, never private keys or seed phrases. No exchange, wallet provider or support agent needs them.
  2. Check the whole address before sending. Bitcoin.org advises verifying the entire receiving address, not just the first and last characters, and considering a small test transaction. See how to send crypto safely.
  3. Use fresh addresses for receiving bitcoin if your wallet offers them, for privacy.
  4. Keep backups offline, and consider a hardware wallet for larger amounts. NIST notes that many users store keys in special secure hardware.
  5. Be careful what you sign. A signature can authorize more than a simple transfer, such as a token approval. See token approvals and how to revoke them.

For how keys fit into the bigger picture, see what is a blockchain? and multisig wallets explained.

Frequently asked questions

Can someone steal my crypto if they know my address?
No. An address is designed to be shared, like an account number for receiving. NIST notes that addresses are not secret. What someone can't do without your private key is sign a transaction that moves your funds.
Is my seed phrase the same as my private key?
Not exactly. A seed phrase is a human-readable backup from which a wallet generates its private keys. Anyone with the seed phrase can recreate those keys, so treat it exactly like a private key: never share it or type it into a website.
Can a lost private key be recovered?
Not by the network. NIST says that if a user loses a private key, the associated assets are lost, because it's computationally infeasible to regenerate the same private key. You can only restore access from a backup, such as your seed phrase.
What happens if I mistype my seed phrase passphrase?
You won't get an error. BIP 39 explains that every passphrase produces a valid wallet, but only the correct one opens yours. A typo simply opens a different, empty wallet, so write the passphrase down exactly and keep it safe; without it, the seed phrase alone can't restore your funds.
Is it safe to share my extended public key (xpub)?
Be careful. An extended public key can't spend coins, but BIP 32 says it lets someone reconstruct the descendant public keys, so they can see your addresses and balances. And if it leaks together with certain private keys derived from it, an attacker could work out the parent private key. Treat it as private.
Why does my bitcoin wallet show a new address every time?
Bitcoin.org says most modern wallets generate a new address for each payment you receive. Old addresses stay valid and belong to your wallet. Using a fresh address improves privacy, because reusing one makes it easier to link your payments together.

Sources

  1. NISTIR 8202: Blockchain Technology Overview — National Institute of Standards and Technology (NIST)
  2. Ethereum accounts — ethereum.org (Ethereum documentation)
  3. Frequently Asked Questions — Bitcoin.org
  4. Wallets (private key formats and HD wallets) — Bitcoin developer documentation (developer.bitcoin.org)
  5. BIP 39: Mnemonic code for generating deterministic keys — Bitcoin Improvement Proposals (bitcoin/bips)
  6. BIP 32: Hierarchical Deterministic Wallets — Bitcoin Improvement Proposals (bitcoin/bips)

First published . Spotted an error or an outdated figure? Tell us and we will check it against the source.