Skip to main content
Learn how to create and manage Sub Accounts using Wagmi hooks and Base Account provider methods.

Prerequisites

Make sure you have:

Overview

Sub Accounts allow you to create child accounts that can spend from the parent account’s balance using Spend Permissions. This reduces the need for frequent user signatures and improves the user experience.

Creating Sub Accounts

Use the Base Account provider to create Sub Accounts:

Listing Sub Accounts

Retrieve existing Sub Accounts for the connected wallet:

Using Sub Accounts for Transactions

Once you have Sub Accounts, you can use them to perform transactions:

Complete Example

Here’s a complete component that combines all Sub Account functionality:

Learn More