Base64 Encoder and Decoder
Paste text to turn it into Base64, or paste a Base64 string to read what it says. Accents and emoji are handled as UTF-8, the URL-safe form is one switch away, and everything happens in your browser.
Base64
SGVsbG8sIFdvcmxkIQ==
13 bytes in UTF-8 → 20 characters
How it works
- Choose Encode or Decode.
- Paste your text or your Base64 string.
- For encoding, choose the standard or URL-safe alphabet and keep or drop the = padding.
- Copy the result.
What people use it for
Checking a token or header
Decode a piece of a JSON Web Token or a Basic authentication header to read it.
Embedding small data
Encode a short text for a configuration value or a data URL.
URL-safe strings
Switch + and / for - and _ so the result can sit in a URL or a file name.
Questions
- Is Base64 encryption?
- No. It is a way to write bytes with 64 safe characters, and anyone can reverse it. Never use it to hide a password or a secret.
- Why is the output longer than the input?
- Every 3 bytes become 4 characters, so the result is about 33 % longer, rounded up to a multiple of 4 when the = padding is kept. The tool shows the size before and after.
- What is the URL-safe form?
- The same encoding with - instead of + and _ instead of /, often without the = padding. When decoding, both alphabets are accepted and a missing padding is fine.
- What if the decoded bytes are not text?
- Base64 can carry images or other binary data. If the bytes are not valid UTF-8 text, the tool says so and shows the first 256 bytes in hexadecimal instead. Text is limited to 100 000 characters.