Understanding ERC-4337 and ERC-4804 Standards
The new ERC-4337 and ERC-4804 standards will enhance user experience, security, and decentralization. Uncover the benefits of Account Abstraction and Unblockable URLs.
“Account abstraction” and “unblockable URLs” have recently been buzzwords in the blockchain and Ethereum spaces. Just what do they mean, and what standards make them work?
In this article, we will learn about the ERC-4337 and ERC-4804 standards, what features they both bring to the blockchain and what challenges exist in their implementation. Let’s delve deeper into these two standards and try to understand how they improve the blockchain experience.
ERC-4337 and Account Abstraction
Account Abstraction was proposed as a way to improve the Ethereum user experience and smart contract wallet security without the need to change the blockchain’s consensus protocol. Technically, accounts on Ethereum can be used solely by a user with a private key or deployed as a smart contract:
- Smart contract account (SCA): the account of an Ethereum smart contract that is used to fund the gas required to execute contractual transactions.
- Externally-owned account (EOA): account belonging to and controlled by users of the Ethereum blockchain.
Each of these accounts can interact with ETH, tokens, and (other) contracts; however, they have differences such as:
- While EOAs can initialize a transaction, SCAs can not. They can only send transactions after they have received transactions.
- The only transactions EOAs can make include sending and receiving ETH or tokens. SCAs can execute contract code on the blockchain after receiving a transaction from EOAs.
- EOAs cost nothing to create, but since smart contracts live on the blockchain, a fee must be paid to create SCAs.
- EOAs have private and public keys for controlling the activities of the account, but SCAs don’t have private keys; they are controlled by code.
The main goal of account abstraction is to enable Ethereum users to use Smart “Abstract” Accounts — instead of EOAs — as their primary accounts, created by merging EOA and SCA features.
The ERC-4337 standard is, therefore, a smart wallet standard proposed by Yoav Weiss and announced to be available on Ethereum at WalletCon on March 1, 2023. The ERC-4337 standard can be adopted on any EVM-compatible blockchain project to enable Ethereum smart accounts with account abstraction and programmable verifiability.
This enhances any project that adopts the standard to abstract away the typical complexity that comes with the smart contract architecture and makes it possible to include multi-parties in a transaction. In simple words, users can do things like interacting with dApps without having their native tokens.
The ERC-4337 standard can be challenging to implement based on the complexity involved in the development and the scarcity of enough materials to guide developers. It is important that only expert blockchain developers with a thorough understanding of the technology should develop projects with the standard.
A better user experience
It doesn’t get said enough that the most important benefit of ERC-4337 and account abstraction is the improved user experience. Let’s look at how this new standard contributes to improving the overall user experience on EVM-compatible blockchain platforms.
Executing many tasks within a single transaction
The ERC-4337 standard makes it possible to bundle multiple transactions into one. For example, you can initiate a transaction, approve it, and execute a trade all simultaneously. This feature is favorable to traders and gamers because they are often faced with the need to sign multiple transactions to execute a single action.
Executing multi-party and sponsored transactions
The ERC-4337 standard makes it possible to add multiple users to your transactions. Assuming you want to execute a transaction on the chain and you need a way to involve the signature (or consent) of a third party (say, your partner), an ERC-4337 smart wallet can make it possible with multi-signature wallets. What’s more, you can assign a third party to pay the gas fee of a transaction you wish to execute — a phenomenon known as sponsored transactions.
Abstract wallet authentication and recovery
The ERC-4337 standard enables smart or “abstract” wallets to adopt traditional login options like via email or social media, as well as via biometric authentications like face ID or fingerprint ID. This means there is a buff in security on dApps and blockchain systems where the ERC-4337 standard is adopted.
Furthermore, whenever a user forgets their password or seed phrase, they completely lose access to the account. This has been a very rampant issue in the blockchain space, resulting in losses that could be otherwise avoided with as simple a feature as recovery. The ERC-4337 standard, however, has brought wallet recovery options to the scene.
More hands on the job
With the advent of this new technology, there have been more roles involved in the event of a transaction. They include:
- Bundlers: they are nodes responsible for bundling transactions on the blockchain and sending them to a bundle marketplace.
- Aggregators: they are helper contracts that validate and aggregate signatures. Bundlers are responsible for whitelisting supported aggregators.
- Senders: they are account contracts that send UserOperations (a data model which describes transactions sent on behalf of a user).
Now that you know what the ERC-4337 standard is, you should learn about the ERC-4804 standard.
The ERC-4804 standard and decentralized URLs
While ERC-4337 brings Web2 authentication options and user experience to Web3, the ERC-4804 standard seeks to make it easier for Web2 users to access Web3 content seamlessly. In this section, we will explore the ERC-4804 standard and what it brings to the Ethereum ecosystem.
Replacing HTTP with Web3
On February 14, 2022, the ERC-4804 protocol was proposed by Qi Zhou under the name: Web3 URL to EVM Call Message Translation. ERC-4804 is an access protocol that specifies URL schema for all Web3 applications to enable users to access decentralized apps using web3:// instead of https:// as the URL prefix right from their browsers.
You can try this out now on a Firefox browser using this extension. Websites using this protocol are hosted on the Ethereum blockchain instead of on “GoDaddy” or “WordPress.” Examples of websites and dApps currently using this protocol include:
- Ethereum Name Service (ENS): web3://app-ens-domain.eth/
- Vitalik Buterin’s blog: web://vitalikblog.eth
- Moon Birds NFTs: web://moon-birds-xyz.eth/render/9880
- W3Mail decentralized email dApp: web3://w3mail.w3q/
- Stanford Blockchain Review: web3:stanfordblockchainreview.w3q/
Decentralized links to decentralized contents
The main reason why the ERC-4804 standard was approved was because initially, Web3 still relied on the centralized servers in Web2 for hosting. This alone defeats the whole idea of complete decentralization.
Using the ERC-4804 standard, Ethereum users will be able to access contents stored on-chain without going through centralized platforms like Domain Name Services. The protocol enables users to execute queries on the Ethereum Virtual Machine (EVM) directly, allowing them to access on-chain content like NFTs and dApps without any concerns about censorship. Rather than seeking decentralized resources that are hosted on a server, the protocol locates decentralized resources that are hosted by a smart contract or ENS.
Unblockable and uncensorable URLs
The Web3 URLs created by this standard cannot be blocked or censored, removing the constraints placed by the gatekeepers of centralization. This is because the URLs are built on a blockchain that has immutability and resistance to censorship as its inherent properties.
This technology will allow users to share and gain access to data without any governmental regulation, promoting high levels of freedom and decentralization over the data being shared or accessed.
Challenges to adopting the ERC-4804 standard
The major challenge projects will face in adopting this standard is the cost of storing content on the Ethereum mainnet. This is a general blockchain challenge, as 1 GB of storage on the blockchain can cost around $ 10 million.
Adopting Layer 2 chains will reduce the cost by a considerable extent, but the result will still be more expensive than traditional Web2 storage solutions.
In this article, we learned detailedly about the ERC-4337 and ERC-4804 standards. We learned the types of standards they are, the features they introduce to the blockchain user experience, and the challenges facing their implementation.
The complexity of implementation and the cost of on-chain storage are the two challenges faced by both standards respectively, but we must remember that the blockchain is an ever-evolving technology. Sooner or later, more standards, techniques, or solutions will be created to meet these challenges and improve the blockchain experience.
About the author:
MacBobby Chibuzor is a software engineer and blockchain fanatic with interests in cryptography and protocols. He is also a devoted community person who loves sharing his knowledge with others through writing.
QuickNode, the leading end-to-end developer platform, is transforming Web3 and blockchain infrastructure by simplifying dApp development and providing high-performance access to 20+ blockchains. Since 2017, QuickNode has empowered hundreds of thousands of top developers and companies to focus on innovation by accelerating dApp build times and offering enterprise-grade solutions to businesses of every size.