# Metadata
Platforms: desktop, server, mobile OS: mac, windows, linux, ios, android Introduced: 1.0 Security:
# Syntax
the base64Encode of data
# Params
- data : A string of binary data of any length.
# Examples
write base64Encode(pictureFileData) to socket thisSocket
# Description
Use the base64Encode function to encode binary file for transmission over communication channels that don't accept raw binary file.
The base64Encode function is the inverse of the base64Decode function. The encode result is generally about a third larger than the original data. The encoded string returned by base64Encode function can include uppercase and lowercase letters, digits, +, /, and =, but no other characters. Base 64-encoded data is wrapped at 72 characters, so each line of the encode data is 72 characters or (for the last or only line) fewer. The base 64 encoding scheme is often used to encode binary data for MIME mail and HTTP transfers.
For technical information about base 64 encoding, see [RFC 2045, section 6.8](https://tools.ietf.org/html/rfc2045#section-6.8).
# Tags
# See
- **keyword:** inverse, characters, line, string - **function:** numToChar, md5Digest, base64Decode - **glossary:** encode, binary file, return - **control structure:** function