Base64 Encoder
Encode text to Base64, with UTF-8 and URL-safe support.
Base64 Encoder
Developer tool running locally in browser
What does Base64 Encoder do?
Encode any text to Base64 with correct UTF-8 handling, so accented characters, emoji and non-Latin scripts encode properly rather than throwing an error. A URL-safe variant is available for tokens and query parameters.
How to Use Base64 Encoder
- 1Type or paste textAny language, any characters.
- 2Choose the variantStandard, or URL-safe for tokens and query strings.
- 3Copy the resultOne tap to your clipboard.
Key Features
- Correct UTF-8 encoding for every language and emoji
- URL-safe variant using - and _ with padding removed
- Optional line wrapping at 76 characters for MIME
- Input and output byte counts
- Live encoding as you type
Frequently Asked Questions
What is Base64 used for?
Carrying binary data through text-only channels: email attachments, data URIs in CSS, JWT payloads, HTTP basic auth headers and JSON fields that cannot hold raw bytes.
Is Base64 encryption?
No — and treating it as such is a genuine security mistake. It is a reversible encoding with no key. Anyone can decode it instantly. Never use it to protect a secret.
What is URL-safe Base64?
A variant that replaces + with - and / with _, and drops the = padding, because those characters have special meaning in URLs. JWTs use it for exactly that reason.
Why do some tools fail on emoji?
Because the browser btoa function only accepts Latin-1 characters. This tool encodes the text to UTF-8 bytes first, which is why it handles any character correctly.
Input is processed in your browser and never transmitted. That said, treat any web page as untrusted for live production secrets — rotate anything you paste anywhere.
Related Tools
Base64 Decoder
Decode Base64 back to readable text, standard or URL-safe.
URL Encoder
Percent-encode text for safe use in URLs and query strings.
Image to Base64 Converter
Turn an image into a Base64 data URI for CSS, HTML or JSON.
JWT Decoder
Decode a JSON Web Token and inspect its header and claims.
