Solana MCP Server
Enables AI agents to read chain data, execute transactions, swap tokens, and manage wallets on Solana through 38 tools across 7 modules. Supports write operations with a private key and includes built-in prompts for common workflows.
README
Solana MCP Server
A production-grade Model Context Protocol server for interacting with the Solana blockchain. Gives AI agents (Claude, Cursor, etc.) the ability to read chain data, execute transactions, swap tokens, manage wallets, and more.
38 tools across 7 modules: Wallet, SPL Tokens, DeFi, NFT, Programs, Analytics, Network.
Quick Start
npx @visioneth/solana-mcp@latest
Claude Desktop / Cursor
Add to your MCP configuration:
{
"mcpServers": {
"solana-mcp": {
"command": "npx",
"args": ["-y", "@visioneth/solana-mcp@latest"],
"env": {
"SOLANA_RPC_URL": "https://api.mainnet-beta.solana.com"
}
}
}
}
For write operations (transfers, swaps, minting), add your private key:
{
"env": {
"PRIVATE_KEY": "your_base58_private_key",
"SOLANA_RPC_URL": "https://api.mainnet-beta.solana.com"
}
}
SSE Mode (Remote)
npx @visioneth/solana-mcp@latest --sse
# Server starts on http://localhost:3001
Tools
Wallet (7 tools)
| Tool | Description |
|---|---|
get_balance |
SOL balance of any address |
get_account_info |
Detailed account info |
transfer_sol |
Send SOL |
request_airdrop |
Test SOL on devnet/testnet |
get_transaction |
Transaction details by signature |
get_recent_transactions |
Recent transactions for an address |
get_wallet_address |
Public key from configured private key |
SPL Tokens (7 tools)
| Tool | Description |
|---|---|
get_token_balance |
Token balance for a wallet |
get_token_info |
Mint info (supply, decimals, authorities) |
get_token_accounts |
All token holdings |
create_token |
Create new SPL token |
mint_tokens |
Mint tokens to an address |
transfer_token |
Transfer SPL tokens |
burn_tokens |
Burn SPL tokens |
DeFi (4 tools)
| Tool | Description |
|---|---|
get_token_price |
USD price via Jupiter |
get_swap_quote |
Jupiter swap quote with routing |
execute_swap |
Execute swap on Jupiter |
get_stake_accounts |
Staking info for a wallet |
NFT (3 tools)
| Tool | Description |
|---|---|
get_nft_metadata |
On-chain NFT metadata |
get_nfts_by_owner |
All NFTs in a wallet |
get_nft_collection_info |
Collection info from sample NFT |
Programs (4 tools)
| Tool | Description |
|---|---|
is_program |
Check if address is executable |
get_program_accounts |
Accounts owned by a program |
read_account_data |
Raw account data |
identify_program |
Look up known programs |
Analytics (5 tools)
| Tool | Description |
|---|---|
get_tps |
Current transactions per second |
get_largest_token_holders |
Top holders of any token |
get_token_supply |
Total supply info |
get_sol_price |
Current SOL price in USD |
get_largest_accounts |
Biggest SOL holders |
Network (8 tools)
| Tool | Description |
|---|---|
get_epoch_info |
Current epoch and progress |
get_slot |
Current slot number |
get_block_height |
Current block height |
get_block |
Block details by slot |
get_cluster_nodes |
Validator/node info |
get_supply |
Total and circulating SOL |
get_minimum_balance_for_rent |
Rent exemption calculator |
get_health |
RPC node health check |
Prompts
Built-in prompts for common workflows:
analyze_wallet— Full wallet analysisinspect_transaction— Transaction deep-diveanalyze_token— Token due diligence with risk scoreportfolio_check— All holdings summaryswap_analysis— Pre-swap analysisanalyze_nft— NFT metadata analysisanalyze_program— Program investigationtoken_research— Comprehensive token researchnetwork_health— Network status dashboardsolana_overview— Full network overview
Safety
- Write operations require explicit network specification — the server will never default to mainnet for transactions
- Private key only needed for writes — read-only tools work without credentials
- Confirmation prompts before executing state-changing operations
- All amounts use human-readable UI values (not raw lamports)
Development
git clone https://github.com/visioneth/solana-mcp.git
cd solana-mcp
npm install
cp .env.example .env
npm run dev # stdio mode
npm run dev:sse # SSE mode
Environment Variables
| Variable | Required | Description |
|---|---|---|
PRIVATE_KEY |
For writes | Base58-encoded Solana private key |
SOLANA_RPC_URL |
No | Custom RPC endpoint (defaults to mainnet-beta) |
LOG_LEVEL |
No | DEBUG, INFO, WARN, ERROR (default INFO) |
PORT |
No | SSE server port (default 3001) |
Supported Networks
- mainnet-beta — Production (real funds)
- devnet — Development and testing
- testnet — Validator testing
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.