2023-04-06

# Zero-Knowledge Explained Like to 5 Years Old

Imagine being able to prove something without actually revealing it. That is the power of zero-knowledge proofs, the technology that keeps your crypto safe.

Zero-knowledge proofs (ZKPs) are a key technology that underpins the security and privacy of many modern cryptocurrencies. In essence, ZKPs allow parties to prove that they know a piece of information, without revealing that information itself. But what does that mean, exactly? In this blog post, we'll explain ZKPs in a way that even a 5-year-old can understand.

## Helper example

Let's start with a basic example. Imagine you have a secret toy that you don't want anyone else to know about. Your friend wants to prove to you that they know what the toy is, without actually telling you what it is. How can they do that?

One way to do it is to play a guessing game. Your friend can ask you a series of questions about the toy, such as "Is it blue?" or "Does it have wheels?" Based on your answers, your friend can narrow down the possibilities until they have a pretty good idea of what the toy is. This is a bit like a multiple-choice test: by eliminating the wrong answers, you can eventually arrive at the right one.

But what if your friend wants to prove that they know the toy, without giving you any clues about what it is? That's where zero-knowledge proofs come in.

Imagine your friend has a magic wand that can tell them whether a particular guess is right or wrong, without actually revealing what the correct answer is. So they can make a guess, wave the wand, and get a "yes" or "no" answer. If the answer is "no", they can make another guess and try again. If the answer is "yes", they've proven that they know the toy, without actually revealing what it is.

This is a bit like playing "20 questions", but with a magical yes-or-no answer that doesn't give away any information. Your friend doesn't need to ask you any questions about the toy, they just need to make a series of guesses and use the magic wand to check if they're right or wrong. And because the wand doesn't reveal anything about the toy itself, you still don't know what it is.

## Zero-knowledge in Cryptocurrency

Now, let's apply this idea to cryptocurrency. In a blockchain system like Bitcoin, transactions are recorded on a public ledger that anyone can see. But the ledger doesn't reveal who the parties involved in the transaction are. Instead, it uses cryptographic techniques to obscure their identities.

For example, imagine you want to send some Bitcoin to a friend. You create a transaction that says "send X amount of Bitcoin to this address". But instead of using your real name and address, you use a pseudonymous address that's associated with your public key.

The public key is a string of characters that's generated using a complex mathematical algorithm. It's unique to you, and it's used to encrypt and decrypt messages that are sent to and from your address. But it doesn't reveal your actual identity.

So when you send the Bitcoin, the transaction is broadcast to the network and added to the blockchain. But nobody knows who the parties involved are, because they're identified only by their public keys.

This is where zero-knowledge proofs come in. Imagine you want to prove to someone that you own a particular address, without revealing what that address is. You could use a zero-knowledge proof to demonstrate that you know the private key associated with that address, without actually showing the key itself.

Zero-knowledge proof (ZKP)The proof works by using a mathematical algorithm that allows you to generate a random "challenge" that's based on your private key. You then provide a response to the challenge that demonstrates that you know the private key, without revealing what it is.

This is a bit like the guessing game we talked about earlier. The challenge is like a question that's designed to test whether you know the private key, and the response is like an answer that proves that you do, without revealing what the key is. This allows you to prove ownership of the address, without revealing any sensitive information.

This is important for privacy and security in cryptocurrency, because it means that you can prove ownership of an address without revealing your identity or any other sensitive information. It also makes it much harder for hackers or other bad actors to steal your cryptocurrency, because they would need to know your private key in order to access your funds.

So there you have it, zero-knowledge proofs explained like you're 5 years old! They're a clever way of proving that you know something, without actually revealing what it is. And in the world of cryptocurrency, they're a key technology that helps to ensure the security and privacy of your transactions.

ZKP OriginZero-knowledge proofs were first introduced by researchers Shafi Goldwasser, Silvio Micali, and Charles Rackoff in 1985. Their groundbreaking paper, "The Knowledge Complexity of Interactive Proof-Systems," laid the foundation for zero-knowledge proof systems. Silvio Micali, won the Turing Award for his works on cryptography and inventing Zero Knowledge (ZK) Proofs

## Related reading

- The reddit user busterrulezzz (u/busterrulezzz) - Redditproposed other ELI5 explanation of how the ZKP works: Zero-knowledge proof explained like you are 5 years old : r/CryptoCurrency
- Zero Knowledge Proof: Explain it Like I’m 5 (Halloween Edition) | HackerNoon

*Any comments or suggestions? Let me know.*

**To cite this article:**

@article{Saf2023Zero-Knowledge, author = {Krystian Safjan}, title = {Zero-Knowledge Explained Like to 5 Years Old}, journal = {Krystian's Safjan Blog}, year = {2023}, }