info
💡 Note: This is not a ranking-based comparison before we jump in. This guide aims to show blockchain developers the available Account Abstraction SDKs they can rely on to integrate the ERC-4337 specification for Smart Contract Accounts and UserOperations into their build projects.

As the Ethereum ecosystem matures, ERC-4337, a smart contract-based account standard, has emerged as a popular choice. The challenge now is navigating the vast ocean of Account Abstraction SDKs. Our mission today is to explore and compare the top contenders.

This article will walk you through the top Account Abstraction SDKs and their key features in moderate technical depth. At the end, you can decide which suits your application's needs.

Prerequisites

Introduction

The Account Abstraction Specification document ERC-4337 was first created in September 2021. Amongst its seven authors are popular names like Vitalik Buterin, Co-Founder of Ethereum, Kristof Gazso, Founder of Pimlico, and Dror Tirosh, an Ethereum Foundation researcher. According to a Tweet by @erc4337, ERC-4337 was deployed on Mainnet on March 1st, 2023, with bundler smart contracts and paymasters deployed by StackUp, Biconomy, Alchemy, Etherspot, Blocknative and others. We are still very much in the early days of Account Abstraction, so let’s check out what SDKs are available and how they compare.

StackUp

StackUp's Userop.js is a TypeScript library designed for easy integration with ERC-4337 UserOperations. This tool lets developers quickly craft Smart Contract Accounts and send UserOperations to bundlers. Since its launch in May 2023, it's seen a surge in usage, with over 1,800 weekly downloads.

info
💡 Note: The StackUp team shipped the first Smart Contract Accounts when the ERC-4337 specification was released under the eth-infinitism team.

Just as Ethers.js simplifies traditional EVM transactions, Userop.js streamlines the creation and transmission of UserOperations to ERC-4337 bundlers with no bias toward any specific implementation.

To expedite the development process, Userop.js comes with presets for common tasks, including Presets.Builder.SimpleAccount.init and Presets.Builder.Kernel.init, the latter of which facilitates batched UserOperations.

Additionally, StackUp offers a node service for providers connecting with supported blockchains. However, their paymaster contract isn't freely accessible for testing.

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
StackUp2,187

Biconomy

The Biconomy Modular SDK is a package for common account abstraction use cases. The SDK operates in a non-custodial manner, giving developers flexibility over their implementation using the SDK.

The Biconomy SDK is available as three separate libraries:

  • @biconomy/bundler is used for specific methods in the validation and execution phase of sending UserOperations. It connects to a bundler instance and is used for RPC methods such as estimateUserOpGas, sendUserOp, and getUserOpByHash. You can think of it as the principal library for batching UserOps. To initialize it via the Biconomy SDK, you need to create a Smart Contract Account, and there is a library for that.

  • @biconomy/account is used to create Smart Contract Accounts. Creating such an account with Biconomy requires an instance of the bundler to interface with. This is because the bundler carries specific information, such as the network where the account is deployed in its instance:

JavaScript
IBundler = new Bundler({

bundlerUrl: "",

chainId: ChainId.POLYGON_MUMBAI,

entryPointAddress: DEFAULT_ENTRYPOINT_ADDRESS,

})

The above instance is passed to the method for the creation of the Smart Contract Account.

  • @biconomy/paymaster enables the sponsoring of gas payments for users. It is not compulsory for use. Developers can also make use of the paymaster service to sponsor UserOperations created by other SDKs.

These three libraries, plus the @biconomy/core-types library, are used in the implementation of ERC-4337 methods. It is important to note that each of them can be used independently of the other. The @biconomy/account can be used to create Smart Contract Accounts for other bundlers, just as the paymaster can be used by other Account Abstraction SDK services.

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
Biconomy2,441

Etherspot

Etherspot is an early player in the ERC-4337 space and provides a wallet service as well as their developer SDK, aptly named Prime SDK. The Etherspot Prime SDK makes it incredibly easy to get up and running with Account Abstraction. From social logins to transaction batching, using an Etherspot Smart Wallet can give dApps a Web2-like interface to ensure the user has a seamless experience.

The Etherspot Prime SDK is available as a singular library for implementing ERC-4337 methods.

Etherspot operates a bundler smart contract named Skandha and offers a paymaster service, Arka, for developer testing—currently available on the Goerli Testnet.

What sets Etherspot apart is its social login feature. Powered by Web3Auth, it positions Etherspot as both a wallet provider and a gateway for fiat transactions. This gives developers an avenue to allow users to purchase tokens with fiat currency.

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
Etherspot994

Pimlico

Pimlico is an infrastructure platform for building the next generation of Smart Contract Accounts, providing bundlers and ERC-20 paymasters services. Built by one of the original authors of the ERC-4337, Kristof Gazso, Pimlico recently announced a raise of $1.6 million to build more Account Abstraction infrastructure. This has led to a surge in the number of weekly downloads of this project.

