Base64 Encode / Decode
Client-sidePopularFeaturedNewEncode UTF-8 text to Base64 or decode Base64 back to text - instantly in your browser.
Base64 Encode / Decode converts UTF-8 text to Base64 and back in your browser. Base64 is encoding, not encryption, and your input is not uploaded.
Examples
Key takeaways
- UTF-8 safe encode and decode
- Runs fully client-side
- Not encryption - reversible by design
- Intent pages cover text, JSON, HTML, and URL use cases
What is Base64?
Base64 encodes binary or text as ASCII using 64 characters so data can travel in text-only channels.
Anyone can decode Base64. Use it for transport and embedding (JSON, email, data URLs), not for secrecy. This tool uses UTF-8 for text round-trips.
Features
UTF-8 safe
Correctly encodes and decodes Unicode text, not just ASCII.
Encode & decode
One workspace for both directions with clear primary actions.
Data URL friendly
Paste a data:...;base64,... value and decode the payload.
Copy & download
Move results into tickets, configs, or editors in one click.
How it works
Paste text or Base64
Use plain text for Encode, or a Base64 string for Decode.
Choose Encode or Decode
Encode produces Base64. Decode restores UTF-8 text.
Copy the result
Copy or download the output for use in code or payloads.
Example walkthroughs
Hello World
Encode produces SGVsbG8sIFdvcmxkIQ==.
Hello, World!
Unicode
UTF-8 bytes are Base64-encoded without mojibake.
café ☕
Use cases
Embed secrets in configs
Encode short tokens or keys for YAML/JSON configuration files.
Inspect data URLs
Decode Base64 segments from data URLs or API responses.
Debug JWT segments
Pair with JWT Decode when you need raw Base64URL inspection.
Code snippets
UTF-8 Base64 in the browser
jsThis tool uses the same UTF-8 → Base64 approach for Unicode text.
const bytes = new TextEncoder().encode(text); const b64 = btoa(String.fromCharCode(...bytes));
Common errors
Invalid character in decode
Cause: The string includes spaces, newlines, or non-Base64 characters.
Fix: Strip whitespace or paste a clean Base64 / data-URL payload.
Mojibake after decode
Cause: The original bytes were not UTF-8 text (or were Latin-1 treated as UTF-8).
Fix: Confirm the source encoding; this decoder emits UTF-8 text.
About Base64 Encode / Decode
Base64 Encode / Decode converts between plain UTF-8 text and Base64 so you can embed binary-safe payloads in JSON, APIs, emails, and data URLs. Use it whenever a channel only accepts ASCII or mangles raw binary and Unicode.
Base64 is encoding, not encryption - anyone can decode the result. Prefer it for transport and embedding, not for secrecy. This workspace uses UTF-8 for text round-trips and can decode data:...;base64,... payloads when you paste a full data URL.
Encoding and decoding run entirely in your browser. Draft notes, tokens wrapped for transport, and internal IDs never need to hit a remote encoder. Intent pages cover text-, JSON-, HTML-, and URL-specific workflows when search intent is more specific than the general tool.
Best practice: decode and inspect before trusting opaque fields. For query parameters that must remain readable URLs, use URL Encode instead of Base64 of a whole link. For JWT inspection, decode the token with JWT Decode rather than treating the middle segment as ordinary Base64 text alone.
Frequently asked questions
Is Base64 encryption?
No. Base64 is encoding for transport, not encryption. Anyone can decode it.
Does this support binary files?
This tool targets text. Paste text or Base64 text; large binary uploads are not the focus.
Is my data uploaded?
No. Encoding and decoding run entirely in your browser on this site.
Related tools
URL Encode / Decode
Percent-encode text for URLs or decode encoded query strings - private and instant.
HTML Escape
Escape and unescape HTML entities in your browser - private encode/decode, no upload.
JWT Decode
Decode JWT header and payload in your browser - inspect claims without uploading tokens.
UUID Generator
Generate UUID v4 identifiers in bulk - uppercase and hyphenless options, fully client-side.
Hash Generator
Generate SHA-1 / SHA-256 / SHA-384 / SHA-512 digests of text with Web Crypto - fully client-side.
Base64 Encode Text
Encode plain text notes, messages, and Unicode strings to Base64 in your browser - private and instant.
More in Encoding
Base64 Encode HTML
Encode HTML fragments and markup to Base64 for data URLs, emails, and embeds - decode back in your browser.
Base64 Encode JSON
Encode JSON payloads to Base64 for APIs, JWTs, and transport - decode back to UTF-8 JSON in your browser.
Base64 Encode URL
Encode URLs and query strings to Base64 for opaque links and redirects - distinct from percent-encoding.
Popular tools
JSON Formatter
Format, beautify, and minify JSON in your browser. Free, private, and instant - no upload to a server.
JSON Validator
Validate JSON instantly in your browser. See type, size, and node counts - or exact parse errors with line and column.
JSON Viewer
Explore JSON as an interactive tree with paths, types, and expandable nodes - all processed locally in your browser.
Regex Tester
Test JavaScript regular expressions against sample text - matches and groups, private in your browser.
Newest tools
HTML Email Preview
Preview HTML email with estimated client compatibility - private sandbox, no upload.
Gmail Email Preview
Preview HTML email with Gmail-focused estimated compatibility checks - private browser sandbox.
Outlook Email Preview
Preview HTML email with Outlook-focused estimated warnings for Word-based rendering risks.
Email Dark Mode Tester
Test HTML email dark-mode risks with light/dark preview chrome and color heuristics - private and client-side.
Explore more
Guides & articles
How to decode a JWT safely (without trusting claims)
Inspect JWT header and payload in your browser. Learn why decoding is not verification, and which claims matter when debugging auth.
Base64 for developers: text, JSON, URLs, and what it is not
Learn when to Base64-encode text or JSON, how that differs from URL percent-encoding, and why Base64 is not encryption.
Keyboard shortcuts
Common keyboard shortcuts for Toolverse by RS workspaces - format, copy, reset, and global search.
Privacy model (client-side tools)
How Toolverse by RS handles data: browser-first processing, what we do not upload, and how that claim maps to product behavior.
How tools work on this site
Architecture overview for Toolverse by RS: registry-driven pages, lazy panels, SEO content, and client processors.
Base64 encoding on the RS Roshi blog
Encoding tutorials and edge cases for base64 encoding.
Privacy model
Why encoding tools process data only in your browser.