Why account abstraction is important and a practical pathway to achieving it

A look into ERC-4337 and how it can provide a 10x increase in today's wallet experience.
This article originally appeared on Substack on November 15, 2021.

A majority of wallets today, such as MetaMask and Ledger nano, revolves around the use of a private key to sign transactions on the blockchain. However, the current experience of these wallets include several high friction points that might be slowing the adoption of cryptocurrencies for the average consumer.

  • A wallet must always have Ether in order to do anything. If you want to send USDC to a friend then you need to make sure your wallet has enough ETH to pay for the fee. This is a bad experience when compared to traditional payment rails. For example when we buy things with a credit card we don’t pay the store in dollars but then pay the card company in Euros. Instead the details of foreign exchange is handled in the backend.
  • Permanently losing your key means permanently losing your assets. A significant benefit of traditional banks is the sense of security from being able to recover your life savings if you forget your password. To a lot of consumers this risk mitigation will significantly outweigh any inefficiencies such as slow transfer times and low interest rates.
  • An understanding of cryptography and how seed phrases, private keys, public keys, and addresses work. Even to technical folk, the topic of cryptography can feel quite complex and require hours of study to wrap your head around. To expect the majority of non-technical consumers to also learn this and then go through the extra effort of securing their keys becomes an almost unrealistic goal.

Although this is a non-exhaustive list, we can start to see some of the more obvious UX hurdles in the wallet space that might be preventing wider crypto adoption. However, this is also the type of problems account abstraction aims to solve. Put simply, account abstraction allows us to implement all sorts of arbitrary and complex logic into our wallets compared to what’s currently possible with just a standard private key or seed phrase.

Account abstraction gives users the comfortable experience of traditional finance with the speed and efficiency of blockchains, without requiring custody. We believe this is the step change in user experience required to onboard the world to Web 3.0.

Account abstraction sounds great! Why isn’t it a thing yet?

To date there has been a bunch of proposals for achieving account abstraction on Ethereum such as EIP-2938 and EIP-3074. These proposals however require a consensus layer change at a time where a majority of core development is being focused on the merge and then on shard chains to improve scalability. This is of course the right thing to do, since without scalability, blockchains (let alone account abstraction) won’t be feasible due to high transaction fees.

However a recent proposal is ERC-4337 and it sets out a standard for achieving the goal of account abstraction without consensus layer changes. This means it can be developed and adopted today without diverting core developers away from the Eth2 roadmap.

How does ERC-4337 work?

erc-4337-with-paymaster
A diagram of how the different systems of ERC-4337 interact. Source

ERC-4337 proposes a bunch of systems that work together to enable a seamless wallet experience. An explanation of the implementation can be found in the EIP, but the five major parts are:

  1. User operation. The atomic instruction for what a user wants to do. For example, this could be approve 1000 USDC on UniSwap or swap 1000 USDC for ETH.
  2. Bundler. A system that can bundle multiple user operations and send them off to the Entry Point. In return the bundler gets refunded the cost of gas. This could enable bundling multiple operations like approve and swap together to be executed in one transaction.
  3. Entry Point. A smart contract that can take a list of user operations from any source and co-ordinate its verification,  execution, and gas payments accordingly.
  4. Wallet. A smart contract that accepts user operations from the Entry Point, verifies if its legit, pays the gas, and executes the instructions.
  5. Paymaster. An optional smart contract that has a staked amount of ETH in the Entry Point. It can be used to sponsor the gas fees for a user operation. This can enable wallets to not hold any ETH but reimburse the Paymaster in tokens like USDC instead.

An example: Sending USD to a friend from anywhere in the world, instantly.

Let’s say you’re based in Australia and you wanted to send $1000 to a friend who’s based in the US. Through the traditional system you’d have to pay a bunch of fees and wait multiple days before your friend can receive the funds. However using the combination of scalable blockchains and account abstraction we can actually achieve an experience that’s 10x faster, better, and cheaper. Let’s see how this works using ERC-4337.

  1. Your wallet has USDC but no ETH. This is not a problem because your wallet app will sign two operations. The first is to approve a paymaster to take the equivalent gas fees in USDC from your wallet and the second is to transfer 1000 USDC from your wallet to your friends wallet.
  2. You send these two user operations to the bundler which pays the initial gas to forward it to the Entry Point.
  3. During verification, the Entry Point checks if the wallet is willing to accept the two operations and if the paymaster is also willing to sponsor it.
  4. Once verified, the Entry Point sends the operation to the wallet to execute and then cuts a portion of the paymaster’s stake to cover gas fees.
  5. After execution, the paymaster takes the equivalent cost of gas in USDC from your wallet while the Entry Point refunds the bundler the cost of gas in ETH.

While all this complexity is happening in the backend, the user experience for you becomes incredibly simple. You’ve effectively managed to send $1000 USD  in a single click to your friend while also paying for the transaction fee in the same currency (while not holding or knowing anything about ETH). If this was also done on a layer 2 network, then it would’ve been settled in seconds for less than a dollar in fees!

Account abstraction enables many more opportunities for building better crypto wallets.

This article only outlines a short introduction to ERC-4337. For those interested in doing a deeper dive, be sure to read the original article by Vitalik Buterin and also the EIP proposal itself.

Account abstraction can also solve many more UX problems with todays crypto wallets. Besides just gas-less transactions, it could power other big features like social recovery, multi-sig, and abstracting away seed phrases. At Stackup, we’re committed to making Web 3.0 more accessible and we think account abstraction will play a significant role in achieving that goal.

Want to try Account Abstraction yourself?

Test out Stackup's quickstart guide!