Resources
/
Technical
Technical
November 6, 2024

What is EIP-4337?

Stackup explains how EIP-4337 account abstraction enables smart contract wallets with social logins, gasless transactions, one click multi-operations, and more!
John Rising

EIP-4337, also known as the ERC-4337 standard, is a proposed Ethereum improvement proposal that aims to introduce account abstraction to the Ethereum network. Account abstraction allows smart contracts to act as wallets and execute transactions on behalf of users. This allows users to interact with the Ethereum network without the need for their own private keys or the need to hold Ether for gas fees.

The ERC-4337 standard consists of four main components: UserOperations, Bundlers, EntryPoint, and Contract Accounts.

Contract Accounts can also be supplemented by Aggregators and Paymasters.
  • UserOperations are pseudo-transaction objects that are used to execute actions through a smart contract wallet.
  • Bundlers package UserOperations and send them to the EntryPoint contract on the blockchain for verification and execution.
  • EntryPoint is a singleton smart contract that handles the verification and execution logic for transactions.
  • Contract Accounts are owned by a user and can be supplemented with features from other smart contracts like aggregators and paymasters.

Here is the process is a diagram:

First, a user creates a UserOperation object and submits it to the mempool. The Bundler then receives the UserOperation and submits it to the EntryPoint for verification and execution. The EntryPoint verifies the UserOperation is valid by checking the Contract Account and if needed the Paymaster and Aggregator, and then sends the call data to the Wallet Contract for execution. Any unused gas fees are refunded to the Wallet Contract or a function is called on the Paymaster Contract to run any post-execution logic.

The ERC-4337 standard has the potential to revolutionize the way users interact with the Ethereum network and could make it easier for non-technical users to participate in the Ethereum ecosystem. However, it is important for all implementations of the ERC-4337 standard to be thoroughly audited to ensure security and reliability.