Install
Installhelius-wallet-kit from npm (Node.js 18+):
react >= 18react-dom >= 18@solana/web3.js ^1.98
next >= 14 is an optional peer — install it if you use the server route handler.
Setup
1
Wrap your app in the provider
Add You choose which sign-in methods your users see in the dashboard — see Configure sign-in methods. Because the client key is exposed in the browser, use a key locked to your domains via RPC Access Control.
HeliusWalletProvider near the root of your app in a client component, and pass your Helius API key. That’s the only required config — the SDK resolves your project id and key-less Secure RPC URLs automatically.app/providers.tsx
2
Import the styles
Import the SDK stylesheet once, in your root layout:
app/layout.tsx
3
(Optional) Add the server route handler
By default the SDK talks to Helius directly from the browser using your project’s key-less Secure RPC URLs — no server route required. To route your RPC, send, and transaction-history calls through your own server (and to use Sender-optimized landing and transaction history), mount the catch-all route handler at Set
/api/helius/[...path]:app/api/helius/[...path]/route.ts
HELIUS_API_KEY as a server env var; the handler injects it on those forwarded requests.The wallet bootstrap still uses your
apiKey client-side — it’s passed
to the provider config and sent to /waas/config from the browser — so
the key is present in the browser even with the route handler. Use a
domain-restricted key (set allowed origins on the key in your
dashboard) scoped to your app’s origin, and rotate it if needed. Fully
server-side key handling is on the roadmap.Next steps
Configuration
Config options and dashboard sign-in methods.
Using the wallet
Read auth state, sign, send, and read history.