Encodings

Base58 (Ripple)

Base58 with the XRP Ledger alphabet where account addresses start with r
IDbase58-ripple11 / 20base58 · 58 characters
Encoding / Base58

Base58 (Ripple)

Base58 shuffled so addresses start with r.

Overhead
+37% on random bytes
Padding
none
Standard
XRP Ledger address encoding
Used by
XRP Ledger
family 4 / 20

Sample

Out
pyGNbAREy6PZZckKw
Back
"hello world!"

Access

Importimport { base58ripple } from "@agntn/encodings/base58"
CLIencodings encode base58-ripple 'hello world!'
Tryplayground with the sample above
Kinbase58, base58check, base58-flickr

The XRP Ledger shuffled the alphabet so that r is the zero digit. Version byte zero, address starts with r. Cute.

ts
hex.encode(decode("base58-ripple", "rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh").bytes);
// "00b5f762798a53d543a014caf8b297cff8f2f937e8bf32ba9f"

That's the ledger's genesis account. Version 0x00, then a 20-byte account ID, then bf32ba9f. Those last four bytes? The double SHA-256 of everything before them. Same checksum scheme as Bitcoin. This codec decodes the alphabet and leaves the checksum to you. So a typo here decodes without complaint.