05 What is the Base58 Encoding?

Binary-to-text encoding – Wikipedia

Base58 describes a method from the computer field for encoding positive integers.

The alphabet of Base58 results from that of Base62 coding by omitting the characters

  • 0 (zero),
  • O (capital o),
  • I (capital i),
  • l (small L),
  • (plus),
  • / (slash).

The resulting alphabet of length 58 is 123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz.

It thus consists only of alpha-numeric characters that are not subject to confusion.

The Base58 encoding is typically used where long integer numbers are to be converted into shorter strings and a confusion-free recognition of the address is to be ensured, for example with Flickr short URLs or with Bitcoin addresses.

The advantage of Base58 compared to Base62 and Base64 is that confusion between similar looking characters (0, O, o; 1, I, l) is excluded regardless of the font used. In addition, as with Base62 (and in contrast to Base64), the use of exclusively alpha-numeric characters (without + and /) ensures that the entire Base58 string is marked when double-clicked and that no unwanted line breaks occur when used, for example, in e-mails.

The disadvantage is a slightly longer string than with a Base62 or Base64 encoding. Furthermore, two numbers that contain the same number of bits in binary representation can have different lengths in Base58 representation because 58 is not a power of two.