# Pimlico > Pimlico is the world's most popular account abstraction infrastructure platform ## Migration from Stackup \[This guide is intended for users migrating from Stackup to Pimlico] Welcome to Pimlico! We're excited to help you in your transition from Stackup. This guide will help you understand the migration process, the changes you'll need to make to your existing setup, and give a brief overview of new features you will have access to. ### Migration Process for Startup and Developer Tiers If you were previously subscribed to Stackup's Startup or Developer tiers, your information has been pre-loaded onto our system for a smooth migration process. Follow these steps to migrate to Pimlico: :::steps #### Go to the Pimlico dashboard The Pimlico dashboard can be found at [https://dashboard.pimlico.io](https://dashboard.pimlico.io). ![dashboard-login](/dashboard-login.png) #### Sign up using the email address previously used on Stackup We have used your email address you used for Stackup to pre-load your information for a seamless migration process. ![dashboard-signup](/dashboard-signup.png) #### Enter your card details Once signed in, you will be prompted to enter your card details and confirm your new plan. Enter your card information to continue your subscription seamlessly. ::: After completing these steps, your Pimlico account will be fully set up and ready to use. ### Pimlico Overview With Pimlico, you'll have largely the same functionality as Stackup, with a few small differences and several new features. #### Dashboard The Pimlico dashboard offers a wide range of features to help streamline your smart account development. ![dashboard](/dashboard.png) Dashboard features include: * [Rich analytics and metrics](https://dashboard.pimlico.io/metrics) * [Logs and requests overview](https://dashboard.pimlico.io/logs) * [Debugging tools](/guides/how-to/debugging/dropped-user-operations#how-to-debug-dropped-user-operations) * [Gas grants](https://dashboard.pimlico.io/sponsorship-policies) * [Sponsorship policies](/guides/how-to/sponsorship-policies) #### API Credit system Pimlico uses a transparent API credit system, ensuring fair billing based on your actual usage. The 'worth' of each API credit is different than it is for Stackup. The API cost of each RPC call is detailed on our [pricing page](/guides/pricing). #### API Endpoint changes There are several API changes you may need to implement for a successful migration. ##### pimlico\_getUserOperationGasPrice The Pimlico bundler requires gasPrices to be fetched from the `pimlico_getUserOperationGasPrice` endpoint. This is necessary to ensure the UserOperation is sent with a sufficient gas price regardless of network conditions. ##### Separate RPC for node requests The Stackup endpoint supports both standard RPC and ERC-4337 calls, but Pimlico only supports ERC-4337. During migration, you'll need a separate RPC provider for standard calls. #### Multichain support The Pimlico API supports seamless multichain access. This means that the same API key and sponsorship policies (if configured) can be used on all chains. The API uses a standardized endpoint structure for all networks: ```ts const endpoint = `https://api.pimlico.io/v2/${chainId}/rpc?apikey=${apiKey}` ``` where `chainId` specifies the target chainId. The Pimlico bundler is currently live on 90+ chains, the full breakdown can be found on the [supported-chains page](/guides/supported-chains). #### ERC-20 Paymaster endpoint If you are using Stackup's `pm_getERC20TokenQuotes` endpoint, you can migrate to Pimlico's `pimlico_getTokenQuotes`. The Pimlico endpoint does not take in a user operation, however you can follow this [how-to guide](/guides/how-to/erc20-paymaster/how-to/use-paymaster) to achieve the same functionality. #### Origin and user agent whitelist If you were previously using Stackup's origin whitelist or user agent whitelist, you can apply the same settings by navigating to apikeys and clicking the edit button. ![apikey-settings](/apikey-settings.png) ### FAQs #### Do I need to enter my billing details to start using Pimlico? Yes, you'll be prompted to enter your billing details during the migration process. This ensures your account is fully configured and ready to use Pimlico seamlessly. #### How do I reach out if I need help? If you run into any issues or have any questions during the migration, feel free to reach out to us at [support@pimlico.io](mailto\:support@pimlico.io) or [directly through telegram](https://t.me/kristofgazso). ## Create API Key To use Pimlico's services, you'll need an API key. We recommend using our CLI for the quickest setup, but you can also use the dashboard. ### Using the CLI (Recommended) The fastest way to get started is with our CLI tool. Run the following command from your project's root directory: ```bash pnpm dlx @pimlico/cli@latest ``` This command will: * Interactively guide you through the setup process * Create your API key automatically * Add it to your `.env` file for immediate use ### Using the Dashboard Alternatively, you can create an API key through our web dashboard: 1. Go to the [Pimlico Dashboard](https://dashboard.pimlico.io/) 2. Sign up or log in to your account 3. Click **API Keys** in the sidebar 4. Click **Create API key** 5. Copy your API key and add it to your project's `.env` file :::tip Save your API key securely as you'll need it for all API requests. You can always retrieve it later from the [Dashboard](https://dashboard.pimlico.io/apikeys). ::: ### Next Steps Once you have your API key: * Add it to your `.env` file as `PIMLICO_API_KEY=your_key_here` * Start building with our [tutorials](/guides/tutorials/) ## Getting Started with Pimlico Welcome to Pimlico, the world's most advanced ERC-4337 account abstraction infrastructure platform. This guide will help you understand Pimlico's ecosystem and get you started with building applications using our tools and services. ### What is Pimlico? Pimlico provides a suite of tools and services to help you build, deploy, and manage smart accounts on Ethereum and other EVM-compatible chains. Our infrastructure powers the next generation of web3 applications by making account abstraction accessible and easy to implement. ### Core Products Pimlico offers several key products that work together to provide a complete account abstraction solution: #### permissionless.js A TypeScript library built on viem for interacting with ERC-4337 bundlers, paymasters, and user operations. It provides: * High-level smart account support for popular implementations (Safe, Kernel, Biconomy, TrustWallet, etc.) * Bundler support for all ERC-4337 actions * Gas sponsorship capabilities * User Operation utility functions * Modular and extensible architecture [Learn more about permissionless.js →](/references/permissionless) #### Bundler Our Alto Bundler is a performant, type-safe ERC-4337 bundler written in TypeScript that powers smart accounts by relaying user operations for fast and reliable on-chain inclusion. Key features include: * Full type safety * Transaction inclusion reliability * Fast transaction inclusion speed * Support for 100+ EVM chains [Learn more about our Bundler →](/references/bundler) #### Paymasters Pimlico offers two types of paymasters to abstract away gas fees for your users: 1. **Verifying Paymaster**: Load up your off-chain Pimlico balance through our dashboard and sponsor on-chain gas fees for your users across 100+ chains. 2. **ERC-20 Paymaster**: A permissionless on-chain smart contract that lets your users pay for their own gas fees using ERC-20 tokens. [Learn more about our Paymasters →](/references/paymaster) {/* ### Batua A fully customizable smart account UI component built with shadcn/ui and secured with passkeys. Batua makes it easy to add account abstraction to your application with a beautiful, ready-to-use interface. [Learn more about Batua →](https://batua.sh/) */} ### Quick Start The fastest way to get started with Pimlico is to follow our step-by-step tutorials: #### Tutorial 1: Send Your First Gasless Transaction In this tutorial, you'll learn how to: * Set up the necessary permissionless.js clients * Create a user operation * Use Pimlico's verifying paymaster to sponsor gas fees * Submit the operation on-chain with Pimlico's bundler [Start Tutorial 1 →](/references/permissionless/tutorial/tutorial-1) #### Tutorial 2: Pay for Gas with ERC-20 Tokens Learn how to use Pimlico's ERC-20 paymaster to allow users to pay for their transactions with tokens instead of ETH. [Start Tutorial 2 →](/references/permissionless/tutorial/tutorial-2) #### Getting a Pimlico API Key To use Pimlico's services, you'll need an API key. [Learn how to create one](/guides/create-api-key) ### Understanding Account Abstraction If you're new to account abstraction, we recommend starting with our conceptual guides: * [About Account Abstraction](/guides/conceptual/account-abstraction) * [ERC-4337 Explained](/guides/conceptual/erc4337) * [EIP-7702 Explained](/guides/eip7702) * [ERC-7579 Explained](/guides/conceptual/erc7579) ### Choosing a Smart Account Pimlico supports various smart account implementations. Check out our comparison guide to choose the right one for your needs: * [Smart Account Comparison](/guides/how-to/accounts/comparison) Or jump directly to implementation guides for specific accounts: * [Safe Account](/guides/how-to/accounts/use-safe-account) * [Kernel Account](/guides/how-to/accounts/use-kernel-account) * [Biconomy Account](/guides/how-to/accounts/use-biconomy-account) * [Simple Account](/guides/how-to/accounts/use-simple-account) * And more... ### Advanced Topics Once you're familiar with the basics, explore these advanced topics: * [Dapp Gas Sponsorship](/guides/how-to/dapp-gas-sponsorship) * [Parallel Transactions](/guides/how-to/parallel-transactions) * [Conditional Sponsoring](/guides/how-to/paymasters/conditional-sponsoring) ### Community and Support Join our community to get help, share your projects, and stay updated: * Follow [@pimlicoHQ](https://twitter.com/pimlicoHQ) on Twitter for project updates * Join the [discussions on 4337 Mafia](https://t.me/+emlONDb-lXI4ZTFh) * Star [permissionless.js](https://github.com/pimlicolabs/permissionless.js) and our [Alto Bundler](https://github.com/pimlicolabs/alto) on GitHub * Browse the [awesome-account-abstraction](https://github.com/4337Mafia/awesome-account-abstraction) list of resources ### Next Steps Ready to dive deeper? Check out our How-To Guides for step-by-step instructions on implementing specific features, or explore our API References for detailed technical documentation. ## Pricing Below is a comparison of the different pricing plans available for Pimlico. With Pimlico, you're able to launch without any upfront costs, and only pay for what you use with our pay-as-you-go plan, even for production applications with significant volume. We can also offer enterprise plans for users wishing to have a custom plan tailored to their needs. If you have any questions, please don't hesitate to [contact us through telegram](https://t.me/pimlicoHQ) or [through email](mailto\:support@pimlico.io) | Feature |
Free
|
Pay-as-you-go
|
Enterprise (contact us)
| | ----------------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | | Subscription Fee | $0/mo | $0/mo, card required | Custom | | Networks | Testnets: ✅ (all 25+ testnet chains)
Mainnets: ❌ | Testnets: ✅ (all 25+ testnet chains)
Mainnets: ✅ (all 25+ mainnet chains) | Testnets: ✅ (all 25+ testnet chains)
Mainnets: ✅ (all 25+ mainnet chains) | | API Requests | 1,000,000 credits / month included | 10,000,000 credits / month included, then $1 per additional 100,000 credits | Custom (incl. lower pre-paid rate) | | Approximate User Operations | \~1,300 user operations (\~950 if sponsored) / month included | \~13,000 user operations (\~9,500 if sponsored) / month included, then \~$0.0075 per additional user operation (\~$0.0105 if sponsored) | Custom (incl. lower pre-paid rate) | | Rate Limit | 500 requests / min | 5000 requests / min | Custom / Unlimited | | Bundler | ✅ | ✅ | ✅ | | Verifying Paymaster Surcharge | Testnets: Free
Mainnets: N/A | Testnets: Free
Mainnets: 10% | Custom | | Billing Usage Threshold | N/A | $1,000 / month (we bill immediately once accumulated fees reach the limit) | Custom / Unlimited | | ERC-20 Paymasters | ❌ | USDC on Ethereum, Polygon, Base, Optimism, Arbitrum | Custom (up to 300+ tokens: ✅)
Custom ERC-20 tokens: ✅ | | ERC-20 Paymaster Surcharge | N/A | 10% | Custom | | Support | Community Support: ✅ | Community Support: ✅
Private Slack/Telegram Chat: ✅ | Community Support: ✅
Private Slack/Telegram Chat: ✅
24x7x365 Phone: ✅ | | Uptime SLA | ❌ | ❌ | ✅ | ### Pay-as-you-go pricing simulation :::warning These numbers are approximate and may vary based on the actual number of API credits used. The simulation assumes 750 API credits per unsponsored user operation and 1,050 API credits per sponsored user operation. ::: import Slider from "../../components/slider" ### API credit breakdown The cost of individual API requests is measured in credits, with the breakdown of credits for each method provided below. | method | credits | | --------------------------------- | ------- | | pm\_sponsorUserOperation | 500 | | eth\_sendUserOperation | 500 | | pm\_getPaymasterData | 300 | | pm\_getPaymasterStubData | 200 | | eth\_estimateUserOperationGas | 200 | | pimlico\_getTokenQuotes | 100 | | pimlico\_getSupportedTokens | 100 | | pimlico\_getUserOperationGasPrice | 10 | | eth\_getUserOperationReceipt | 10 | | eth\_getUserOperationByHash | 10 | | pm\_validateSponsorshipPolicies | 10 | | pimlico\_getUserOperationStatus | 5 | | eth\_supportedEntryPoints | 1 | | eth\_chainId | 1 | ### FAQ #### How do we calculate the paymaster surcharge? Here's a simplified and more fluent version of your text: When you request paymaster data using `pm_getPaymasterData`, you need to include the user operation with the gas fees value. We sign the gas fees you specify because it’s the bundler’s responsibility to reject user operations that underpay them. Once the transaction is included on-chain, we use the `actualGasCost` based on the details in the `UserOperationEvent`. Here’s how `entryPoint` determines the `actualGasCost` and calculates the gas price: ```javascript const gasPrice = min(userop.maxFeePerGas, baseFee + userop.maxPriorityFeePerGas); const actualGasCost = actualGas * gasPrice; ``` At the end of the month, we add a 10% surcharge to the `actualGasCost` and bill you. The total billed amount is: ```javascript const billedAmount = actualGasCost * 1.1; // 10% surcharge ``` Why don’t we charge 10% based on what the bundler pays? Because we might not be the bundler—you’re free to use any bundler available. Since the paymaster pays the `gasCost` to the bundler, and there’s no guarantee that we will be the bundler, we must charge the full `actualGasCost` plus the surcharge. #### Where do I find a gas tank to top up my paymaster? You do not need to top up you paymaster with Pimlico. We manage the paymaster for you automatically. We track your usage and generate an invoice for you at the end of the month which you can pay with your preferred payment method. ## Supported Chains All API calls must use the JSON-RPC format and be sent to the following URL: ``` https://api.pimlico.io/v2/target_chain/rpc?apikey=your_api_key_here ``` Where chain is either the chainId or chain name. For example to access Base, both of these endpoints will work: * [https://api.pimlico.io/v2/8453/rpc?apikey=your\_api\_key\_here](https://api.pimlico.io/v2/8453/rpc?apikey=your_api_key_here) * [https://api.pimlico.io/v2/base/rpc?apikey=your\_api\_key\_here](https://api.pimlico.io/v2/base/rpc?apikey=your_api_key_here) You can also access the public endpoint without an API key ([more info](/references/bundler/public-endpoint)). ## Pimlico supports the following chains: import SupportedChains from "../../../data/supported-chains.md" import ChainDetails from "../../../data/chain-details.md"; ### Chain Details Below you can find detailed information about supported entrypoints and account implementations for each chain. For each chain, the table shows which account implementations support which entrypoint versions. ## Boosted Paymaster The Boosted paymaster is an offchain paymaster that offers faster execution times and cheaper gas fees due to requiring fewer RPC calls and requiring no paymaster data. :::info The Boosted Paymaster is available upon request. To activate this feature, please contact us at [support@pimlico.io](mailto\:support@pimlico.io) ::: ### How does Boosted user operations work? Boosted user operations are sponsored user operations without paymaster data. This allows you to save on extra RPC calls and optimize the latency. These are the RPC calls that are skipped: * `pimlico_getUserOperationGasPrice` - we set the gas price to zero, read below for why. * `pm_getPaymasterStubData` - since we don't have paymaster data, we don't need to call this. * `pm_getPaymasterData` - since we don't have paymaster data, we don't need to call this. optional: * `eth_estimateUserOperationGas` - If your `callData` is predictable, you can hard code the gas limits and skip this call as well. When you set `maxFeePerGas` and `maxPriorityFeePerGas` to zero, no balance is deducted from user operation's sender on chain. While we charge you off-chain at the end of the month when your bill gets generated. The charge is based on how much fees the bundler has to pay to include the user operation plus the paymaster surcharge for that user operation. ### How to send a Boosted User Operation To send a Boosted User Operation, you only need to: * Set `maxFeePerGas` and `maxPriorityFeePerGas` to zero * Remove the `paymaster` and `paymasterData` fields You won't need to make any changes to your application logic as the Boosted User Operation is sent using the standard eth\_sendUserOperation endpoint. In the background, Pimlico will calculate the User Operation cost offchain based on the User Operation's `gasUsed` and the bundler's `gasPrice`. #### Code Example ```ts import { createSmartAccountClient } from "permissionless" import { toSimpleSmartAccount } from "permissionless/accounts" import { http, createPublicClient, zeroAddress } from "viem" import { generatePrivateKey, privateKeyToAccount } from "viem/accounts" import { sepolia } from "viem/chains" const apiKey = "YOUR_PIMLICO_API_KEY" const pimlicoUrl = `https://api.pimlico.io/v2/${chain.id}/rpc?apikey=${apiKey}` const publicClient = createPublicClient({ chain: sepolia, transport: http() }) const account = await toSimpleSmartAccount({ owner: privateKeyToAccount(generatePrivateKey()), client: publicClient }) const pimlicoClient = createPimlicoClient({ // [!code --] chain: sepolia, // [!code --] transport: http(pimlicoUrl), // [!code --] entryPoint // [!code --] }) // [!code --] const smartAccount = createSmartAccountClient({ bundlerTransport: http(pimlicoUrl), paymaster: pimlicoClient, // [!code --] account, chain: sepolia, userOperation: { // [!code ++] estimateFeesPerGas: async () => { // [!code ++] return { // [!code ++] maxFeePerGas: 0n, // [!code ++] maxPriorityFeePerGas: 0n // [!code ++] } // [!code ++] } // [!code ++] } // [!code ++] }) // Send a mock transaction const tx = await smartAccount.sendTransaction({ to: zeroAddress, value: 0n }) console.log(`Transaction included: https://sepolia.etherscan.io/tx/${tx}`) ``` ### Further optimizations For maximum performance, hardcode your gas limits if you know your User Operation's gas usage. This eliminates the gas estimation RPC call, reducing your entire transaction to a single `eth_sendUserOperation` request. ```ts ... // Send a mock transaction with hardcoded gasLimits const tx = await smartAccount.sendTransaction({ to: zeroAddress, value: 0n, callGasLimit: 250_000n, verificationGasLimit: 250_000n, preVerificationGas: 0n }) ``` :::info * Set `preVerificationGas` to 0 as the bundler skips this check for Boosted User Operations * Don't set gas limits too high - the bundler will reject operations that exceed the block gas limit ::: ### Benchmarks | Chain | % faster | Avg. ms saved | Standard latency (ms) | Boosted latency (ms) | | ---------------- | -------: | ------------: | --------------------: | -------------------: | | OP Mainnet | 42.27% | 2,524.22 ms | 5,971.89 ms | 3,447.67 ms | | Base Sepolia | 43.15% | 3,216.54 ms | 7,454.20 ms | 4,237.65 ms | | Base | 39.23% | 2,662.73 ms | 6,786.65 ms | 4,123.93 ms | | Arbitrum One | 33.93% | 2,799.35 ms | 8,250.12 ms | 5,450.78 ms | | Arbitrum Sepolia | 41.88% | 3,881.81 ms | 9,267.81 ms | 5,386.01 ms | | Sepolia | 34.74% | 5,396.30 ms | 15,535.38 ms | 10,139.09 ms | *Benchmarks were collected by sending 100 simple ETH-transfer user operations per chain and comparing end-to-end latency between a standard sponsored flow and the Boosted flow. Real-world performance will vary depending on network conditions and callData complexity.* ## Account Abstraction Account abstraction is a feature that allows users to customize their Ethereum accounts with smart contract logic. It simplifies the account system by reducing Ethereum's two types of accounts (Externally Owned Accounts and Contract Accounts) to one type - Contract Accounts. The resulting contract accounts can initiate transactions, pay transaction fees, and have more flexibility and security than regular accounts. ### Why is account abstraction necessary? Account abstraction is essential for several reasons: * It enables users to create **smart contract wallets** with features such as multi-sig, social recovery, meta-transactions, batched transactions, gas abstraction, etc. * It allows users to **pay transaction fees with any token or asset** they want, not just ETH. This can lower the entry barriers for new users and increase the adoption of Ethereum. * It gives developers more **freedom and creativity** to design their account logic and user experience **without being constrained by the protocol rules**. This can foster innovation and diversity in the Ethereum ecosystem. ### How does account abstraction work? Account abstraction allows contract accounts to specify their validation logic instead of relying on the protocol's signature verification and nonce incrementing. This means that contract accounts can decide how to authorize transactions, how to pay gas fees, and how to prevent replay attacks using smart contract code. The leading proposal for account abstraction is [ERC-4337](https://eips.ethereum.org/EIPS/eip-4337). ERC-4337 is a specification that aims to use an entry point contract to achieve account abstraction without changing the consensus layer protocol of Ethereum. ERC-4337 simplifies the stack by modularizing the responsibilities of executing the transaction into several entities. The different entities that make up ERC-4337 are: * **Bundlers**: entities that collect UserOperations from users and submit them to an EntryPoint contract. * **EntryPoint**: a contract that receives UserOperations from bundlers, validates them, pays for gas, and executes them. * **UserOperations**: pseudo-transaction objects that are used to execute transactions with contract accounts. They contain information such as nonce, gas limit, gas price, initCode or target, data, signature, etc. * **Wallets**: smart contract accounts that can execute transactions with UserOperations. They have logic to verify signatures, update nonces, and perform actions. * **Paymasters**: contracts that pay for the gas fees of UserOperations on behalf of wallets. They can implement various payment schemes such as tokens, subscriptions, etc. For a user-friendly explanation of account abstraction, ERC-4337, and smart contract wallets, we recommend the below video by Kristof Gazso, co-author of ERC-4337 and founder of Pimlico: