MCP

Scan and reclaim dormant SOL from Solana wallets directly from AI assistants like Claude, ChatGPT, Cursor, Windsurf, and others that support the Model Context Protocol.

View the package on npm or the source on GitHub.

Prerequisites

  • Node.js 20 or later
  • A Solana keypair file (for claiming — not needed for scan-only mode)
  • A Solana RPC endpoint (a dedicated RPC is recommended for claiming)

Setup

Pick your AI client below and follow the steps. No git clone or build is needed — the server runs directly via npx.

Claude Desktop / Cursor / Windsurf

  1. Open the MCP configuration file for your client:
    • Claude Desktop — claude_desktop_config.json
    • Cursor — .cursor/mcp.json
    • Windsurf — ~/.codeium/windsurf/mcp_config.json
  2. Add the following (replace the env values with your own):
    {
      "mcpServers": {
        "unclaimed-sol": {
          "command": "npx",
          "args": ["-y", "@unclaimed-sol/mcp"],
          "env": {
            "SOLANA_KEYPAIR_PATH": "~/.config/solana/id.json",
            "SOLANA_RPC_URL": "https://your-rpc-provider.com"
          }
        }
      }
    }
  3. Save the file and restart the client.

Claude Code

Run this in your terminal:

claude mcp add unclaimed-sol \
  -e SOLANA_KEYPAIR_PATH=~/.config/solana/id.json \
  -e SOLANA_RPC_URL=https://your-rpc-provider.com \
  -- npx -y @unclaimed-sol/mcp

Verify with claude mcp list — you should see unclaimed-sol.

Codex CLI

codex mcp add unclaimed-sol \
  --env SOLANA_KEYPAIR_PATH=~/.config/solana/id.json \
  --env SOLANA_RPC_URL=https://your-rpc-provider.com \
  -- npx -y @unclaimed-sol/mcp

Verify with codex mcp list.

Scan-only mode

If you only want to scan wallets without claiming, omit the env block entirely. Only the scan_claimable_sol tool will be exposed — no transactions, no keypair needed.

{
  "mcpServers": {
    "unclaimed-sol": {
      "command": "npx",
      "args": ["-y", "@unclaimed-sol/mcp"]
    }
  }
}

Try it out

Once the server is connected, ask your AI assistant any of these:

  • “Scan my wallet for reclaimable SOL”
  • “How much SOL can I reclaim from <wallet_address>?”
  • “Do a dry run to see what I can claim”
  • “Claim my dormant token accounts”
  • “Claim rewards for my wallet”
  • “Claim my deactivated stakes”

Available tools

The server exposes up to four tools depending on whether a keypair is configured:

Tool Description Fee Keypair required
scan_claimable_sol Check how much SOL a wallet can reclaim. Read-only. — No
claim_sol Close empty token accounts and program buffers to reclaim rent SOL. Greater of 2% or the amount above 0.002 SOL per token account; 5% buffers Yes
claim_rewards Claim uncollected Pump.fun and PumpSwap cashback and creator fees. 3%, capped at 1 SOL or 100 USDC; 5% on accumulator rent Yes
claim_stakes Claim SOL from deactivated stake accounts. 3% Yes

All claim tools use a two-step flow: a dry run shows what will happen and returns a one-time execution token (valid 60 seconds), then you execute to sign and broadcast. This prevents accidental transactions. A failed or uncertain attempt requires a new dry run; the server never re-signs a transaction whose outcome is unknown.

Environment variables

Variable Default Description
SOLANA_KEYPAIR_PATH — Path to Solana keypair JSON file. Enables claiming tools.
SOLANA_RPC_URL https://api.mainnet-beta.solana.com Solana RPC endpoint. Claim dry runs read account state and simulate stake withdrawals through it; use a dedicated RPC for claiming, since the public endpoint rate-limits these reads.
SOLANA_PRIVATE_KEY — Private key as base58 or JSON byte array. Prefer SOLANA_KEYPAIR_PATH.
SOLANA_PRIORITY_FEE 1000 Priority fee in microlamports per compute unit. Max: 200,000.
UNCLAIMED_SOL_API_URL https://unclaimedsol.com Backend API URL.
UNCLAIMED_SOL_ALLOW_DEV_API — Set to true to allow a custom HTTPS API host or local HTTP during development.
UNCLAIMED_SOL_API_KEY — API key sent as Authorization: Bearer header.

Security

  • Keypair stays local — your private key never leaves your machine. Transactions are signed locally.
  • Two-step execution — every claim requires a dry run first. Execution tokens are single-use, single-wallet, and expire in 60 seconds, and are consumed before any network call.
  • Pre-sign validation — every transaction is validated before signing: program allowlist, exact instruction account layouts, fee cap enforcement.
  • Safety filtering — Cleanup requests backend safe-mode candidates, checks each one's owner, mint, balance and close authority through your RPC, and revalidates them before signing. Only empty accounts are closed.
  • HTTPS & allowlist — Claim mode connects only to unclaimedsol.com over HTTPS. Set UNCLAIMED_SOL_ALLOW_DEV_API=true to use a custom host or localhost for development.

Troubleshooting

Tools don’t appear

  • Make sure Node.js 20+ is installed (node -v).
  • Restart your AI client after editing the config file.

Claim tools are missing

  • Confirm SOLANA_KEYPAIR_PATH (or SOLANA_PRIVATE_KEY) is set in the env block. Without a keypair, only the scan tool is available.

Scan returns no results

  • Check that the wallet address is a valid Solana public key.
  • The wallet may simply not have any reclaimable accounts.

Still need help?

Reach out on Discord or open an issue on GitHub.