Overview
This guide shows you how to sign messages with your Bitcoin wallet. Message signing uses the BIP-322 standard, which provides a unified way to sign messages across all Bitcoin address types. The signature is returned as a base64 string.Prerequisites
Basic Message Signing
Simple Message Signing
Whether you need to provideexternalServerKeyShares depends on how you created your wallet:
With Automatic Backup (Recommended)
If you created your wallet withbackUpToClientShareService: true, you don’t need to provide external key shares:
With Manual Backup
If you created your wallet withbackUpToClientShareService: false, you must provide external key shares:
- If your wallet was created without a password, omit the
passwordparameter - If your wallet was created with a password, you must provide it for all operations
- The password parameter is always optional in the API, but required if the wallet is password-protected
BIP-322 Message Signing
The SDK automatically uses BIP-322 for message signing, which works with both Native SegWit and Taproot addresses:Native SegWit (P2WPKH)
Taproot (P2TR)
Common Use Cases
Authentication
Data Integrity
Proof of Ownership
Understanding BIP-322
BIP-322 (Generic Signed Message Format) provides a standardized way to sign and verify messages for all Bitcoin address types:- Native SegWit (P2WPKH): Uses ECDSA signatures
- Taproot (P2TR): Uses Schnorr signatures (BIP-340)