Skip to main content
External wallets include MetaMask, Coinbase Wallet, Rabby, and WalletConnect-compatible mobile wallets. Connect one with wagmi, convert its active wallet client to a viem account, and use that account as the Rhinestone owner. This creates a smart account controlled by the external wallet. To use the connected address itself without a smart account, configure a plain EOA.

Reown AppKit example

1

Install the dependencies

2

Configure AppKit

Get a project ID from the Reown Dashboard, then configure AppKit once in your client application:
Wrap your application with wagmi’s WagmiProvider using wagmiAdapter.wagmiConfig, and with TanStack Query’s QueryClientProvider.
3

Configure browser authentication

An external wallet authenticates the user, not your app’s requests to Rhinestone. Keep RHINESTONE_API_KEY on your server and use short-lived JWTs in the browser:
See security for server handlers and sponsored-intent extension tokens.
4

Create the Rhinestone account

walletClientToAccount requires a wallet client with an active account. Recreate the Rhinestone account object when the connected wallet changes.
EIP-7702 requires the signer to support EIP-7702 authorizations. Do not assume every injected or WalletConnect wallet exposes that capability; use a plain EOA or a separate smart account when it does not.
For sponsored transactions, follow sponsorship setup. For the transaction lifecycle, continue to send a transaction.