... and how do you tell P2WPKH invoice addresses apart from P2PKH?
1 Answer
- P2PKH addresses are 33-34 characters long, use Base58Check encoding, and (on mainnet) start with "1".
- P2SH addresses are 34 characters long, use Base58Check encoding, and (on mainnet) start with "3".
- P2WPKH addresses are 42 characters long, use bech32 encoding, and (on mainnet) start with "bc1q".
- P2WSH addresses are 62 characters long, use bech32 encoding, and (on mainnet) start with "bc1q".
- P2TR addresses (coming in november) are 62 characters long, use bech32m encoding, and (on mainnet) start with "bc1p".
P2SH-wrapped P2WSH exists too. These cannot be distinguished from other P2SH addresses, until they are spent.