Base64 is an encod­ing and decod­ing tech­nique used to con­vert binary data to an ASCII text for­mat, and vice versa. It often serves to trans­fer binary data over the Inter­net using plain text medi­ums such as email (e.g., as MIME encoded multi-parts) and instant mes­sages, or to embed binary data in text files as XML files, CSV files, PEM files and oth­ers.

Base64 works by divid­ing every three bits of binary data into six bit units. The newly cre­ated data is rep­re­sented in a 64-radix numeral sys­tem and as seven-bit ASCII text. Because each bit is divided into two bits, the con­verted data is 33 per­cent, or one-third, larger than the orig­i­nal data.

Like binary data, Base64 encoded data is not human read­able.