Overview
What is Nostr MCP Server?
A Model Context Protocol (MCP) server that gives LLMs like Claude tools to read public profiles, text notes, long-form content, and zaps from the Nostr network.
How to use Nostr MCP Server?
Clone the repo, install dependencies with npm install, build with npm run build, then add the server to your Claude for Desktop or Cursor MCP configuration. Once configured, ask Claude to use any of the seven Nostr tools.
Key features of Nostr MCP Server
- Fetch profile information by public key
- Retrieve text notes (kind 1) and long-form content (kind 30023)
- Fetch received, sent, or all zaps with payment details
- Search Nostr Implementation Possibilities (NIPs) with relevance scoring
- Supports both hex public keys and npub format
- Allows custom relays and adjustable result limits
Use cases of Nostr MCP Server
- Ask Claude to show a user’s Nostr profile and recent posts
- Retrieve long-form articles from a specific public key
- Check how many zaps a user has received or sent
- Search for NIPs about zaps, relays, or encryption
FAQ from Nostr MCP Server
What key formats are supported?
Both hex public keys and npub (NIP-19 encoded) format are fully supported; the server converts between them automatically.
Which relays does the server use by default?
The default relays are wss://relay.damus.io, wss://relay.nostr.band, wss://relay.primal.net, wss://nos.lol, wss://relay.current.fyi, and wss://nostr.bitcoiner.social.
Can I use a custom relay for a query?
Yes, you can specify any relay by adding “using relay wss://…” to your request.
What is the default query timeout?
The server has a default 8‑second timeout; you can increase it by editing the QUERY_TIMEOUT value in the source code.
Are there any known limitations?
Only public keys in hex or npub format are supported, and only a subset of relays is used by default. Timeouts may occur if a relay is slow.