🧭 What Does did-nostr
Do?
did-nostr
is a DID method that brings decentralized identity to Nostr. It lets you attach useful metadata and service endpoints to your Nostr public key, turning it into a portable identity hub.
Instead of just being a key that signs events, your Nostr pubkey becomes a rich identifier that can point to relays, profiles, storage, Bitcoin wallets, and much more.
💡 Example: Basic did-nostr
Document
{ "@context": [ "https://www.w3.org/ns/did/v1", "https://w3id.org/nostr/context" ], "id": "did:nostr:124c0fa99407182ece5a24fad9b7f6674902fc422843d3128d38a0afbee0fdd2", "verificationMethod": [ { "id": "#key1", "type": "SchnorrVerification2023", "controller": "did:nostr:124c0fa99407182ece5a24fad9b7f6674902fc422843d3128d38a0afbee0fdd2", "publicKeyBase16": "124c0fa99407182ece5a24fad9b7f6674902fc422843d3128d38a0afbee0fdd2" } ], "authentication": ["#key1"], "assertionMethod": ["#key1"], "service": [ { "id": "#relay", "type": "Relay", "serviceEndpoint": [ "wss://relay.nostr.example", "wss://nostr-pub.wellorder.net" ] }, { "id": "#profile", "type": "Profile", "serviceEndpoint": "https://your.site/profile.json" }, { "id": "#storage", "type": "DecentralizedStorage", "serviceEndpoint": "https://storage.example.com/alice/" }, { "id": "#inbox", "type": "Messaging", "serviceEndpoint": "https://inbox.example.org/alice" }, { "id": "#vc", "type": "VerifiableCredentialService", "serviceEndpoint": "https://vc.example.com/submit" }, { "id": "#wallet", "type": "BitcoinTaprootAddress", "serviceEndpoint": "bc1p...yourTaprootAddress" } ] }
🧩 What Kind of Services Can You Attach?
Here are just a few possibilities:
🔌 Relays
Let others know where you're active or reachable.
{ "id": "#relay", "type": "Relay", "serviceEndpoint": [ "wss://relay.nostr.example", "wss://nostr.damus.io" ] }
🧾 Consistent Profiles
Point to a hosted profile document (e.g., NIP-05
, JSON-LD, or Solid).
{ "id": "#profile", "type": "Profile", "serviceEndpoint": "https://yoursite.example/profile.json" }
📦 Storage
Advertise where your public data or documents live.
{ "id": "#storage", "type": "DecentralizedStorage", "serviceEndpoint": "https://storage.example/alice/" }
✉️ Messaging Inbox
Allow others to DM you using email-style or DIDComm-compatible protocols.
{ "id": "#inbox", "type": "Messaging", "serviceEndpoint": "https://inbox.example.org/users/alice" }
🪪 Verifiable Credentials
Issue or receive credentials, badges, or attestations.
{ "id": "#vc", "type": "VerifiableCredentialService", "serviceEndpoint": "https://vc.example.com/submit" }
🪙 Bitcoin Wallet
Include your Taproot (P2TR) address derived from your pubkey.
{ "id": "#wallet", "type": "BitcoinTaprootAddress", "serviceEndpoint": "bc1p...yourTaprootAddress" }
🤝 Why Use did-nostr
?
Because your Nostr pubkey can do more than sign events. With a did:nostr
document, you can:
- Make your key discoverable
- Declare your preferred relays
- Publish profile or storage locations
- Link to wallet or message inboxes
- Become part of a broader decentralized identity ecosystem
All of this is portable, self-hosted, and standardized.
📬 Want to Build With It?
The did-nostr
method spec is open and evolving. You can check out the latest draft here:
👉 https://nostrcg.github.io/did-nostr/
PRs welcome. Identities are yours. Let’s build the semantic web of Nostr, one DID at a time.
Top comments (0)