📜 ERC-4337 Spec: UserOps & Bundlers
Understand how account abstraction works under the hood
Explore EIP-4337 and the future of wallets
Your Progress
0 / 5 completedERC-4337 Specification
**ERC-4337** is the standard that enables account abstraction without requiring changes to Ethereum's consensus layer. It introduces a new object called **UserOperation**—a pseudo-transaction that describes what the user wants to do. These UserOps flow through a separate mempool to bundlers, who package them into actual transactions.
The beauty of ERC-4337 is its compatibility: it works on any EVM chain today, leverages existing security assumptions, and enables innovation at the application layer without waiting for protocol upgrades.
Interactive: UserOperation Flow
Watch how a UserOperation flows through the ERC-4337 architecture from user to execution.
UserOperation
User signs intent to execute operation
Bundler
Aggregates multiple UserOps into one transaction
EntryPoint
Validates and routes UserOperations
Smart Wallet
Executes the actual operation
Paymaster (Optional)
Sponsors gas fees for the user
📋 UserOperation Structure
A UserOperation contains all information needed to execute an operation on behalf of the user:
Key Components Deep Dive
🎯 EntryPoint Contract (0x5FF...000)
Singleton contract that validates and executes all UserOperations. Think of it as the universal entry point for all AA wallets.
📦 Bundlers
Specialized nodes that collect UserOps from alt-mempool, simulate execution, bundle multiple ops, and submit to EntryPoint. They get refunded for gas + take a small fee.
👛 Smart Contract Wallets
Must implement IAccount interface with validateUserOp() function. This is where custom logic lives: multisig, social recovery, spending limits, etc.
💰 Paymasters
Optional contracts that sponsor gas fees. Can accept ERC-20 tokens, implement subscription models, or provide free transactions for marketing.
🔐 Security Guarantees
- ✓Replay Protection: Nonce prevents same UserOp from executing twice
- ✓Gas Griefing Prevention: Bundlers simulate ops before submission, reject invalid ones
- ✓DoS Protection: Reputation system bans misbehaving wallets/paymasters
- ✓Censorship Resistance: Multiple bundlers compete, users can run their own
Why Not Change Ethereum Protocol?
ERC-4337 achieves account abstraction at the application layer, avoiding consensus changes. This means: