Ready
Base64 is an alpha-numeric representation format, not an encryption protocol. It provides no cryptographic security.
Guide
Base64 is a binary-to-text encoding scheme that represents binary data (like files, images, or raw bytes) as a string of printable ASCII characters. It was defined in RFC 4648 and is used pervasively across web development, email protocols, APIs, and security systems — anywhere binary data needs to be safely embedded in a text context.
The encoding works by taking every 3 bytes of binary input and converting them into 4 Base64 characters drawn from an alphabet of 64 characters: A–Z, a–z, 0–9, +, and /. Padding = characters are appended when the input length is not a multiple of 3. The result is always approximately 33% larger than the original but guaranteed to contain no special characters that might be misinterpreted by parsers, HTML renderers, or network protocols.
Data URIs: Images, fonts, and small files can be embedded directly into HTML or CSS as Base64-encoded data URIs (data:image/png;base64,...), eliminating additional HTTP requests. This is a common optimization for small icons in email templates where external URLs may be blocked.
Email attachments (MIME): The SMTP email protocol only transmits 7-bit ASCII text. Binary files attached to emails are Base64-encoded before transmission and decoded by the recipient's email client. Without Base64, PDF attachments or images could not travel through email.
JWT tokens: JSON Web Tokens encode their header and payload sections as Base64URL (a URL-safe variant using - and _ instead of + and /). Decoding the middle section of a JWT with a Base64 decoder reveals the user claims and metadata inside the token (see also our JWT Decoder).
Basic HTTP Authentication: The Authorization: Basic <credentials> header encodes username:password as Base64 before sending. Note this is encoding, not encryption — it should only be used over HTTPS.
API responses and webhooks: Many APIs return binary content (images, documents, audio) encoded as Base64 strings within JSON responses, since JSON cannot natively represent binary data.
Storing binary data in text fields: Base64 is used to store certificate public keys in PEM files (the -----BEGIN CERTIFICATE----- format), SSH public keys, and configuration blobs in YAML/JSON config files.
Encoding converts raw text or binary to a Base64 string. Decoding reverses the process — it converts a Base64 string back to the original content. If the Base64 string is malformed (wrong padding, invalid characters), decoding will fail with an error, which is useful for verifying that a Base64 value is well-formed before using it.
The UtilsGo Base64 tool runs entirely in your browser. Credentials, private keys, and sensitive values you encode or decode are never transmitted to any server.
Executed entirely on the client side. Your code, hashes, or credentials are never transmitted over the internet.
Designed for developer comfort with a high-contrast layout, clean typography, and optimized code displays.
Complies with standard RFCs and programming specifications (JSON, Web Tokens, standard cryptographic hashes) for reliable results.
Everything runs inside your web browser. We never upload your text, files, or personal data to any servers.
No sign-ups, no subscriptions, and no usage limits. Get your results instantly in a single click.