Pimlico has an Account Abstraction SDK called Permissionless.js. It is built on top of Viem.js specifically for ERC-4337 methods and the paymaster service.

Developers can use any bundler service to interact with Pimlico and batch UserOperations using the Pimlico EntryPoint smart contract. Pimlico is great for developers as their bundlers and paymasters are free for use on testnets. Pimlico supports any token on any EVM chains that has Chainlink support.

The docs are straightforward, and all you have to do to start using the service is to simply create an API Key!

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
Pimlico1,149

Alchemy

Alchemy, best described as the latest kid on the ERC-4337 block, has its own SDK @alchemy/aa-core.

The main interfaces are the SmartAccountProvider and BaseSmartContractAccount.

SmartAccountProvider aligns with the ERC-1193 standard, enveloping JSON RPC and certain wallet procedures. It offers two specialized methods to send UserOperations:

  • sendUserOperation: This manages tasks like estimating gas consumption, obtaining fee details, optionally procuring paymasterAndData, and ultimately, executing the signing process. A sequence of middleware tools ensures these steps proceed in a set sequence.

  • sendTransaction: Here, a standard transaction request input is received. It's then transformed into a UserOperation. At present, the data extracted from this transaction request comprises the from, to, data, and value fields

Alchemy, as mentioned above, also provides a paymaster and gas manager middleware functionality.

Alchemy recently open-sourced its bundler built in Rust and named it Rundler. They also provide a list of bundler API endpoints to interact with RPC across Ethereum, Polygon, Arbitrum, Optimism and Base.

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
Alchemy3,801

Safe

Previously called Gnosis Safe, the Safe team's main purpose is to bring Account Abstraction to life by focusing on integrating Safe with different third parties that can be provided to developers and users to abstract the complexity that comes with setting up a Smart Contract Account. They have set out to build the Safe{Core} Account Abstraction SDK

This SDK is available as four different libraries:

  • Auth Kit creates externally owned accounts (EOA) and authenticates them using an email address, a social media account or another crypto wallet account. It uses Web3Auth under the hood.

  • Protocol Kit facilitates the interaction with the Safe contracts and allows the creation of new accounts, updating the configuration, signing and executing transactions, and other features. The use of the Protocol Kit is dependent on the Safe API Kit. The API Kit facilitates the interaction with the Safe Transaction Service API, allowing the sharing of transactions among the signers and getting information from a Safe like the configuration or transaction history, among other features. It represents the core protocol infra for building using Safe, so its functionalities are extended beyond Safe {Core}.

  • OnRamp Kit allows users to buy cryptocurrencies with fiat money to fund a Safe account via a credit card or other payment methods.

  • Relay Kit allows users to pay gas fees with native tokens or ERC-20 tokens. This will enable you to pay transaction fees directly from funding available in a Safe.

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
Safe347

ZeroDev

ZeroDev provides Smart Wallets as a service. Using ZeroDev, you can:

  • Create self-custody wallets that support Web2 logins (socials, email, passkeys, etc.), so users don’t need to worry about seed phrases and can recover their wallets if they lose their login credentials.

  • Sponsor gas for your users or let them pay with ERC-20 tokens.

  • Simplify user flow by batching related transactions, removing repetitive signing prompts, and even automating transactions for them while they are offline (think subscriptions).

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
ZeroDev5000

Comparing Top Account Abstraction SDKs

Below is a chart comparing the feature set of each Account Abstraction SDK we’ve looked at:

SDKNode ProviderBundlerPayG SandboxBundler AgnosticWeb3Auth IntegrationWallet ServiceWeekly Downloads
StackUp2,187
Biconomy2,441
Etherspot994
Pimlico1,149
Alchemy3,801
Safe347
ZeroDev5000

Conclusion

In conclusion, navigating the world of Account Abstraction SDKs and APIs can be both exciting and challenging. As the blockchain ecosystem evolves, developers are presented with a variety of tools to integrate ERC-4337 Smart Contract Accounts into their projects.

StackUp's Userop.js is notable for its simplicity and TypeScript compatibility. Biconomy shines with its modular approach. Etherspot provides a holistic solution, including social logins. Pimlico is notable for its free testnet tools, while Alchemy's new core SDK presents unique interfaces. Safe covers everything from login to gas fee abstraction, and ZeroDev stands out with its user-friendly smart wallets.

When selecting an SDK, assess your project's needs, your preferred development languages, and the distinct features of each SDK. Continuously monitor updates, gauge community support, and ensure integration flexibility.

As we venture into the ERC-4337 era, this is just the beginning. Keep an eye out for further innovations in Account Abstraction. Happy coding!