Last updated
Edit

base58 Encodings

XRP Ledger APIs often use a "base58" encoding with a checksum (sometimes called "Base58Check") to represent account addresses and other types of values related to cryptographic keys. This encoding is the same as the one used for Bitcoin addresses, except that the XRP Ledger uses the following dictionary: rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz.

The XRP Ledger prefixes different types of values with a specific 8-bit number before encoding them to distinguish between different data types. With the arrangement of characters in the XRP Ledger's base58 dictionary, the result is that the base58 representations for different types of encoded values start with specific letters by type.

The following table lists all the encodings the XRP Ledger uses:

Data TypeStarts WithType PrefixContent size¹Maximum characters
Account addressr0x0020 bytes35
Account public keya0x2333 bytes53
Seed value (for secret keys)s0x2116 bytes29
Validation public key or node public keyn0x1C33 bytes53

¹ Content size excludes the 1-byte type prefix.

See Also