Scalability is a key challenge that the Ethereum community is actively trying to solve, and ensuring unlimited scalability is the only way to ensure mass adoption of the technology. One of the most viable scalability solutions that has emerged is the Zero-Knowledge Ethereum Virtual Machine (zkEVM).
This guide explains the basics of zkEVM and dives into why zkEVM is critical to scaling web3 and promoting its widespread adoption. Finally, we'll look at some use cases for this exciting new technology.
Guidelines for this article:
What is zkEVM?
Why do we need to scale Ethereum?
What zkEVM projects are there in the ecosystem?
zkSync Era
What are the applications of zkEVM?
Multi-prover zkEVM is the future
What is zkEVM?
Before we get into zkEVM, let’s first get familiar with zero-knowledge proof (ZKP), a key concept that forms the basis of zk technology. Essentially, a ZKP is a cryptographic proof that allows one party to prove to another party that they possess certain information without revealing it.
There are currently multiple algorithms that can be used to generate ZKPs. The two most notable are zk-STARKs and zk-SNARKs. Both are abbreviations for the methods by which two parties prove their knowledge: zk-STARK stands for Zero-Knowledge Scalable Transparent Argument of Knowledge. Meanwhile, zk-SNARK stands for Zero-Knowledge Succinct Non-Interactive Argument of Knowledge.
Now let’s understand what zkEVM is. zkEVM is a zk-rollup that mimics Ethereum’s transaction execution environment and executes smart contracts. It proves the correctness of execution using ZKPs. ZkEVM recreates aspects of Ethereum’s design to provide an “Ethereum-like” experience for developers and users. When combined with rollup technology, zkEVM provides unparalleled security and scalability for decentralized applications (DApps) and their users.
zk-rollup reduces the computational load on Ethereum by executing transactions in a separate Layer 2 (L2) environment. The rollup operator, called a sequencer, periodically bundles transactions on L2 into rollup batches and submits this proof to a smart contract on Layer 1 (L1) Ethereum.
Why do we need to scale Ethereum?
The Ethereum Virtual Machine (EVM) is a distributed computing environment that runs on the Ethereum network. It is critical to the network as it allows the execution of smart contracts and powers the various DApps running on Ethereum.
As more and more users turned to Ethereum, network limitations led to high gas prices, or the fees users pay to use the network. As a result, the Ethereum network provided the benefits of security and decentralization, but sacrificed scalability in the process, as every node on the network needed to re-execute transactions and store the world state.
Some of the solutions that have emerged to address Ethereum’s scalability issues are sidechains and rollups. Sidechains are like independent blockchains that run in parallel to L1 Ethereum. Meanwhile, rollups execute transactions off-chain, bundle them up, and then publish them to L1. The criticism against these solutions remains that they do not scale Ethereum directly. However, they allow developers to run Ethereum DApps on a scalable off-chain layer while being a low-cost option for users.
Not all scaling solutions are created equal. Take sidechains, for example, which lack the security provided by the Ethereum network. Therefore, the safety of user funds depends on the integrity of the validators associated with the sidechain. In dire circumstances, if the validator set is compromised, there is a significant risk of illegally diverting funds from the bridge or denying users access to legally owned funds through transaction censorship.
Zk-rollups have quickly become one of the most effective ways to solve Ethereum's scalability issues. Since they are "zero-knowledge", they only require proof of validity, not data of the entire transaction. This ensures that zk-rollups require less block space, making the verification process faster and cheaper than executing transactions on L1.
What zkEVM projects are there in the ecosystem?
Many L2 projects have emerged in the Ethereum ecosystem over the past few years. However, we will focus on four of the most notable.
The zkSync Era
Developed by Matter Labs, ZkSync Era is an EVM-compatible zkVM that supports general applications. It is an upgraded version of zkSync Lite, providing low-fee ERC-20 token and ETH transfers, swaps, and NFT minting/trading.
ZkSync Era takes a compiler-based approach to EVM compatibility, using a special compiler to convert high-level programming languages such as Solidity or Vyper into a format suitable for zkSync zkEVM. This change results in some incompatibilities with Ethereum, but provides benefits such as improved proof generation time and reduced end-user costs.
ZkSync Era will be available to all users on the Ethereum mainnet on March 24, 2023.
·StarkWare
StarkWare is the developer of two different zk products: StarkEx, a permissioned extension service that powers applications such as dYdX, Sorare, ImmutableX, and rhino.fi; and StarkNet, a general-purpose rollup tailored for executing Cairo programming language applications.
Notably, StarkWare is credited with popularizing “validiums,” which function like rollup structures with off-chain data availability. By ensuring correctness through proofs of validity, validiums offer superior security compared to other scaling solutions with off-chain data availability.
StarkNet went live on the Ethereum mainnet on April 25, 2023.
Polygon zkEVM
Polygon zkEVM positions itself as the “EVM equivalent zkEVM.” Essentially, it’s a zkVM that understands and processes the same instructions as the Ethereum Virtual Machine.
STARKs are used to generate proofs of computational integrity in the Polygon zkEVM, while SNARKs (generated using PLONK) are used for L1 verification purposes. This combination provides a "best of both worlds" scenario, where STARKs are used to quickly generate proofs. At the same time, the correctness of the STARK proof is proven using the final SNARK proof to reduce verification costs.
Polygon zkEVM debuted on the Ethereum mainnet on March 27, 2023.
·Line
Linea is a developer-friendly Type-2 zkEVM. The R&D team at Consensys developed this rollup. It is an EVM-equivalent zk-rollup solution that is fully compatible with existing tools and infrastructure. This enables developers to develop as they would on Ethereum mainnet (e.g. Linea uses ETH for Gas payments) at a fraction of the cost of building on Ethereum.
As a Type 2 zkEVM, Linea prioritizes compatibility with all Ethereum applications and infrastructure. It allows seamless integration with EVM wallets ( MetaMask ). In addition, developer tools (Truffle, Remix, Brownie, Foundry, Hardhat, etc.) and key infrastructure such as node providers (Infura) and execution clients (Besu).
Linea provides the advantages of Ethereum's scaling solution, which is low fees, fast confirmation, and large transactions per second, while avoiding the shortcomings that some competing projects may have, such as delayed finality, high costs, and poor security.
In addition, Linea also provides EVM equivalent infrastructure. This means that users can build new DApps while benefiting from Ethereum's security, decentralization, and developer experience.
Linea announced its launch on the Ethereum mainnet on July 11, 2023, and began recruiting partners on the same day. It opened the network to all users on July 18, 2023.
What are the applications of zkEVM?
DeFi: Traders and investors will benefit from increased capital efficiency and improved liquidity access on zkEVM rollups while minimizing withdrawal latency. The exponential cost savings of zkEVM are particularly noteworthy in the DeFi space. This is because there is no need to compensate liquidity providers for quick exits.
Additionally, zkEVM’s optimizations for scalability translate into extremely fast and cost-effective decentralized computer operations. This makes it ideal for peer-to-peer payments and institutional settlements. Ethereum’s highly decentralized network, with over 500,000 validators and growing, ensures strong transaction finality guarantees.
Gaming: On-chain gaming applications that process a large number of transactions greatly benefit from the scalability advantages provided by zkEVM. In addition to the previously mentioned benefits, on-chain players can also reduce the cost of each transaction. This is due to the inherent data compression capabilities of zkEVM.
NFT: The unique combination of ultra-low gas fees and high transactions per second on the zkEVM chain makes it an ideal platform for large-scale NFT minting and trading. In addition, once the on-chain validator contract accepts the submitted proof, withdrawals will be completed immediately, ensuring a seamless user experience for transferring NFTs to Ethereum L1.
Social Media: Another area where zkEVM has proven useful is in social media. Take for example DApps such as Lineaster, a decentralized social media platform built by Lens Protocol and deployed on Linea. Lineaster is able to take advantage of the high throughput and low gas fees achieved by Linea.
Multi-prover zkEVM is the future
All in all, it’s clear that zkEVM’s potential for web3 proliferation and adoption is unparalleled. But in particular, multi-prover can play a special role. In the case of multi-prover zkEVM, every transaction published to L2 is attested by multiple independent attesters. That is, a batch of transactions can have many validity proofs confirming the integrity of the transaction data contained in the batch.
To achieve this, we need multiple high-performance Type-2 EVM equivalent zkEVMs that can work together. Multi-prover zkEVMs have many benefits. The key is that it reduces the risk of failure because there is no single point of attack. Another benefit is that it encourages innovation in proof schemes.
Vitalik Buterin refers to most rollup solutions available today as “training wheels,” meaning that projects still rely on multi-signatures to ensure a specific outcome in the event of a bug in the code. They are not yet fully reliant on Zk-proof technology. However, multi-validator solutions are key to helping remove these “training wheels” and truly realize the benefits of this technology.