Guide
How to Encode and Decode Base64
A step-by-step way to encode bytes to Base64 text and decode them back.
Base64 turns arbitrary bytes into a text-safe alphabet so they survive systems that only carry text. Encoding and decoding are exact inverses.
01Steps
- Start from the exact bytes or UTF-8 text you want to carry.
- Choose standard or URL-safe Base64 for the destination.
- Encode and copy the value without wrapping or stripping characters.
- Decode with the same alphabet and verify the bytes match.
Not encryption
Base64 is reversible by anyone. It hides nothing.
Sources
- RFC 4648: The Base16, Base32, and Base64 Data Encodings — IETF (accessed 2026-09-01)
Test this in your browser
The tool runs entirely in your browser; the input you use never leaves it.
About the author
Gampangin builds and maintains free, browser-based developer tools and the documentation that makes them trustworthy. The organization is accountable for every page published on this site.