x402 enables pay-per-call access to the Nansen API using cryptocurrency. No subscription or API key required. Send a request, pay with USDC on EVM (Base) or Solana, and get data back.
x402 is an open HTTP payment protocol. When you make a request to a supported endpoint without an API key, the server returns a 402 Payment Required response with payment instructions. Your client pays the specified amount in USDC, then retries the request with a payment receipt.
Copy 1. Client sends request (no API key)
2. Server returns 402 with payment details
3. Client pays USDC on Base or Solana
4. Client retries with payment receipt in header
5. Server verifies payment and returns data
Copy # 1. Initial request returns 402 with payment instructions
curl -X POST ' https://api.nansen.ai/api/v1/smart-money/holdings ' \
-H ' Content-Type: application/json ' \
-d ' {"chains": ["ethereum"]} '
# Response: 402 Payment Required
# Headers include payment details (amount, recipient, network) With an x402-compatible client, payment and retry happen automatically:
All Pro-tier endpoints are available via x402 (except labels endpoint). Pricing is based on endpoint tier.
Tier
Price Per Call
Endpoints
Token Screener, Wallet Balances, Transactions, PnL, DEX Trades, Flows, and more
Counterparties, Holders, PnL Leaderboard, Perp Leaderboard
SM Net Flow, SM Inflows, SM Holdings, SM DEX Trades
Basic Endpoints — $0.01/call
/api/v1/profiler/address/current-balance
/api/v1/profiler/address/historical-balances
/api/v1/profiler/perp-positions
/api/v1/profiler/address/transactions
/api/v1/profiler/perp-trades
/api/v1/profiler/address/related-wallets
/api/v1/profiler/address/pnl-summary
/api/v1/profiler/address/pnl
/api/v1/tgm/flow-intelligence
/api/v1/tgm/who-bought-sold
/api/v1/portfolio/defi-holdings
Premium Endpoints — $0.05/call
/api/v1/profiler/address/counterparties
/api/v1/tgm/pnl-leaderboard
/api/v1/tgm/perp-pnl-leaderboard
Smart Money Endpoints — $0.05/call
/api/v1/smart-money/netflow
/api/v1/smart-money/holdings
/api/v1/smart-money/dex-trades
Excluded Endpoints
/api/v1/labels/*; these require a Pro subscription due to the proprietary nature of Nansen's entity classification data.
/api/v1/portfolio/defi-holdings
Payment Details
Instant (onchain verification)
Base: Coinbase CDP
Solana: Payai
x402 requests have separate rate limits from API key authenticated requests.
If you exceed rate limits, you'll receive a 429 Too Many Requests response. Payments are not charged for rate-limited requests.
Q: Do I need a Nansen account? No. x402 is fully permissionless. You only need a wallet with USDC on Base or Solana.
Q: What happens if payment fails? You'll receive a 402 Payment Required response again. No data is returned until payment succeeds.
Q: Can I use x402 and an API key together? If you include a valid API key, it takes precedence and no x402 payment is required.
Q: Which networks are supported for payment? Currently Base and Solana. More networks may be added in the future.
Q: Is there a minimum balance required? No minimum. You just need enough USDC to cover the call price plus gas fees (typically < $0.01).