- What is Bitcoin?
- What is blockchain?
- What is mining?
- Where are your coins stored? (wallet addresses, keys)
- What is cryptocurrency and why would I need it?
- Where can you spend your Bitcoin?
- What are altcoins and where can I buy them?
- What is Ethereum?
- What is the difference between Bitcoin and Bitcoin Cash?
- What is the Lightning Network?
- What is Tether (USDT)? When would you use it?
- Top crypto resources that you should follow
- Ten commandments of cryptocurrency investing
What are crypto wallet addresses and public/private keys?
Remember this important Commandment of Crypto: “YOUR private keys = YOUR bitcoin; NOT YOUR private keys = NOT YOUR bitcoin!”
For cryptocurrencies, cryptography not only secures the network itself but also secures transactions and stored funds. As you start using cryptocurrencies, it is important to understand the basic concepts of how wallet addresses and public and private keys work.
First, some basic terminology. It is very important to understand the difference between a lot of the jargon you will come across with respect to storing your coins, so that you make sure they are safe and accessible only to you.
Cryptocurrency Wallet: This refers to an app, software, or hardware that manages your crypto wallet addresses and private keys. It lets you interact with the blockchain and complete transactions. The term wallet might be confusing because unlike a physical money wallet, a cryptocurrency does NOT hold your cryptocurrency funds (these are held in the public ledger of the blockchain). Because your crypto wallet only controls the KEYS (public and private keys) to access your wallet addresses on the blockchain, you can better remember that cryptocurrency wallet is a KEY WALLET (or KEY CHAIN) instead of a MONEY wallet.
Crypto Wallet address: This is automatically generated by wallet software or by an address generation program. It is a string of digits in a specific format that is recognized by the cryptocurrency’s network and is used to receive transactions. Your wallet address can be shared publicly so people know where to send you funds. Think of this as your blockchain “bank account”.
Public/private key pair: Your wallet address is derived from two strings of digits: the public and private key pair. To authorize a transaction, you enter with your private key, proves ownership of the funds stored in your wallet address. This is a different string of digits than the wallet address, and it is essential that you keep your private key secret and NEVER share it with ANYONE! No one other than you should ever see your private key because the person that controls the private key owns the funds in a wallet address. If someone steals your private key, there is no way to prove that the coins are yours. When your wallet software generates your private key, write it on a piece of paper and keep it in a safe place – if it is stored on your computer then there is the chance it can be hacked and stolen.
A public key is derived from the private key, and used to create the wallet address. The public key is used in the digital signature of a transaction so the network can verify that the private key was used to sign that transaction. This way, the private key doesn’t have to be revealed when the transaction is broadcasted to the network.
Usually, it is not necessary to deal with the public key directly, this is handled by your wallet software. You really only need to think about your wallet address (used to receive funds) and private key (keep secret and back up.)
Generating a wallet address
To visualize the process of generating a public/private key pair and corresponding wallet address, we have included a simplified schematic overview:
- With a key/wallet generation program, you can generate wallet addresses. Most wallet software programs have this function built in already and you will not have to deal with this part.
- The software needs a random number input. The software generally also does this automatically, or will require the user to generate some form of randomness, for example by moving their mouse over the screen for a period of time.
- With this random number, the algorithm of the key generation software will generate your private key
- The software will use the private key to generate the public key (again, you usually will not have to worry about this.)
- From the public key, your wallet address will be generated. Note: The amazing thing about the algorithmic generation of the wallet address from the private key is that generating the public key and wallet address is easy, but doing the reverse calculation from wallet address to private key is effectively impossible! This is what secures the funds in your wallet address.
- Your wallet is all set up – ese your new wallet address to send and receive coins!
It is essential to understand that the newly generated wallet address does not yet exist on the blockchain. If you try to find it with a blockchain explorer, it will not show up. That is because it was created without interacting with the blockchain network, and will only be recorded on the blockchain after it is used for a transaction. After a transaction that uses the address is included in a new block, it will be visible on the blockchain via a blockchain explorer, and the updated balance of the wallet will become visible in the wallet software.
Side note: this is why cryptocurrency is referred to as a permissionless payment system: you don’t need permission from anyone to participate in the system! When you generate a wallet address with a private key and receive a transaction, you are already participating in the network.
How does a transaction work?
In other another article, we will explain how to actually create a transaction. Here, however, we will walk through how a transaction really works, hopefully, to help you understand what happens under the hood when you use cryptocurrency.
Take a look at this infographic explaining how the process works:
Here is what happens if Alice wants to send the equivalent of $500 in Bitcoin to Bob:
- Alice generates a transaction in her wallet software that is basically a message saying “I will pay $500 from my wallet address to Bob’s wallet address”.
- She signs her message (transaction) with her private key, resulting in an encrypted transaction. The code that this results in is known as the transaction hash. This tx hash does not reveal Alice’s private key, but does include her public key.
- The tx hash is sent to the network for verification.
- The network of nodes and miners decrypts the message using the public key, verifies if Alice’s private key was used to sign the transaction, without revealing the private key, and checks if Alice has sufficient balance to make this transaction.
- If Alice DOES NOT have enough money in her wallet address, her transaction will be rejected by the network.
- If Alice DOES have enough money in her wallet address, her transaction will be mined and included in one of the next blocks on the blockchain.
- When the transaction is included in a block, Alice’s wallet address will decrease by $500 and Bob’s wallet address will increase by $500.
Of course, the Bitcoin blockchain doesn’t record transactions in $USD, but in Bitcoins.
The word “wallet” is often used to mean either “wallet address” OR “wallet software”. You may also hear people say “public key” when they actually mean “wallet address,” or “public address” when they often mean “wallet address.”
If you are confused about which type of wallet would best fit for your needs, read our crypto wallet guide, it covers different types of wallet solutions.
Important to remember
- Your wallet address can be shared publicly to anyone who wants to send you funds – in fact they need this address to be able to send the money.
- Keep your private key secret, never ever share with anyone!!!
- Backup your private key, perhaps in several secure locations. If you lose it, the funds on that wallet address are unrecoverable and your money is gone forever.
- If you don’t own the private key to your wallet, you effectively do not own the balance in that wallet. This is the case with coins kept on exchanges: the exchange controls the private keys of those wallets. This is one reason why it is recommended that you do not store large amounts of money on an exchange.
- Repeat until you remember it by heart: “YOUR private keys = YOUR bitcoin; NOT YOUR private keys = NOT YOUR bitcoin!”
This article was written to the best of our knowledge with the information available to us. We do not guarantee that every bit of information is completely accurate or up-to-date. Please use this information as a complement to your own research. Nothing we write in any of our articles is intended as investment advice nor as an endorsement to buy/sell/hold anything. Cryptocurrency investments are inherently risky so you should never invest more than you can afford to lose.