It’s not necessary to know the math behind cryptography before investing in Bitcoin or other cryptocurrencies. What is important to know, though, are some basic crypto concepts. One such concept is that of cryptocurrency key pairs. Luckily, if you understand how email works, you can understand the basic ideas behind private and public keys.
Your Private Key Is Like Your Email Password (But Worth a Lot More!)
While cryptocurrency is popularly thought of as a currency or an asset, it actually functions like a messaging system, just like email. While email runs on the SMTP protocol, digital assets like Bitcoin run on a blockchain protocol.
Both protocols transmit information between users, but it’s not necessary to know the math behind how the protocols work to be able to use either email or blockchain. In this section, we’ll use the cryptocurrency and email analogy that was presented in the Future of Everything article, “What Is a Bitcoin Address?”, and develop it further to illustrate the concept of key pairs.
Before we do that, though, if thinking of cryptocurrency as a type of messaging system sounds strange, consider the following. Finance in general can be described as a kind of record of wealth transfers. What really happens, for instance, if you transfer $100 to your friend from your online bank account to her online bank account? No physical assets are moved anywhere; one bank just communicates some information to another bank. Just like with blockchain, shifts of money to and from your online checking account are a kind of virtual record of transfers in wealth.
If we compare cryptocurrency to email, then the private key is like your email password. It’s a set of letters and numbers unique to an investor’s own crypto wallet that allows the investor to send digital currency from that wallet. Just like your email password, the private key needs to be kept absolutely secret at all times or you will likely lose all of the wealth in your crypto wallet.
Crypto Transactions Need to Validate Private Keys
So, how do different users “communicate” (i.e. transfer assets) to one another via the blockchain? Each crypto wallet generates a cryptocurrency address, which functions in a similar way as your email address. Your crypto address is 100% public and available for all to see. Anyone can send you an email if they know your email address, and, similarly, anyone can send you cryptocurrency if they know your crypto address.
Every cryptocurrency transfer is stamped with a unique digital signature. This is a cryptographic value that verifies the authenticity of both parties’ identities (i.e. key pairs) in a transaction. Back to the email analogy, the digital signature can be thought of as an email’s metadata (i.e. To, From, and Subject). Once you see that information at the top of an email, you know exactly who the communicating parties are and the nature of the unique message sent between them.
Private key(s) are stored in a cryptocurrency wallet. This is analogous to your email client, like Gmail or Yahoo Mail, which creates an interface for accessing your record of messages. The type of crypto wallet that you choose to store your private keys is highly important. Read more about the different types of wallets here.
One key difference between email and cryptocurrency is the number of identifiers required to access and control private data. Email requires two unique identifiers, username and password, to gain entry. Cryptocurrency, though, can be accessed and transferred with one unique identifier, the private key.
So, it can’t be emphasized enough how important it is to keep your private key secret and secure at all costs!
Getting a Little More Technical (But Not Too Much)
Blockchain, the underlying protocol behind Bitcoin and other digital coins, is based on a concept called asymmetric encryption. This means that some of the encrypted data from a financial transaction on the blockchain can be accessed by the public via one key, while other data can only be accessed privately with another key. In contrast, something coded with symmetric encryption would only use private keys (i.e. this is not the case with blockchain).
The private key can derive other keys or addresses that themselves can’t be decrypted to decode the private key. In other words, it’s encryption in one direction and not in reverse. It works like a fingerprint. By looking at a fingerprint, someone can tell which finger it came from but won’t be able to produce the finger itself. This process used by cryptocurrency is known as elliptic curve multiplication.
A public key is a derivation of a private key, which can be traced back to a private key but can’t be used to decode it. Using a similar one-way process — called a hash function — the public key creates a shorter version of itself: the crypto address. This hashed string of characters is the address seen by the public that represents (though does not show) a private key.
So, what is the difference between a public key and a public (crypto) address? The latter is typically shared with others to have them send you cryptocurrency. Since the public address is derived from the public key, the hash function serves as another layer of security (a fail-safe backup) in addition to the encryption connecting the public key to the private key. For those brave souls interested in the math behind Bitcoin, read more here.
It is crucially important to keep your digital assets safe by securing your private key and crypto wallet. To learn more about how private keys can be stolen and ways to safeguard against this, see our extensive Cryptocurrency Security Guide.