Encoding & Conversion

Base64 Encoder & Decoder

Encoding text should not corrupt accented characters or emoji. This tool converts text to UTF-8 bytes and then to standard Base64, with the reverse operation available on the same page. It is useful when inspecting a payload that represents text rather than a binary file. Decoding rejects malformed input and invalid UTF-8 instead of silently replacing unknown bytes. Anyone who can read the encoded value can decode it; never treat this conversion as protection for a secret.

Your workspace

Runs locally in your browser

Result

Your input is processed locally in your browser unless explicitly stated otherwise. Inputs are not saved by this tool.

How to use this tool

Enter text and choose Encode, or paste standard Base64 and choose Decode.

Example

Input

Hello 🌍

Output

SGVsbG8g8J+MjQ==

What does this tool do?

Base64 represents bytes with a restricted alphabet. It is often used in message payloads and data transport. This tool converts text to UTF-8 bytes before encoding.

Common mistakes and limitations

Base64 is not encryption. Binary files and non-UTF-8 byte sequences cannot be displayed as text here. URL-safe JWT segments should be inspected with the JWT decoder.

Bytes, padding and UTF-8

Base64 uses groups of printable characters to represent bytes. Four encoded characters normally describe three input bytes, with = padding used when the final group is incomplete. The size is therefore usually larger than the source byte sequence. This tool starts with UTF-8 bytes, so emoji and Marathi or accented text are encoded correctly rather than truncated to single-byte character codes. Decoding expects the recovered bytes to form valid UTF-8 text.

Recognize a data URL before decoding

A data URL combines a media type, an optional Base64 marker and a payload. The prefix is not part of the encoded value. For data:text/plain;base64,SGVsbG8=, the Base64 payload is SGVsbG8=. This tool handles text, not an arbitrary image or binary file viewer. JWTs use the URL-safe Base64 alphabet and often omit padding; use the JWT Decoder to inspect those structured segments instead of assuming every Base64-looking string uses the same rules.

Hello → SGVsbG8=
मराठी → UTF-8 bytes → Base64

Encoding is not protection

Anyone who obtains an encoded value can attempt to decode it. Do not place a password in a URL or client script merely because it has been Base64 encoded. Malformed input can contain misplaced padding, invalid characters or bytes that are not valid UTF-8. Check whether your source is standard Base64, Base64URL or a full data URL before changing it. Local processing avoids uploading the text through the tool, but clipboard history and browser extensions remain part of your environment.

Compare decoded bytes with expected text

If decoding succeeds but the text looks wrong, check how the source application encoded characters. A byte sequence from a legacy character set is not automatically UTF-8. Base64 itself carries no charset declaration. Preserve a copy of the encoded source and check the associated protocol or Content-Type before substituting replacement characters. Re-encoding altered text may produce a plausible-looking string that no longer represents the original bytes.

Frequently asked questions

Are accented letters supported?

Yes. UTF-8 encoding supports accented letters, Marathi text and emoji.

Related tools