In December 2022, we announced that EVM compatibility had been launched on the Zilliqa testnet, allowing smart contracts written in Solidity to be deployed natively to the Zilliqa blockchain.
EVM (Ethereum Virtual Machine) is the software platform used to build applications on Ethereum and other protocols that have implemented EVM compatibility. Bringing EVM to Zilliqa opens our ecosystem to the wider blockchain developer community and allows users to use popular wallets such as MetaMask with the Zilliqa ecosystem.
The next step after this testnet implementation is to bring the first complete release of EVM compatibility to the Zilliqa mainnet, which is set to go live at 08:00 UTC on April 25th, 2023.
Once this EVM implementation launches on mainnet, users will be able to transfer native ZILs using wallets such as MetaMask and deploy Solidity smart contracts using popular developer tools such as Truffle and Hardhat.
Going forward, EVM compatibility will be expanded to include full interoperability between Scilla and Solidity smart contract standards. This functionality will be phased in first on the testnet and later on the Zilliqa mainnet.
To find out more about the upcoming launch of EVM compatibility on the Zilliqa mainnet and what functionality is in the pipeline, we spoke with Zilliqa Head of Distributed System Engineering Valeriy Zamaraiev.
What to expect from EVM on mainnet
Valeriy explains that the way EVM compatibility has been implemented on Zilliqa is superior to many layer-2 protocols due to the ability to transfer tokens natively without complex and extraneous conversion processes.
“This is a full, complete implementation of EVM compatibility with all the APIs, and most of the dApps will not require any adaptation at all. We have a better implementation than many layer-2 blockchains because one of the things that we've decided is to make EVM native to the Zilliqa ecosystem,” Valeriy says.
“There are a small number of exceptions that are already published in our documentation and relate primarily to certain opcodes, but to a significant extent we have fully native EVM compatibility.”
This native implementation means people can use wallets like MetaMask in the same way they do on other blockchains without worrying about address space differences or converting ZIL tokens.
“EVM accesses the same ZIL as Scilla in the same address space. For example, if I send some ZIL from my account to your account, and you use ZILSwap and I use Metamask, it's in the same address space. If my smart contract sends ZIL to you, we can exchange value directly without any bridges, without any unnecessary delays. In most layer-2 implementations, you would still have to wrap your tokens and have another token to complete this transfer.”
“Once this first full EVM compatibility release is live, people can use the same MetaMask setup they already use with other chains. All they will need to do is to move their balances from their Zilliqa wallet to Metamask, and then they can exchange native ZILs among themselves,” Valeriy says.
“Additionally, they can write code in Solidity, deploy that to the mainnet and create dApps using the same tools as you would in any other EVM environment - Truffle, Hardhat, and so on.”
Zilliqa’s EVM compatibility also provides extensive support for API libraries such as Ethers.js and Web3.js - both of which are working well in the current testnet implementation.
Interoperability between Scilla and Solidity
Once EVM compatibility is live on mainnet, the next step will be to build out more features by implementing interoperability between Scilla and Solidity standards, including ERC-20 and ZRC-2 for fungible tokens and ERC-721 and ZRC-6 for NFTs.
This interoperability will make it as easy to natively transfer NFTs and fungible tokens between EVM and Scilla interfaces as it is to transfer native ZIL tokens. The approach Valeriy and the team are taking to tackling this problem is one that focuses on user accessibility and seamless integration.
“Scilla and EVM have different models of execution - Scilla's model is deliberately more restricted for security. To make them interoperable, you also need to execute EVM slightly differently,” Valeriy explains.
“We implemented something called continuation passing style that allows us to interleave execution of one EVM contract with another contract that can be written in Scilla. You basically can have one contract that makes a call into Scilla that gets a return, and then that can make yet another EVM call, which in turn can call Scilla, and so on - and all of this is processed in the same transaction.”
This method ensures that the benefits of interoperability can apply retroactively to existing tokens and offer an incentive for users to deploy contracts that open up tokens in the Zilliqa ecosystem to a range of cross-chain dApps.
“This approach is needed to implement such things as ERC-20 to ZRC-2 proxies, for example, so that you can see your ZRC-2 tokens as if they were ERC-20 tokens. Our goal is to add ERC-20 compatibility to all ZRC-2 tokens on the platform, even the current ones,” Valeriy says.
“That would immediately make them available to all the DeFi protocols out there. The only thing that will be left to do would be for someone to deploy them, and there will be a lot of incentive for developers to do that.”
Better reach for Scilla developers
The launch of EVM compatibility on mainnet and the upcoming implementation of interoperability between Scilla and Solidity smart contracts is also great news for Scilla dApps and developers, Valeriy says.
“In a way, EVM compatibility supports Scilla developers. In the past, people who wrote contracts in Scilla would be concerned with how they would make themselves compatible with other ecosystems and potentially abandon the idea of wider compatibility and adoption in favour of Zilliqa’s secure-by-design native smart contract language.”
“Now, with EVM compatibility and the upcoming interoperability with Solidity, you can actually make the choice to use Scilla and not lose the connection with the world of EVM-compatible chains. That’s a great reason to keep using Scilla and prioritise it for your next projects because if you needed a window into the EVM world, you have it now,” he adds.
“This creates an opportunity that few other blockchains can offer - you can use the right tool for the right job. Solidity brings accessibility to the world of DeFi and all the software that's already there, and Scilla can be used for any novel development where security is the main priority.”
With this first full implementation of EVM compatibility, people will be able to use MetaMask natively with Zilliqa and deploy Solidity smart contracts directly to the Zilliqa mainnet. When it comes to the development of more complex dApps and the testing process, however, the testnet remains the best place to explore the potential use cases for EVM compatibility.
“The testnet is where all testing and development should be happening. We are releasing EVM on mainnet because we are confident about the completeness of our implementation, but for anything non-trivial you should be using the testnet for the development of your dApps,” Valeriy notes.
“Use Metamask to send ZILs on the mainnet and deploy your smart contracts on the mainnet, but when you have a complex dApp where you need to be confident about your implementation, please use our testnet.”
“On top of that, the features that we plan for the next upgrade of the mainnet, such as Scilla-Solidity interoperability, will be available on the testnet much sooner.”
These interoperability features will be available on the testnet well before they are deployed to the mainnet, and developers who are looking to leverage these features to build DeFi solutions and more should look out for future announcements on EVM compatibility upgrades coming to the Zilliqa testnet.
An exciting future for Zilliqa with EVM
The launch of EVM compatibility on the Zilliqa mainnet is a significant milestone in Zilliqa’s ecosystem growth, ushering in incentives for the deployment of DeFi services and making adoption easier than ever thanks to native support for popular wallets such as MetaMask.
“I think what’s coming next as a result of EVM compatibility is Zilliqa being a much bigger player in the DeFi world - that excites me a lot,” Valeriy says.
“This is also a giant user experience upgrade to Zilliqa - we're removing the fragmentation of user experience that hinders the usability of the network.”
“All the improvements in the EVM compatible wallets, we'll get the benefit of those automatically rather than trying to catch up with the industry. We are becoming a more native participant in the wider crypto industry and in some areas we are aiming to be more collaborative than competitive,” he adds.
Looking ahead to the big network upgrades coming this year and the road to a more scalable and user-friendly network with Zilliqa 2.0, Valeriy says that while the speed and scalability of the network are key benchmarks for improvement, user experience is a key factor in improving adoption.
“We need to think about not just how to scale our network, but also our users. There's not much point to having a scalable network which nobody uses. For me personally, keeping the user experience in mind is the number-one priority,” Valeriy says.
“This is a major part of our philosophy as we grow the speed and scalability of the Zilliqa network with the development of Zilliqa 2.0.”